/* ================================================================
 *  custom.css — Beispiel-Website „Hof Sonnmatt“ (HOF³ von mds³)
 *
 *  Lädt nach dem Template und dem Theme. Klassen mit „site-“ sind
 *  eigene Bausteine; die übrigen Regeln passen Bausteine der
 *  Vorlage „Island Resort“ an den Hof an.
 *
 *  1. Schriften (lokal, keine Google-Abrufe)
 *  2. Farben und Grundwerte
 *  3. Kopfzeile, Marke, Hero
 *  4. Abschnitte (Wohnungen, Tag, Hofladen, Angebote, Karte, Anreise)
 *  5. HOF³-Anfrage (Formular im Demo-Modus)
 *  6. Hinweis „Beispiel-Website“
 *  7. Bewegung reduzieren
 * ================================================================ */

/* ---------- 1. Schriften ---------- */
/* Nur zwei Stärken je Schrift (Latin + Latin-Ext, woff2, SIL Open Font License,
   Lizenztexte in assets/fonts). Die Bereiche ordnen jede angefragte Stärke
   einer echten Datei zu, damit der Browser nichts künstlich fett rechnet:
   bis 500 → Regular, ab 501 → Semibold. */
@font-face { font-family: 'Fraunces'; font-style: normal; font-weight: 100 500; font-display: swap; src: url('../fonts/fraunces-latin-400.woff2') format('woff2'); }
@font-face { font-family: 'Fraunces'; font-style: normal; font-weight: 501 900; font-display: swap; src: url('../fonts/fraunces-latin-600.woff2') format('woff2'); }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 100 500; font-display: swap; src: url('../fonts/plus-jakarta-sans-latin-400.woff2') format('woff2'); }
@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 501 900; font-display: swap; src: url('../fonts/plus-jakarta-sans-latin-600.woff2') format('woff2'); }

/* ---------- 2. Farben und Grundwerte ---------- */
:root {
    --site-rot: #b8322a;          /* Geranienrot: nur kleine Akzente, 5,3:1 auf Creme */
    --site-rot-hell: #f08a7e;     /* Rot als Schrift auf Tannengrün */
    --site-holz: #7b5b3c;
    --site-gold: #e9c27a;         /* Morgenlicht: Akzente auf dunklem Grund */
    --site-logo-sonne: #e2ad4f;   /* Sonne im Logo */
}

h1, h2, h3, h4, .font-heading, .site-brand-name { font-kerning: normal; }

/* Skip-Link: erst bei Tastaturfokus sichtbar */
.skip-link {
    position: absolute;
    left: 1rem;
    top: -4rem;
    z-index: 1000;
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-sm, 0.375rem);
    background: var(--color-secondary-base);
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    transition: top 0.2s ease;
}
.skip-link:focus { top: 1rem; outline: 3px solid var(--site-gold); outline-offset: 2px; }

/* Eyebrows (Dachzeilen) in Holzbraun statt Grau */
html[data-demo='resort-1'] .eyebrow { color: var(--site-holz); }
html[data-demo='resort-1'] :is(.section-dark, .footer-main) .eyebrow { color: var(--site-gold); }

/* ---------- 3. Kopfzeile, Marke, Hero ---------- */

