@import url("https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,600;9..144,750&family=Inter:wght@400;500;600;700;800&display=swap");

:root {
    color-scheme: light;
    --paper: #f7f3ea;
    --paper-strong: #fffaf0;
    --ink: #142321;
    --muted: #62716d;
    --soft: #87938f;
    --line: rgba(20, 35, 33, 0.13);
    --line-strong: rgba(20, 35, 33, 0.24);
    --green: #0f7666;
    --green-dark: #0a4d45;
    --coral: #e85d3f;
    --gold: #c28c35;
    --blue: #2d6f93;
    --night: #102321;
    --surface: rgba(255, 250, 240, 0.76);
    --surface-strong: rgba(255, 250, 240, 0.94);
    --shadow-soft: 0 18px 45px rgba(20, 35, 33, 0.1);
    --shadow-deep: 0 35px 90px rgba(10, 25, 24, 0.22);
    --radius-xs: 10px;
    --radius-sm: 14px;
    --radius-md: 20px;
    --radius-lg: 28px;
    --radius-xl: 38px;
    --content: min(1180px, calc(100vw - 2rem));
    --font-sans: "Inter", system-ui, sans-serif;
    --font-display: "Fraunces", Georgia, serif;
    --header-h: 82px;
    --fast: 180ms ease;
    --slow: 620ms cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-width: 320px;
    background:
        linear-gradient(90deg, rgba(20, 35, 33, 0.035) 1px, transparent 1px) 0 0 / 44px 44px,
        linear-gradient(180deg, #fff9ee 0%, #f5efe3 42%, #edf4ef 100%);
    color: var(--ink);
    font-family: var(--font-sans);
    line-height: 1.55;
    overflow-x: hidden;
}

body.nav-open {
    overflow: hidden;
}

img {
    display: block;
    max-width: 100%;
}

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

button,
input,
textarea,
select {
    font: inherit;
}

button,
select {
    cursor: pointer;
}

::selection {
    background: rgba(232, 93, 63, 0.18);
}

.preloader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: grid;
    place-items: center;
    background: var(--night);
    color: #fff9ee;
    transition: opacity 420ms ease, visibility 420ms ease;
}

.preloader.is-hidden {
    opacity: 0;
    visibility: hidden;
}

.preloader-card {
    display: inline-flex;
    align-items: center;
    gap: 0.9rem;
    padding: 1rem 1.15rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.scroll-progress {
    position: fixed;
    inset: 0 auto auto 0;
    z-index: 1000;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--green), var(--coral), var(--gold));
}

.site-header,
main,
.site-footer {
    position: relative;
    z-index: 1;
}

.site-header {
    position: sticky;
    top: 0.75rem;
    z-index: 900;
    width: min(1220px, calc(100vw - 1rem));
    min-height: var(--header-h);
    margin: 0 auto;
    padding: 0.75rem 0.85rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    background: rgba(255, 250, 240, 0.78);
    border: 1px solid rgba(20, 35, 33, 0.1);
    border-radius: 999px;
    backdrop-filter: blur(18px);
    box-shadow: 0 18px 48px rgba(20, 35, 33, 0.08);
    transition: box-shadow var(--fast), background var(--fast), transform var(--fast);
}

.site-header.is-scrolled {
    background: rgba(255, 250, 240, 0.94);
    box-shadow: 0 22px 60px rgba(20, 35, 33, 0.14);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    min-width: 0;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 3rem;
    height: 3rem;
    flex: 0 0 auto;
    border-radius: 50%;
    background: conic-gradient(from 160deg, var(--green), var(--blue), var(--coral), var(--green));
    color: white;
    font-weight: 800;
    box-shadow: 0 16px 34px rgba(15, 118, 102, 0.24);
}

.brand-copy {
    display: grid;
    gap: 0.05rem;
}

