:root {
    --bg-beige: #f3e7d3;
    --bg-brown: #4a3120;
    --green-light: #9abf7f;
    --green: #2f5e3b;
    --red-deep: #8b2f32;
    --text-dark: #203020;
    --accent: #be9b5f;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-beige);
}

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

main, #main-content {
    scroll-margin-top: 90px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -999px;
    left: 0;
    padding: 0.65rem 1rem;
    background: #203020;
    color: #fff;
    border-radius: 999px;
    z-index: 2000;
    transition: top 0.2s ease;
}
.skip-link:focus {
    top: 12px;
    left: 12px;
    outline: 3px solid #f7f0e6;
}

a:focus-visible,
button:focus-visible,
.btn:focus-visible {
    outline: 3px solid #f7ecdc;
    outline-offset: 2px;
    box-shadow: 0 0 0 3px rgba(47,94,59,0.35);
}

/* Header & Nav */

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: calc(0.7rem + env(safe-area-inset-top, 0px)) 2rem 0.7rem;
    background: rgba(32, 48, 32, 0.75);
    backdrop-filter: blur(6px);
    color: #fff;
}

.logo {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 0.9rem;
}

.logo span {
    font-weight: 700;
}

.site-header nav {
    display: flex;
    gap: 1.5rem;
    font-size: 0.95rem;
}

.site-header nav a {
    position: relative;
    padding-bottom: 0.1rem;
}

.site-header nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: #fff;
    transition: width 0.2s ease;
}

.site-header nav a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-left: 0.6rem;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.menu-toggle:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.45);
}

.menu-icon {
    position: relative;
    width: 20px;
    height: 14px;
    display: inline-flex;
    flex-direction: column;
    justify-content: space-between;
}

.menu-icon span {
    display: block;
    height: 2px;
    width: 100%;
    background: currentColor;
    border-radius: 2px;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.menu-toggle.open .menu-icon span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.menu-toggle.open .menu-icon span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.open .menu-icon span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(4px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 900;
}

.menu-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* Hero */

.hero {
    position: relative;
    height: 70vh;
    min-height: 480px;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 140px;
    padding-bottom: 140px;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("img/hero-bukk-tavasz.png");
    background-size: cover;
    background-position: 50% 45%;
    filter: saturate(1.12) contrast(0.95) brightness(1.08);
    pointer-events: none;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.08),
        rgba(0, 0, 0, 0.22)
    );
    pointer-events: none;
}

.hero-inner {
    position: relative;
    max-width: 900px;
}

.hero-badge {
    font-family: 'Cormorant Garamond', serif;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    font-size: 2.2rem;
    margin: 0 0 0.25rem 0;
    opacity: 0.97;
    display: block;
    padding: 0;
    color: #f5f5f5;
    text-shadow:
        0 0 2px #000,
        0 0 4px #000,
        0 2px 10px rgba(0,0,0,0.35);
}

.hero-title {
    font-family: 'Great Vibes', 'Segoe Script', 'Brush Script MT', cursive;
    font-size: clamp(3.4rem, 6vw, 5.2rem);
    line-height: 1.08;
    letter-spacing: 0.02em;
    margin: 0;
    display: inline-block;
    max-width: 100%;
    position: relative;
    padding: 0.2rem 0.3rem 0.25rem;
    background: linear-gradient(
        135deg,
        rgba(11, 122, 48, 0.85) 0%,
        rgba(255, 255, 255, 0.92) 45%,
        rgba(197, 0, 36, 0.85) 100%
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    -webkit-text-stroke: 0.35px rgba(0, 0, 0, 0.45);
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.28);
}

.hero-subtitle {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.5rem;
    margin: 0.5rem 0 1.5rem;
}

.hero-meta {
    font-size: 1rem;
    opacity: 0.95;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1.75rem;
    flex-wrap: wrap;
}

.btn {
    border-radius: 999px;
    padding: 0.7rem 1.8rem;
    font-weight: 500;
    font-size: 0.95rem;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-primary {
    background-color: #2f5e3b;
    border-color: #2f5e3b;
    color: #fff;
}

.btn-primary:hover {
    background-color: #264c30;
}

.btn-ghost {
    background-color: transparent;
    border-color: #f5f5f5;
    color: #f5f5f5;
}

.btn-ghost:hover {
    background-color: rgba(245, 245, 245, 0.1);
}
.btn-secondary {
    background-color: #2f5e3b;
    border-color: #2f5e3b;
    color: #fff;
}
.btn-secondary:hover {
    background-color: #264c30;
    color: #fff;
}

/* Sections */

main {
    background: var(--bg-beige);
}

section {
    padding: 4rem 1.5rem;
}

.section-inner {
    max-width: 1100px;
    margin: 0 auto;
}

.section-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2.1rem;
    margin-bottom: 1rem;
}

