/* ============================================================
   Dorfflohmarkt Metterzimmern – Zwischensaison-Landingpage 2027
   Design-System "Sommerfest": Papier & Tinte, Wimpel & Preisschilder.
   Eigenständig – kollidiert nicht mit style.css (Event-Modus/Rechtstexte).
   ============================================================ */

/* ---- Lokale Fonts (DSGVO-konform, kein CDN) ---- */
@font-face {
    font-family: 'Caveat';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../fonts/caveat-latin.woff2') format('woff2');
}
@font-face {
    font-family: 'DM Sans';
    font-style: normal;
    font-weight: 300 700;
    font-display: swap;
    src: url('../fonts/dmsans-latin.woff2') format('woff2');
}
@font-face {
    font-family: 'DM Sans';
    font-style: italic;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/dmsans-italic-latin.woff2') format('woff2');
}

:root {
    --paper:        #FCF9F3;
    --paper-2:      #F4EDDF;
    --ink:          #2A2320;
    --ink-soft:     #6E6157;
    --tomato:       #E8482B;
    --tomato-dark:  #C5371D;
    --marigold:     #F2A93B;
    --marigold-soft:#FBE3B8;
    --meadow:       #3E7C5A;
    --meadow-dark:  #284C39;
    --line:         #E7DDCC;
    --font-body: 'DM Sans', system-ui, sans-serif;
    --font-hand: 'Caveat', 'DM Sans', cursive;
    --wrap: 1120px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: hidden; }

body.lp {
    font-family: var(--font-body);
    color: var(--ink);
    background-color: var(--paper);
    background-image:
        radial-gradient(circle at 12% 18%, rgba(242,169,59,0.10) 0, transparent 38%),
        radial-gradient(circle at 88% 8%,  rgba(232,72,43,0.07) 0, transparent 34%),
        radial-gradient(var(--line) 1px, transparent 1px);
    background-size: auto, auto, 26px 26px;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

.lp-wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }

a { color: inherit; }

::selection { background: var(--marigold); color: var(--ink); }

/* ---------- Wimpelkette (Bunting) ---------- */
.bunting {
    display: flex;
    justify-content: center;
    gap: 0;
    height: 34px;
    margin: 0;
    padding: 0;
    width: 100%;
    overflow: hidden;
    position: relative;
    background: linear-gradient(var(--ink) 0 1.5px, transparent 1.5px) top/100% 100% no-repeat;
}
.bunting span {
    width: 30px;
    height: 38px;
    margin: 0 1px;
    clip-path: polygon(0 0, 100% 0, 50% 100%);
    transform-origin: top center;
    animation: sway 3.6s ease-in-out infinite;
}
.bunting span:nth-child(4n+1){ background: var(--tomato);   animation-delay: 0s; }
.bunting span:nth-child(4n+2){ background: var(--marigold); animation-delay: .2s; }
.bunting span:nth-child(4n+3){ background: var(--meadow);   animation-delay: .4s; }
.bunting span:nth-child(4n+4){ background: var(--tomato-dark); animation-delay: .6s; }
@keyframes sway {
    0%,100% { transform: rotate(-3deg); }
    50%     { transform: rotate(3deg); }
}

/* ---------- Navbar ---------- */
.lp-nav {
    position: sticky; top: 0; z-index: 50;
    background: rgba(252,249,243,0.86);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid transparent;
    transition: border-color .25s, box-shadow .25s;
}
.lp-nav.scrolled { border-bottom-color: var(--line); box-shadow: 0 4px 20px rgba(42,35,32,0.05); }
.lp-nav-inner {
    max-width: var(--wrap); margin: 0 auto; padding: 12px 24px;
    display: flex; align-items: center; justify-content: space-between;
}
.lp-nav-logo img { height: 46px; width: auto; display: block; }
.lp-cta-mini {
    font-weight: 600; font-size: .95rem;
    background: var(--ink); color: var(--paper);
    padding: 10px 20px; border-radius: 999px;
    text-decoration: none; transition: transform .2s, background .2s;
}
.lp-cta-mini:hover { background: var(--tomato); transform: translateY(-2px); }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 0 0 80px; }
.hero-inner {
    max-width: var(--wrap); margin: 0 auto; padding: 64px 24px 0;
    position: relative; text-align: center;
}
.hero-eyebrow {
    font-family: var(--font-hand);
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    color: var(--tomato);
    font-weight: 700;
    transform: rotate(-2deg);
    display: inline-block;
    margin-bottom: 6px;
}
.hero h1 {
    font-weight: 700;
    font-size: clamp(1.8rem, 7.2vw, 6rem);
    line-height: .94;
    letter-spacing: -0.03em;
    text-transform: uppercase;
    margin: 4px 0 8px;
    overflow-wrap: break-word;
}
.hero h1 .folgt {
    color: var(--tomato);
    position: relative; display: inline-block;
}
/* handgemalter Unterstrich unter "folgt!" */
.hero h1 .folgt::after {
    content: "";
    position: absolute; left: -2%; right: -2%; bottom: .04em; height: .14em;
    background: var(--marigold);
    border-radius: 60% 40% 55% 45%;
    transform: rotate(-1.2deg);
    z-index: -1;
}
.hero-year {
    font-family: var(--font-hand);
    font-weight: 700;
    color: var(--meadow);
    font-size: clamp(2rem, 7vw, 4.6rem);
    line-height: 1;
    transform: rotate(-3deg);
    max-width: 100%;
    display: inline-block;
    margin: 6px 0 18px;
}
.hero-sub {
    max-width: 620px; margin: 0 auto 30px;
    font-size: clamp(1.02rem, 2.3vw, 1.22rem);
    color: var(--ink-soft);
}
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.btn {
    display: inline-flex; align-items: center; gap: 9px;
    font-family: var(--font-body); font-weight: 600; font-size: 1.02rem;
    padding: 15px 30px; border-radius: 999px; text-decoration: none;
    cursor: pointer; border: 2px solid transparent;
    transition: transform .2s, box-shadow .2s, background .2s, color .2s;
}
.btn-primary { background: var(--tomato); color: #fff; box-shadow: 0 10px 22px rgba(232,72,43,0.28); }
.btn-primary:hover { background: var(--tomato-dark); transform: translateY(-3px); box-shadow: 0 14px 28px rgba(232,72,43,0.34); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--paper); transform: translateY(-3px); }