.brand-copy strong {
    font-size: 0.98rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.brand-copy span {
    color: var(--muted);
    font-size: 0.84rem;
}

.site-nav {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.site-nav a {
    padding: 0.74rem 0.95rem;
    border-radius: 999px;
    color: var(--muted);
    font-weight: 800;
    font-size: 0.91rem;
    transition: color var(--fast), background var(--fast), transform var(--fast);
}

.site-nav a:hover,
.site-nav a.is-active {
    color: var(--ink);
    background: rgba(15, 118, 102, 0.11);
    transform: translateY(-1px);
}

.nav-toggle {
    display: none;
    width: 3rem;
    height: 3rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: var(--night);
}

.nav-toggle span {
    display: block;
    width: 1.1rem;
    height: 2px;
    margin: 0.22rem auto;
    background: white;
    border-radius: 999px;
}

.hero,
.section {
    width: var(--content);
    margin: 0 auto;
}

.hero {
    min-height: calc(100svh - 1rem);
    padding: clamp(3rem, 7vw, 6rem) 0 4rem;
    display: grid;
    grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
    align-items: center;
    gap: clamp(1.5rem, 5vw, 4rem);
}

.eyebrow,
.section-kicker,
.mini-kicker {
    margin: 0 0 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    color: var(--green-dark);
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-size: 0.76rem;
}

.eyebrow::before,
.section-kicker::before,
.mini-kicker::before {
    content: "";
    width: 2.3rem;
    height: 1px;
    background: currentColor;
    opacity: 0.65;
}

h1,
h2,
h3 {
    margin: 0;
    font-family: var(--font-display);
    line-height: 0.98;
}

.hero h1 {
    font-size: clamp(3.5rem, 8vw, 7.2rem);
    max-width: 10.5ch;
}

.hero-text,
.section-heading p,
.journey-hero-copy p,
.notebook-card p,
.contact-copy p,
.map-copy p {
    color: var(--muted);
    font-size: clamp(1rem, 1.65vw, 1.1rem);
}

.hero-text {
    max-width: 42rem;
    margin: 1.35rem 0 0;
}

.hero-actions,
.journey-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
    margin-top: 2rem;
}

.primary-button,
.secondary-button,
.text-link,
.chip {
    transition: transform var(--fast), box-shadow var(--fast), background var(--fast), border-color var(--fast), color var(--fast);
}

.primary-button,
.secondary-button {
    min-height: 3.35rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.9rem 1.25rem;
    border-radius: 999px;
    border: 1px solid transparent;
    font-weight: 900;
}

.primary-button {
    color: #fffaf0;
    background: linear-gradient(135deg, var(--green) 0%, var(--coral) 110%);
    box-shadow: 0 18px 38px rgba(15, 118, 102, 0.23);
}

.secondary-button {
    color: var(--ink);
    background: rgba(255, 250, 240, 0.72);
    border-color: var(--line);
}

.primary-button:hover,
.secondary-button:hover,
.text-link:hover,
.chip:hover,
.journey-card:hover,
.featured-card:hover {
    transform: translateY(-2px);
}

.stat-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.8rem;
    margin-top: 2.2rem;
}

.stat-strip article {
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: rgba(255, 250, 240, 0.72);
    box-shadow: 0 14px 35px rgba(20, 35, 33, 0.06);
}

.stat-strip strong {
    display: block;
    font-size: clamp(1.35rem, 3vw, 2rem);
    line-height: 1;
}

.stat-strip span {
    display: block;
    margin-top: 0.35rem;
    color: var(--soft);
    font-size: 0.83rem;
    font-weight: 700;
}

.stat-strip.compact {
    max-width: 34rem;
}

.hero-stage {
    position: relative;
    display: grid;
    gap: 1rem;
    align-self: stretch;
}

.hero-frame {
    position: relative;
    min-height: clamp(30rem, 58vw, 46rem);
    overflow: hidden;
    border-radius: clamp(1.8rem, 5vw, 4.5rem);
    box-shadow: var(--shadow-deep);
    isolation: isolate;
}

