
.train-page {
    --label-space: 1.9rem;
    --field-height: 3.1rem;
    box-sizing: border-box;
    max-width: 76rem;
    margin: 0 auto;
    padding: 1rem 0.8rem 2.5rem;
    color: #000080;
}

.train-page *,
.train-page *::before,
.train-page *::after {
    box-sizing: border-box;
}

.train-page h1,
.train-page h2,
.train-page h3,
.train-page p {
    line-height: 1.4;
}

.hero-card,
.finder-card,
.popular-card,
.faq-card,
.content-card,
.footer-links-card {
    max-width: 100%;
    margin: 0 auto 1.25rem;
    padding: 1.15rem 1rem;
    border-radius: 1rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(245, 248, 255, 0.96));
    box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 128, 0.08);
    overflow: visible;
}

.hero-card {
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(16rem, 0.88fr);
    gap: 1.3rem;
    align-items: center;
}

.hero-card h1 {
    margin: 0 0 0.5rem;
    font-size: clamp(2rem, 3vw, 2.8rem);
}

.hero-card h2,
.finder-card h2,
.popular-card h2,
.faq-card h2,
.content-card h2 {
    margin: 0 0 0.85rem;
    text-align: left;
}

.hero-card h2 {
    font-size: clamp(1rem, 1.7vw, 1.25rem);
}

.hero-card p {
    margin: 0;
    max-width: 43rem;
}

.hero-image-wrap {
    margin: 0;
    width: 100%;
}

.hero-image {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    border-radius: 0.9rem;
}

.finder-grid {
    display: grid;
    grid-template-columns: minmax(0, 15rem) minmax(0, 15rem) auto;
    gap: 0.85rem 1rem;
    align-items: start;
    justify-content: center;
}

.field-wrap {
    position: relative;
    min-width: 0;
}

.field-wrap label {
    display: block;
    min-height: var(--label-space);
    margin: 0 0 0.35rem 0.55rem;
    font-weight: 700;
    text-align: left;
}

.station-input {
    display: block;
    width: 100%;
    max-width: 15rem;
    min-width: 0;
    height: var(--field-height);
    margin: 0;
    padding: 0.75rem 0.9rem;
    border: 0.0625rem solid rgba(0, 0, 128, 0.28);
    border-radius: 0.85rem;
    background: #fff;
    color: #000080;
    font: inherit;
}

.station-input:focus {
    outline: 0.125rem solid rgba(0, 86, 214, 0.28);
    outline-offset: 0.06rem;
    border-color: #0056d6;
}

.action-wrap {
    display: flex;
    align-items: flex-start;
    padding-top: calc(var(--label-space) + 0.35rem);
    min-width: 0;
}

.secondary-button,
.primary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: var(--field-height);
    padding: 0.75rem 1rem;
    border-radius: 0.85rem;
    text-decoration: none;
    font-weight: 700;
    font: inherit;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.secondary-button {
    width: auto;
    min-width: 11rem;
    border: 0.0625rem solid rgba(0, 0, 128, 0.22);
    background: linear-gradient(180deg, rgba(230, 240, 255, 0.98), rgba(213, 230, 255, 0.98));
    color: #000080;
}

.primary-button {
    width: auto;
    min-width: 12rem;
    border: 0.0625rem solid rgba(0, 86, 214, 0.15);
    background: linear-gradient(180deg, rgba(0, 86, 214, 0.98), rgba(0, 72, 186, 0.98));
    color: #fff;
}

.secondary-button:hover,
.primary-button:hover,
.popular-link:hover {
    transform: translateY(-0.0625rem);
    box-shadow: 0 0.45rem 1rem rgba(0, 0, 128, 0.12);
}

.suggestions {
    position: absolute;
    top: calc(var(--label-space) + var(--field-height) + 0.45rem);
    left: 0;
    width: 100%;
    max-width: 15rem;
    z-index: 20;
    display: grid;
    gap: 0.25rem;
}

.suggestion-item {
    width: 100%;
    margin: 0;
    padding: 0.62rem 0.8rem;
    border: 0.0625rem solid rgba(0, 0, 128, 0.14);
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.99);
    color: #000080;
    text-align: left;
    font: inherit;
    cursor: pointer;
    box-shadow: 0 0.3rem 0.8rem rgba(0, 0, 128, 0.08);
}

.suggestion-item:hover,
.suggestion-item:focus {
    background: rgba(232, 241, 255, 0.99);
    outline: none;
}

.finder-note {
    margin: 0.9rem 0 1rem;
}

.route-result-card {
    display: flex;
    justify-content: center;
}

.result-inner {
    width: 100%;
    max-width: 40rem;
    padding: 1.15rem 1rem;
    border-radius: 1rem;
    background: rgba(240, 246, 255, 0.9);
    text-align: left;
}

.result-inner-centered {
    text-align: center;
}

.result-inner-success {
    background: linear-gradient(180deg, rgba(240, 246, 255, 0.95), rgba(229, 240, 255, 0.96));
}

.result-inner h3,
.result-inner p {
    margin: 0 0 0.7rem;
}

.result-inner p:last-child {
    margin-bottom: 0;
}

.selected-route-line {
    font-size: clamp(1.2rem, 2vw, 1.5rem);
    font-weight: 700;
}

.route-label {
    font-weight: 700;
}

.popular-grid,
.faq-list {
    display: grid;
    gap: 0.85rem;
}

.popular-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.popular-link {
    display: block;
    padding: 1rem;
    border-radius: 0.95rem;
    background: rgba(244, 248, 255, 0.98);
    text-decoration: none;
    color: #000080;
}

.popular-route,
.popular-cta {
    display: block;
}

.popular-route {
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.faq-item {
    padding: 1rem;
    border-radius: 0.95rem;
    background: rgba(244, 248, 255, 0.98);
}

.faq-item h3 {
    margin: 0 0 0.45rem;
}

.faq-item p,
.content-card p,
.today-line {
    max-width: 48rem;
}

.today-line {
    margin: 1rem auto 0;
    text-align: left;
}

@media (max-width: 840px) {
    .hero-card {
        grid-template-columns: 1fr;
    }

    .finder-grid {
        grid-template-columns: 1fr;
        justify-content: stretch;
    }

    .station-input,
    .suggestions {
        max-width: 100%;
    }

    .action-wrap {
        padding-top: 0;
    }

    .secondary-button,
    .primary-button {
        width: 100%;
    }

    .popular-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .train-page {
        padding: 0.8rem 0.45rem 2rem;
    }

    .hero-card,
    .finder-card,
    .popular-card,
    .faq-card,
    .content-card,
    .footer-links-card {
        padding: 1rem 0.8rem;
    }
}
