* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    background: #f8fafc;
    color: #1e293b;
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Header Styles */
.header {
    background: white;
    border-bottom: 1px solid #e2e8f0;
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
}

.app-icon {
    font-size: 24px;
}

.app-title {
    font-size: 20px;
    font-weight: 600;
    color: #1e293b;
}

.header-info {
    flex: 1;
    text-align: center;
}

.info-text {
    color: #64748b;
    font-size: 14px;
}

.crypto-dropdown-container {
    position: relative;
    min-width: 180px;
}

.selected-crypto {
    background: white;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
}

.selected-crypto:hover {
    border-color: #3b82f6;
}

.dropdown-arrow {
    font-size: 12px;
    color: #64748b;
    transition: transform 0.2s;
}

.crypto-dropdown-container.open .dropdown-arrow {
    transform: rotate(180deg);
}

.crypto-search {
    width: 100%;
    background: white;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 14px;
    color: #374151;
    outline: none;
    margin-bottom: 8px;
}

.crypto-search:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.crypto-dropdown-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    display: none;
    max-height: 300px;
    overflow-y: auto;
}

.crypto-dropdown-container.open .crypto-dropdown-list {
    display: block;
}

.crypto-dropdown-list .search-container {
    padding: 12px;
    border-bottom: 1px solid #e2e8f0;
}

.crypto-option {
    padding: 12px;
    cursor: pointer;
    border-bottom: 1px solid #f1f5f9;
    transition: background-color 0.2s;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.crypto-option:hover {
    background: #f8fafc;
}

.crypto-option:last-child {
    border-bottom: none;
}

.crypto-option.selected {
    background: #eff6ff;
    color: #1d4ed8;
    font-weight: 500;
}

.crypto-name {
    font-weight: 500;
    color: #1e293b;
}

.crypto-symbol {
    font-size: 12px;
    color: #64748b;
    background: #f1f5f9;
    padding: 2px 6px;
    border-radius: 4px;
}


/* Small responsive adjustments */
@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }
    
    .header-content {
        gap: 12px;
        padding: 0 20px;
    }
    
    .header-right {
        gap: 8px;
    }
    
    .crypto-dropdown-container {
        min-width: 140px;
    }
    
    .selected-crypto {
        font-size: 13px;
        padding: 6px 10px;
    }
    
    .crypto-search {
        font-size: 13px;
        padding: 6px 10px;
    }
    
    .modal-content {
        width: 95%;
        margin: 20px;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .model-item {
        padding: 12px;
    }
    
    .model-name {
        font-size: 14px;
    }
    
    .model-description {
        font-size: 12px;
    }
    
    .chart-controls {
        gap: 2px;
    }
}

.chart-controls {
    display: flex;
    gap: 4px;
    background: #f1f5f9;
    border-radius: 8px;
    padding: 4px;
}

.chart-btn {
    background: transparent;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.chart-btn:hover {
    background: #e2e8f0;
    color: #374151;
}

.chart-btn.active {
    background: #1e293b;
    color: white;
}

.share-btn, .export-btn {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 16px;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 36px;
}

.share-btn:hover, .export-btn:hover {
    background: #ffffff;
    border-color: #3b82f6;
    color: #3b82f6;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.export-btn:hover {
    border-color: #10b981;
    color: #10b981;
}

.share-btn:active, .export-btn:active {
    transform: translateY(0);
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.chart-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Main Content */
.main-content {
    padding: 24px 0;
}

/* Top Metrics */
.top-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.metric-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    position: relative;
    transition: all 0.2s;
    min-height: 120px;
    display: flex;
    flex-direction: column;
}

.metric-card:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border-color: #d1d5db;
}

.current-price-card {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    border-color: #3b82f6;
}

.current-price-card .metric-label,
.current-price-card .metric-subtitle {
    color: rgba(255, 255, 255, 0.9);
}