.section-lead {
    max-width: 680px;
    font-size: 1rem;
    line-height: 1.6;
}
.archive-intro .section-lead {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
}

/* About Section */

.about {
    background: #f6eee0;
}

.about-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.4fr);
    gap: 2.5rem;
    align-items: center;
    margin-top: 1rem;
}

.about-photo {
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0,0,0,0.16);
}

.about-photo img {
    width: 100%;
    display: block;
    object-fit: cover;
}

/* Routes */

.routes {
    background: var(--bg-beige);
}

.routes-header {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 2.5rem;
}

.routes-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 320px));
    gap: 1.5rem;
    justify-content: center;
    justify-items: center;
}
.archive-year .routes-row {
    grid-template-columns: repeat(auto-fit, minmax(280px, 320px));
    justify-content: center;
    justify-items: center;
}
.archive-year .routes-row > a {
    width: 100%;
    max-width: 320px;
}

.route-card {
    border-radius: 18px;
    padding: 1.8rem 1.4rem;
    color: #fff;
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 320px;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    justify-content: flex-start;
    height: 100%;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.18);
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, translate 0.18s ease;
}

.route-logo {
    position: absolute;
    top: 0.8rem;
    right: 0.8rem;
    width: 60px;
    height: 60px;
    object-fit: contain;
    z-index: 10;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.route-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top left, rgba(255,255,255,0.25), transparent 55%);
    mix-blend-mode: screen;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.route-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.22);
}

.route-card:hover::after {
    opacity: 1;
}

