/* angie-holste.de – public site. Layout reference: Canva "Neue Webseite 2", 1366 px wide. */

@font-face {
    font-family: "Libre Caslon Text";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../fonts/libre-caslon-text-latin-400-normal.woff2") format("woff2");
}
@font-face {
    font-family: "Libre Caslon Text";
    font-style: italic;
    font-weight: 400;
    font-display: swap;
    src: url("../fonts/libre-caslon-text-latin-400-italic.woff2") format("woff2");
}
@font-face {
    font-family: "Libre Caslon Text";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("../fonts/libre-caslon-text-latin-700-normal.woff2") format("woff2");
}
@font-face {
    font-family: "Montserrat";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../fonts/montserrat-latin-400-normal.woff2") format("woff2");
}
@font-face {
    font-family: "Montserrat";
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url("../fonts/montserrat-latin-600-normal.woff2") format("woff2");
}

:root {
    --dark: #252627;
    --text: #231f20;
    --beige: #c4bdac;
    --sand: #e7dfd8;
    --rose: #f4e3e6;
    --white: #ffffff;
    --placeholder: #b3ab99;

    --serif: "Libre Caslon Text", Georgia, "Times New Roman", serif;
    --sans: "Montserrat", "Helvetica Neue", Arial, sans-serif;

    --nav-h: 64px;
    --gutter: max(16px, 5.6vw);
    --content: 1212px;
    --section-space: clamp(3.5rem, 5.6vw, 5rem);

    --fs-title: clamp(2rem, 3.4vw, 2.9rem);
    --fs-name: clamp(1.35rem, 2.1vw, 1.85rem);
    --fs-price: clamp(1rem, 1.5vw, 1.3rem);
    --fs-body: clamp(1rem, 1.3vw, 1.15rem);
    --fs-intro: clamp(1.1rem, 1.9vw, 1.6rem);
}

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

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

html:has(dialog[open]) {
    overflow: hidden;
}

body {
    margin: 0;
    background: var(--sand);
    color: var(--text);
    font-family: var(--serif);
    font-size: var(--fs-body);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

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

a {
    color: inherit;
    text-underline-offset: 0.18em;
    text-decoration-thickness: 1px;
}

:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

h1,
h2,
h3 {
    font-weight: 400;
    line-height: 1.15;
}

.container {
    width: min(var(--content), 100% - 2 * var(--gutter));
    margin-inline: auto;
}

.visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.skip-link {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    z-index: 100;
    padding: 0.6rem 1rem;
    background: var(--white);
    color: var(--dark);
    font-family: var(--sans);
    font-size: 0.9rem;
    transform: translateY(-200%);
}

.skip-link:focus {
    transform: none;
}

/* Neutral placeholder until an image is uploaded. */
.ph {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 100%;
    background:
        repeating-linear-gradient(135deg, transparent 0 14px, rgb(255 255 255 / 0.14) 14px 15px),
        var(--placeholder);
}

.prose > :first-child {
    margin-top: 0;
}

.prose > :last-child {
    margin-bottom: 0;
}

.prose p,
.prose ul {
    margin: 0 0 1em;
}

.prose h2 {
    margin: 1.8em 0 0.6em;
    font-size: 1.45em;
}

.prose h3 {
    margin: 1.5em 0 0.5em;
    font-size: 1.2em;
}

.prose ul {
    padding-left: 1.2em;
}

/* Buttons */

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 3.2rem;
    padding: 0.85rem 2.4rem;
    border: 1px solid currentColor;
    font-family: var(--sans);
    font-size: clamp(0.8rem, 1vw, 0.95rem);
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.button--light {
    min-width: min(100%, 20rem);
    color: var(--white);
}

.button--light:hover {
    background: var(--white);
    color: var(--dark);
}

.button--dark {
    color: var(--dark);
}

.button--dark:hover {
    background: var(--dark);
    color: var(--white);
}

/* Logo */

.logo {
    margin: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
    background: var(--white);
    color: var(--dark);
    text-decoration: none;
}

.logo--hero {
    position: relative;
    width: clamp(210px, 22.3vw, 320px);
    aspect-ratio: 305 / 149;
}

.logo--small {
    width: 150px;
    aspect-ratio: 305 / 149;
}

/* The whole logo stays visible, whatever its aspect ratio. */
.logo__img {
    width: 100%;
    height: 100%;
    padding: 9% 11%;
    object-fit: contain;
}

.logo__text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35em;
    font-size: clamp(0.9rem, 1.6vw, 1.4rem);
    line-height: 1;
}

