:root {
    --bg: #08110f;
    --bg-soft: #0d1916;
    --surface: #111f1b;
    --surface-2: #172923;
    --line: rgba(190, 210, 198, 0.18);
    --text: #eef6f1;
    --muted: #a9b9af;
    --soft: #d7e7df;
    --accent: #42d392;
    --accent-2: #e6b450;
    --danger: #e86b6b;
    --shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
    --radius: 8px;
    --max: 1180px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text);
    background:
        radial-gradient(circle at 8% 0%, rgba(66, 211, 146, 0.12), transparent 32rem),
        linear-gradient(180deg, #08110f 0%, #0c1715 48%, #101712 100%);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.55;
}

body.menu-open {
    overflow: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
select {
    font: inherit;
}

.site-header {
    position: fixed;
    inset: 0 0 auto;
    z-index: 50;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(8, 17, 15, 0.78);
    backdrop-filter: blur(18px);
}

.nav-inner {
    width: min(var(--max), calc(100% - 36px));
    min-height: 68px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: 0;
}

.brand-mark {
    position: relative;
    width: 44px;
    height: 44px;
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 15px;
    background: #131d36;
    box-shadow: inset 0 0 0 1px rgba(106, 162, 255, 0.1), 0 10px 24px rgba(0, 0, 0, 0.18);
}

.brand-mark::before {
    content: "";
    position: absolute;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: radial-gradient(circle at 50% 42%, rgba(255, 255, 255, 0.18), rgba(10, 14, 24, 0.78) 68%);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.brand-icon {
    position: relative;
    z-index: 1;
    font-size: 22px;
    line-height: 1;
    transform: translateY(1px);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 6px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 12px;
    border-radius: 999px;
    color: var(--muted);
    font-size: 0.94rem;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
}

.menu-btn {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
    cursor: pointer;
}

.hero {
    min-height: 92svh;
    display: grid;
    align-items: end;
    padding: 110px 0 56px;
    background-image:
        linear-gradient(90deg, rgba(8, 17, 15, 0.94), rgba(8, 17, 15, 0.62) 40%, rgba(8, 17, 15, 0.24) 70%),
        url("assets/hero-art.png");
    background-size: cover;
    background-position: center;
}

.hero-inner,
.section-inner,
.footer-inner {
    width: min(var(--max), calc(100% - 36px));
    margin: 0 auto;
}

.eyebrow {
    margin: 0 0 14px;
    color: var(--accent);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero h1,
.page-title {
    max-width: 760px;
    margin: 0;
    font-size: clamp(3.4rem, 9vw, 7.5rem);
    line-height: 0.94;
    letter-spacing: 0;
}

.hero-copy,
.lead {
    max-width: 650px;
    margin: 22px 0 0;
    color: var(--soft);
    font-size: clamp(1.05rem, 2vw, 1.28rem);
}

.hero-actions,
.action-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 30px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: 999px;
    cursor: pointer;
    color: #06100c;
    background: var(--accent);
    font-weight: 800;
}

.btn.secondary {
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.18);
}

.live-strip {
    width: min(var(--max), calc(100% - 36px));
    margin: -28px auto 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: rgba(13, 25, 22, 0.9);
    box-shadow: var(--shadow);
}

.metric {
    min-height: 116px;
    padding: 22px;
    border-right: 1px solid var(--line);
}

.metric:last-child {
    border-right: 0;
}

.metric-value {
    display: block;
    color: var(--text);
    font-size: clamp(1.8rem, 4vw, 3rem);
    line-height: 1;
    font-weight: 850;
}

.metric-label {
    display: block;
    margin-top: 10px;
    color: var(--muted);
    font-size: 0.9rem;
}

.section {
    padding: 92px 0;
}

.section.alt {
    background: rgba(255, 255, 255, 0.025);
}

.section-head {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(280px, 0.55fr);
    gap: 40px;
    align-items: end;
    margin-bottom: 34px;
}

.section-title {
    margin: 0;
    font-size: clamp(2rem, 4vw, 4rem);
    line-height: 1;
}

.section-copy {
    margin: 0;
    color: var(--muted);
}

.overview-grid {
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 28px;
    align-items: stretch;
}

.panel {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(17, 31, 27, 0.82);
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.18);
}

.panel-pad {
    padding: 26px;
}

.route-canvas {
    min-height: 520px;
    padding: 24px;
    overflow: hidden;
}

