:root {
    --yankees-navy: #0C2340;
    --yankees-gray: #C4CED4;
    --cubs-blue: #0E3386;
    --cubs-red: #CC3433;
    --bg: #F9F8F6;
    --surface: #FFFFFF;
    --text: #1A1A1A;
    --text-secondary: #555555;
    --border: #DDD9D0;
    --accent: #0C2340;
    --accent-light: #E8ECF1;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --radius: 8px;
    --radius-lg: 12px;
    --font-sans: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --max-width: 1100px;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0.75rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--yankees-navy);
    font-weight: 700;
    font-size: 1.1rem;
}

.logo-icon {
    color: var(--cubs-red);
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.15s;
}

.main-nav a:hover {
    color: var(--accent);
}

main {
    flex: 1;
}

.hero-section {
    background: linear-gradient(135deg, var(--yankees-navy) 0%, #1a3a5c 50%, var(--cubs-blue) 100%);
    color: #FFFFFF;
    padding: 3rem 1.25rem 3.5rem;
    text-align: center;
}

.hero-content {
    max-width: 700px;
    margin: 0 auto;
}

.hero-content h1 {
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 0.75rem;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: rgba(255,255,255,0.85);
    margin-bottom: 2rem;
}

.hero-presets {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}

.preset-btn {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.25);
    color: #FFFFFF;
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius);
    cursor: pointer;
    text-align: left;
    transition: background 0.2s, border-color 0.2s;
    font-family: inherit;
    font-size: 0.9rem;
}

.preset-btn:hover {
    background: rgba(255,255,255,0.22);
    border-color: rgba(255,255,255,0.5);
}

.preset-label {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    opacity: 0.7;
    margin-bottom: 0.2rem;
}

.preset-matchup {
    font-weight: 600;
    font-size: 0.95rem;
}

.comparison-section {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 2.5rem 1.25rem;
}

.section-heading {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--yankees-navy);
}

.selector-row {
    display: flex;
    align-items: flex-end;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.player-selector {
    flex: 1;
    min-width: 200px;
}

.player-selector label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.yankees-selector label {
    color: var(--yankees-navy);
}

.cubs-selector label {
    color: var(--cubs-blue);
}

.player-dropdown {
    width: 100%;
    padding: 0.7rem 0.9rem;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: inherit;
    background: var(--surface);
    color: var(--text);
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M6 8L1 3h10z' fill='%23555'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.9rem center;
    cursor: pointer;
}

.player-dropdown:focus {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-color: var(--accent);
}

.vs-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    padding-bottom: 0.5rem;
}

.vs-text {
    font-weight: 800;
    font-size: 1.3rem;
    color: var(--cubs-red);
    background: var(--bg);
    padding: 0.3rem 0.8rem;
    border-radius: 50%;
    border: 2px solid var(--border);
}

.comparison-dashboard {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-md);
    min-height: 300px;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-secondary);
    padding: 3rem 1rem;
}

.empty-icon {
    color: var(--border);
    margin-bottom: 1rem;
}

.empty-hint {
    font-size: 0.9rem;
    margin-top: 0.5rem;
    opacity: 0.7;
}

.comparison-results {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 1.5rem;
    align-items: start;
}

.player-card {
    text-align: center;
}

.player-card h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.player-card .player-team {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.player-card.yankees h3 {
    color: var(--yankees-navy);
}

.player-card.cubs h3 {
    color: var(--cubs-blue);
}

.legacy-index {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.legacy-index .index-value {
    display: block;
}

.legacy-index .index-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-secondary);
    font-weight: 500;
}

.dimension-list {
    text-align: left;
    list-style: none;
}

.dimension-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.9rem;
}

.dimension-item:last-child {
    border-bottom: none;
}

.dimension-name {
    font-weight: 500;
}

.dimension-score {
    font-weight: 700;
    min-width: 2.5rem;
    text-align: right;
}

.score-bar {
    width: 100%;
    height: 6px;
    background: #E8ECF1;
    border-radius: 3px;
    margin-top: 0.3rem;
    overflow: hidden;
}

.score-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.4s ease;
}

.score-fill.yankees {
    background: var(--yankees-navy);
}

.score-fill.cubs {
    background: var(--cubs-blue);
}

.vs-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 3rem;
    gap: 0.5rem;
}

.vs-col .vs-badge {
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--cubs-red);
}

.hof-probability {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
}

.comparison-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1.2rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--text);
    font-family: inherit;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}

.action-btn:hover {
    background: var(--accent-light);
    border-color: var(--accent);
}

.history-section {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.25rem 2.5rem;
}

.history-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.history-entry {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.6rem 1rem;
    font-size: 0.85rem;
    cursor: pointer;
    transition: border-color 0.15s;
}

.history-entry:hover {
    border-color: var(--accent);
}

.history-empty {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.content-section {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.25rem 2.5rem;
}

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

.content-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.content-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--yankees-navy);
}

.content-card p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.faq-section {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.25rem 3rem;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.faq-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.faq-item summary {
    padding: 1rem 1.25rem;
    font-weight: 600;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.95rem;
}

.faq-item summary::after {
    content: '+';
    font-size: 1.3rem;
    color: var(--text-secondary);
    transition: transform 0.2s;
}

.faq-item[open] summary::after {
    content: '\2212';
}

.faq-item p {
    padding: 0 1.25rem 1rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.site-footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: 1.5rem 1.25rem;
    margin-top: auto;
}

.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 1rem;
}

.footer-meta {
    max-width: 500px;
}

.footer-version {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
}

.footer-disclaimer {
    font-size: 0.75rem;
    color: var(--text-secondary);
    opacity: 0.7;
}

.footer-links {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
    flex-wrap: wrap;
}

.footer-links a {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-decoration: none;
}

.footer-links a:hover {
    color: var(--accent);
    text-decoration: underline;
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 1.8rem;
    }
    .hero-subtitle {
        font-size: 1rem;
    }
    .selector-row {
        flex-direction: column;
        align-items: stretch;
    }
    .vs-divider {
        padding: 0.5rem 0;
    }
    .comparison-results {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .vs-col {
        flex-direction: row;
        padding-top: 0;
        justify-content: center;
    }
    .content-grid {
        grid-template-columns: 1fr;
    }
    .footer-inner {
        flex-direction: column;
    }
}

@media print {
    .site-header, .site-footer, .comparison-actions, .selector-row, .hero-section, .history-section, .content-section, .faq-section {
        display: none;
    }
    .comparison-dashboard {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}



/* Factory-injected deployment helpers. The AI owns the site design above this block. */
.ad-unit {
  width: min(100%, 720px);
  min-height: 120px;
  margin: 24px auto;
  display: block;
}

.legal-page {
  width: min(900px, calc(100% - 32px));
  margin: 40px auto;
}

.factory-fallback-nav {
  width: min(900px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  font-size: 0.95rem;
}

.factory-fallback-nav a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
