/* Railtown page: the game's own look (station signs in green, cream and brass).
   Only loaded on /games/railtown; the site header and footer keep Blurrydream's style. */

@font-face {
    font-family: 'Big Shoulders Display';
    src: url('/public/fonts/big-shoulders-display.woff2') format('woff2');
    font-weight: 100 900;
    font-display: swap;
}

body.theme-railtown {
    --bg: #0E241B;
    --surface: rgba(30, 77, 58, 0.55);
    --surface-strong: rgba(30, 77, 58, 0.8);
    --border: rgba(232, 190, 80, 0.28);
    --rt-green: #1E4D3A;
    --rt-green-dark: #12301F;
    --rt-brass: #E8BE50;
    --rt-brass-dark: #B88E2E;
    --rt-cream: #FFF4DC;
    --rt-amber: #F5B83D;
    --muted: rgba(255, 244, 220, 0.78);
    --faint: rgba(255, 244, 220, 0.55);
    --rt-font: 'Big Shoulders Display', var(--font-display);
    background:
        radial-gradient(ellipse at 50% -10%, rgba(232, 190, 80, 0.16), transparent 60%),
        linear-gradient(180deg, #12301F 0%, #0E241B 45%, #0B1C15 100%);
    background-attachment: fixed;
}

/* the animated background (petals) goes on top of the page background, so it must be see-through */
.theme-railtown #bg {
    background: transparent;
}

/* ---------- Titles in the game's typeface ---------- */

.theme-railtown .section-title {
    font-family: var(--rt-font);
    font-weight: 900;
    font-size: clamp(34px, 5vw, 52px);
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--rt-cream);
}

.theme-railtown .section-title::after {
    content: '';
    display: block;
    width: 72px;
    height: 5px;
    margin: 12px auto 0;
    border-radius: 3px;
    background: var(--rt-brass);
}

.theme-railtown .eyebrow {
    color: var(--rt-brass);
    font-family: var(--rt-font);
    font-weight: 800;
    letter-spacing: 3px;
}

.theme-railtown .breadcrumb a:hover {
    color: var(--rt-brass);
}

/* ---------- Hero: enamel station sign with a brass strip ---------- */

.rt-sign {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 8px auto 28px;
    font-size: inherit;
    line-height: 1;
}

.rt-sign-plate {
    display: block;
    padding: 10px;
    background: var(--rt-green);
    border-radius: 22px;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.5), inset 0 0 0 2px rgba(255, 255, 255, 0.06);
}

.rt-sign-inner {
    display: block;
    padding: 4px clamp(28px, 6vw, 64px) 10px;
    border: 5px solid var(--rt-cream);
    border-radius: 14px;
    font-family: var(--rt-font);
    font-weight: 900;
    font-size: clamp(64px, 13vw, 150px);
    line-height: 1;
    letter-spacing: clamp(4px, 1vw, 10px);
    color: var(--rt-cream);
    text-transform: uppercase;
}

.rt-sign-strip {
    display: block;
    margin: -4px auto 0;
    padding: 8px 22px 9px;
    background: var(--rt-brass);
    border-radius: 0 0 10px 10px;
    color: var(--rt-green-dark);
    font-family: var(--rt-font);
    font-weight: 800;
    font-size: clamp(15px, 2.2vw, 22px);
    letter-spacing: 3px;
    text-transform: uppercase;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.theme-railtown .hero-frame {
    padding: 3px;
    background: var(--rt-brass);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5), 0 0 60px rgba(232, 190, 80, 0.22);
}

.theme-railtown .hero-badge {
    background: rgba(232, 190, 80, 0.12);
    border-color: rgba(232, 190, 80, 0.5);
    color: var(--rt-brass);
}

.theme-railtown .hero-badge .pulse-dot {
    background: var(--rt-brass);
    box-shadow: 0 0 0 0 rgba(232, 190, 80, 0.6);
}

.theme-railtown .hero-description {
    color: var(--muted);
}

.theme-railtown .hero-meta li {
    font-family: var(--rt-font);
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--rt-cream);
}

/* ---------- Buttons ---------- */

.theme-railtown .btn-steam,
.theme-railtown .btn-primary {
    background: linear-gradient(135deg, var(--rt-brass-dark), var(--rt-brass));
    color: var(--rt-green-dark);
    box-shadow: 0 10px 30px rgba(232, 190, 80, 0.35);
    animation: none;
}

.theme-railtown .btn-steam .steam-icon {
    filter: brightness(0.2);
}

.theme-railtown .btn-ghost {
    background: rgba(30, 77, 58, 0.5);
    border-color: rgba(232, 190, 80, 0.55);
    color: var(--rt-cream);
}

.theme-railtown .btn-ghost:hover {
    background: rgba(232, 190, 80, 0.15);
}

/* ---------- Features as train tickets ---------- */

.theme-railtown .feature-card {
    position: relative;
    background: var(--rt-cream);
    border: none;
    border-radius: 10px;
    color: var(--rt-green-dark);
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.35);
    /* the two punched notches of a ticket */
    -webkit-mask: radial-gradient(circle 11px at 0 50%, transparent 98%, #000) left / 51% 100% no-repeat,
                  radial-gradient(circle 11px at 100% 50%, transparent 98%, #000) right / 51% 100% no-repeat;
            mask: radial-gradient(circle 11px at 0 50%, transparent 98%, #000) left / 51% 100% no-repeat,
                  radial-gradient(circle 11px at 100% 50%, transparent 98%, #000) right / 51% 100% no-repeat;
}

.theme-railtown .feature-card::before {
    content: '';
    position: absolute;
    inset: 10px;
    border: 2px dashed rgba(30, 77, 58, 0.3);
    border-radius: 6px;
    pointer-events: none;
}

.theme-railtown .feature-card:hover {
    transform: translateY(-4px) rotate(-0.6deg);
}

.theme-railtown .feature-card .feature-icon,
.theme-railtown .feature-card[style*="--accent"] .feature-icon {
    color: var(--rt-green);
    background: rgba(232, 190, 80, 0.35);
    border-color: transparent;
}

.theme-railtown .feature-title {
    font-family: var(--rt-font);
    font-weight: 900;
    font-size: 26px;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--rt-green);
}

.theme-railtown .feature-text {
    color: rgba(18, 48, 31, 0.85);
}

/* ---------- Trailer and gallery in a departures board ---------- */

.theme-railtown .video-frame,
.theme-railtown .gallery-grid {
    padding: 14px;
    background: #141A16;
    border: 3px solid var(--rt-brass);
    border-radius: 16px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.theme-railtown .video-frame video {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.theme-railtown .gallery-item {
    border-radius: 8px;
}

.theme-railtown .buy .section-subtitle,
.theme-railtown .follow .section-subtitle {
    color: var(--muted);
}

/* ---------- Phones ---------- */

@media (max-width: 600px) {
    .rt-sign {
        max-width: 100%;
    }

    .rt-sign-plate {
        max-width: 100%;
        padding: 7px;
        border-radius: 16px;
    }

    .rt-sign-inner {
        padding: 2px 18px 6px;
        border-width: 4px;
        border-radius: 10px;
        font-size: clamp(44px, 15vw, 72px);
        letter-spacing: 3px;
    }

    .rt-sign-strip {
        max-width: calc(100% - 24px);
        padding: 6px 14px 7px;
        font-size: 13px;
        letter-spacing: 1.5px;
        line-height: 1.25;
        text-align: center;
    }
}