.metric-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.metric-label {
    font-size: 12px;
    font-weight: 500;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.trend-icon {
    font-size: 16px;
}

.metric-value {
    font-size: 24px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 4px;
    word-break: break-word;
    overflow-wrap: break-word;
    line-height: 1.2;
}

.metric-value.large {
    font-size: 32px;
}

.current-price-card .metric-value {
    color: white;
}

.metric-subtitle {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 8px;
}

.metric-detail {
    font-size: 14px;
    font-weight: 600;
}

.positive {
    color: #059669;
}

.negative {
    color: #dc2626;
}

.neutral {
    color: #d97706;
}

/* Content Grid */
.content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

/* Chart Section */
.chart-section {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
    height: fit-content;
    align-self: start;
    width: 100%;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.chart-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
}

.chart-period {
    font-size: 14px;
    color: #64748b;
}

.unified-chart-container {
    position: relative;
    height: 500px;
    width: 100%;
}

/* Strategy Summary */
.strategy-summary {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
}

.strategy-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.strategy-icon {
    font-size: 20px;
}

.strategy-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
}

.strategy-grid-compact {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 24px;
}

.strategy-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.strategy-label {
    font-size: 14px;
    color: #64748b;
    font-weight: 500;
}

.strategy-value {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
}

.strategy-value.highlight {
    color: #059669;
    font-weight: 700;
}

.dca-section {
    border-top: 1px solid #e2e8f0;
    padding-top: 20px;
}

.dca-section h4 {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 16px;
}

.dca-levels-compact {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.dca-item {
    display: grid;
    grid-template-columns: 40px 60px 1fr;
    gap: 12px;
    align-items: center;
    padding: 8px 12px;
    background: #f8fafc;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.dca-label {
    font-weight: 600;
    font-size: 14px;
    color: #374151;
}

.dca-percent {
    font-size: 14px;
    font-weight: 600;
    color: #059669;
}

.dca-price {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    text-align: right;
}

.dca-note {
    font-size: 12px;
    color: #64748b;
    font-style: italic;
    line-height: 1.4;
}

/* Analysis Sections */
.analysis-sections {
    display: none; /* Hide old structure */
}

.analyzers-section,
.technical-levels-section {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
}

.technical-levels-section {
    align-self: start;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.section-icon {
    font-size: 20px;
}

.model-config-btn {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.model-config-btn:hover {
    background: #f1f5f9;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal-overlay.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #64748b;
    cursor: pointer;
    padding: 4px;
    line-height: 1;
}

.modal-close:hover {
    color: #1e293b;
}

.modal-body {
    padding: 24px;
    max-height: 400px;
    overflow-y: auto;
}

.model-search-container {
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e2e8f0;
}

.model-search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 0;
    transition: all 0.2s ease;
}

.model-search-wrapper:hover {
    border-color: #cbd5e1;
    background: #f1f5f9;
}

.model-search-wrapper:focus-within {
    border-color: #3b82f6;
    background: white;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1), 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.search-icon {
    position: absolute;
    left: 14px;
    color: #64748b;
    font-size: 16px;
    pointer-events: none;
    z-index: 1;
}

.model-search-input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    background: transparent;
    color: #1e293b;
    outline: none;
    transition: all 0.2s ease;
}

.model-search-input::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.search-clear {
    position: absolute;
    right: 14px;
    color: #64748b;
    font-size: 14px;
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
}

.search-clear:hover {
    background: #e2e8f0;
    color: #374151;
}

/* No results message */
.no-results-message {
    text-align: center;
    padding: 40px 20px;
    color: #64748b;
}

.no-results-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.no-results-text {
    font-size: 16px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 4px;
}

.no-results-subtitle {
    font-size: 14px;
    color: #64748b;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
}

.btn-primary {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-primary:hover {
    background: #2563eb;
}

/* Model List Styles */
.model-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Configuration Group Styles */
.config-group-section {
    margin-bottom: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
}

.config-group-header {
    padding: 12px 16px;
    background: #f1f5f9;
    border-bottom: 1px solid #e2e8f0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s ease;
}

.config-group-header:hover {
    background: #e2e8f0;
}

.config-group-title {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: #334155;
}

.config-group-toggle {
    font-size: 12px;
    color: #64748b;
    transition: transform 0.2s ease;
}

.config-group-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    background: #ffffff;
}

.model-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
}

.model-info {
    flex: 1;
}