.logo--small .logo__text {
    font-size: 0.75rem;
}

.logo__name {
    font-family: var(--serif);
    font-style: italic;
    font-size: 1.25em;
}

.logo__sub {
    font-family: var(--sans);
    font-size: 0.55em;
    letter-spacing: 0.55em;
    margin-right: -0.55em;
    text-transform: uppercase;
}

/* Hero */

.hero {
    position: relative;
    display: grid;
    min-height: 100vh;
    min-height: 100svh;
    overflow: hidden;
    background: var(--dark);
    color: var(--white);
}

.hero__bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 30%;
}

.hero .ph.hero__bg {
    background: linear-gradient(160deg, #57524a, var(--dark));
}

.hero__shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgb(20 20 20 / 0.25), rgb(20 20 20 / 0.42));
}

.hero__inner {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-block: max(calc(var(--nav-h) + 1.5rem), clamp(3rem, 13.7vh, 6.5rem)) clamp(3rem, 9vh, 5rem);
    text-align: center;
}

.hero__brand {
    position: relative;
    display: flex;
    justify-content: center;
    width: 100%;
}

.hero__brand::before {
    content: "";
    position: absolute;
    inset-inline: 0;
    top: 15%;
    height: 1px;
    background: var(--white);
}

.hero__intro {
    max-width: 62rem;
    margin-top: clamp(2.5rem, 9vh, 4.5rem);
    font-size: var(--fs-intro);
    line-height: 1.35;
    letter-spacing: -0.02em;
    text-shadow: 0 1px 12px rgb(0 0 0 / 0.35);
}

.hero__intro p {
    margin: 0 0 0.6em;
}

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

.hero__tagline {
    margin: clamp(2.5rem, 12vh, 6rem) 0 0;
    font-family: var(--sans);
    font-size: var(--fs-intro);
    line-height: 1.4;
    letter-spacing: -0.01em;
    text-shadow: 0 1px 12px rgb(0 0 0 / 0.35);
}

.hero .button {
    margin-top: clamp(2rem, 7.5vh, 3.75rem);
}

/* Section title with rule, used by tile groups and contact */

.section-title {
    margin: 0;
    padding-bottom: clamp(0.9rem, 1.5vw, 1.3rem);
    border-bottom: 1px solid var(--dark);
    font-size: var(--fs-title);
    letter-spacing: -0.04em;
    text-align: center;
}

.rule {
    height: 0;
    margin: clamp(3rem, 5.5vw, 5rem) 0 0;
    border: 0;
    border-top: 1px solid var(--dark);
}

/* About */

.about {
    padding-block: clamp(3rem, 11.7vw, 10rem) clamp(3rem, 5.6vw, 5rem);
    background: var(--sand);
}

.about__frame {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.86fr);
    gap: clamp(1.5rem, 2.8vw, 2.5rem);
    padding: clamp(1rem, 1.35vw, 1.2rem);
    padding-left: clamp(1.25rem, 3.8vw, 3.5rem);
    border: 1px solid var(--text);
}

.about__text {
    align-self: center;
    padding-block: clamp(1rem, 2vw, 2rem);
    font-size: clamp(1rem, 1.45vw, 1.25rem);
    line-height: 1.35;
    letter-spacing: -0.02em;
    text-align: center;
}

.about__text .social {
    justify-content: flex-start;
    margin-top: 1.5rem;
}

.about__media {
    min-height: 100%;
}