.route-card-short { background: #7fa76a; } /* Zöld - < 12 km */
.route-card-medium { background: #315c3a; } /* Sötétzöld - 12-16 km */
.route-card-extended { background: #d97706; } /* Narancs - 16-22 km */
.route-card-long { background: #8b3638; } /* Piros - > 22 km */
.route-card-event { background: #5a4a3a; } /* Barna - speciális események */

.route-card-event .route-logo {
    top: 0.5rem;
    right: 0.5rem;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    padding: 2px;
    background: rgba(255, 255, 255, 0.1);
}

.route-category-icon {
    width: 32px;
    height: 32px;
    margin-bottom: 0.8rem;
}

.route-distance {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2.3rem;
    margin-bottom: 0.2rem;
}

.route-name {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
}

.route-meta {
    font-size: 0.9rem;
    opacity: 0.95;
}

.route-footer {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
}

.route-footer span { opacity: 0.9; }

.route-link {
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.route-link::after {
    content: ">";
    font-size: 0.9rem;
}

/* Info Section */

.info-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.info-card {
    background: #f9f0dd;
    border-radius: 16px;
    padding: 1.4rem 1.3rem;
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.info-card h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.28rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    margin-top: 0;
    margin-bottom: 0.55rem;
}

.info-card p {
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0;
}
.external-link {
    color: #2f5e3b;
    font-weight: 600;
    text-decoration: none;
}
.external-link:hover {
    text-decoration: underline;
}
.external-link::after {
    content: " ↗";
    font-size: 0.95em;
}

/* Route page */
.route-page {
    background: var(--bg-beige);
    color: var(--text-dark);
}
.route-page .hero {
    position: relative;
    height: 55vh;
    min-height: 360px;
    color: #fff;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    text-align: left;
    padding: 0 1.5rem clamp(3rem, 7vh, 4.5rem);
}
.route-page .hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("img/bukk-tavasz-panoramakep.png");
    background-size: cover;
    background-position: 50% 45%;
    filter: saturate(1.12) contrast(0.95) brightness(1.08);
    pointer-events: none;
}
.route-page .hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(10,14,10,0.32) 0%, rgba(10,14,10,0.16) 42%, rgba(0,0,0,0.05) 100%);
}
.route-page .hero-inner {
    position: relative;
    max-width: 1100px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.8rem;
}
.route-page .hero-back {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    color: #f7f4ed;
    text-shadow: 0 2px 8px rgba(0,0,0,0.45);
    background: linear-gradient(120deg, rgba(0,0,0,0.42), rgba(0,0,0,0.3));
    padding: 0.55rem 1rem;
    border-radius: 999px;
    font-weight: 600;
    border: 1px solid rgba(255,255,255,0.18);
    box-shadow: 0 12px 24px rgba(0,0,0,0.28);
    margin-top: 0.7rem;
}
.route-hero-inner {
    position: relative;
    width: 100%;
    max-width: 1100px;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    transform: translateY(40px);
}
.route-hero-panel {
    background: rgba(18, 24, 16, 0.44);
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 16px 36px rgba(0,0,0,0.28);
    border-radius: 18px;
    padding: 1.3rem 1.5rem 1.4rem;
    backdrop-filter: blur(3px);
    max-width: min(600px, 92vw);
    margin-top: 10px;
}
.route-hero-kicker {
    margin: 0 0 0.5rem;
    font-family: 'Cormorant Garamond', serif;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    font-size: 0.95rem;
    opacity: 0.9;
}
.route-hero-title {
    margin: 0.2rem 0 0.7rem;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-weight: 800;
    font-size: clamp(2.5rem, 5.4vw, 3.4rem);
    line-height: 1.08;
    letter-spacing: 0.01em;
    color: #f9f6ee;
    text-shadow: 0 4px 16px rgba(0,0,0,0.4);
}
.route-hero-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    color: #315c3a;
}
.route-hero-icon .route-category-icon {
    width: 24px;
    height: 24px;
}
.route-hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem 0.9rem;
    font-weight: 600;
    font-size: 0.98rem;
}
.route-hero-meta span {
    position: relative;
}
.route-hero-meta span + span::before {
    content: "•";
    margin-right: 0.55rem;
    color: rgba(255,255,255,0.75);
}
.route-cat-short .route-hero-icon { color: #7fa76a; }
.route-cat-medium .route-hero-icon { color: #315c3a; }
.route-cat-long .route-hero-icon { color: #8b3638; }
.route-page .hero-back {
    position: static;
    top: auto;
    left: auto;
}
.route-page main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1.5rem 3rem;
}
.route-page h2 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.7rem;
    margin: 0 0 0.5rem 0;
    color: var(--text-dark);
}
.route-page section {
    margin: 0 0 0.6rem 0;
    padding: 0 0 0.4rem 0;
}
.route-page .info-grid {
    display: grid;
    grid-template-columns: minmax(0,1.05fr) minmax(0,0.95fr);
    gap: 1.2rem;
    align-items: start;
}
.route-page .grid-2 {
    display: grid;
    grid-template-columns: minmax(0,1.4fr) minmax(0,1fr);
    gap: 1rem;
}
.route-page .basic-list {
    list-style: none;
    padding: 0;
    margin: 1rem 0 0;
}
.route-page .basic-list li {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.4rem;
    font-size: 0.96rem;
}
.route-page .icon-circle {
    width: 26px;
    height: 26px;
    border-radius: 999px;
    border: 2px solid var(--green);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
}
.route-page .profile-box {
    background: #f7ecdc;
    border-radius: 14px;
    padding: 1rem 1.2rem;
}
.route-page .profile-chart {
    height: 120px;
    background: linear-gradient(to top, #7f5b3b, #c79b6c);
    clip-path: polygon(0% 70%, 20% 40%, 40% 55%, 55% 35%, 75% 60%, 100% 30%, 100% 100%, 0% 100%);
    border-radius: 10px;
    position: relative;
    overflow: hidden;
}
.route-page .profile-axis {
    font-size: 0.75rem;
    display: flex;
    justify-content: space-between;
    margin-top: 0.3rem;
}
.route-page .map-section {
    margin: 1rem 0 1.2rem;
}
.route-page .map-placeholder {
    background: #e0d8c6;
    border-radius: 18px;
    padding: 1rem;
    box-shadow: 0 14px 40px rgba(0,0,0,0.1);
}
.route-page .map-box {
    background: #d0c7b0;
    border-radius: 16px;
    height: 540px;
    position: relative;
    overflow: hidden;
}
.route-page .map-placeholder p {
    font-size: 0.85rem;
    margin-top: 0.6rem;
    opacity: 0.85;
}
.route-page .elev-card {
    margin-top: 1rem;
    background: #f7ecdc;
    border-radius: 14px;
    padding: 0.8rem 1rem 1rem;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.5);
}
.route-page .elev-card h3 {
    margin: 0 0 0.4rem;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
}
.route-page .elev-svg {
    width: 100%;
    height: 180px;
}
.route-page .elev-axes {
    font-size: 0.8rem;
    display: flex;
    justify-content: space-between;
    opacity: 0.75;
    margin-top: 0.2rem;
}
.route-page .segments {
    margin-top: 1rem;
}
.route-page .segments h3 {
    margin: 0 0 0.6rem;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
}
.route-page .segments ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.8rem;
}
.route-page .segments li {
    background: #f7ecdc;
    border-radius: 999px;
    padding: 0.55rem 0.9rem;
    border: 1px solid rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.route-page .segments .stop {
    font-weight: 600;
    font-size: 0.95rem;
    white-space: normal;
}
.route-page .segments .stop-icon {
    font-size: 1.1rem;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    margin-right: 0.4rem;
    flex-shrink: 0;
}
.route-page .segments li.stop-start,
.route-page .segments li.stop-finish {
    display: flex;
    align-items: center;
}
.route-page .segments .signs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    font-size: 1rem;
    flex: 0 0 auto;
    white-space: nowrap;
}
.route-page .segments .arrow {
    color: #b5aea4;
    font-size: 1.1rem;
    padding: 0 0.2rem;
}
.route-page .segments .arrow-segment {
    background: #f7ecdc;
    border-radius: 999px;
    border: 1px solid rgba(0,0,0,0.06);
    padding: 0.55rem 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.route-page .segments .arrow-segment .arrow {
    color: #b5aea4;
    font-size: 1.1rem;
    padding: 0;
    flex-shrink: 0;
    line-height: 1;
    display: inline-flex;
    align-items: center;
}
.route-page .segments .arrow-segment .signs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    font-size: 1rem;
    flex: 0 0 auto;
    white-space: nowrap;
    align-items: center;
    line-height: 1;
}
.route-page .toursign {
    font-family: 'Toursign', 'Signs', sans-serif;
    font-size: 1.05rem;
    line-height: 1;
}
.route-page .toursign.g { color: green; }
.route-page .toursign.r { color: red; }
.route-page .toursign.b { color: blue; }
.route-page .toursign.y { color: #ffb719; }
.route-page .sign-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.2rem 0.45rem;
    border-radius: 10px;
    border: 1px solid rgba(0,0,0,0.15);
    background: #fff;
}
.route-page .sign-badge.sign-text {
    color: #203020;
    border-color: rgba(0,0,0,0.12);
}
.route-page .checkpoint-list {
    list-style: none;
    padding: 0;
    margin: 0.6rem 0 0;
}
.route-page .checkpoint-list li {
    margin-bottom: 0.3rem;
    font-size: 0.96rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.route-page .checkpoint-index {
    width: 24px;
    height: 24px;
    border-radius: 999px;
    border: 2px solid var(--green);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}
.route-page .download-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 0.9rem;
}
.route-page .schedule {
    margin-top: 0.5rem;
}
.route-page .schedule table {
    border-collapse: collapse;
    width: 100%;
    max-width: 520px;
    font-size: 0.95rem;
}
.route-page .schedule th,
.route-page .schedule td {
    padding: 0.35rem 0.4rem;
    text-align: left;
}
.route-page .schedule tr:nth-child(even) {
    background: #f6edde;
}
.route-page .schedule th {
    font-weight: 700;
}
.route-page .custom-marker {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}
.route-page .custom-marker .marker-pin {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 3px solid #fff;
    box-shadow: 0 4px 8px rgba(0,0,0,0.35);
}
.route-page .custom-marker.start .marker-pin { background: #2f8f58; }
.route-page .custom-marker.finish .marker-pin { background: #b63a2f; }
.route-page .custom-marker .marker-label {
    background: #fff;
    color: #1f3120;
    font-size: 12px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.28);
    line-height: 1.1;
}

/* Route visuals by category */
.route-page .hero::before {
    background-image: url("img/bukk-tavasz-panoramakep.png");
}
.route-cat-short .hero::before {
    background-image: url("img/track-route-easy.png");
}
.route-cat-medium .hero::before {
    background-image: url("img/track-route-med.png");
}
.route-cat-long .hero::before {
    background-image: url("img/track-route-hard.png");
}
.route-page .route-hero-event.hero::before {
    background-image: var(--hero-image, url("img/rakoczi350_hero.png"));
}
.route-hero-text-overlay {
    position: absolute;
    top: clamp(1.5rem, 5vh, 3rem);
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    max-width: min(600px, 55vw);
    text-align: center;
}
.route-hero-text-main {
    margin: 0 0 0.4rem 0;
    line-height: 1.1;
    text-align: center;
    display: inline-block;
}
.route-hero-text-rakoczi {
    font-family: 'Great Vibes', 'Cormorant Garamond', serif;
    font-size: clamp(3.5rem, 8vw, 5.5rem);
    font-weight: 600;
    color: #000;
    text-shadow: 
        0 0 2px rgba(255, 255, 255, 0.9),
        0 0 4px rgba(255, 255, 255, 0.7),
        0 2px 10px rgba(0, 0, 0, 0.25);
    letter-spacing: 0.02em;
    white-space: nowrap;
}
.route-hero-text-number {
    font-family: 'Great Vibes', 'Cormorant Garamond', serif;
    font-size: clamp(3.5rem, 8vw, 5.5rem);
    font-weight: 600;
    color: #000;
    text-shadow: 
        0 0 2px rgba(255, 255, 255, 0.9),
        0 0 4px rgba(255, 255, 255, 0.7),
        0 2px 10px rgba(0, 0, 0, 0.25);
    letter-spacing: 0.02em;
    margin-left: 0.3rem;
}
.route-hero-text-sub {
    margin: 0.25rem 0 0 0;
    font-family: 'Dancing Script', 'Great Vibes', cursive;
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    font-weight: 500;
    color: #000;
    line-height: 1.4;
    text-align: center;
    text-shadow: 
        0 0 2px rgba(255, 255, 255, 0.9),
        0 0 4px rgba(255, 255, 255, 0.7),
        0 2px 6px rgba(0, 0, 0, 0.2);
}
.route-accent-bar {
    height: 8px;
    width: 100%;
    background: #2f5e3b;
}
.route-cat-short .route-accent-bar { background: #7fa76a; }
.route-cat-medium .route-accent-bar { background: #315c3a; }
.route-cat-long .route-accent-bar { background: #8b3638; }
@media (max-width: 800px) {
    .route-page .grid-2 {
        grid-template-columns: minmax(0,1fr);
    }
    .route-page .info-grid {
        grid-template-columns: minmax(0,1fr);
    }
    .route-page .hero {
        align-items: flex-end;
        text-align: left;
        padding-bottom: 2.6rem;
    }
    .route-hero-inner {
        gap: 0.7rem;
        transform: translateY(24px);
    }
    .route-hero-panel {
        padding: 1.05rem 1.1rem 1.15rem;
        border-radius: 14px;
        margin-top: 6px;
    }
    .route-hero-title {
        font-size: clamp(2rem, 8vw, 2.6rem);
    }
    .route-hero-text-overlay {
        top: clamp(1rem, 3vh, 2rem);
        max-width: min(450px, 75vw);
    }
    .route-hero-text-rakoczi {
        font-size: clamp(2.2rem, 9vw, 3.5rem);
    }
    .route-hero-text-number {
        font-size: clamp(2.2rem, 9vw, 3.5rem);
    }
    .route-hero-text-sub {
        font-size: clamp(1.2rem, 5.5vw, 1.8rem);
        margin-top: 0.2rem;
    }
    .route-hero-icon {
        width: 42px;
        height: 42px;
    }
    .route-page .hero-back {
        position: static;
        margin-bottom: 0.3rem;
    }
    .route-page main {
        padding-inline: 1.2rem;
    }
}

/* Not found page */
.not-found {
    background: var(--bg-beige);
    color: var(--text-dark);
    margin: 0;
}
.nf-hero {
    position: relative;
    min-height: 60vh;
    padding: 140px 1.5rem 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
}
.nf-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("img/hero-bukk-tavasz.png");
    background-size: cover;
    background-position: center;
    filter: saturate(1.05) contrast(0.95) brightness(1.05);
}
.nf-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.35) 60%, rgba(0,0,0,0.2) 100%);
}
.nf-inner {
    position: relative;
    max-width: 720px;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    align-items: center;
}
.nf-badge {
    font-family: 'Cormorant Garamond', serif;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    font-size: 2rem;
    text-shadow: 0 3px 16px rgba(0,0,0,0.5);
}
.nf-hero h1 {
    margin: 0;
    font-family: 'Great Vibes', cursive;
    font-size: clamp(3.2rem, 6vw, 4.8rem);
    text-shadow: 0 4px 16px rgba(0,0,0,0.55);
}
.nf-sub {
    margin: 0.4rem 0 1rem;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
    text-shadow: 0 2px 12px rgba(0,0,0,0.5);
}
.nf-actions {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
    justify-content: center;
}
.nf-main {
    max-width: 900px;
    margin: -70px auto 80px;
    padding: 0 1.5rem;
}
.nf-box {
    background: #f6eee0;
    border-radius: 18px;
    padding: 1.6rem 1.5rem;
    box-shadow: 0 12px 28px rgba(0,0,0,0.12);
}
.nf-box h2 {
    margin-top: 0;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.6rem;
}
.nf-box ul {
    margin: 0.4rem 0 0.6rem;
    padding-left: 1.1rem;
}
.nf-box li {
    margin-bottom: 0.2rem;
}
.nf-tip {
    margin: 0.8rem 0 0;
    font-weight: 600;
}
.info-card .btn {
    display: inline-block;
    margin-top: 0.6rem;
    margin-bottom: 0.1rem;
}

/* Archive page */
.archive-page {
    background: var(--bg-beige);
    color: var(--text-dark);
}
.secondary-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 2rem;
    background: rgba(32, 48, 32, 0.92);
    backdrop-filter: blur(6px);
    color: #fff;
}
.secondary-header nav {
    display: flex;
    gap: 1.2rem;
    font-size: 0.95rem;
}
.secondary-header nav a {
    position: relative;
    padding-bottom: 0.1rem;
}
.secondary-header nav a.active::after,
.secondary-header nav a:hover::after {
    width: 100%;
}
.secondary-header nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: #fff;
    transition: width 0.2s ease;
}