.model-name {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 4px;
}

.model-description {
    font-size: 14px;
    color: #64748b;
}

/* Toggle Switch Styles */
.toggle-switch {
    position: relative;
    width: 50px;
    height: 24px;
}

.toggle-input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5e1;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.toggle-input:checked + .toggle-slider {
    background-color: #3b82f6;
}

.toggle-input:checked + .toggle-slider:before {
    transform: translateX(26px);
}

.toggle-slider:hover {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.section-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
}

.analyzers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

.derivatives-section {
    margin-top: 20px;
    padding: 16px;
    border: 1px dashed #dbeafe;
    border-radius: 12px;
    background: #f8fbff;
}

.derivatives-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.derivatives-header h4 {
    margin: 0;
    font-size: 16px;
    color: #0f172a;
}

.derivatives-header p {
    margin: 2px 0 0;
    color: #64748b;
    font-size: 13px;
}

.derivatives-symbol {
    font-size: 13px;
    color: #1d4ed8;
    background: #e0e7ff;
    padding: 6px 10px;
    border-radius: 999px;
    border: 1px solid #c7d2fe;
    font-weight: 600;
}

.derivatives-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
}

.derivatives-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.deriv-card-header {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-bottom: 10px;
}

.exchange-label {
    font-weight: 600;
    color: #111827;
}

.badge {
    font-size: 11px;
    padding: 4px 8px;
    border-radius: 999px;
    border: 1px solid transparent;
}

.badge.live {
    background: #ecfdf3;
    border-color: #bbf7d0;
    color: #15803d;
}

.deriv-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.deriv-label {
    color: #475569;
    font-size: 13px;
}

.deriv-value {
    font-weight: 700;
    color: #0f172a;
}

.deriv-meta {
    margin-top: 6px;
    font-size: 12px;
    color: #94a3b8;
}

.analyzer-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0;
    position: relative;
    perspective: 1000px;
    min-height: 300px;
    overflow: hidden;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 300px;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.card-inner.flipped {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    min-height: 300px;
    top: 0;
    left: 0;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    border-radius: 8px;
    box-sizing: border-box;
}

.card-front {
    background: #ffffff;
    padding: 16px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.card-back {
    transform: rotateY(180deg);
}

/* Main Layout for columns */
.main-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.left-column,
.right-column {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* User's config button styles */
.config-toggle-btn {
    position: absolute;
    top: 16px;
    right: 50px;
    background: #ffffff;
    color: #334155;
    border: 1px solid #cbd5e1;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s, transform 0.15s, border-color 0.2s, box-shadow 0.2s;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    z-index: 10;
}

.info-toggle-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #ffffff;
    color: #334155;
    border: 1px solid #cbd5e1;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s, transform 0.15s, border-color 0.2s, box-shadow 0.2s;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    z-index: 10;
}

.info-toggle-btn:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    transform: scale(1.05);
}

.info-toggle-btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.25);
}

.info-content {
    background: #f1f5f9;
    text-align: left;
    height: 100%;
    overflow-y: auto;
    padding: 16px;
    border-radius: 8px;
}

.info-content::-webkit-scrollbar {
    width: 4px;
}

.info-content::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.info-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.info-content::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.info-title {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 12px;
}

.info-text {
    font-size: 14px;
    color: #475569;
    line-height: 1.5;
}

.config-toggle-btn:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    transform: scale(1.05);
}

.config-toggle-btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.25);
}

.config-content {
    background: #f1f5f9;
    text-align: left;
    height: 100%;
    overflow-y: auto;
    padding: 16px;
    border-radius: 8px;
}

.config-content::-webkit-scrollbar {
    width: 4px;
}

.config-content::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.config-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.config-content::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.config-section {
    margin-bottom: 12px;
}

.config-title {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
}

.config-item {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    margin-bottom: 3px;
}

.config-label {
    color: #64748b;
}

.config-value {
    color: #1e293b;
    font-weight: 500;
}

.analyzer-card h4 {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 8px 0;
    padding-right: 50px;
    line-height: 1.3;
    word-wrap: break-word;
    flex-shrink: 0;
}