.about__media .about__img,
.about__media .ph {
    width: 100%;
    height: 100%;
    min-height: 22rem;
    aspect-ratio: 508 / 495;
    object-fit: cover;
}

/* Social links */

.social {
    display: flex;
    gap: 1.1rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.social__link {
    display: inline-flex;
    padding: 0.2rem;
    color: var(--text);
}

.social__icon {
    width: 1.9rem;
    height: 1.9rem;
}

/* Material */

.material {
    background: var(--beige);
    overflow: hidden;
}

.material__grid {
    display: grid;
    grid-template-columns: minmax(0, 47.4fr) minmax(0, 44.4fr);
    gap: clamp(1rem, 3.3vw, 3rem);
    max-width: 1600px;
    min-height: min(56.2vw, 52rem);
    margin-inline: auto;
    padding-left: 1.8vw;
    padding-right: 3.2vw;
}

.material__main {
    position: relative;
    min-height: 26rem;
}

.material__main > .material__img,
.material__main > .ph {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.material__main::after {
    content: "";
    position: absolute;
    inset: 0 0 45% 0;
    background: linear-gradient(180deg, rgb(20 20 20 / 0.45), transparent);
    pointer-events: none;
}

.material__text {
    position: relative;
    z-index: 1;
    max-width: 34rem;
    padding: clamp(2rem, 8vw, 7rem) 6% 2rem 21%;
    color: var(--rose);
    font-size: clamp(0.95rem, 1.45vw, 1.25rem);
    line-height: 1.4;
    letter-spacing: -0.02em;
}

.material__text p {
    margin: 0 0 1.2em;
}

.material__lead {
    font-size: 1.12em;
}

.material__side {
    display: grid;
    align-content: start;
    gap: clamp(0.75rem, 1.3vw, 1.2rem);
    padding-top: clamp(1.5rem, 3vw, 2.6rem);
}

/* Fixed format from the Canva layout, so tall photos cannot stretch the section. */
.material__side > .material__img,
.material__side > .ph {
    width: 100%;
    height: auto;
    aspect-ratio: 606 / 355;
    object-fit: cover;
}

/* Tile groups */

.tiles {
    padding-block: var(--section-space);
    background: var(--beige);
}

.tiles + .tiles {
    padding-top: 0;
}

.tiles + .tiles .section-title {
    padding-top: var(--section-space);
}

.tiles__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(3rem, 5.5vw, 5rem) clamp(1rem, 1.6vw, 1.4rem);
    margin: clamp(2rem, 3.4vw, 3rem) 0 0;
    padding: 0;
    list-style: none;
}

.tile__card {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font: inherit;
    text-align: center;
}

.tile__card--link {
    cursor: pointer;
}

.tile__media {
    display: block;
    aspect-ratio: 390 / 369;
    margin-bottom: clamp(1.5rem, 3.8vw, 3.25rem);
    overflow: hidden;
}

.tile__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.tile__card--link:hover .tile__img,
.tile__card--link:focus-visible .tile__img {
    transform: scale(1.04);
}

.tile__name {
    display: block;
    padding-top: clamp(0.6rem, 0.9vw, 0.8rem);
    border-top: 1px solid var(--dark);
    font-size: var(--fs-name);
    line-height: 1.1;
    letter-spacing: -0.05em;
}

.tile__price {
    display: block;
    margin-top: 0.55rem;
    font-size: var(--fs-price);
    letter-spacing: -0.03em;
}

.tile__more {
    display: block;
    margin-top: 0.7rem;
    font-family: var(--sans);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    opacity: 0.75;
}

.tile__card--link:hover .tile__more {
    opacity: 1;
    text-decoration: underline;
    text-underline-offset: 0.3em;
}

/* Contact */

.contact {
    padding-block: var(--section-space);
    background: var(--sand);
}

.contact__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(2rem, 5vw, 5rem);
    margin-top: clamp(2rem, 3.4vw, 3rem);
}

.contact__intro {
    font-size: clamp(1.1rem, 1.7vw, 1.45rem);
    line-height: 1.4;
    letter-spacing: -0.02em;
}