/* Marke: Zeichen + Name */
/* display bleibt bei .brand der Vorlage (sonst erscheint die Handy-Marke auch am Desktop) */
.site-brand {
    align-items: center;
    gap: 0.625rem;
    text-decoration: none;
}
.site-brand-name {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.375rem;
    letter-spacing: 0;
    line-height: 1;
    white-space: nowrap;
}
/* Logo-Zeichen (inline aus #hof-logo): Haus in Textfarbe, Sonne in Gold */
.site-logo { display: block; flex: none; height: auto; aspect-ratio: 114 / 90; overflow: visible; }
.site-header .site-logo { width: 2.75rem; }
.footer-main .site-logo { width: 3.25rem; }
.footer-main .site-brand-name { font-size: 1.5rem; color: #fff; }

/* Kopfzeile: Ortszeile erst auf breiten Bildschirmen, Menüpunkte etwas enger */
@media (width < 1500px) {
    .site-header .nav-aside { display: none; }
}
html[data-demo='resort-1'] .site-header .nav-link { letter-spacing: 0.1em; }
@media (1024px <= width < 1320px) {
    html[data-demo='resort-1'] .site-header .nav-link { letter-spacing: 0.05em; font-size: 0.75rem; padding-inline: 0.5rem; }
    html[data-demo='resort-1'] .site-header .custom-nav-action { letter-spacing: 0.06em; padding-inline: 0.875rem; font-size: 0.75rem; }
    html[data-demo='resort-1'] .site-header { --brand-slot-gap: 1rem; }
    .site-header .site-brand-name { font-size: 1.0625rem; }
}

/* Über dem Hero-Bild: helle Navigation statt Tinte */
/* (nicht, wenn das Handy-Menü offen ist: dann liegt die Kopfzeile auf Creme) */
html[data-demo='resort-1'] .header-transparent:not(.scrolled):not(:has(.nav-megamenu:is(:hover, :focus-within), .nav-cascade:hover, .hamburger[aria-expanded='true'])) :is(.brand, .nav-link, .hamburger, .custom-nav-note) {
    color: #fff;
}
html[data-demo='resort-1'] .header-transparent:not(.scrolled):not(:has(.nav-megamenu:is(:hover, :focus-within), .nav-cascade:hover, .hamburger[aria-expanded='true'])) .nav-link:is(:hover, .active) {
    color: var(--site-gold);
}

/* Zusätzlicher Menüpunkt nur fürs Handy, gesetzt wie die erzeugten Links */
.nav-panel-menu > .mobile-link[data-mobile-only] {
    display: block;
    font-family: var(--font-heading);
    font-size: 1.375rem;
    font-weight: 400;
    padding: 0.875rem 0.25rem;
    color: var(--color-text);
    border-top: 1px solid var(--color-border);
}
html[data-demo='resort-1'] .header-transparent:not(.scrolled) .navbar {
    box-shadow: inset 0 -1px 0 rgb(255 255 255 / 0.18);
}

/* Hero: Abdunklung über dem Foto, damit weiße Schrift sicher lesbar ist */
.custom-hero { color: #fff; }
.site-hero-scrim {
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        linear-gradient(180deg, rgb(20 26 16 / 0.7) 0%, rgb(20 26 16 / 0.3) 34%, rgb(20 26 16 / 0.22) 50%, rgb(20 26 16 / 0.58) 70%, rgb(20 26 16 / 0.8) 100%);
}
html[data-demo='resort-1'] .custom-hero-title,
html[data-demo='resort-1'] .custom-hero .custom-hero-place {
    color: #fff;
    text-shadow: 0 2px 24px rgb(10 14 8 / 0.45);
}
html[data-demo='resort-1'] .site-hero-title {
    font-size: clamp(3.25rem, 1.2rem + 9vw, 10.5rem);
    font-weight: 400;
    letter-spacing: -0.02em;
    white-space: normal;
    line-height: 0.9;
}
.site-hero-title .site-hero-hof {
    display: block;
    font-size: 0.32em;
    font-weight: 400;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    margin-bottom: 0.35em;
    padding-left: 0.32em; /* optisch zentriert trotz Laufweite */
}
.custom-hero-tide { color: var(--site-gold); }
.site-hero-lead { text-shadow: 0 1px 14px rgb(10 14 8 / 0.5); }

/* ---------- 4. Abschnitte ---------- */

/* Wohnungen: zwei Karten statt Karussell */
.site-wohnung {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 24px 48px -36px rgb(31 43 29 / 0.45);
    transition: transform 0.5s cubic-bezier(.2,.8,.2,1), box-shadow 0.5s cubic-bezier(.2,.8,.2,1);
}
.site-wohnung:hover { transform: translateY(-4px); box-shadow: 0 32px 60px -36px rgb(31 43 29 / 0.55); }
.site-wohnung-bild { overflow: hidden; }
.site-wohnung-bild img { display: block; width: 100%; aspect-ratio: 5 / 4; object-fit: cover; transition: transform 1.2s cubic-bezier(.2,.8,.2,1); }
.site-wohnung:hover .site-wohnung-bild img { transform: scale(1.04); }
.site-wohnung-text { display: flex; flex-direction: column; gap: 1rem; padding: clamp(1.25rem, 1rem + 1vw, 2rem); flex: 1; }
.site-wohnung-kopf { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.25rem 1rem; }
.site-wohnung-kopf h3 { margin: 0; font-size: clamp(1.625rem, 1.3rem + 1vw, 2.125rem); line-height: 1.1; }
.site-preis { margin: 0; color: var(--color-text-soft); font-size: 0.9375rem; }
.site-preis b { color: var(--color-text); font-weight: 600; font-variant-numeric: tabular-nums; font-size: 1.125rem; }
.site-wohnung-text > p { margin: 0; color: var(--color-text-soft); line-height: 1.6; }
.site-wohnung-aktion { margin-top: auto; padding-top: 0.5rem; display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.25rem; }
.site-hinweis { margin: 0; font-size: 0.875rem; color: var(--color-text-soft); }

/* Hero-Foto: Haus steht rechts, auf schmalen Bildschirmen nicht abschneiden; Handy hat ein eigenes Hochformat */
.site-hero-foto { object-position: 72% 50%; }
@media (width <= 767px) {
    .site-hero-foto { object-position: 50% 50%; }
}

/* Ein Tag auf dem Hof: Stallbild ist quer, Kinderhände und Kalb sollen sichtbar bleiben */
.custom-day-frame img.site-tag-stall { object-position: 28% 50%; }

/* Ankommen: Kennzahlen mit Wörtern nicht zu groß */
.site-fakt-einheit { font-size: 0.42em; margin-left: 0.2em; }
@media (width <= 479px) {
    #ankommen dt { letter-spacing: 0.1em; font-size: 0.6875rem; text-align: center; }
}

/* Ein Tag auf dem Hof: Uhrzeiten */
.custom-day time span { letter-spacing: 0.1em; }

/* Hofladen: Bild füllt die linke Hälfte */
.site-hofladen-bild { object-position: 50% 45%; }
.site-hofladen-fuss { margin: 2rem 0 0; font-size: 0.9375rem; color: var(--color-text-soft); }

/* Angebote auf Tannengrün: Karten ohne Bild */
.site-angebot {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    height: 100%;
    padding: clamp(1.5rem, 1.1rem + 1.2vw, 2.25rem);
    border: 1px solid rgb(255 255 255 / 0.16);
    border-radius: var(--radius-md);
    background: rgb(255 255 255 / 0.04);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
.site-angebot:hover { background: rgb(255 255 255 / 0.08); border-color: rgb(233 194 122 / 0.5); }
.site-angebot-icon {
    display: grid;
    place-items: center;
    width: 3.25rem;
    aspect-ratio: 1;
    border-radius: 999px;
    border: 1px solid rgb(233 194 122 / 0.55);
    color: var(--site-gold);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}
.site-angebot h3 { margin: 0; font-size: clamp(1.5rem, 1.25rem + 0.8vw, 1.875rem); line-height: 1.15; color: #fff; }
.site-angebot p { margin: 0; line-height: 1.6; color: rgb(255 255 255 / 0.8); }
.site-angebot .custom-venue-hours { margin-top: auto; }
.site-angebot--herz { border-color: rgb(240 138 126 / 0.6); }
.site-angebot-badge {
    position: absolute;
    top: -0.8rem;
    right: 1.25rem;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    background: var(--site-rot);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

/* Karte „Rund um den Hof“ */
.site-karte .custom-map-wald { fill: color-mix(in oklch, var(--color-primary-base) 32%, var(--color-tertiary-base)); stroke: none; }
.site-karte .custom-map-wiese { fill: var(--color-tertiary-base); }
.site-karte .custom-map-bach { stroke: #5b8fa6; stroke-width: 2.5px; }
.site-karte .custom-map-weiher { fill: #a9c9d6; stroke: #5b8fa6; }
.site-karte .custom-map-weg { stroke: var(--site-holz); stroke-dasharray: 6 6; stroke-width: 1.75px; }
.site-karte .custom-map-strasse { stroke: color-mix(in oklch, var(--custom-ink) 55%, transparent); stroke-width: 3px; }
.site-karte .custom-map-haus { fill: var(--custom-ink); stroke: none; }
.custom-map-panel .site-ort-titel {
    margin: 0;
    font-family: var(--font-heading);
    font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem);
    font-weight: 600;
    line-height: 1.15;
    color: var(--color-text);
}
.custom-map-panel .site-ort-weg {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--site-holz);
}
.custom-map-panel > div { padding-bottom: 0.25rem; }
.custom-map-list button { min-height: 44px; }

/* Anreise: Hinweise rechts */
.site-anreise-fakten { display: grid; gap: 2rem; margin: 0; }
.site-anreise-fakten > div { border-top: 1px solid rgb(255 255 255 / 0.14); padding-top: 1.25rem; }
.site-anreise-fakten dd { margin: 0.5rem 0 0; color: rgb(255 255 255 / 0.82); line-height: 1.6; }
.custom-route-leg--feldweg:before {
    content: '';
    position: absolute;
    inset-block: 0.375rem;
    left: 0;
    border-left: 2px dotted var(--site-gold);
}

/* Footer */
.custom-footer-cta { color: var(--custom-ink); }
.custom-footer-cta .footer-cta-media-img { object-position: 60% 40%; }
.site-footer-cta-scrim {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: linear-gradient(180deg, rgb(247 241 230 / 0.78) 0%, rgb(247 241 230 / 0.55) 60%, rgb(247 241 230 / 0.2) 100%);
}
.custom-footer-cta > .container { position: relative; z-index: 1; }
.site-footer-hinweis { margin: 0; font-size: 0.875rem; color: rgb(255 255 255 / 0.72); }
.site-footer-hinweis a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- 5. HOF³-Anfrage ---------- */
.site-anfrage-karte {
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: clamp(1.25rem, 0.75rem + 2vw, 2.5rem);
    box-shadow: 0 30px 60px -40px rgb(31 43 29 / 0.5);
    scroll-margin-top: calc(var(--header-h, 5rem) + 1rem);
}
#anfrage .hof3 {
    --hof3-akzent: var(--color-primary-base);
    --hof3-akzent-hell: #e3ead6;
    --hof3-text: var(--color-text);
    --hof3-grau: var(--color-text-soft);
    --hof3-linie: #d9d0bf;
    --hof3-belegt: #efe6d6;
    max-width: none;
    font-family: var(--font-sans);
}
#anfrage .hof3 h3 { font-family: var(--font-heading); font-weight: 600; font-size: 1.375rem; letter-spacing: -0.005em; }
#anfrage .hof3 h4 { font-family: var(--font-heading); font-weight: 600; font-size: 1.0625rem; }
#anfrage .hof3-senden { font-size: 1.0625rem; padding-inline: 2rem; transition: background-color 0.2s ease, transform 0.2s ease; }
#anfrage .hof3-senden:hover:not(:disabled) { background: color-mix(in oklch, var(--color-primary-base) 85%, #000); }
#anfrage .hof3-senden:active:not(:disabled) { transform: scale(0.98); }
#anfrage .hof3-tag { transition: background-color 0.15s ease; }
#anfrage .hof3-tag.belegt { color: #66695f; } /* 4,6:1 statt 3:1 auf dem Belegt-Ton */
#anfrage .hof3-erfolg { outline: none; }

.site-kontakt-liste { list-style: none; margin: 2rem 0 0; padding: 0; display: grid; gap: 1rem; }
.site-kontakt-liste li { display: grid; grid-template-columns: 2.75rem minmax(0, 1fr); align-items: center; column-gap: 1rem; }
.site-kontakt-liste i {
    display: grid;
    place-items: center;
    width: 2.75rem;
    aspect-ratio: 1;
    border-radius: 999px;
    border: 1px solid var(--color-border);
    background: #fff;
    color: var(--color-primary-ink);
    font-size: 1.25rem;
}
.site-kontakt-liste span { color: var(--color-text-soft); line-height: 1.5; }
.site-kontakt-liste b { display: block; color: var(--color-text); font-weight: 600; }
.site-schritte { list-style: none; margin: 2.5rem 0 0; padding: 0; display: grid; gap: 1.25rem; counter-reset: schritt; }
.site-schritte li { position: relative; padding-left: 2.75rem; line-height: 1.55; color: var(--color-text-soft); counter-increment: schritt; }
.site-schritte li::before {
    content: counter(schritt);
    position: absolute;
    left: 0;
    top: -0.1rem;
    display: grid;
    place-items: center;
    width: 1.875rem;
    aspect-ratio: 1;
    border-radius: 999px;
    background: var(--color-primary-base);
    color: #fff;
    font-size: 0.875rem;
    font-weight: 600;
}
.site-schritte b { color: var(--color-text); font-weight: 600; }

/* ---------- 6. Hinweis „Beispiel-Website“ ---------- */
.site-demo-hinweis {
    position: fixed;
    left: 1rem;
    bottom: 1rem;
    z-index: 40;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    max-width: calc(100vw - 6rem);
    min-height: 44px;
    padding: 0.5rem 1rem 0.5rem 0.75rem;
    border-radius: 999px;
    background: var(--color-secondary-base);
    color: #fff;
    font-size: 0.8125rem;
    line-height: 1.25;
    text-decoration: none;
    box-shadow: 0 12px 30px -12px rgb(0 0 0 / 0.5);
    transition: background-color 0.2s ease, opacity 0.4s ease, translate 0.4s ease, visibility 0.4s;
}
/* Erst sichtbar, wenn die Suchleiste im Hero aus dem Bild ist (hof.js setzt die Klasse) */
.site-demo-hinweis.is-versteckt { opacity: 0; translate: 0 1rem; visibility: hidden; }
.site-demo-hinweis:hover { background: var(--color-primary-base); color: #fff; }
.site-demo-hinweis:focus-visible { outline: 3px solid var(--site-gold); outline-offset: 3px; }
.site-demo-hinweis b { font-weight: 600; }
.site-demo-hinweis .site-demo-punkt {
    flex: none;
    width: 0.5rem;
    aspect-ratio: 1;
    border-radius: 999px;
    background: var(--site-rot-hell);
}
@media (width <= 479px) {
    .site-demo-hinweis .site-demo-lang { display: none; }
}

/* ---------- 7. Bewegung reduzieren ---------- */
@media (prefers-reduced-motion: reduce) {
    .site-wohnung,
    .site-wohnung-bild img,
    .site-angebot { transition: none; }
    .site-wohnung:hover { transform: none; }
    .site-wohnung:hover .site-wohnung-bild img { transform: none; }
}