.archive-hero {
    height: auto;
    padding-top: 140px;
    padding-bottom: 100px;
}
.archive-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("img/hero-bukk-tavasz_arch.png");
    background-size: cover;
    background-position: center;
    filter: saturate(1.08) contrast(1) brightness(1.04);
}
.archive-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.22) 0%, rgba(0,0,0,0.16) 55%, rgba(0,0,0,0.12) 100%);
}
.archive-hero-inner {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
}
.archive-kicker {
    font-family: 'Cormorant Garamond', serif;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    font-size: 0.95rem;
    margin: 0;
}
.archive-hero h1 {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-weight: 800;
    font-size: clamp(2.8rem, 6vw, 3.6rem);
    letter-spacing: 0.01em;
    text-shadow: 0 4px 14px rgba(0,0,0,0.45);
}
.archive-subtitle {
    max-width: 680px;
    margin: 0;
    font-size: 1rem;
    line-height: 1.5;
    opacity: 0.95;
}
.archive-hero .hero-title {
    font-family: 'Great Vibes', 'Segoe Script', 'Brush Script MT', cursive;
    font-size: clamp(3.4rem, 6vw, 5.2rem);
    line-height: 1.08;
    letter-spacing: 0.02em;
    margin: 0;
    display: inline-block;
    max-width: 100%;
    position: relative;
    padding: 0.2rem 0.3rem 0.25rem;
    background: linear-gradient(
        135deg,
        rgba(11, 122, 48, 0.85) 0%,
        rgba(255, 255, 255, 0.92) 45%,
        rgba(197, 0, 36, 0.85) 100%
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    -webkit-text-stroke: 0.35px rgba(0, 0, 0, 0.45);
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.28);
}