.contact__item {
    margin: 0 0 1.4rem;
}

.contact__label {
    display: block;
    margin-bottom: 0.2rem;
    font-family: var(--sans);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.contact__details .social {
    margin-top: 0.5rem;
}

/* Footer */

.footer {
    padding-block: 1.75rem;
    background: var(--dark);
    color: var(--white);
    font-family: var(--sans);
    font-size: 0.85rem;
}

.footer__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 2rem;
}

.footer__copy {
    margin: 0;
}

.footer__nav {
    display: flex;
    gap: 1.5rem;
}

.footer__nav a {
    display: inline-block;
    padding-block: 0.5rem;
    text-decoration: none;
}

.footer__nav a:hover,
.footer__nav a[aria-current="page"] {
    text-decoration: underline;
}

/* Legal pages */

.legal {
    padding-block: calc(var(--nav-h) + var(--section-space)) var(--section-space);
}

.legal__inner {
    max-width: 46rem;
}

.legal__title {
    margin: 0 0 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--dark);
    font-size: var(--fs-title);
    letter-spacing: -0.04em;
    /* "Datenschutzerklärung" is wider than a 320 px screen. */
    overflow-wrap: break-word;
    hyphens: auto;
}

.legal .prose {
    line-height: 1.6;
}

/* Lightbox */

.lightbox {
    width: min(1120px, 100% - 2rem);
    max-width: none;
    max-height: calc(100svh - 2rem);
    padding: 0;
    border: 0;
    background: var(--sand);
    color: var(--text);
    overflow: auto;
    overscroll-behavior: contain;
}

.lightbox::backdrop {
    background: rgb(37 38 39 / 0.82);
}

.lightbox__close {
    position: absolute;
    top: 0.6rem;
    right: 0.6rem;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgb(255 255 255 / 0.9);
    color: var(--dark);
    cursor: pointer;
}

.lightbox__close svg,
.lb__nav svg {
    width: 1.3rem;
    height: 1.3rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
}

.lb {
    display: grid;
}

.lb--gallery {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
}

.lb__gallery {
    position: relative;
    background: var(--dark);
}

.lb__slides,
.lb__slide {
    height: 100%;
    margin: 0;
}

.lb__slide[hidden] {
    display: none;
}

.lb__img {
    width: 100%;
    height: min(78svh, 46rem);
    object-fit: contain;
}

.lb__nav {
    position: absolute;
    top: 50%;
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgb(255 255 255 / 0.9);
    color: var(--dark);
    cursor: pointer;
    transform: translateY(-50%);
}

.lb__nav--prev {
    left: 0.75rem;
}

.lb__nav--next {
    right: 0.75rem;
}

.lb__count {
    position: absolute;
    bottom: 0.75rem;
    left: 50%;
    margin: 0;
    padding: 0.2rem 0.7rem;
    border-radius: 1rem;
    background: rgb(37 38 39 / 0.6);
    color: var(--white);
    font-family: var(--sans);
    font-size: 0.75rem;
    transform: translateX(-50%);
}

.lb__body {
    align-self: center;
    padding: clamp(2.5rem, 4vw, 3.5rem) clamp(1.5rem, 3.5vw, 3rem);
}

.lb__title {
    margin: 0;
    padding-bottom: 0.8rem;
    border-bottom: 1px solid var(--dark);
    font-size: var(--fs-title);
    letter-spacing: -0.04em;
}

.lb__price {
    margin: 0.8rem 0 0;
    font-size: var(--fs-price);
}

.lb__text {
    margin-top: 1.5rem;
    line-height: 1.55;
}

.lb__cta {
    margin-top: 2rem;
}

/* Sticky menu. Transparent on the hero, dark after scrolling (nav--scrolled) and on legal pages (nav--solid). */

main [id],
.hero {
    scroll-margin-top: var(--nav-h);
}

