/* DAX Trading Signal System - Styles */

:root {
    --primary-color: #1a73e8;
    --success-color: #0f9d58;
    --danger-color: #ea4335;
    --warning-color: #fbbc04;
    --dark-bg: #1e1e1e;
    --card-bg: #ffffff;
    --text-primary: #202124;
    --text-secondary: #5f6368;
    --border-color: #e0e0e0;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.15);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    color: var(--text-primary);
}

/* Navigation */
.navbar {
    background: var(--card-bg);
    box-shadow: var(--shadow);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-info {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.status-badge {
    background: var(--success-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.status-badge i {
    font-size: 0.5rem;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.time-display {
    color: var(--text-secondary);
    font-weight: 500;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 2rem;
}

/* Live Price Card */
.live-price-card {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 1.5rem 2rem;
    margin-bottom: 2rem;
    color: white;
}

.live-price-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.live-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #ef5350;
}

.live-indicator i {
    font-size: 0.5rem;
    animation: pulse 1s infinite;
}

.live-indicator.active {
    color: #26a69a;
}

.market-status {
    font-size: 0.875rem;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.1);
}

.market-status.open {
    background: rgba(38, 166, 154, 0.2);
    color: #26a69a;
}

.market-status.closed {
    background: rgba(239, 83, 80, 0.2);
    color: #ef5350;
}

.live-price-content {
    display: flex;
    align-items: baseline;
    gap: 1rem;
}

.live-price-label {
    font-size: 1.25rem;
    font-weight: 600;
    opacity: 0.8;
}

.live-price-value {
    font-size: 2.5rem;
    font-weight: 700;
    font-family: 'Courier New', monospace;
}

.live-price-change {
    font-size: 1rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.live-price-change.positive {
    background: rgba(38, 166, 154, 0.2);
    color: #26a69a;
}

.live-price-change.negative {
    background: rgba(239, 83, 80, 0.2);
    color: #ef5350;
}

.live-price-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.75rem;
    font-size: 0.75rem;
    opacity: 0.6;
}

.delay-notice {
    font-style: italic;
}

/* Methodology Card */
.methodology-card {
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 2rem;
    border-top: 4px solid var(--primary-color);
}

.methodology-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.methodology-header h3 {
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.methodology-header h3 i {
    color: var(--primary-color);
}

.methodology-content {
    color: var(--text-primary);
    line-height: 1.7;
}

.methodology-section {
    margin-bottom: 2rem;
}

.methodology-section h4 {
    color: var(--primary-color);
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
    border-left: 3px solid var(--primary-color);
    padding-left: 0.75rem;
}

.methodology-section p {
    color: var(--text-secondary);
    text-align: justify;
}

.methodology-section ul {
    margin-top: 1rem;
    padding-left: 1.5rem;
    color: var(--text-secondary);
}

.methodology-section ul li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.considerations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.consideration-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 3px solid var(--primary-color);
}

.consideration-item i {
    color: var(--primary-color);
    font-size: 1.25rem;
    margin-top: 0.1rem;
}

.consideration-item span {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
}

.methodology-disclaimer {
    margin-top: 2rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, #fff3cd 0%, #ffeeba 100%);
    border-radius: 8px;
    border-left: 4px solid var(--warning-color);
}

.methodology-disclaimer p {
    color: #856404;
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 0;
}

.methodology-disclaimer i {
    color: var(--warning-color);
    margin-right: 0.5rem;
}

/* Signal Card */
.signal-card {
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 2rem;
    transition: transform 0.3s ease;
}

.signal-card:hover {
    box-shadow: var(--shadow-hover);
}

.signal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.signal-header h2 {
    font-size: 1.5rem;
    color: var(--text-primary);
}

.signal-timestamp {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.signal-direction {
    display: flex;
    align-items: center;
    gap: 2rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
    margin-bottom: 2rem;
}

.signal-direction.long {
    background: linear-gradient(135deg, #0f9d58 0%, #0d7a46 100%);
}

.signal-direction.short {
    background: linear-gradient(135deg, #ea4335 0%, #c42518 100%);
}

.direction-label {
    color: white;
    opacity: 0.9;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.direction-value {
    color: white;
    font-size: 2rem;
    font-weight: 700;
}

.confidence-badge {
    margin-left: auto;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-weight: 600;
}

/* Price Levels */
.price-levels {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.price-item {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
}

.price-item.take-profit {
    border-left-color: var(--success-color);
}

.price-item.stop-loss {
    border-left-color: var(--danger-color);
}

.price-label {
    display: block;
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.price-value {
    display: block;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Fibonacci Levels */
.fibonacci-levels h3 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.fib-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.fib-item {
    background: #f0f0f0;
    padding: 0.75rem;
    border-radius: 6px;
    text-align: center;
}

.fib-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
    text-transform: uppercase;
}

.fib-value {
    display: block;
    font-weight: 600;
    color: var(--text-primary);
}

/* Narrative Card */
.narrative-card {
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 2rem;
}

.narrative-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.narrative-style {
    color: var(--text-secondary);
    font-style: italic;
    font-size: 0.875rem;
}

.narrative-content {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--text-primary);
    font-style: italic;
    position: relative;
    padding: 1rem 2rem;
}

.narrative-content::before,
.narrative-content::after {
    content: '"';
    font-size: 3rem;
    color: var(--primary-color);
    opacity: 0.2;
    position: absolute;
}

.narrative-content::before {
    top: -10px;
    left: 0;
}

.narrative-content::after {
    bottom: -30px;
    right: 0;
}

/* Charts */
.charts-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.chart-card {
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 2rem;
}

.chart-card h3 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.chart-legend {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.legend-item {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.legend-item.tp-line {
    color: #26a69a;
}

.legend-item.sl-line {
    color: #ef5350;
}

/* Metrics */
.metrics-card {
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 2rem;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.metric-item {
    text-align: center;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.metric-label {
    display: block;
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.metric-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* Admin Panel */
.admin-panel {
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 2rem;
    border: 2px dashed var(--warning-color);
}

.admin-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: #1557b0;
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--text-secondary);
    color: white;
}

.btn-secondary:hover {
    background: #4a4d50;
    transform: translateY(-2px);
}

/* Footer */
.footer {
    background: var(--dark-bg);
    color: white;
    text-align: center;
    padding: 2rem;
    margin-top: 4rem;
}

.footer p {
    margin: 0.5rem 0;
}

.disclaimer {
    opacity: 0.7;
    font-size: 0.875rem;
    margin-top: 1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .charts-row {
        grid-template-columns: 1fr;
    }
    
    .price-levels {
        grid-template-columns: 1fr;
    }
    
    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .admin-buttons {
        flex-direction: column;
    }
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