.analyzer-period {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #e2e8f0;
    color: #64748b;
    font-size: 12px;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 4px;
}

.analyzer-data {
    flex: 1;
    overflow-y: auto;
    min-height: 0;
}

.analyzer-data::-webkit-scrollbar {
    width: 4px;
}

.analyzer-data::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.analyzer-data::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.analyzer-data::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.analyzer-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.analyzer-row:last-child {
    margin-bottom: 0;
}

.analyzer-row .label {
    font-size: 14px;
    color: #64748b;
}

.analyzer-row .value {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
}

/* Analyzer Table Styles */
.analyzer-table-container {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
}

.analyzer-table-container::-webkit-scrollbar {
    width: 4px;
}

.analyzer-table-container::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.analyzer-table-container::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.analyzer-table-container::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.prediction-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    flex-shrink: 0;
}

.prediction-table th {
    background: #f1f5f9;
    color: #475569;
    font-weight: 600;
    padding: 6px 4px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
    font-size: 10px;
}

.prediction-table td {
    padding: 4px 4px;
    border-bottom: 1px solid #f1f5f9;
    color: #1e293b;
}

.prediction-table tr:last-child td {
    border-bottom: none;
}

.prediction-table .positive {
    color: #059669;
    font-weight: 600;
}

.prediction-table .negative {
    color: #dc2626;
    font-weight: 600;
}

.analyzer-summary {
    padding-top: 12px;
    padding-bottom: 8px;
    border-top: 1px solid #e2e8f0;
    font-size: 13px;
    text-align: center;
    margin-top: auto;
    flex-shrink: 0;
    background: #ffffff;
}

.analyzer-summary .positive {
    color: #059669;
    font-weight: 600;
}

.analyzer-summary .negative {
    color: #dc2626;
    font-weight: 600;
}

/* Technical Levels */
.technical-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.pivot-levels {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 16px;
}

.pivot-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e2e8f0;
}

.pivot-label {
    font-weight: 600;
    color: #1e293b;
}

.pivot-value {
    font-weight: 700;
    color: #3b82f6;
}

.pivot-current {
    font-size: 14px;
    color: #64748b;
}