.nav {
    position: fixed;
    inset: 0 0 auto;
    z-index: 50;
    height: var(--nav-h);
    color: var(--white);
    background: transparent;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

/* Placed at the top of the hero by site.js; when it leaves the viewport, the bar turns dark. */
.nav-sentinel {
    position: absolute;
    top: 0;
    left: 0;
    width: 1px;
    height: var(--nav-h);
    pointer-events: none;
}

.nav--scrolled,
.nav--solid {
    background: var(--dark);
    box-shadow: 0 1px 0 rgb(255 255 255 / 0.08);
}

.nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    height: 100%;
}

.nav__brand {
    display: flex;
    flex-direction: column;
    padding-block: 0.4rem;
    color: inherit;
    line-height: 1;
    text-decoration: none;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* On the hero the big logo is visible, so the small one stays hidden. */
.nav:not(.nav--scrolled):not(.nav--solid) .nav__brand {
    opacity: 0;
    visibility: hidden;
}

.nav:not(.nav--scrolled):not(.nav--solid) a {
    text-shadow: 0 1px 8px rgb(0 0 0 / 0.4);
}

.nav:not(.nav--scrolled):not(.nav--solid) .nav__toggle {
    filter: drop-shadow(0 1px 6px rgb(0 0 0 / 0.35));
}

.nav__brand-name {
    font-family: var(--serif);
    font-size: 1.2rem;
    font-style: italic;
}

.nav__brand-sub {
    margin-top: 0.3rem;
    font-family: var(--sans);
    font-size: 0.55rem;
    letter-spacing: 0.5em;
    text-transform: uppercase;
}

.nav__desktop {
    display: none;
    align-items: center;
    gap: 1.75rem;
}

.nav__list,
.nav__legal {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.nav__list a {
    display: inline-block;
    padding-block: 0.5rem;
    font-family: var(--sans);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-decoration: none;
    text-transform: uppercase;
    text-underline-offset: 0.6em;
}

.nav__list a:hover,
.nav__list a[aria-current] {
    text-decoration: underline;
    text-decoration-thickness: 1px;
}

.nav__legal {
    gap: 1rem;
    padding-left: 1.5rem;
    border-left: 1px solid rgb(255 255 255 / 0.35);
}

.nav__legal a {
    display: inline-block;
    padding-block: 0.5rem;
    font-family: var(--sans);
    font-size: 0.7rem;
    text-decoration: none;
    opacity: 0.85;
}

.nav__legal a:hover,
.nav__legal a[aria-current] {
    opacity: 1;
    text-decoration: underline;
}

.nav__toggle {
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    margin-right: -0.6rem;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    cursor: pointer;
}

.nav__toggle svg {
    width: 1.6rem;
    height: 1.6rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
}

@media (min-width: 1100px) {
    .nav:not(.nav--compact) .nav__desktop {
        display: flex;
    }

    .nav:not(.nav--compact) .nav__toggle {
        display: none;
    }
}

/* Offcanvas menu for small screens: a modal <dialog> sliding in from the right. */

.offcanvas {
    inset: 0 0 0 auto;
    width: min(22rem, 85vw);
    max-width: none;
    height: 100%;
    max-height: none;
    margin: 0;
    padding: 0;
    border: 0;
    background: var(--sand);
    color: var(--text);
    overflow-y: auto;
    overscroll-behavior: contain;
}

.offcanvas[open] {
    display: flex;
    flex-direction: column;
}

.offcanvas::backdrop {
    background: rgb(37 38 39 / 0.6);
}

.offcanvas__head {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: space-between;
    height: var(--nav-h);
    padding: 0 0.75rem 0 1.5rem;
    border-bottom: 1px solid var(--dark);
}

.offcanvas__brand {
    font-family: var(--serif);
    font-size: 1.2rem;
    font-style: italic;
}

.offcanvas__close {
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 0;
    background: none;
    color: var(--dark);
    cursor: pointer;
}

.offcanvas__close svg {
    width: 1.4rem;
    height: 1.4rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
}

.offcanvas__list {
    margin: 0;
    padding: 1rem 1.5rem;
    list-style: none;
}

.offcanvas__list a {
    display: block;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgb(37 38 39 / 0.15);
    font-size: 1.45rem;
    letter-spacing: -0.03em;
    line-height: 1.2;
    text-decoration: none;
}

.offcanvas__list a[aria-current] {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.2em;
}

.offcanvas__foot {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: auto;
    padding: 1.5rem;
}

.offcanvas__legal {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
    font-family: var(--sans);
    font-size: 0.85rem;
}

.offcanvas__legal a {
    display: inline-block;
    padding-block: 0.4rem;
}

@media (prefers-reduced-motion: no-preference) {
    .offcanvas[open] {
        animation: offcanvas-in 0.3s ease-out;
    }

    .offcanvas[open]::backdrop {
        animation: popup-fade 0.3s ease-out;
    }
}

@keyframes offcanvas-in {
    from {
        transform: translateX(100%);
    }
    to {
        transform: none;
    }
}

/* Start popup. Colors come from a nonce-protected <style> block as custom properties. */

.popup {
    --popup-bg: var(--sand);
    --popup-overlay: rgb(37 38 39 / 0.4);
    width: min(640px, 100% - 2rem);
    max-width: none;
    max-height: calc(100svh - 2rem);
    padding: 0;
    border: 0;
    background: var(--popup-bg);
    color: var(--text);
    overflow: auto;
    overscroll-behavior: contain;
}

.popup--has-media {
    width: min(960px, 100% - 2rem);
}

.popup::backdrop {
    background: rgb(37 38 39 / 0.7);
}

.popup--text-light {
    color: var(--white);
}

.popup__close {
    position: absolute;
    top: 0.6rem;
    right: 0.6rem;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgb(255 255 255 / 0.9);
    color: var(--dark);
    cursor: pointer;
}

.popup__close svg {
    width: 1.3rem;
    height: 1.3rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
}

.popup__layout {
    display: grid;
}

.popup--has-media .popup__layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    min-height: 26rem;
}

.popup--image-right .popup__media {
    order: 2;
}

.popup__media {
    position: relative;
    min-height: 22rem;
    background: var(--dark);
}

.popup__img,
.popup__bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.popup__body {
    position: relative;
    display: grid;
    align-items: center;
}

.popup--bg-image .popup__body {
    min-height: 26rem;
}

.popup__overlay {
    position: absolute;
    inset: 0;
    background: var(--popup-overlay);
}

.popup__content {
    position: relative;
    padding: clamp(3rem, 5vw, 4rem) clamp(1.5rem, 5vw, 3.5rem);
}

.popup--align-center .popup__content {
    text-align: center;
}

.popup__title {
    margin: 0 0 1rem;
    font-size: var(--fs-title);
    letter-spacing: -0.04em;
}

.popup__text {
    line-height: 1.55;
}

.popup__button {
    margin-top: 1.75rem;
}

.popup--text-dark .popup__button:hover {
    background: var(--dark);
    color: var(--white);
}

.popup--text-light .popup__button:hover {
    background: var(--white);
    color: var(--dark);
}

@media (prefers-reduced-motion: no-preference) {
    .popup[open] {
        animation: popup-in 0.35s ease-out;
    }

    .popup[open]::backdrop {
        animation: popup-fade 0.35s ease-out;
    }
}

@keyframes popup-in {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes popup-fade {
    from {
        opacity: 0;
    }
}

@media (max-width: 699px) {
    .popup--has-media .popup__layout {
        grid-template-columns: minmax(0, 1fr);
        min-height: 0;
    }

    .popup--image-right .popup__media {
        order: 0;
    }

    .popup__media {
        min-height: 0;
        height: 40svh;
    }

    .popup--bg-image .popup__body {
        min-height: 60svh;
    }
}

/* Responsive */

@media (max-width: 1023px) {
    .tiles__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 899px) {
    .about__frame {
        grid-template-columns: minmax(0, 1fr);
        padding: 1rem;
    }

    .about__media {
        order: -1;
    }

    .about__media .about__img,
    .about__media .ph {
        min-height: 0;
        height: auto;
    }

    .about__text .social {
        justify-content: center;
    }

    .material__grid {
        grid-template-columns: 1fr;
        min-height: 0;
        padding: 0 0 var(--gutter);
    }

    .material__main {
        min-height: 0;
        aspect-ratio: 4 / 3;
    }

    .material__text {
        max-width: none;
        padding: 2.5rem var(--gutter);
    }

    .material__side {
        grid-template-rows: none;
        grid-template-columns: 1fr 1fr;
        padding: 0 var(--gutter);
    }

    .material__side > .material__img,
    .material__side > .ph {
        aspect-ratio: 1;
        min-height: 0;
    }

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

    .lb--gallery {
        grid-template-columns: 1fr;
    }

    .lb__img {
        height: min(60svh, 34rem);
    }
}

/* Tablet portrait: stacked about image in a calmer landscape format. */
@media (min-width: 600px) and (max-width: 899px) {
    .about__media .about__img,
    .about__media .ph {
        aspect-ratio: 4 / 3;
    }
}

/* Phones in landscape: little height, so dialogs drop their minimum heights and use two columns. */
@media (max-height: 500px) and (min-width: 600px) {
    .popup--has-media .popup__layout,
    .popup__media,
    .popup--bg-image .popup__body {
        min-height: 0;
    }

    .popup__content {
        padding-block: 2rem;
    }

    .lb--gallery {
        grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    }

    .lb__img {
        height: calc(100svh - 2rem);
    }

    .lb__body {
        padding-block: 2rem;
    }
}

@media (max-width: 699px) {
    :root {
        --nav-h: 56px;
    }
}

@media (max-width: 599px) {
    .tiles__grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .material__main {
        aspect-ratio: 4 / 5;
    }

    .hero__intro p br {
        display: none;
    }

    .lightbox {
        width: 100%;
        max-height: 100svh;
        height: 100svh;
        margin: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        transition: none !important;
        animation: none !important;
    }
}

/* ---------- Section types from the "Bereiche" kit: text, gallery, photo band, quotes, FAQ, events ---------- */

.sec {
    padding-block: var(--section-space);
    background: var(--sand);
}

.sec + .sec {
    padding-top: 0;
}

.sec__head {
    margin-bottom: clamp(2rem, 4vw, 3rem);
}

.sec__action {
    margin: clamp(1.75rem, 3vw, 2.5rem) 0 0;
    text-align: center;
}

.sec-text__inner,
.sec-faq__inner,
.sec-events__inner {
    width: min(52rem, 100% - 2 * var(--gutter));
}

.sec-text__body {
    font-size: var(--fs-body);
    text-align: center;
}

.sec-gallery__intro,
.sec-faq__intro,
.sec-events__intro {
    max-width: 46rem;
    margin: 0 auto clamp(1.5rem, 3vw, 2.5rem);
    text-align: center;
}

/* Gallery */

.sec-gallery__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(0.6rem, 1.4vw, 1.2rem);
    margin: 0;
    padding: 0;
    list-style: none;
}

.sec-gallery__item {
    display: block;
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    padding: 0;
    border: 0;
    background: var(--placeholder);
    cursor: zoom-in;
}

.sec-gallery__img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: scale 0.6s ease;
}