.route-track {
    position: relative;
    min-height: 470px;
}

.route-track::before {
    content: "";
    position: absolute;
    left: 28px;
    top: 16px;
    bottom: 16px;
    width: 3px;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--accent), rgba(230, 180, 80, 0.9));
}

.station-row {
    position: relative;
    display: grid;
    grid-template-columns: 58px 1fr auto;
    align-items: center;
    gap: 14px;
    min-height: 74px;
    padding: 12px 14px 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    color: var(--text);
    cursor: pointer;
}

.station-row:last-child {
    border-bottom: 0;
}

.station-dot {
    position: relative;
    z-index: 1;
    width: 58px;
    height: 42px;
    display: grid;
    place-items: center;
    color: #06100c;
    font-weight: 850;
}

.station-dot::before {
    content: "";
    position: absolute;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 5px rgba(66, 211, 146, 0.14);
    z-index: -1;
}

.station-name {
    font-weight: 800;
}

.station-meta {
    color: var(--muted);
    font-size: 0.88rem;
}

.station-chip,
.tag {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border: 1px solid rgba(66, 211, 146, 0.28);
    border-radius: 999px;
    color: var(--accent);
    background: rgba(66, 211, 146, 0.08);
    font-size: 0.8rem;
    font-weight: 750;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.field {
    display: grid;
    gap: 8px;
    margin-bottom: 16px;
}

.field label {
    color: var(--muted);
    font-size: 0.9rem;
}

select {
    width: 100%;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    color: var(--text);
    background: #0a1411;
}

.result {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.result-line,
.status-line {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--muted);
}

.result-line strong,
.status-line strong {
    color: var(--text);
}

.line-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}