.resistance-support {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.levels-column {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.level-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: white;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.level-label {
    font-weight: 600;
    color: #64748b;
}

.level-value {
    font-weight: 600;
    color: #1e293b;
}

.pivot-note {
    font-size: 12px;
    color: #64748b;
    line-height: 1.4;
}

/* Bottom Sections */
.bottom-sections {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}

.risk-notes-section,
.summary-section {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
}

.risk-notes-section h3,
.summary-section h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 16px;
}

.risk-notes {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.risk-note {
    font-size: 14px;
    color: #64748b;
    line-height: 1.5;
}

.summary-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.summary-label {
    font-size: 14px;
    color: #64748b;
}

.summary-value {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .header-content {
        grid-template-columns: 1fr auto 150px auto;
        gap: 16px;
    }
    
    .content-grid,
    .analysis-sections {
        grid-template-columns: 1fr;
    }
    
    .bottom-sections {
        grid-template-columns: 1fr;
    }

    .main-layout {
        grid-template-columns: minmax(0, 1fr);
    }
    
    .left-column,
    .right-column {
        gap: 16px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
    
    .header-content {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
    
    .top-metrics {
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        gap: 12px;
    }
    
    .strategy-grid-compact {
        grid-template-columns: 1fr;
    }
    
    .analyzers-grid {
        grid-template-columns: 1fr;
    }
    
    .resistance-support {
        grid-template-columns: 1fr;
    }
    
    .unified-chart-container {
        height: 400px;
    }
}

@media (max-width: 480px) {
    .top-metrics {
        grid-template-columns: 1fr;
    }
    
    .dca-item {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 4px;
    }
    
    .pivot-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

/* Chart Styling */
.unified-chart-container canvas {
    border-radius: 8px;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.font-bold {
    font-weight: 700;
}

.text-sm {
    font-size: 14px;
}

.text-xs {
    font-size: 12px;
}

/* Trading Recommendation Styles */
.trading-recommendation {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05), rgba(147, 51, 234, 0.05));
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
    text-align: center;
}

.recommendation-label {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 8px;
    font-weight: 500;
}

.recommendation-signal {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
    display: block;
}

.recommendation-details {
    font-size: 13px;
    color: #64748b;
}

/* Signal Colors */
.signal-strong-buy {
    color: #059669;
    background: rgba(5, 150, 105, 0.1);
    border-color: rgba(5, 150, 105, 0.3);
}

.signal-buy {
    color: #16a34a;
    background: rgba(22, 163, 74, 0.1);
    border-color: rgba(22, 163, 74, 0.3);
}

.signal-neutral {
    color: #d97706;
    background: rgba(217, 119, 6, 0.1);
    border-color: rgba(217, 119, 6, 0.3);
}

.signal-sell {
    color: #dc2626;
    background: rgba(220, 38, 38, 0.1);
    border-color: rgba(220, 38, 38, 0.3);
}

.signal-strong-sell {
    color: #991b1b;
    background: rgba(153, 27, 27, 0.1);
    border-color: rgba(153, 27, 27, 0.3);
}

/* Top Movers Section */
.top-movers-section {
    background: white;
    border-radius: 12px;
    padding: 24px;
    border: 1px solid #e2e8f0;
    margin-top: 24px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.movers-content {
    margin-top: 16px;
}

.movers-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 12px;
}

.movers-tab {
    background: none;
    border: none;
    padding: 10px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: #64748b;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.movers-tab:hover {
    background: #f1f5f9;
    color: #475569;
    transform: translateY(-1px);
}

.movers-tab.active {
    background: #3b82f6;
    color: white;
    box-shadow: 0 4px 14px 0 rgba(59, 130, 246, 0.25);
}

.movers-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.mover-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.mover-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: transparent;
    transition: background-color 0.2s ease;
}

.mover-item.rising::before {
    background: #16a34a;
}

.mover-item.falling::before {
    background: #dc2626;
}

.mover-item:hover {
    background: white;
    border-color: #cbd5e1;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.mover-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mover-icon {
    font-size: 18px;
    width: 32px;
    height: 32px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.mover-item.rising .mover-icon {
    background: rgba(22, 163, 74, 0.1);
}

.mover-item.falling .mover-icon {
    background: rgba(220, 38, 38, 0.1);
}

.mover-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mover-name {
    font-weight: 600;
    font-size: 15px;
    color: #1e293b;
    line-height: 1.2;
}

.mover-symbol {
    font-size: 12px;
    color: #64748b;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mover-prediction {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    text-align: right;
}

.mover-change {
    font-weight: 700;
    font-size: 16px;
    line-height: 1.2;
}

.mover-change.positive {
    color: #16a34a;
}

.mover-change.negative {
    color: #dc2626;
}

.mover-models {
    font-size: 11px;
    color: #64748b;
    font-weight: 500;
    background: rgba(100, 116, 139, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
}

.movers-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 40px;
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
}

.loading-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid #e2e8f0;
    border-top: 2px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.movers-note {
    font-size: 11px;
    color: #64748b;
    text-align: center;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #e2e8f0;
    font-style: italic;
}

.no-data-message {
    padding: 32px;
    text-align: center;
    color: #64748b;
    font-size: 14px;
    font-style: italic;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px dashed #cbd5e1;
}

.calculation-message {
    display: flex;
    align-items: center;
    padding: 24px;
    background: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: 12px;
    margin: 16px 0;
}

.calculation-icon {
    font-size: 32px;
    margin-right: 16px;
    animation: pulse 2s infinite;
}

.calculation-text {
    flex: 1;
}

.calculation-title {
    font-size: 16px;
    font-weight: 600;
    color: #92400e;
    margin-bottom: 4px;
}

.calculation-subtitle {
    font-size: 14px;
    color: #b45309;
    line-height: 1.4;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Responsive design */
@media (max-width: 768px) {
    .mover-item {
        padding: 12px 16px;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .mover-prediction {
        align-items: flex-start;
        text-align: left;
        width: 100%;
    }
    
    .mover-header {
        width: 100%;
    }
}