.sec-gallery__item:hover .sec-gallery__img {
    scale: 1.04;
}

.sec-gallery__item:focus-visible {
    outline: 2px solid var(--dark);
    outline-offset: 3px;
}

/* Photo band */

.sec-band {
    position: relative;
    overflow: hidden;
    background: var(--dark);
}

.sec-band__media {
    margin: 0;
}

.band__img {
    display: block;
    width: 100%;
    height: clamp(18rem, 62vh, 40rem);
    object-fit: cover;
}

.sec-band__overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    background: linear-gradient(to top, rgb(37 38 39 / 0.7), rgb(37 38 39 / 0) 65%);
    pointer-events: none;
}

.sec-band__content {
    padding-block: clamp(1.5rem, 4vw, 3rem);
    color: var(--white);
    text-align: center;
    pointer-events: auto;
}

.sec-band__text {
    max-width: 40rem;
    margin: 0 auto;
    font-family: var(--serif);
    font-size: var(--fs-intro);
    line-height: 1.35;
}

.sec-band .sec__action {
    margin-top: 1.25rem;
}

/* Quotes */

.sec-quotes__list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(18rem, 100%), 1fr));
    gap: clamp(1rem, 2vw, 1.5rem);
    margin: 0;
    padding: 0;
    list-style: none;
}