.archive-intro {
    background: #f6eee0;
    padding: 1.4rem 1.5rem 0.4rem;
    margin-top: -20px;
}

.archive-year {
    padding: 1.6rem 1.5rem 1.2rem;
}
.archive-year-header {
    display: grid;
    grid-template-columns: minmax(0,1fr) auto;
    align-items: center;
    gap: 0.8rem 1rem;
    margin-bottom: 0.8rem;
}
.archive-year-left {
    display: inline-flex;
    align-items: center;
    gap: 0.9rem;
    flex-wrap: wrap;
}
.archive-year-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 14px;
    background: var(--bg-brown);
    color: #fff;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.4rem;
    letter-spacing: 0.06em;
    box-shadow: 0 8px 20px rgba(0,0,0,0.18);
    margin-bottom: 0.5rem;
}
.archive-year-title {
    margin: 0.1rem 0 0.15rem;
    font-family: 'Cormorant Garamond', serif;
    font-size: 2rem;
}
.archive-year-subtitle {
    margin: 0;
    opacity: 0.9;
    max-width: 540px;
    line-height: 1.5;
}
.archive-docs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-top: 0.2rem;
    justify-content: flex-end;
}
.archive-routes-title {
    margin: 0.4rem 0 0.8rem;
}
.archive-year-note {
    background: #f9f0dd;
    border-radius: 14px;
    padding: 1rem 1.1rem;
    box-shadow: 0 8px 18px rgba(0,0,0,0.08);
    max-width: 320px;
    font-size: 0.95rem;
}
.archive-year-note p {
    margin: 0 0 0.6rem 0;
}