.line-link {
    min-height: 168px;
    padding: 20px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.line-link:hover {
    transform: translateY(-4px);
    border-color: rgba(66, 211, 146, 0.5);
    background: var(--surface-2);
}

.line-code {
    color: var(--accent-2);
    font-weight: 900;
    font-size: 1.8rem;
}

.line-link h3 {
    margin: 16px 0 8px;
}

.line-link p {
    margin: 0;
    color: var(--muted);
    font-size: 0.92rem;
}

.chart-wrap {
    min-height: 360px;
}

.passenger-bars {
    min-height: 330px;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    align-items: end;
    gap: 12px;
    padding: 20px 8px 4px;
}

.bar-item {
    display: grid;
    grid-template-rows: 1fr auto;
    align-items: end;
    min-width: 0;
    height: 300px;
    gap: 10px;
}

.bar-value {
    width: 100%;
    min-height: 12px;
    border-radius: 5px 5px 0 0;
    background: linear-gradient(180deg, var(--accent), rgba(66, 211, 146, 0.22));
    border: 1px solid rgba(66, 211, 146, 0.35);
}

.bar-label {
    color: var(--muted);
    font-size: 0.78rem;
    text-align: center;
}

.page-hero {
    padding: 130px 0 48px;
    background:
        linear-gradient(135deg, rgba(66, 211, 146, 0.14), transparent 30rem),
        #08110f;
}

.page-hero .lead {
    max-width: 760px;
}

.line-visual {
    position: relative;
    min-height: 430px;
    padding: 0;
    overflow: hidden;
}

.line-map-stack {
    display: grid;
    gap: 16px;
}

.line-info-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.line-info-strip .status-line {
    min-height: 78px;
    display: grid;
    align-content: center;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(17, 31, 27, 0.82);
}

.dynamic-map {
    display: block;
    width: 100%;
    min-height: 430px;
    border-radius: var(--radius);
    background:
        radial-gradient(circle at 28% 20%, rgba(58, 126, 255, 0.16), transparent 20rem),
        #101827;
}

.route-shadow {
    fill: none;
    stroke: rgba(38, 73, 132, 0.4);
    stroke-width: 15;
    stroke-linecap: round;
    filter: url(#mapGlow);
}

.route-line {
    fill: none;
    stroke: url(#routeBlue);
    stroke-width: 9;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: url(#mapGlow);
}

.route-line-animated {
    stroke-dasharray: 1300;
    stroke-dashoffset: 1300;
    animation: routeDraw 1.8s ease-out forwards;
}

.branch-line {
    fill: none;
    stroke: #5f9dff;
    stroke-width: 4;
    stroke-linecap: round;
    stroke-dasharray: 4 7;
    animation: branchFlow 1.4s linear infinite;
}

.map-station {
    filter: url(#mapGlow);
}

.station-halo {
    fill: rgba(238, 246, 241, 0.96);
}

.station-ring {
    fill: none;
    stroke: #6aa2ff;
    stroke-width: 5;
}

.station-core {
    fill: #377bff;
}

.map-station.is-transfer .station-halo {
    animation: stationPulse 1.9s ease-in-out infinite;
}

.map-station text {
    fill: rgba(238, 246, 241, 0.92);
    font-size: 16px;
    font-weight: 800;
    paint-order: stroke;
    stroke: rgba(16, 24, 39, 0.86);
    stroke-width: 4px;
}

.route-train {
    fill: #eaf3ff;
    stroke: #377bff;
    stroke-width: 5;
    filter: url(#mapGlow);
}

@keyframes routeDraw {
    to {
        stroke-dashoffset: 0;
    }
}

@keyframes branchFlow {
    to {
        stroke-dashoffset: -22;
    }
}

@keyframes stationPulse {
    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.12);
        opacity: 0.78;
    }
}

.station-layout {
    display: grid;
    grid-template-columns: 0.72fr 1.28fr;
    gap: 28px;
    align-items: start;
}

.station-aside {
    position: sticky;
    top: 92px;
}

.station-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.info-list {
    display: grid;
    gap: 12px;
}

.info-item {
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.info-item small {
    display: block;
    color: var(--muted);
}

.info-item strong {
    display: block;
    margin-top: 4px;
    font-size: 1.06rem;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.site-footer {
    padding: 50px 0 34px;
    border-top: 1px solid var(--line);
    background: #07100e;
}

.footer-grid {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) auto minmax(240px, 0.6fr) auto;
    gap: 34px;
}

.footer-title {
    margin: 0 0 10px;
    font-size: 1.25rem;
}

.footer-copy,
.footer-links,
.footer-contact,
.visit-stats {
    color: var(--muted);
    font-size: 0.92rem;
}

.footer-links,
.footer-contact {
    display: grid;
    gap: 8px;
}

.footer-contact h3 {
    margin: 0 0 4px;
    color: var(--text);
    font-size: 1rem;
}

.visit-stats {
    display: grid;
    gap: 8px;
    min-width: 210px;
}

.visit-stats strong {
    color: var(--text);
}

.modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 22px;
    background: rgba(0, 0, 0, 0.62);
}

.modal.active {
    display: flex;
}

.modal-content {
    width: min(560px, 100%);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow);
}

.modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 20px 22px;
    border-bottom: 1px solid var(--line);
}

.modal-title {
    margin: 0;
    font-size: 1.55rem;
}

.modal-close {
    width: 38px;
    height: 38px;
    border: 1px solid var(--line);
    border-radius: 50%;
    color: var(--text);
    background: transparent;
    cursor: pointer;
}

.modal-body {
    padding: 22px;
}

@media (max-width: 900px) {
    .section-head,
    .overview-grid,
    .line-map-stack,
    .line-info-strip,
    .station-layout,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .live-strip,
    .line-grid,
    .tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .station-aside {
        position: static;
    }
}

@media (max-width: 720px) {
    .nav-inner {
        min-height: 62px;
    }

    .menu-btn {
        display: inline-grid;
        place-items: center;
    }

    .nav-links {
        position: fixed;
        inset: 62px 0 auto;
        display: none;
        padding: 18px;
        border-bottom: 1px solid var(--line);
        background: rgba(8, 17, 15, 0.98);
    }

    .nav-links.active {
        display: grid;
    }

    .nav-links a {
        min-height: 44px;
    }

    .hero {
        min-height: 86svh;
        background-position: 63% center;
    }

    .live-strip,
    .line-grid,
    .tools-grid,
    .station-list {
        grid-template-columns: 1fr;
    }

    .metric {
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .metric:last-child {
        border-bottom: 0;
    }

    .station-row {
        grid-template-columns: 52px 1fr;
    }

    .station-chip {
        justify-self: start;
        grid-column: 2;
    }

    .chart-wrap {
        min-height: 260px;
    }

    .passenger-bars {
        min-height: 250px;
        gap: 6px;
    }

    .bar-item {
        height: 220px;
    }

    .bar-label {
        font-size: 0.68rem;
    }
}