.quote {
    height: 100%;
    margin: 0;
    padding: clamp(1.5rem, 2.5vw, 2.25rem);
    border: 1px solid var(--text);
    text-align: center;
}

.quote__text {
    margin: 0;
    font-family: var(--serif);
    font-size: clamp(1.1rem, 1.5vw, 1.3rem);
    line-height: 1.5;
}

.quote__text p {
    margin: 0;
}

.quote__text p::before {
    content: "„";
}

.quote__text p::after {
    content: "“";
}

.quote__by {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-top: 1.25rem;
    font-size: 0.85rem;
}

.quote__name {
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

/* FAQ */

.faq {
    border-top: 1px solid var(--dark);
}

.faq__item {
    border-bottom: 1px solid var(--dark);
}

.faq__q {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.1rem 0;
    font-family: var(--serif);
    font-size: clamp(1.1rem, 1.6vw, 1.35rem);
    cursor: pointer;
    list-style: none;
}

.faq__q::-webkit-details-marker {
    display: none;
}

.faq__q:focus-visible {
    outline: 2px solid var(--dark);
    outline-offset: 4px;
}

.faq__icon {
    position: relative;
    flex: none;
    width: 1rem;
    height: 1rem;
}

.faq__icon::before,
.faq__icon::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    background: currentColor;
    transition: rotate 0.25s ease;
}