.archive-routes-header {
    text-align: center;
}

.archive-footer-links {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem 2rem;
    display: flex;
    gap: 0.6rem;
    align-items: center;
    color: #f5f0e6;
    font-size: 0.95rem;
}
.archive-footer-links a {
    color: #f5f0e6;
    text-decoration: none;
}
.archive-footer-links span {
    opacity: 0.7;
}

@media (max-width: 1000px) {
    .secondary-header {
        padding-inline: 1.2rem;
    }
}
@media (max-width: 700px) {
    .secondary-header {
        padding: 0.65rem 1rem;
    }
    .secondary-header nav {
        display: none;
    }
    .archive-hero {
        padding: 120px 1.2rem 60px;
    }
    .archive-year-note {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .route-page .segments li {
        font-size: 0.9rem;
        padding: 0.45rem 0.75rem;
    }
    .route-page .segments .stop {
        font-size: 0.9rem;
        white-space: normal;
        flex: 1 1 auto;
    }
    .route-page .segments .signs {
        flex: 0 0 auto;
        white-space: nowrap;
    }
    .route-page .segments .arrow-segment {
        padding: 0.45rem 0.75rem;
    }
    .route-page .segments .arrow-segment .signs {
        flex: 0 0 auto;
        white-space: nowrap;
    }
}

/* Footer */

footer {
    background: var(--bg-brown);
    color: #f5f0e6;
    padding-top: 0.8rem;
}

.tricolor-bar {
    height: 6px;
    background: linear-gradient(to right, #ce2939 0 33%, #ffffff 33% 66%, #008c3b 66% 100%);
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1.4rem 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    font-size: 0.9rem;
}

.footer-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
}

/* Responsive */

@media (max-width: 900px) {
    .site-header {
        padding: calc(0.55rem + env(safe-area-inset-top, 0px)) 1rem 0.55rem;
        gap: 0.6rem;
    }
    .site-header .logo {
        font-size: 0.85rem;
    }
    .menu-toggle {
        display: inline-flex;
    }
    .site-header nav {
        position: fixed;
        top: calc(env(safe-area-inset-top, 0px) + 64px);
        left: 1rem;
        right: 1rem;
        display: none;
        flex-direction: column;
        gap: 0.35rem;
        padding: 0.85rem 1rem;
        background: rgba(32, 48, 32, 0.95);
        border-radius: 14px;
        box-shadow: 0 12px 30px rgba(0,0,0,0.25);
        border: 1px solid rgba(255, 255, 255, 0.08);
        z-index: 1200;
    }
    .site-header nav.open {
        display: flex;
    }
    .site-header nav a {
        padding: 0.2rem 0;
    }
    body.menu-open {
        overflow: hidden;
    }
    .about-grid { grid-template-columns: minmax(0,1fr); }
    .routes-row { 
        grid-template-columns: minmax(0,1fr);
        justify-items: center;
    }
    .info-grid { grid-template-columns: minmax(0,1fr); }
    .hero {
        height: auto;
        min-height: 75vh;
        padding-top: calc(120px + env(safe-area-inset-top, 0px));
        padding-bottom: 180px;
    }
}

/* Content sections for special routes */
.section-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    line-height: 1.7;
}

.section-content p {
    margin-bottom: 1.2rem;
}

.calendar-section {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.calendar-section h2 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--green);
}

.calendar-wrapper {
    width: 100%;
    max-width: 550px;
    margin: 0 auto;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.calendar-wrapper iframe {
    width: 100%;
    height: 480px;
    border: none;
    display: block;
}

.events-table-section {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.events-table-section h2 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--green);
}

@media (max-width: 640px) {
    .calendar-wrapper {
        max-width: 100%;
    }
    .calendar-wrapper iframe {
        height: 400px;
    }
}
