:root {
    --bg-primary: #0d0d0d;
    --bg-secondary: #161616;
    --bg-tertiary: #1f1f1f;
    --bg-elevated: #252525;
    
    --text-primary: #f5f5f5;
    --text-secondary: #a1a1a1;
    --text-muted: #6b6b6b;
    
    --accent-amber: #f59e0b;
    --accent-red: #ef4444;
    --accent-blue: #3b82f6;
    
    --border-subtle: #2a2a2a;
    --border-moderate: #383838;
    
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.6);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, var(--bg-primary) 0%, #0a0a0a 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 24px;
}

/* Page System */
.page {
    display: none;
    opacity: 0;
    animation: fadeIn 0.4s ease-out forwards;
}

.page.active {
    display: block;
}

@keyframes fadeIn {
    to { opacity: 1; }
}

/* Homepage Hero */
.hero {
    text-align: center;
    margin-bottom: 80px;
}

.title {
    font-size: 4rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--text-secondary);
    letter-spacing: 0.01em;
}

/* Preview Panel */
.preview-panel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 80px;
    padding: 40px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
}

.preview-item {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.preview-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.preview-blur {
    font-size: 1.125rem;
    color: var(--text-secondary);
    padding: 16px 20px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    filter: blur(4px);
    user-select: none;
}

/* Capabilities Grid */
.capabilities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 60px;
}

.capability-card {
    padding: 34px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin: 30px;
}

.capability-card:hover {
    border-color: var(--border-moderate);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.capability-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.capability-card p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* System Alert */
.system-alert {
    display: flex;
    gap: 20px;
    padding: 24px 28px;
    margin-bottom: 60px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.08) 0%, rgba(245, 158, 11, 0.02) 100%);
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-left: 3px solid var(--accent-amber);
    border-radius: 8px;
    margin-top: 30px;
}

.alert-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-amber);
    color: var(--bg-primary);
    border-radius: 50%;
    font-weight: 700;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.alert-content {
    flex: 1;
}

.alert-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent-amber);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.alert-text {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Primary CTA */
.cta-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    padding: 18px 32px;
    background: var(--text-primary);
    color: var(--bg-primary);
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.cta-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(245, 245, 245, 0.2);
}

.cta-text {
    letter-spacing: 0.02em;
}

.cta-icon {
    font-size: 1.25rem;
    transition: transform 0.3s ease;
}

.cta-primary:hover .cta-icon {
    transform: translateX(4px);
}

/* Page Header */
.page-header {
    margin-bottom: 48px;
}

.page-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 8px;
}

.page-subtitle {
    font-size: 1.0625rem;
    color: var(--text-secondary);
}

/* Goal Cards */
.goal-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 24px;
}

.goal-card {
    padding: 32px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.goal-card:hover {
    border-color: var(--accent-amber);
    background: var(--bg-tertiary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.goal-card.custom {
    border: 2px dashed var(--border-moderate);
}

.goal-card.custom:hover {
    border-style: solid;
}

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

.goal-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    flex: 1;
}

.goal-badge {
    padding: 4px 12px;
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.goal-badge.critical {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.goal-badge.neutral {
    background: rgba(161, 161, 161, 0.15);
    color: var(--text-secondary);
}

.goal-card p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.5;
}

.goal-meta {
    display: flex;
    gap: 16px;
    font-size: 0.875rem;
    color: var(--text-muted);
    padding-top: 16px;
    border-top: 1px solid var(--border-subtle);
}

/* Goal Mapping */
.mapping-header {
    margin-bottom: 48px;
}

.mapping-progress {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-top: 24px;
}

.progress-bar {
    flex: 1;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: 3px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-amber) 0%, var(--accent-red) 100%);
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0%;
}

.progress-text {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
    white-space: nowrap;
}

.mapping-step {
    display: none;
    animation: slideUp 0.4s ease-out;
}

.mapping-step.active {
    display: block;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mapping-step h3 {
    font-size: 1.75rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.step-description {
    font-size: 1.0625rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

/* Category Options */
.category-options {
    display: grid;
    gap: 16px;
}

.category-btn {
    padding: 24px 28px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    text-align: left;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-btn:hover {
    border-color: var(--accent-amber);
    background: var(--bg-tertiary);
}

.category-btn.selected {
    border-color: var(--accent-amber);
    background: rgba(245, 158, 11, 0.08);
}

.category-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.category-desc {
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

/* Question Blocks */
.question-block {
    margin-bottom: 36px;
}

.question-block label:first-child {
    display: block;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.radio-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.radio-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.radio-option:hover {
    border-color: var(--border-moderate);
    background: var(--bg-tertiary);
}

.radio-option input {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.radio-option span {
    flex: 1;
    color: var(--text-secondary);
}

.radio-option:has(input:checked) {
    border-color: var(--accent-amber);
    background: rgba(245, 158, 11, 0.05);
}

.radio-option:has(input:checked) span {
    color: var(--text-primary);
}

/* Model Display */
.model-display {
    padding: 40px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border: 1px solid var(--border-moderate);
    border-radius: 12px;
    text-align: center;
    margin-bottom: 40px;
}

.model-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, var(--accent-amber) 0%, var(--accent-red) 100%);
    border-radius: 12px;
}

.model-name {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.model-description {
    font-size: 1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.model-characteristics {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: 40px;
}

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

.char-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
}

.char-bar {
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
}

.char-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-amber) 0%, var(--accent-red) 100%);
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0%;
}

/* Unsupported Notice */
.unsupported-notice {
    padding: 48px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.08) 0%, rgba(239, 68, 68, 0.02) 100%);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 12px;
    text-align: center;
    margin-bottom: 32px;
}

.notice-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--danger);
    color: var(--text-primary);
    border-radius: 50%;
    font-size: 2.5rem;
    font-weight: 700;
}