.hero-frame img,
.journey-hero-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-frame::after,
.journey-hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(8, 22, 21, 0.02) 0%, rgba(8, 22, 21, 0.62) 100%),
        linear-gradient(115deg, rgba(255, 250, 240, 0.18), transparent 45%);
    pointer-events: none;
}

.route-overlay {
    position: absolute;
    inset: 10% 10% auto auto;
    z-index: 2;
    width: 42%;
    aspect-ratio: 1;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
}

.route-overlay span {
    position: absolute;
    width: 0.7rem;
    height: 0.7rem;
    border-radius: 50%;
    background: #fffaf0;
    box-shadow: 0 0 0 0.42rem rgba(255, 250, 240, 0.16);
}

.route-overlay span:nth-child(1) {
    top: 24%;
    left: 18%;
}

.route-overlay span:nth-child(2) {
    top: 48%;
    right: 18%;
}

.route-overlay span:nth-child(3) {
    right: 36%;
    bottom: 18%;
}

.hero-panel {
    position: absolute;
    right: 1rem;
    bottom: 7.5rem;
    z-index: 3;
    width: min(25rem, calc(100vw - 3rem));
    padding: 1.25rem;
    border-radius: var(--radius-lg);
    color: #fffaf0;
    background: rgba(16, 35, 33, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(18px);
    box-shadow: 0 22px 60px rgba(5, 15, 14, 0.26);
}

.hero-panel h2 {
    font-size: clamp(2rem, 4vw, 2.8rem);
}

.hero-panel p,
.hero-panel .text-link {
    color: rgba(255, 250, 240, 0.82);
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin-top: 0.9rem;
    color: var(--green-dark);
    font-weight: 900;
}

.text-link::after {
    content: "\2192";
}

.hero-rail {
    position: absolute;
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    z-index: 4;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.7rem;
}

.rail-card {
    display: grid;
    grid-template-columns: 4rem minmax(0, 1fr);
    gap: 0.7rem;
    align-items: center;
    padding: 0.55rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 1.2rem;
    background: rgba(255, 250, 240, 0.86);
    box-shadow: 0 14px 34px rgba(5, 15, 14, 0.18);
}

.rail-card img {
    width: 4rem;
    height: 4rem;
    border-radius: 0.85rem;
    object-fit: cover;
}

.rail-card strong {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.9rem;
}

.rail-card span {
    color: var(--muted);
    font-size: 0.78rem;
}

.section {
    padding-top: clamp(4.5rem, 8vw, 7.5rem);
}

.section-heading {
    max-width: 46rem;
    margin-bottom: 2rem;
}

.section-heading h2,
.notebook-layout h2,
.contact-copy h2,
.map-copy h3 {
    font-size: clamp(2.4rem, 5vw, 4.8rem);
}

.featured-grid,
.archive-grid,
.map-layout,
.contact-layout,
.notebook-layout {
    display: grid;
    gap: 1rem;
}

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

.featured-card {
    position: relative;
    min-height: 24rem;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--night);
    box-shadow: var(--shadow-soft);
    isolation: isolate;
}

.featured-card::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(180deg, transparent 24%, rgba(8, 22, 21, 0.78) 100%);
}

.featured-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 700ms ease;
}

.featured-card:hover img {
    transform: scale(1.07);
}

.featured-content {
    position: absolute;
    inset: auto 0 0;
    z-index: 2;
    display: grid;
    gap: 0.65rem;
    padding: 1.15rem;
    color: #fffaf0;
}

.featured-content h3 {
    font-size: clamp(1.7rem, 3.3vw, 2.35rem);
}

.meta-row,
.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    width: fit-content;
    padding: 0.35rem 0.6rem;
    border-radius: 999px;
    background: rgba(255, 250, 240, 0.15);
    color: inherit;
    font-size: 0.74rem;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.explorer-shell {
    padding: clamp(0.8rem, 2vw, 1.2rem);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    background: rgba(255, 250, 240, 0.64);
    box-shadow: var(--shadow-soft);
}

