/* Safe Choices - Modern Dark Theme */ :root { /* Color Palette */ --bg-base: #0a0f1a; --bg-surface: #111827; --bg-elevated: #1f2937; --bg-hover: #374151; --text-primary: #f9fafb; --text-secondary: #9ca3af; --text-muted: #6b7280; --accent: #3b82f6; --accent-light: #60a5fa; --accent-dark: #2563eb; --accent-glow: rgba(59, 130, 246, 0.15); --success: #10b981; --success-bg: rgba(16, 185, 129, 0.1); --danger: #ef4444; --danger-bg: rgba(239, 68, 68, 0.1); --warning: #f59e0b; --border: rgba(255, 255, 255, 0.08); --border-accent: rgba(59, 130, 246, 0.3); /* Sizing */ --radius-sm: 6px; --radius-md: 10px; --radius-lg: 14px; --radius-xl: 20px; /* Typography */ --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; } /* Reset */ *, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; } html { font-size: 14px; scroll-behavior: smooth; } body { font-family: var(--font); background: var(--bg-base); color: var(--text-primary); line-height: 1.6; min-height: 100vh; -webkit-font-smoothing: antialiased; } /* ===== HEADER ===== */ .header { background: var(--bg-surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 100; backdrop-filter: blur(12px); } .header-content { max-width: 1440px; margin: 0 auto; padding: 0 24px; height: 64px; display: flex; align-items: center; justify-content: space-between; } .brand { display: flex; align-items: center; gap: 12px; } .brand-icon { width: 40px; height: 40px; background: linear-gradient(135deg, var(--accent), var(--accent-dark)); border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; color: white; } .brand-text h1 { font-size: 18px; font-weight: 700; letter-spacing: -0.02em; } .brand-tagline { font-size: 12px; color: var(--text-muted); font-weight: 400; } .data-badge { display: flex; align-items: center; gap: 8px; padding: 6px 12px; background: var(--bg-elevated); border-radius: var(--radius-sm); font-size: 12px; font-weight: 500; color: var(--text-secondary); } .badge-dot { width: 6px; height: 6px; background: var(--success); border-radius: 50%; animation: pulse 2s infinite; } @keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } } /* ===== MAIN LAYOUT ===== */ .main { max-width: 1440px; margin: 0 auto; padding: 24px; display: grid; grid-template-columns: 260px 1fr; gap: 24px; min-height: calc(100vh - 64px); } /* ===== SIDEBAR ===== */ .sidebar { display: flex; flex-direction: column; gap: 24px; position: sticky; top: 88px; height: fit-content; } .sidebar-section { display: flex; flex-direction: column; gap: 10px; } .section-label { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); padding-left: 4px; } /* Toggle Buttons */ .toggle-group { display: flex; flex-direction: column; gap: 6px; } .toggle-btn { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: transparent; border: 1px solid var(--border); border-radius: var(--radius-md); color: var(--text-secondary); font-size: 13px; font-weight: 500; cursor: pointer; transition: all 0.2s; } .toggle-btn:hover { background: var(--bg-elevated); color: var(--text-primary); border-color: var(--border); } .toggle-btn.active { background: var(--accent-glow); border-color: var(--border-accent); color: var(--accent-light); } .toggle-btn svg { flex-shrink: 0; opacity: 0.7; } .toggle-btn.active svg { opacity: 1; } /* Strategy Cards */ .strategy-cards { display: flex; flex-direction: column; gap: 8px; } .strategy-card { display: flex; align-items: center; gap: 12px; padding: 14px; background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-md); cursor: pointer; transition: all 0.2s; text-align: left; } .strategy-card:hover { background: var(--bg-elevated); border-color: rgba(255, 255, 255, 0.12); transform: translateX(2px); } .strategy-card.active { background: var(--accent-glow); border-color: var(--border-accent); } .strategy-icon { width: 36px; height: 36px; background: var(--bg-elevated); border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center; color: var(--text-muted); flex-shrink: 0; } .strategy-card.active .strategy-icon { background: var(--accent); color: white; } .strategy-info { display: flex; flex-direction: column; gap: 2px; } .strategy-name { font-size: 13px; font-weight: 600; color: var(--text-primary); } .strategy-desc { font-size: 11px; color: var(--text-muted); } /* Quick Stats */ .quick-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; } .quick-stat { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 12px; text-align: center; } .quick-stat-value { display: block; font-size: 18px; font-weight: 700; color: var(--accent-light); } .quick-stat-label { font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; } /* ===== CONTENT ===== */ .content { min-width: 0; } .simulation-content { display: flex; flex-direction: column; gap: 20px; } .methodology-content { display: none; } /* ===== PANELS ===== */ .panel { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 24px; } .panel-header { margin-bottom: 20px; } .panel-header h2 { display: flex; align-items: center; gap: 10px; font-size: 16px; font-weight: 600; color: var(--text-primary); } .panel-header h2 svg { color: var(--accent); } /* ===== PARAMETERS ===== */ .params-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; margin-bottom: 24px; } .param-group { display: flex; flex-direction: column; gap: 6px; } .param-label { display: flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 500; color: var(--text-secondary); } .param-hint { position: relative; width: 14px; height: 14px; background: var(--bg-elevated); border-radius: 50%; font-size: 9px; font-weight: 600; color: var(--text-muted); display: inline-flex; align-items: center; justify-content: center; cursor: help; transition: all 0.2s; } .param-hint:hover { background: var(--accent); color: white; } .param-hint::after { content: attr(data-tooltip); position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); padding: 8px 12px; background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 12px; font-weight: 400; color: var(--text-primary); white-space: nowrap; opacity: 0; visibility: hidden; transition: all 0.2s; z-index: 100; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3); } .param-hint:hover::after { opacity: 1; visibility: visible; } .param-input-wrap { position: relative; display: flex; align-items: center; } .param-input { width: 100%; padding: 8px 10px; background: var(--bg-base); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text-primary); font-size: 13px; font-weight: 500; font-family: var(--font); transition: all 0.2s; } .param-input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); } .param-input-wrap .param-input { padding-right: 36px; } .param-unit { position: absolute; right: 8px; font-size: 11px; color: var(--text-muted); pointer-events: none; } .param-select { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%239ca3af' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 8px center; padding-right: 28px; } .custom-target-input { display: none; margin-top: 8px; } .custom-target-input.visible { display: block; } /* Conditional visibility */ .threshold-only, .multi-only, .kelly-only { display: none; } .threshold-only.visible, .multi-only.visible, .kelly-only.visible { display: flex; } /* ===== RUN BUTTON ===== */ .run-container { display: flex; align-items: center; justify-content: center; gap: 16px; padding-top: 20px; border-top: 1px solid var(--border); } .run-btn { display: flex; align-items: center; gap: 10px; padding: 12px 28px; background: linear-gradient(135deg, var(--accent), var(--accent-dark)); border: none; border-radius: var(--radius-md); color: white; font-size: 14px; font-weight: 600; font-family: var(--font); cursor: pointer; transition: all 0.2s; box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3); } .run-btn:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4); } .run-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; } .run-btn.running .run-icon { display: none; } .run-btn.running .run-spinner { display: block; } .run-spinner { display: none; width: 18px; height: 18px; border: 2px solid rgba(255, 255, 255, 0.3); border-top-color: white; border-radius: 50%; animation: spin 0.8s linear infinite; } @keyframes spin { to { transform: rotate(360deg); } } .run-estimate { font-size: 12px; color: var(--text-muted); } /* ===== PROGRESS ===== */ .progress-panel { display: none; padding: 20px 24px; } .progress-panel.visible { display: block; } .progress-content { max-width: 500px; margin: 0 auto; } .progress-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-size: 13px; } #progressText { color: var(--text-primary); font-weight: 500; } #progressPercent { color: var(--accent-light); font-weight: 600; } .progress-track { height: 6px; background: var(--bg-elevated); border-radius: 3px; overflow: hidden; } .progress-fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--accent), var(--accent-light)); border-radius: 3px; transition: width 0.3s ease; } /* ===== RESULTS ===== */ .results { display: none; flex-direction: column; gap: 20px; } .results.visible { display: flex; } /* Key Metrics */ .metrics-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; } .metric-card { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; text-align: center; transition: all 0.2s; } .metric-card:hover { border-color: rgba(255, 255, 255, 0.12); } .metric-card.metric-primary { background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(59, 130, 246, 0.05)); border-color: var(--border-accent); } .metric-card.metric-survivors { background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(16, 185, 129, 0.05)); border-color: rgba(16, 185, 129, 0.3); } .metric-card.metric-risk .metric-value.high-risk { color: var(--danger); } .metric-label { font-size: 11px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); margin-bottom: 8px; } .metric-value { font-size: 28px; font-weight: 700; color: var(--text-primary); letter-spacing: -0.02em; } .metric-value.positive { color: var(--success); } .metric-value.negative { color: var(--danger); } /* Stats Panels */ .stats-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; } .stat-panel { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; } .stat-panel h3 { font-size: 13px; font-weight: 600; color: var(--text-primary); margin-bottom: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--border); } .stat-list { display: flex; flex-direction: column; gap: 12px; } .stat-item { display: flex; justify-content: space-between; align-items: center; } .stat-item .stat-label { font-size: 13px; color: var(--text-secondary); } .stat-item .stat-value { font-size: 14px; font-weight: 600; color: var(--text-primary); } .multi-stats, .threshold-stats, .kelly-stats { display: none; } .multi-stats.visible, .threshold-stats.visible, .kelly-stats.visible { display: block; } /* Charts */ .charts-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; } .chart-panel { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; } .chart-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; } .chart-header h3 { font-size: 14px; font-weight: 600; color: var(--text-primary); } .export-btn { display: flex; align-items: center; gap: 6px; padding: 6px 12px; background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text-secondary); font-size: 12px; font-weight: 500; font-family: var(--font); cursor: pointer; transition: all 0.2s; } .export-btn:hover { background: var(--bg-hover); color: var(--text-primary); } .chart-container { height: 280px; position: relative; } .multi-chart { display: none; grid-column: span 2; } .multi-chart.visible { display: block; } /* ===== METHODOLOGY ===== */ .article { max-width: 800px; margin: 0 auto; } .article-header { text-align: center; margin-bottom: 40px; padding-bottom: 32px; border-bottom: 1px solid var(--border); } .article-header h1 { font-size: 36px; font-weight: 700; color: var(--accent-light); margin-bottom: 8px; letter-spacing: -0.02em; } .article-subtitle { font-size: 16px; color: var(--text-secondary); } .article-section { margin-bottom: 36px; } .article-section h2 { font-size: 20px; font-weight: 600; color: var(--text-primary); margin-bottom: 16px; padding-bottom: 8px; border-bottom: 1px solid var(--border); } .article-section p { font-size: 15px; color: var(--text-secondary); margin-bottom: 16px; line-height: 1.7; } .article-list { margin-left: 20px; margin-bottom: 16px; } .article-list li { font-size: 15px; color: var(--text-secondary); margin-bottom: 8px; line-height: 1.6; } .article-section a { color: var(--accent-light); text-decoration: none; } .article-section a:hover { text-decoration: underline; } /* Callouts */ .callout { padding: 20px 24px; border-radius: var(--radius-lg); margin-bottom: 20px; } .callout-intro { background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(59, 130, 246, 0.05)); border-left: 3px solid var(--accent); } .callout-intro p { color: var(--text-primary); } .callout-intro p:last-child { margin-bottom: 0; } .callout-hypothesis { background: var(--bg-elevated); border: 1px solid var(--accent); } .callout-hypothesis strong { color: var(--accent-light); } /* Tags */ .tag-group { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0; } .tag { padding: 4px 12px; border-radius: 20px; font-size: 12px; font-weight: 500; } .tag-excluded { background: var(--danger-bg); color: var(--danger); } /* Model Steps */ .model-steps { display: flex; flex-direction: column; gap: 12px; } .model-step { display: flex; align-items: center; gap: 16px; padding: 16px; background: var(--bg-elevated); border-radius: var(--radius-md); } .step-num { width: 28px; height: 28px; background: var(--accent); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: white; flex-shrink: 0; } .step-text { font-size: 14px; color: var(--text-primary); } .step-text strong { color: var(--accent-light); } /* Strategy Explainer */ .strategy-explainer { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; } .strategy-box { background: var(--bg-elevated); border-radius: var(--radius-lg); padding: 20px; } .strategy-box h3 { font-size: 15px; font-weight: 600; color: var(--accent-light); margin-bottom: 8px; } .strategy-box p { font-size: 13px; color: var(--text-secondary); margin-bottom: 0; line-height: 1.6; } /* ===== RESPONSIVE ===== */ @media (max-width: 1024px) { .main { grid-template-columns: 1fr; padding: 16px; } .sidebar { position: static; flex-direction: row; flex-wrap: wrap; gap: 16px; } .sidebar-section { flex: 1; min-width: 200px; } .toggle-group { flex-direction: row; } .strategy-cards { flex-direction: row; flex-wrap: wrap; } .strategy-card { flex: 1; min-width: 180px; } .metrics-row { grid-template-columns: repeat(2, 1fr); } .charts-row { grid-template-columns: 1fr; } .multi-chart { grid-column: span 1; } } @media (max-width: 640px) { .header-content { padding: 0 16px; } .brand-tagline { display: none; } .params-grid { grid-template-columns: 1fr 1fr; } .metrics-row { grid-template-columns: 1fr; } .metric-value { font-size: 24px; } .stats-row { grid-template-columns: 1fr; } .strategy-explainer { grid-template-columns: 1fr; } .run-container { flex-direction: column; gap: 12px; } .run-btn { width: 100%; justify-content: center; } } /* Hidden utility */ .simulation-view-only.hidden { display: none !important; }