.unsupported-notice h3 {
    font-size: 1.75rem;
    margin-bottom: 16px;
}

.unsupported-notice > p {
    font-size: 1.0625rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.unsupported-notice ul {
    list-style: none;
    padding: 0;
    margin: 24px auto;
    max-width: 500px;
}

.unsupported-notice li {
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-left: 3px solid var(--danger);
    margin-bottom: 8px;
    text-align: left;
    border-radius: 4px;
    color: var(--text-secondary);
}

.notice-footer {
    font-size: 0.9375rem;
    color: var(--text-muted);
    font-style: italic;
}

/* Secondary Button */
.btn-secondary {
    padding: 14px 28px;
    background: var(--bg-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border-moderate);
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    border-color: var(--text-secondary);
    background: var(--bg-tertiary);
    transform: translateY(-1px);
}

/* Diagnostic Form */
.diagnostic-form {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.input-section {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.input-label {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

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

.option-card {
    display: flex;
    flex-direction: column;
    padding: 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.option-card:hover {
    border-color: var(--border-moderate);
    background: var(--bg-tertiary);
}

.option-card input {
    display: none;
}

.option-card:has(input:checked) {
    border-color: var(--accent-amber);
    background: rgba(245, 158, 11, 0.05);
}

.option-text {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.option-desc {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* Slider Input */
.slider-input {
    padding: 24px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
}

.slider-input input[type="range"] {
    width: 100%;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: 3px;
    outline: none;
    appearance: none;
    margin-bottom: 16px;
}

.slider-input input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 20px;
    height: 20px;
    background: var(--accent-amber);
    border-radius: 50%;
    cursor: pointer;
}

.slider-labels {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
}

/* Select Input */
.input-select {
    padding: 16px 20px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    font-size: 0.9375rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.input-select:hover {
    border-color: var(--border-moderate);
}

.input-select:focus {
    outline: none;
    border-color: var(--accent-amber);
}

/* Report Header */
.report-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 48px;
}

.report-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.report-id {
    display: flex;
    gap: 8px;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Verdict Panel */
.verdict-panel {
    padding: 40px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.12) 0%, rgba(239, 68, 68, 0.04) 100%);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-left: 4px solid var(--danger);
    border-radius: 12px;
    margin-bottom: 40px;
}

.verdict-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--danger);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.verdict-text {
    font-size: 1.375rem;
    font-weight: 500;
    line-height: 1.5;
    color: var(--text-primary);
}

/* Probability Panel */
.probability-panel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 40px;
}

.prob-card {
    padding: 32px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    text-align: center;
}

.prob-value {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.prob-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.success-card .prob-value { color: var(--success); }
.burnout-card .prob-value { color: var(--warning); }
.quit-card .prob-value { color: var(--danger); }

/* Analysis Grid */
.analysis-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 40px;
}

.analysis-panel {
    padding: 32px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
}

.analysis-panel h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.factor-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.factor-list li {
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-left: 2px solid var(--border-moderate);
    border-radius: 4px;
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

/* Effort Panel */
.effort-panel {
    padding: 32px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    margin-bottom: 40px;
}

.effort-panel h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 24px;
}

.effort-comparison {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 32px;
}

.effort-row {
    display: grid;
    grid-template-columns: 140px 1fr 80px;
    gap: 16px;
    align-items: center;
}

.effort-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
}

.effort-bar {
    height: 12px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    overflow: hidden;
}

.effort-fill {
    height: 100%;
    transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0%;
}

.effort-fill.required {
    background: linear-gradient(90deg, var(--danger) 0%, var(--warning) 100%);
}

.effort-fill.current {
    background: linear-gradient(90deg, var(--warning) 0%, var(--success) 100%);
}

.effort-value {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-primary);
    text-align: right;
}

.effort-metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    padding-top: 32px;
    border-top: 1px solid var(--border-subtle);
}

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

.metric-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.metric-value {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--accent-amber);
}

/* Outcome Panel */
.outcome-panel {
    padding: 32px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-left: 4px solid var(--danger);
    border-radius: 12px;
    margin-bottom: 40px;
}

.outcome-panel h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 16px;
}

.outcome-text {
    font-size: 1.0625rem;
    line-height: 1.7;
    color: var(--text-secondary);
}

/* Decision Panel */
.decision-panel {
    padding: 32px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    margin-bottom: 40px;
}

.decision-panel h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 32px;
    text-align: center;
}

.decision-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.decision-card {
    padding: 28px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-moderate);
    border-radius: 8px;
    position: relative;
}

.decision-number {
    position: absolute;
    top: -12px;
    left: 24px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-primary);
    border: 2px solid var(--border-moderate);
    border-radius: 50%;
    font-weight: 700;
    color: var(--accent-amber);
}

.decision-card h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.decision-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.decision-list li {
    padding: 10px 12px;
    background: var(--bg-secondary);
    border-left: 2px solid var(--border-subtle);
    border-radius: 4px;
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

/* Report Actions */
.report-actions {
    display: flex;
    justify-content: center;
}

/* Responsive */
@media (max-width: 768px) {
    .title {
        font-size: 2.5rem;
    }
    
    .preview-panel {
        grid-template-columns: 1fr;
    }
    
    .goal-cards {
        grid-template-columns: 1fr;
    }
    
    .probability-panel {
        grid-template-columns: 1fr;
    }
    
    .analysis-grid,
    .decision-grid {
        grid-template-columns: 1fr;
    }
    
    .effort-row {
        grid-template-columns: 1fr;
    }
    
    .effort-metrics {
        grid-template-columns: 1fr;
    }
}