.explorer-toolbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 12rem 14rem;
    gap: 0.75rem;
}

.search-field,
.select-field,
.field-group {
    display: grid;
    gap: 0.45rem;
}

.search-field {
    position: relative;
}

.search-field .fas {
    position: absolute;
    top: 50%;
    left: 1rem;
    color: var(--soft);
    transform: translateY(-50%);
}

.search-field input,
.select-field select,
.field-group input,
.field-group textarea {
    width: 100%;
    min-height: 3.25rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.74);
    color: var(--ink);
    outline: 0;
    transition: border-color var(--fast), box-shadow var(--fast), background var(--fast);
}

.search-field input {
    padding: 0 1rem 0 2.75rem;
}

.select-field span,
.field-group span {
    color: var(--muted);
    font-size: 0.8rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.select-field select {
    padding: 0 0.9rem;
}

.field-group input,
.field-group textarea {
    border-radius: var(--radius-sm);
    padding: 0.85rem 1rem;
}

.field-group textarea {
    min-height: 10rem;
    resize: vertical;
}

.search-field input:focus,
.select-field select:focus,
.field-group input:focus,
.field-group textarea:focus {
    border-color: rgba(15, 118, 102, 0.52);
    background: white;
    box-shadow: 0 0 0 4px rgba(15, 118, 102, 0.1);
}

.filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin-top: 1rem;
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 2.7rem;
    padding: 0.65rem 0.9rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.65);
    font-weight: 900;
}

.chip.is-active {
    color: white;
    background: var(--night);
    border-color: var(--night);
}

.results-summary {
    margin: 1rem 0;
    color: var(--muted);
    font-weight: 800;
}

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

.journey-card {
    position: relative;
    overflow: hidden;
    min-height: 23rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: transparent;
    box-shadow: 0 14px 34px rgba(20, 35, 33, 0.08);
    isolation: isolate;
}

.journey-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: var(--surface-strong);
}

.journey-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    background-color: #2a3532; /* Color de fondo oscuro por si la imagen tarda o falla */
    transition: transform 650ms ease;
}

.journey-card:hover img {
    transform: scale(1.06);
}

.journey-card::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(180deg, rgba(8, 22, 21, 0.06) 0%, rgba(8, 22, 21, 0.82) 100%);
    pointer-events: none;
}

.journey-card-content {
    position: relative;
    z-index: 2;
    display: grid;
    gap: 0.7rem;
    padding: 1.1rem;
    color: #fffaf0;
}

.journey-card h3 {
    font-size: clamp(1.6rem, 3vw, 2.15rem);
}

.journey-card p {
    margin: 0;
    color: rgba(255, 250, 240, 0.78);
    font-size: 0.92rem;
}

.empty-state {
    grid-column: 1 / -1;
    padding: 2rem;
    border: 1px dashed var(--line-strong);
    border-radius: var(--radius-lg);
    color: var(--muted);
    background: rgba(255, 250, 240, 0.72);
}

.map-layout {
    grid-template-columns: minmax(0, 1.2fr) minmax(19rem, 0.8fr);
    align-items: stretch;
}

.map-board {
    position: relative;
    min-height: 34rem;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    background:
        linear-gradient(130deg, rgba(15, 118, 102, 0.16), transparent 45%),
        linear-gradient(320deg, rgba(232, 93, 63, 0.12), transparent 46%),
        #fdf8ed;
    box-shadow: var(--shadow-soft);
}

.map-board::before {
    content: "";
    position: absolute;
    inset: 12%;
    border: 1px dashed rgba(20, 35, 33, 0.2);
    border-radius: 52% 48% 45% 55%;
}

.map-point {
    position: absolute;
    left: var(--x);
    top: var(--y);
    transform: translate(-50%, -50%);
    display: inline-grid;
    place-items: center;
    width: clamp(2.6rem, 5vw, 4rem);
    height: clamp(2.6rem, 5vw, 4rem);
    border: 0;
    border-radius: 50%;
    background: var(--point-color, var(--green));
    color: white;
    box-shadow: 0 14px 34px rgba(20, 35, 33, 0.2);
}

