/*
Theme Name: Höfeflohmarkt Nierstein
Author: Höfeflohmarkt Nierstein
Description: Schlankes, eigenständiges Theme für den Höfeflohmarkt-MVP.
Version: 0.1.0
Requires at least: 6.7
Requires PHP: 8.1
Text Domain: hfm-nierstein
*/

*, *::before, *::after { box-sizing: border-box; }
html { font-size: 17px; }
body { margin: 0; background: #f7f2e7; color: #17231c; font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }
.screen-reader-text:focus { z-index: 99999; top: 10px; left: 10px; width: auto; height: auto; clip: auto; padding: 12px 16px; background: #fff; color: #17231c; }

.site-header { position: absolute; z-index: 20; top: 0; left: 0; width: 100%; color: #fff; }
.site-header__inner { display: flex; width: min(1180px, calc(100% - 40px)); min-height: 76px; margin-inline: auto; align-items: center; justify-content: space-between; gap: 24px; }
.site-brand { display: inline-flex; align-items: center; gap: 11px; color: #fff; font-weight: 900; text-decoration: none; letter-spacing: -.02em; }
.site-brand__mark { display: inline-grid; width: 38px; height: 38px; place-items: center; border-radius: 50% 50% 50% 10px; background: #dce879; color: #17231c; transform: rotate(-7deg); }
.site-nav { display: flex; align-items: center; gap: 26px; }
.site-nav a { color: rgba(255,255,255,.82); font-size: .84rem; font-weight: 800; text-decoration: none; }
.site-nav a:hover { color: #dce879; }
.site-nav__cta { padding: 10px 16px; border: 1px solid rgba(255,255,255,.55); border-radius: 999px; }

.site-main--page { min-height: 70vh; padding: 140px 0 90px; }
.page-shell { width: min(790px, calc(100% - 40px)); min-width: 0; margin-inline: auto; }
.page-header { margin-bottom: 40px; }
.page-header h1 { max-width: 100%; margin: 0; font: 800 clamp(2.65rem, 7vw, 4rem)/.98 Georgia, serif; overflow-wrap: anywhere; hyphens: manual; letter-spacing: -.055em; }
.page-content { min-width: 0; font-size: 1.04rem; line-height: 1.75; overflow-wrap: break-word; }
.page-content h2, .page-content h3 { margin-top: 2em; font-family: Georgia, serif; line-height: 1.08; letter-spacing: -.035em; }
.page-content h2 { font-size: 2rem; }
.page-content h3 { font-size: 1.5rem; }
.page-content a { text-decoration-thickness: 2px; text-underline-offset: 4px; }

body:not(.home) .site-header { position: relative; background: #244c38; }

.site-footer-mini { background: #17231c; color: #fff; }
.site-footer-mini__inner { display: flex; width: min(1180px, calc(100% - 40px)); min-height: 72px; margin-inline: auto; align-items: center; justify-content: space-between; gap: 24px; }
.site-footer-mini__inner > span { color: rgba(255,255,255,.55); font-size: .75rem; font-weight: 800; }
.site-footer-mini nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px 20px; }
.site-footer-mini a, .site-footer-mini button { padding: 0; border: 0; color: rgba(255,255,255,.72); background: transparent; font-size: .75rem; font-weight: 750; line-height: 1.4; text-decoration: none; cursor: pointer; }
.site-footer-mini a:hover, .site-footer-mini button:hover { color: #dce879; }

.hfm-consent[hidden] { display: none !important; }
.hfm-consent { position: fixed; z-index: 99999; inset: 0; display: flex; padding: clamp(10px, 3vw, 28px); align-items: flex-end; justify-content: center; pointer-events: none; }
.hfm-consent__backdrop { position: absolute; inset: 0; background: rgba(11,15,18,.48); pointer-events: auto; }
.hfm-consent__panel { position: relative; display: grid; width: min(100%, 780px); max-height: calc(100vh - 24px); overflow: auto; grid-template-columns: minmax(0,1fr) auto; gap: clamp(18px,3vw,32px); padding: clamp(20px,3vw,30px); border: 1px solid rgba(23,35,28,.16); border-radius: 12px; background: #fffaf0; color: #17231c; box-shadow: 0 22px 70px rgba(0,0,0,.2); pointer-events: auto; }
.hfm-consent__panel:focus { outline: none; }
.hfm-consent__eyebrow { margin: 0 0 8px; color: #66736b; font-size: .68rem; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.hfm-consent__title { margin: 0; font: 800 clamp(1.45rem,3vw,2.05rem)/1.08 Georgia,serif; letter-spacing: -.035em; }
.hfm-consent__text { max-width: 58ch; margin: 12px 0 0; font-size: .9rem; line-height: 1.55; }
.hfm-consent__details { max-width: 60ch; margin-top: 13px; font-size: .76rem; line-height: 1.5; }
.hfm-consent__details summary { display: inline-flex; gap: 7px; align-items: center; font-weight: 850; cursor: pointer; }
.hfm-consent__details summary::after { content: '+'; color: #f26447; }
.hfm-consent__details[open] summary::after { content: '−'; }
.hfm-consent__details p { margin: 9px 0 0; padding: 11px 12px; border: 1px solid rgba(23,35,28,.14); border-radius: 8px; background: #f7f2e7; }
.hfm-consent__meta { display: flex; gap: 8px; margin: 13px 0 0; color: #66736b; font-size: .76rem; }
.hfm-consent__meta a { text-decoration: underline; text-underline-offset: 3px; }
.hfm-consent__actions { display: flex; min-width: min(210px,100%); flex-direction: column; justify-content: flex-end; gap: 10px; }
.hfm-consent__button { display: inline-flex; min-height: 46px; padding: 0 18px; align-items: center; justify-content: center; border: 1px solid #17231c; border-radius: 999px; font-size: .84rem; font-weight: 850; cursor: pointer; }
.hfm-consent__button--primary { border-color: #f26447; background: #f26447; color: #fff; }
.hfm-consent__button--secondary { background: #fffaf0; color: #17231c; }
.hfm-consent__button:hover { transform: translateY(-1px); }
html.hfm-consent-open { overflow: hidden; }

@media (max-width: 720px) {
  html { font-size: 16px; }
  .site-header__inner { width: min(100% - 26px, 1180px); }
  .site-brand__text { max-width: 130px; line-height: 1.05; }
  .site-nav a:not(.site-nav__cta) { display: none; }
  .site-footer-mini__inner { width: min(100% - 26px, 1180px); min-height: 92px; align-items: flex-start; flex-direction: column; justify-content: center; gap: 8px; }
  .site-footer-mini nav { justify-content: flex-start; }
  .hfm-consent__panel { grid-template-columns: 1fr; }
  .hfm-consent__actions { width: 100%; }
  .site-main--page { padding: 96px 0 64px; }
  .page-shell { width: min(100% - 26px, 790px); }
  .page-header { margin-bottom: 28px; }
  .page-header h1 { font-size: clamp(2.35rem, 13vw, 3.65rem); }
}

@media (prefers-reduced-motion: reduce) {
  .hfm-consent__button { transition: none; }
}