/* ---------- Schwingende Preisschilder ---------- */
.tag {
    position: absolute; z-index: 2;
    font-family: var(--font-hand); font-weight: 700;
    font-size: 1.25rem; color: var(--ink);
    background: var(--marigold-soft);
    border: 1.5px solid rgba(42,35,32,0.18);
    padding: 12px 18px 12px 26px;
    border-radius: 8px;
    box-shadow: 0 8px 18px rgba(42,35,32,0.12);
    transform-origin: 14px -14px;
    animation: tagswing 5s ease-in-out infinite;
}
.tag::before { /* Loch */
    content: ""; position: absolute; left: 11px; top: 50%; transform: translateY(-50%);
    width: 9px; height: 9px; border-radius: 50%;
    background: var(--paper); border: 1.5px solid rgba(42,35,32,0.35);
}
.tag::after { /* Schnur */
    content: ""; position: absolute; left: 14px; top: -16px;
    width: 1.5px; height: 18px; background: rgba(42,35,32,0.4);
    transform: rotate(8deg);
}
.tag { display: none; }                 /* nur auf breiten Screens, s.u. */
.tag-1 { bottom: 116px; left: 18px;  background: #FBE3B8; animation-delay: .2s;  --rot: -7deg; }
.tag-2 { bottom: 84px;  right: 18px; background: #F8D2C7; animation-delay: .9s;  --rot: 6deg; }
.tag-3 { top: 96px;     right: 24px; background: #D9E8DD; animation-delay: 1.5s; --rot: 4deg; }
@keyframes tagswing {
    0%,100% { transform: rotate(var(--rot, 0deg)); }
    50%     { transform: rotate(calc(var(--rot, 0deg) + 3deg)); }
}

/* ---------- Rückblick-Streifen ---------- */
.rueckblick {
    background: var(--ink); color: var(--paper);
    padding: 40px 0;
}
.rueckblick .lp-wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 18px 44px; text-align: center; }
.rueckblick .rb-lead {
    font-family: var(--font-hand); font-size: 1.7rem; font-weight: 700;
    color: var(--marigold); flex: 0 0 auto;
}
.stat { display: flex; flex-direction: column; }
.stat b { font-size: clamp(2rem, 5vw, 2.9rem); font-weight: 700; line-height: 1; letter-spacing: -0.02em; }
.stat span { font-size: .82rem; text-transform: uppercase; letter-spacing: .12em; color: rgba(252,249,243,0.65); margin-top: 6px; }

/* ---------- Sektion / Ablauf ---------- */
.section { padding: 84px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 48px; }
.eyebrow {
    font-family: var(--font-hand); font-size: 1.5rem; font-weight: 700;
    color: var(--tomato); transform: rotate(-1.5deg); display: inline-block;
}
.section-head h2 {
    font-size: clamp(1.9rem, 5vw, 2.9rem); font-weight: 700;
    letter-spacing: -0.02em; line-height: 1.05; margin-top: 4px;
}
.section-head p { color: var(--ink-soft); margin-top: 14px; font-size: 1.05rem; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.step {
    background: #fff; border: 1px solid var(--line); border-radius: 18px;
    padding: 34px 26px 30px; position: relative;
    transition: transform .25s, box-shadow .25s;
}
.step:hover { transform: translateY(-6px); box-shadow: 0 18px 36px rgba(42,35,32,0.10); }
.step-num {
    position: absolute; top: -18px; left: 26px;
    width: 46px; height: 46px; border-radius: 50%;
    background: var(--tomato); color: #fff;
    display: grid; place-items: center;
    font-family: var(--font-hand); font-weight: 700; font-size: 1.7rem;
    box-shadow: 0 6px 14px rgba(232,72,43,0.3);
    transform: rotate(-6deg);
}
.step:nth-child(2) .step-num { background: var(--marigold); color: var(--ink); }
.step:nth-child(3) .step-num { background: var(--meadow); }
.step .step-ico { font-size: 1.9rem; margin: 6px 0 12px; display: block; }
.step h3 { font-size: 1.28rem; font-weight: 700; margin-bottom: 8px; }
.step p { color: var(--ink-soft); font-size: .98rem; }

/* ---------- Vormerken (Postkarte) ---------- */
.vormerken { background: var(--paper-2); }
.card-postkarte {
    max-width: 720px; margin: 0 auto; background: #fff;
    border-radius: 22px; border: 1px solid var(--line);
    box-shadow: 0 22px 50px rgba(42,35,32,0.12);
    padding: 52px 40px; text-align: center; position: relative; overflow: hidden;
}
.card-postkarte::before { /* Briefmarke-Akzent */
    content: "✉"; position: absolute; top: 18px; right: 22px;
    font-size: 1.4rem; color: var(--marigold);
}
.card-postkarte .eyebrow { color: var(--meadow); }
.card-postkarte h2 { font-size: clamp(1.8rem, 4.5vw, 2.6rem); font-weight: 700; letter-spacing: -0.02em; margin: 2px 0 14px; }
.card-postkarte p { color: var(--ink-soft); max-width: 440px; margin: 0 auto 26px; }
.mail-big {
    display: inline-flex; align-items: center; gap: 10px;
    font-size: clamp(1.05rem, 3vw, 1.4rem); font-weight: 600;
    color: var(--tomato); text-decoration: none;
    border-bottom: 3px solid var(--marigold); padding-bottom: 3px;
    transition: color .2s, border-color .2s;
    word-break: break-word;
}
.mail-big:hover { color: var(--tomato-dark); border-color: var(--tomato); }

/* ---------- Footer ---------- */
.lp-footer { background: var(--meadow-dark); color: rgba(252,249,243,0.92); padding: 56px 0 30px; }
.lp-footer-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 36px; }
.lp-footer h4 { font-family: var(--font-hand); font-weight: 700; font-size: 1.5rem; color: var(--marigold); margin-bottom: 10px; }
.lp-footer p { color: rgba(252,249,243,0.78); font-size: .96rem; max-width: 380px; }
.lp-footer a { color: #fff; }
.lp-footer-links { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.lp-footer-links a { text-decoration: none; opacity: .85; transition: opacity .2s; }
.lp-footer-links a:hover { opacity: 1; text-decoration: underline; }
.lp-footer-bottom {
    border-top: 1px solid rgba(252,249,243,0.16);
    margin-top: 40px; padding-top: 20px;
    font-size: .85rem; color: rgba(252,249,243,0.6);
    display: flex; flex-wrap: wrap; gap: 6px 16px; justify-content: space-between;
}
.lp-footer-bottom a { color: rgba(252,249,243,0.85); }

/* ---------- Cookie-Banner ---------- */
.cookie-banner {
    position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 100;
    max-width: 760px; margin: 0 auto;
    background: var(--ink); color: rgba(252,249,243,0.92);
    border-radius: 16px; padding: 16px 20px;
    display: none; align-items: center; gap: 16px;
    box-shadow: 0 14px 40px rgba(42,35,32,0.35);
    font-size: .9rem;
}
.cookie-banner.show { display: flex; }
.cookie-banner p { margin: 0; }
.cookie-banner a { color: var(--marigold); }
.cookie-banner button {
    flex: 0 0 auto; cursor: pointer; border: none;
    background: var(--marigold); color: var(--ink); font-weight: 600;
    padding: 9px 22px; border-radius: 999px; font-family: var(--font-body);
    transition: transform .2s;
}
.cookie-banner button:hover { transform: translateY(-2px); }
@media (max-width: 560px) { .cookie-banner { flex-direction: column; text-align: center; } }

/* ---------- Reveal-Animationen ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
.hero-eyebrow, .hero h1, .hero-year, .hero-sub, .hero-actions { animation: rise .8s cubic-bezier(.2,.7,.2,1) both; }
.hero h1 { animation-delay: .08s; }
.hero-year { animation-delay: .16s; }
.hero-sub { animation-delay: .24s; }
.hero-actions { animation-delay: .32s; }
@keyframes rise { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }

/* ---------- Focus / Accessibility ---------- */
a:focus-visible, .btn:focus-visible, .lp-cta-mini:focus-visible, .menu-toggle:focus-visible {
    outline: 3px solid var(--meadow); outline-offset: 3px; border-radius: 6px;
}

/* ---------- Responsive ---------- */
@media (min-width: 1080px) { .tag { display: block; } }
@media (max-width: 860px) {
    .steps { grid-template-columns: 1fr; gap: 30px; }
    .lp-footer-grid { grid-template-columns: 1fr; }
    .rueckblick .lp-wrap { gap: 16px 30px; }
}
@media (max-width: 520px) {
    .hero-inner { padding: 44px 18px 0; }
    .section { padding: 60px 0; }
    .card-postkarte { padding: 40px 24px; }
    .hero-year { font-size: clamp(1.8rem, 9vw, 3rem); }
}

/* ---------- Reduced Motion ---------- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
    .reveal { opacity: 1; transform: none; }
}