.map-point span {
    position: absolute;
    left: 50%;
    top: calc(100% + 0.35rem);
    width: max-content;
    max-width: 9rem;
    padding: 0.28rem 0.48rem;
    border-radius: 999px;
    background: rgba(255, 250, 240, 0.92);
    color: var(--ink);
    font-size: 0.72rem;
    font-weight: 900;
    transform: translateX(-50%);
}

.map-copy,
.notebook-card,
.contact-form,
.contact-copy {
    padding: clamp(1.1rem, 3vw, 1.8rem);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    background: rgba(255, 250, 240, 0.72);
    box-shadow: var(--shadow-soft);
}

.map-copy h3 {
    font-size: clamp(2rem, 4vw, 3.3rem);
}

.map-legend,
.notebook-points {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin-top: 1rem;
}

.legend-item,
.notebook-points span {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 0.75rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    color: var(--muted);
    font-weight: 900;
    font-size: 0.85rem;
}

.legend-dot {
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    background: var(--dot-color);
}

.notebook-layout,
.contact-layout {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    align-items: start;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
}

.contact-form {
    display: grid;
    gap: 0.9rem;
}

.form-feedback {
    min-height: 1.5rem;
    margin: 0;
    color: var(--muted);
    font-weight: 800;
}

.form-feedback.is-error {
    color: #b53022;
}

.form-feedback.is-success {
    color: var(--green-dark);
}

.site-footer {
    width: var(--content);
    margin: 5rem auto 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    color: var(--muted);
    font-weight: 700;
}

.scroll-top-btn {
    width: 3rem;
    height: 3rem;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 50%;
    color: white;
    background: var(--night);
    box-shadow: var(--shadow-soft);
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
    transition: opacity var(--fast), transform var(--fast);
}

.scroll-top-btn.is-visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity var(--slow), transform var(--slow);
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.journey-hero {
    width: var(--content);
    margin: 0 auto;
    padding: clamp(2rem, 5vw, 4rem) 0 1rem;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: clamp(1rem, 4vw, 2rem);
    align-items: end;
}

.journey-hero-media {
    position: relative;
    min-height: clamp(24rem, 48vw, 40rem);
    overflow: hidden;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-deep);
}

.journey-hero-copy {
    padding: clamp(1rem, 3vw, 1.6rem);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    background: rgba(255, 250, 240, 0.82);
    box-shadow: var(--shadow-soft);
}

.journey-hero-copy h1 {
    font-size: clamp(3rem, 7vw, 6rem);
}

.gallery-grid {
    columns: 4 15rem;
    column-gap: 1rem;
}

.gallery-item {
    position: relative;
    display: block;
    width: 100%;
    margin: 0 0 1rem;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: var(--radius-md);
    background: #ddd3c5;
    box-shadow: 0 12px 30px rgba(20, 35, 33, 0.1);
    break-inside: avoid;
}

.gallery-item img {
    width: 100%;
    height: auto;
    transition: transform 500ms ease, filter 500ms ease;
}

.gallery-item:hover img {
    transform: scale(1.045);
    filter: saturate(1.08);
}

.gallery-item span {
    position: absolute;
    left: 0.65rem;
    bottom: 0.65rem;
    padding: 0.28rem 0.52rem;
    border-radius: 999px;
    background: rgba(16, 35, 33, 0.74);
    color: white;
    font-size: 0.74rem;
    font-weight: 900;
}

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: grid;
    place-items: center;
    padding: 1rem;
    background: rgba(5, 15, 14, 0.92);
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--fast);
}

.lightbox.is-open {
    opacity: 1;
    pointer-events: auto;
}

.lightbox figure {
    margin: 0;
    display: grid;
    gap: 0.8rem;
    justify-items: center;
}