.faq__icon::after {
    rotate: 90deg;
}

.faq__item[open] .faq__icon::after {
    rotate: 0deg;
}

.faq__a {
    padding-bottom: 1.25rem;
}

/* Events */

.events {
    margin: 0;
    padding: 0;
    border-top: 1px solid var(--dark);
    list-style: none;
}

.event {
    display: grid;
    grid-template-columns: 4.75rem minmax(0, 1fr);
    gap: clamp(1rem, 2.5vw, 2rem);
    align-items: start;
    padding: 1.25rem 0;
    border-bottom: 1px solid var(--dark);
}

.event__date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1;
    margin: 0;
    background: var(--dark);
    color: var(--white);
    line-height: 1;
}

.event__day {
    font-family: var(--serif);
    font-size: 1.9rem;
}

.event__month {
    margin-top: 0.35rem;
    font-size: 0.72rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.event__title {
    margin: 0;
    font-family: var(--serif);
    font-size: clamp(1.2rem, 1.8vw, 1.5rem);
    font-weight: 400;
}

.event__meta {
    margin: 0.35rem 0 0;
    font-size: 0.85rem;
}

.event__text {
    margin: 0.6rem 0 0;
}

.event__link {
    display: inline-block;
    margin-top: 0.4rem;
    padding-block: 0.4rem;
    color: inherit;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.events__empty {
    margin: 0;
    padding: 1.5rem;
    border: 1px solid var(--dark);
    font-family: var(--serif);
    font-size: var(--fs-body);
    text-align: center;
}

/* Lightbox for galleries: photos only, with caption */

.lb--images {
    grid-template-columns: minmax(0, 1fr);
}

.lb--images .lb__img {
    height: min(72svh, 44rem);
}

.lb__caption {
    margin: 0;
    padding: 0.75rem 1.25rem 2.75rem;
    color: var(--white);
    font-size: 0.9rem;
    text-align: center;
}

@media (max-width: 599px) {
    .sec-gallery__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .event {
        grid-template-columns: 3.75rem minmax(0, 1fr);
    }

    .event__day {
        font-size: 1.5rem;
    }
}