.lightbox img {
    max-width: min(96vw, 1280px);
    max-height: 82svh;
    border-radius: var(--radius-sm);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.42);
}

.lightbox figcaption {
    color: rgba(255, 250, 240, 0.84);
    font-weight: 800;
}

.lightbox-close,
.lightbox-nav {
    position: fixed;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: white;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
}

.lightbox-close {
    top: 1rem;
    right: 1rem;
    width: 3rem;
    height: 3rem;
}

.lightbox-nav {
    top: 50%;
    width: 3.2rem;
    height: 3.2rem;
    transform: translateY(-50%);
}

.lightbox-nav.prev {
    left: 1rem;
}

.lightbox-nav.next {
    right: 1rem;
}

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

@media (max-width: 1100px) {
    .hero,
    .journey-hero,
    .map-layout,
    .notebook-layout,
    .contact-layout {
        grid-template-columns: 1fr;
    }

    .hero h1 {
        max-width: 12ch;
    }

    .hero-stage {
        order: -1;
    }

    .hero-panel {
        position: relative;
        right: auto;
        bottom: auto;
        width: 100%;
        margin-top: -4rem;
    }

    .hero-rail {
        position: relative;
        left: auto;
        right: auto;
        bottom: auto;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

    .explorer-toolbar {
        grid-template-columns: 1fr 1fr;
    }

    .search-field {
        grid-column: 1 / -1;
    }
}

@media (max-width: 780px) {
    :root {
        --content: min(100vw - 1rem, 1180px);
    }

    .site-header {
        top: 0.5rem;
        min-height: auto;
        border-radius: 1.4rem;
    }

    .nav-toggle {
        display: block;
        flex: 0 0 auto;
    }

    .site-nav {
        position: fixed;
        inset: 5.4rem 0.5rem auto 0.5rem;
        display: grid;
        padding: 0.7rem;
        border: 1px solid var(--line);
        border-radius: 1.2rem;
        background: rgba(255, 250, 240, 0.98);
        box-shadow: var(--shadow-deep);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-8px);
        transition: opacity var(--fast), visibility var(--fast), transform var(--fast);
    }

    .site-nav-inline {
        position: static;
        display: none;
    }

    body.nav-open .site-nav {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .site-nav a {
        width: 100%;
        background: rgba(255, 255, 255, 0.65);
    }

    .brand-copy span {
        display: none;
    }

    .hero {
        min-height: auto;
        padding-top: 2rem;
    }

    .hero h1,
    .journey-hero-copy h1 {
        font-size: clamp(2.8rem, 14vw, 4.7rem);
    }

    .hero-frame,
    .journey-hero-media {
        min-height: 23rem;
        border-radius: 1.8rem;
    }

    .hero-rail,
    .featured-grid,
    .archive-grid,
    .related-grid,
    .form-grid,
    .stat-strip {
        grid-template-columns: 1fr;
    }

    .explorer-toolbar {
        grid-template-columns: 1fr;
    }

    .filter-chips {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 0.2rem;
    }

    .chip {
        flex: 0 0 auto;
    }

    .map-board {
        min-height: auto;
        display: grid;
        gap: 0.75rem;
        padding: 1rem;
    }

    .map-board::before {
        display: none;
    }

    .map-point {
        position: static;
        width: 100%;
        height: auto;
        min-height: 3.25rem;
        transform: none;
        grid-template-columns: auto 1fr;
        justify-content: start;
        gap: 0.8rem;
        padding: 0.8rem 0.95rem;
        border-radius: 999px;
    }

    .map-point span {
        position: static;
        max-width: none;
        padding: 0;
        background: transparent;
        color: white;
        transform: none;
        font-size: 0.85rem;
    }

    .gallery-grid {
        columns: 1;
    }

    .lightbox-nav {
        top: auto;
        bottom: 1rem;
        transform: none;
    }

    .site-footer {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation: none !important;
        transition-duration: 0.01ms !important;
        transition-delay: 0ms !important;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }
}
