/* ================================================================
   Castro Bau – Design System
   Palette: Navy · Silber · Weiß – direkt aus dem Castro Bau Logo
   Font:    Source Sans 3 (alle Ebenen)
================================================================ */

/* --- Tokens – Navy #0F1F4B · Silber #A8B2C4 · Weiß #FFFFFF --- */
:root {
  --bg:          #F4F7FC;
  --surface:     #EAF0F8;
  --surface-2:   #DAE2EF;
  --brick:       #0F1F4B;   /* Logo-Navy */
  --brick-dark:  #071228;
  --brick-light: rgba(15,31,75,.07);
  --wood:        #A8B2C4;   /* Logo-Silber */
  --wood-light:  rgba(168,178,196,.07);
  --text:        #0D1A3B;   /* Dunkel-Navy für Text */
  --muted:       #5B6A82;
  --border:      #C8D2E2;
  --white:       #FFFFFF;
  --green:       #0F1F4B;   /* bleibt Navy */

  --f-serif: 'Source Sans 3', Arial, Helvetica, sans-serif;
  --f-sans:  'Source Sans 3', Arial, Helvetica, sans-serif;

  --nav-h:   96px;
  --max-w:   1180px;
  --r:       4px;
  --r-lg:    10px;
  --t:       240ms ease;
  --t-slow:  420ms ease;

  --shadow:  0 4px 20px rgba(15,31,75,.08);
  --shadow-lg: 0 12px 40px rgba(15,31,75,.12);
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-sans);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* Subtle paper texture */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='4'%3E%3Crect x='1' y='1' width='1' height='1' fill='%235A3820' fill-opacity='0.025'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
}
body > * { position: relative; z-index: 1; }

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, textarea, select { font-family: inherit; }

/* --- Typography --- */
h1, h2, h3 {
  font-family: var(--f-serif);
  line-height: 1.12;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.4rem, 5.5vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 3.5vw, 3rem); }
h3 { font-size: clamp(1.2rem, 2.2vw, 1.7rem); }
h4 {
  font-family: var(--f-sans);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}

p { color: var(--muted); font-size: 1.05rem; max-width: 64ch; line-height: 1.75; }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 5vw, 2.5rem);
}
.section-pad { padding: clamp(4.5rem, 9vw, 7.5rem) 0; }

/* --- Utility --- */
.kicker {
  display: inline-block;
  font-family: var(--f-sans);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--brick);
  margin-bottom: 1.1rem;
  position: relative;
  padding-left: 1.5rem;
}
.kicker::before {
  content: '';
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  width: 18px; height: 2px;
  background: var(--brick);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--f-sans);
  font-size: .95rem;
  font-weight: 600;
  letter-spacing: .02em;
  padding: .85rem 1.75rem;
  border-radius: var(--r);
  transition: var(--t);
  white-space: nowrap;
}
.btn-brick {
  background: var(--brick);
  color: var(--white);
}
.btn-brick:hover {
  background: var(--brick-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(15,31,75,.3);
}
.btn-outline {
  border: 1.5px solid var(--border);
  color: var(--text);
  background: transparent;
}
.btn-outline:hover {
  border-color: var(--brick);
  color: var(--brick);
  transform: translateY(-2px);
}
.btn-wood {
  background: var(--wood);
  color: var(--white);
}
.btn-wood:hover { background: var(--text); transform: translateY(-2px); }
/* CTA-Banner Buttons (auf dunkelm Hintergrund) */
.btn-light {
  background: var(--white);
  color: var(--brick);
}
.btn-light:hover { background: var(--wood); color: var(--white); transform: translateY(-2px); }
.btn-outline-light {
  border: 1.5px solid rgba(255,255,255,.5);
  color: rgba(255,255,255,.85);
  background: transparent;
}
.btn-outline-light:hover { border-color: var(--white); color: var(--white); transform: translateY(-2px); }

.divider {
  width: 48px; height: 3px;
  background: var(--brick);
  border-radius: 2px;
  margin: 1.25rem 0 1.75rem;
}

/* Reveal animation */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .6s ease, transform .6s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .3s; }

/* ================================================================
   HEADER / NAV
================================================================ */
#site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 900;
  background: var(--brick);
  transition: background var(--t), box-shadow var(--t);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
#site-header.scrolled {
  background: rgba(15,31,75,.97);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 2px 20px rgba(15,31,75,.35);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-h);
  gap: 1rem;
}

/* Logo */
.site-logo {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-shrink: 0;
  text-decoration: none;
}
/* Echtes Logo-PNG im Header */
.site-logo-img {
  height: 84px;
  width: auto;
  display: block;
  mix-blend-mode: lighten; /* dunkler Logo-Hintergrund wird auf Navy-Header unsichtbar */
}
/* Echtes Logo-PNG im Footer */
.footer-logo-img {
  height: 56px;
  width: auto;
  display: block;
  margin-bottom: 1rem;
  mix-blend-mode: lighten;
}
/* Fallback: SVG-Platzhalter (wird überschrieben, wenn logo.png vorhanden) */
.logo-mark svg { width: 34px; height: 34px; }
.logo-mark svg path, .logo-mark svg line { stroke: white !important; }
.logo-text { display: flex; flex-direction: column; line-height: 1; gap: 2px; }
.logo-name {
  font-family: var(--f-serif);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: .02em;
}
.logo-sub {
  font-family: var(--f-sans);
  font-size: .65rem;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: rgba(255,255,255,.6);
}

/* Main nav */
.main-nav { display: flex; align-items: center; gap: 0; }
.main-nav > ul { display: flex; align-items: center; gap: .25rem; }
.main-nav a {
  font-size: .875rem;
  font-weight: 600;
  color: rgba(255,255,255,.75);
  padding: .5rem .8rem;
  border-radius: var(--r);
  transition: color var(--t), background var(--t);
  position: relative;
}
.main-nav a:hover { color: var(--white); background: rgba(255,255,255,.1); }
.main-nav a.active { color: var(--white); }

/* Dropdown */
.main-nav .has-dropdown { position: relative; }
.main-nav .dropdown {
  position: absolute;
  top: calc(100% + .5rem);
  left: 50%;
  transform: translateX(-50%);
  min-width: 210px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  padding: .5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--t), transform var(--t);
  transform: translateX(-50%) translateY(-6px);
  z-index: 100;
}
.main-nav .has-dropdown:hover .dropdown,
.main-nav .has-dropdown:focus-within .dropdown {
  opacity: 1;
  pointer-events: all;
  transform: translateX(-50%) translateY(0);
}
.main-nav .dropdown a {
  display: flex;
  align-items: center;
  gap: .625rem;
  padding: .6rem .875rem;
  border-radius: var(--r);
  color: var(--text);
  font-size: .875rem;
}
.main-nav .dropdown a:hover { background: var(--surface); color: var(--brick); }
.main-nav .dropdown a .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--brick);
  flex-shrink: 0;
  opacity: .4;
}
.main-nav .dropdown a:hover .dot { opacity: 1; }

/* Header CTA */
.header-phone {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .875rem;
  font-weight: 700;
  color: var(--white);
  padding: .5rem 1rem;
  border: 1.5px solid rgba(255,255,255,.5);
  border-radius: var(--r);
  transition: var(--t);
}
.header-phone:hover {
  background: var(--white);
  color: var(--brick);
  border-color: var(--white);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px; height: 36px;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 22px; height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: var(--t);
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile menu */
.mobile-menu {
  position: fixed; inset: 0;
  background: var(--bg);
  z-index: 899;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--t-slow);
}
.mobile-menu.open { opacity: 1; pointer-events: all; }
.mobile-menu ul { display: flex; flex-direction: column; align-items: center; gap: .25rem; width: 100%; padding: 0 2rem; }
.mobile-menu a {
  display: block;
  font-family: var(--f-serif);
  font-size: clamp(1.5rem, 5vw, 2.2rem);
  font-weight: 700;
  color: var(--muted);
  padding: .5rem 1rem;
  text-align: center;
  transition: color var(--t);
}
.mobile-menu a:hover { color: var(--brick); }
.mobile-menu .mobile-sub {
  font-family: var(--f-sans);
  font-size: .9rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: .08em;
}
.mobile-menu .mobile-divider {
  width: 40px; height: 2px;
  background: var(--border);
  margin: 1rem auto;
}
.mobile-menu .mobile-phone {
  margin-top: 1.5rem;
  font-family: var(--f-sans);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--brick);
}

.cookie-banner {
  position: fixed;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 9999;
  background: #111;
  color: #fff;
  padding: 20px;
  border-radius: 14px;
  box-shadow: 0 10px 40px rgba(0,0,0,.25);
  display: none;
  gap: 20px;
  justify-content: space-between;
  align-items: center;
}

.cookie-banner p {
  margin: 8px 0 0;
  color: #ccc;
}

.cookie-actions {
  display: flex;
  gap: 10px;
}

.cookie-actions button {
  border: 0;
  padding: 12px 18px;
  cursor: pointer;
  border-radius: 8px;
  font-weight: 600;
}

#cookie-accept {
  background: #fff;
  color: #111;
}

#cookie-reject {
  background: transparent;
  color: #fff;
  border: 1px solid #555;
}

@media (max-width: 768px) {
  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ================================================================
   FOOTER
================================================================ */
#site-footer {
  background: var(--text);
  padding-top: 4.5rem;
}

.footer-credit {
  opacity: .7;
  font-size: .9em;
}

.footer-credit a {
  color: inherit;
  text-decoration: none;
  transition: opacity .2s ease;
}

.footer-credit a:hover {
  opacity: 1;
}

.footer-main {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer-brand .site-logo { margin-bottom: 1rem; }
.footer-brand .site-logo .logo-name { color: var(--white); }
.footer-brand .site-logo .logo-sub { color: rgba(255,255,255,.4); }
.footer-brand p {
  font-size: .875rem;
  color: rgba(255,255,255,.5);
  max-width: 30ch;
  line-height: 1.7;
}
.footer-brand .footer-tel {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  margin-top: 1.25rem;
  font-weight: 700;
  color: var(--brick);
  font-size: .95rem;
  transition: color var(--t);
}
.footer-brand .footer-tel:hover { color: var(--wood); }

.footer-col h5 {
  font-family: var(--f-sans);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(255,255,255,.3);
  margin-bottom: 1.25rem;
}
.footer-col ul { display: flex; flex-direction: column; gap: .65rem; }
.footer-col a {
  font-size: .875rem;
  color: rgba(255,255,255,.55);
  transition: color var(--t);
}
.footer-col a:hover { color: var(--bg); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1.25rem 0;
}
.footer-bottom p {
  font-size: .8rem;
  color: rgba(255,255,255,.25);
  max-width: 100%;
}
.footer-legal { display: flex; gap: 1.5rem; }
.footer-legal a {
  font-size: .8rem;
  color: rgba(255,255,255,.3);
  transition: color var(--t);
}
.footer-legal a:hover { color: rgba(255,255,255,.6); }

/* ================================================================
   INDEX – HERO
================================================================ */
.home-hero {
  padding-top: calc(var(--nav-h) + 4rem);
  padding-bottom: 5rem;
  overflow: hidden;
}
.home-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}
.home-hero-visual {
  position: relative;
  aspect-ratio: 4/3;
  background: var(--surface);
  border-radius: var(--r-lg);
  overflow: hidden;
  order: -1;
}
.home-hero-visual::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(15,31,75,.12), transparent 60%);
}
/* Craft pattern overlay */
.hero-craft-bg {
  width: 100%; height: 100%;
  background:
    linear-gradient(rgba(90,56,32,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(90,56,32,.04) 1px, transparent 1px);
  background-size: 24px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-craft-numeral {
  font-family: var(--f-serif);
  font-size: clamp(6rem, 12vw, 10rem);
  font-weight: 900;
  color: rgba(15,31,75,.07);
  line-height: 1;
  user-select: none;
}

.home-hero-content { }
.home-hero-content h1 { margin-bottom: .75rem; }
.home-hero-content h1 em { font-style: italic; color: var(--brick); }
.home-hero-content > p { margin-bottom: 2.25rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .875rem; align-items: center; }

/* Vertical label (like a blueprint annotation) */
.hero-blueprint-label {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  transform: rotate(180deg);
  position: absolute;
  bottom: 2rem; right: 1.5rem;
  font-family: var(--f-sans);
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgba(90,56,32,.3);
  z-index: 2;
}

/* ================================================================
   INDEX – LEISTUNGEN (Werkbank-Liste statt Karten-Raster)
================================================================ */
.werkbank-section { background: var(--surface); }

.werkbank-list { margin-top: 3rem; }

.werkbank-item {
  display: grid;
  grid-template-columns: 80px 1fr auto;
  align-items: center;
  gap: 2rem;
  padding: 2.25rem 0;
  border-top: 1px solid var(--border);
  text-decoration: none;
  transition: background var(--t);
  position: relative;
  cursor: pointer;
}
.werkbank-item:last-child { border-bottom: 1px solid var(--border); }

.werkbank-item::before {
  content: '';
  position: absolute;
  left: -2.5rem; right: -2.5rem; top: 0; bottom: 0;
  background: var(--bg);
  opacity: 0;
  transition: opacity var(--t);
  z-index: 0;
}
.werkbank-item:hover::before { opacity: 1; }
.werkbank-item > * { position: relative; z-index: 1; }

.werkbank-num {
  font-family: var(--f-serif);
  font-size: 2.6rem;
  font-weight: 900;
  color: rgba(15,31,75,.18);
  line-height: 1;
  transition: color var(--t);
  flex-shrink: 0;
  text-align: right;
}
.werkbank-item:hover .werkbank-num { color: var(--brick); }

.werkbank-body { flex: 1; }
.werkbank-body h3 {
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  color: var(--text);
  margin-bottom: .5rem;
  transition: color var(--t);
}
.werkbank-item:hover .werkbank-body h3 { color: var(--brick); }
.werkbank-body p {
  font-size: .9375rem;
  max-width: 60ch;
  margin: 0;
}

.werkbank-arrow {
  width: 44px; height: 44px;
  border: 1.5px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  flex-shrink: 0;
  transition: var(--t);
}
.werkbank-item:hover .werkbank-arrow {
  background: var(--brick);
  border-color: var(--brick);
  color: var(--white);
  transform: translateX(4px);
}

/* ================================================================
   INDEX – ÜBER UNS
================================================================ */
.about-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}
.about-visual {
  background: var(--surface);
  border-radius: var(--r-lg);
  aspect-ratio: 3/4;
  position: relative;
  overflow: hidden;
}
/* Typographic large numeral as visual element */
.about-visual-inner {
  width: 100%; height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 2rem;
  background: linear-gradient(to bottom, transparent 40%, rgba(15,31,75,.55) 100%);
}
.about-big-num {
  font-family: var(--f-serif);
  font-size: clamp(5rem, 10vw, 9rem);
  font-weight: 900;
  color: rgba(15,31,75,.12);
  position: absolute;
  top: 1rem; left: 1.5rem;
  line-height: 1;
  user-select: none;
}
.about-caption {
  font-family: var(--f-sans);
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(255,255,255,.6);
  margin-bottom: .25rem;
}
.about-caption-big {
  font-family: var(--f-serif);
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  color: var(--bg);
  line-height: 1.2;
}

.about-content h2 { margin-bottom: .5rem; }
.about-content > p { margin-bottom: 2rem; }
.about-list { display: flex; flex-direction: column; gap: .875rem; margin-bottom: 2.5rem; }
.about-list li {
  display: flex;
  align-items: flex-start;
  gap: .875rem;
  font-size: .9375rem;
  color: var(--muted);
}
.about-list li::before {
  content: '';
  width: 20px; height: 20px;
  background: var(--brick-light);
  border: 1px solid rgba(15,31,75,.2);
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 2px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 12 12'%3E%3Cpolyline points='2,6 5,9 10,3' fill='none' stroke='%23A83428' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

/* ================================================================
   INDEX – KONTAKTFORMULAR
================================================================ */
.contact-section { background: var(--surface); }
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}
.contact-sidebar h2 { margin-bottom: .75rem; }
.contact-sidebar > p { margin-bottom: 2rem; }
.contact-detail-list { display: flex; flex-direction: column; gap: 1.25rem; margin-bottom: 2.5rem; }
.contact-detail {
  display: flex;
  align-items: center;
  gap: .875rem;
}
.contact-detail-icon {
  width: 42px; height: 42px;
  background: var(--brick-light);
  border: 1px solid rgba(15,31,75,.15);
  border-radius: var(--r);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brick);
  flex-shrink: 0;
}
.contact-detail-body { display: flex; flex-direction: column; gap: 1px; }
.contact-detail-label {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}
.contact-detail-value { font-size: 1rem; font-weight: 600; color: var(--text); transition: color var(--t); }
.contact-detail-value:hover { color: var(--brick); }

/* Opening hours table */
.oh-table { width: 100%; }
.oh-table td { padding: .4rem 0; font-size: .875rem; color: var(--muted); }
.oh-table td:last-child { text-align: right; font-weight: 600; color: var(--text); }
.oh-table tr { border-bottom: 1px solid var(--border); }
.oh-table tr:last-child td { border-bottom: none; }

/* Form */
.form-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: clamp(1.75rem, 4vw, 2.5rem);
  box-shadow: var(--shadow);
}
.form-card-title {
  font-family: var(--f-serif);
  font-size: 1.5rem;
  color: var(--text);
  margin-bottom: .375rem;
}
.form-card-sub { font-size: .875rem; margin-bottom: 1.75rem; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: .375rem; }
.form-group.full { grid-column: 1 / -1; }

.form-group label {
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .05em;
  color: var(--text);
  text-transform: uppercase;
}
.form-group label .req { color: var(--brick); margin-left: 2px; }

.form-input {
  width: 100%;
  padding: .75rem 1rem;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  color: var(--text);
  font-size: .9375rem;
  outline: none;
  transition: border-color var(--t), box-shadow var(--t);
  appearance: none;
  -webkit-appearance: none;
}
.form-input::placeholder { color: rgba(122,92,74,.4); }
.form-input:focus { border-color: var(--brick); box-shadow: 0 0 0 3px rgba(15,31,75,.1); }
.form-input.has-error { border-color: #c0392b; }
textarea.form-input { resize: vertical; min-height: 110px; }
select.form-input {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%237A5C4A' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right .9rem center;
  padding-right: 2.5rem;
  cursor: pointer;
}

.hp-field { display: none !important; visibility: hidden; }

.form-check {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  grid-column: 1 / -1;
}
.form-check input[type="checkbox"] {
  width: 18px; height: 18px; min-width: 18px;
  margin-top: 2px;
  accent-color: var(--brick);
  cursor: pointer;
  border-radius: var(--r);
}
.form-check span { font-size: .8125rem; color: var(--muted); line-height: 1.55; }
.form-check a { color: var(--brick); text-decoration: underline; }

.field-error { font-size: .77rem; color: #c0392b; display: none; }
.form-group.has-error .field-error { display: block; }

.form-actions { grid-column: 1 / -1; margin-top: .75rem; }
.form-actions .btn { width: 100%; justify-content: center; padding: 1rem; font-size: 1rem; }
.form-note {
  margin-top: .625rem;
  font-size: .77rem;
  color: var(--muted);
  text-align: center;
}

#form-status { display: none; padding: .875rem 1rem; border-radius: var(--r); font-size: .9rem; font-weight: 600; grid-column: 1/-1; }
#form-status.success { display: block; background: rgba(39,174,96,.1); border: 1px solid rgba(39,174,96,.3); color: #1a7a42; }
#form-status.error { display: block; background: rgba(192,57,43,.1); border: 1px solid rgba(192,57,43,.3); color: #9b2317; }

/* Map placeholder */
.map-embed {
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 16/9;
  background: var(--surface-2);
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: .75rem;
  color: var(--muted); font-size: .875rem;
  margin-top: 1.5rem;
}
.map-embed iframe { width: 100%; height: 100%; }

/* ================================================================
   SUBPAGE – HERO
================================================================ */
.sub-hero {
  padding-top: calc(var(--nav-h) + 3.5rem);
  padding-bottom: 4rem;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
/* Grain texture on subhero */
.sub-hero::after {
  content: '';
  position: absolute; inset: 0;
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 28px, rgba(90,56,32,.025) 29px),
    repeating-linear-gradient(90deg, transparent, transparent 28px, rgba(90,56,32,.025) 29px);
  pointer-events: none;
}
.sub-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative; z-index: 1;
}
.sub-hero-content h1 { margin-bottom: .75rem; }
.sub-hero-content > p { margin-bottom: 2rem; }
.sub-hero-actions { display: flex; flex-wrap: wrap; gap: .875rem; }
.sub-hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ================================================================
   SUBPAGE – INTRO / LEISTUNGSDETAIL
================================================================ */
.service-intro { background: var(--bg); }
.service-intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: start;
}
.service-intro-text h2 { margin-bottom: .75rem; }
.service-intro-text > p { margin-bottom: 1.5rem; }

.feature-list { display: flex; flex-direction: column; gap: 1.25rem; margin-top: 2rem; }
.feature-item {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 1rem;
  align-items: start;
  padding: 1.25rem;
  background: var(--surface);
  border-radius: var(--r-lg);
  border: 1px solid var(--border);
  transition: border-color var(--t), transform var(--t);
}
.feature-item:hover { border-color: rgba(15,31,75,.25); transform: translateX(4px); }
.feature-num {
  font-family: var(--f-serif);
  font-size: 1.8rem;
  font-weight: 900;
  color: rgba(15,31,75,.2);
  line-height: 1;
}
.feature-item:hover .feature-num { color: var(--brick); }
.feature-body h4 { margin-bottom: .3rem; }
.feature-body p { font-size: .875rem; max-width: 100%; }

/* ================================================================
   SUBPAGE – PROZESS
================================================================ */
.process-section { background: var(--surface); }
.process-section h2 { margin-bottom: 3.5rem; }

.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0;
  position: relative;
}
/* Connecting line */
.process-steps::before {
  content: '';
  position: absolute;
  top: 2rem;
  left: 2.5rem;
  right: 2.5rem;
  height: 2px;
  background: linear-gradient(to right, var(--border), var(--brick), var(--border));
  z-index: 0;
}
.process-step {
  position: relative;
  z-index: 1;
  padding: 0 1.5rem;
  text-align: center;
}
.process-step:first-child { padding-left: 0; }
.process-step:last-child { padding-right: 0; }

.step-circle {
  width: 4rem; height: 4rem;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1.25rem;
  font-family: var(--f-serif);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--muted);
  transition: var(--t);
}
.process-step:hover .step-circle {
  background: var(--brick);
  border-color: var(--brick);
  color: var(--white);
}
.process-step h4 { margin-bottom: .4rem; font-size: .95rem; }
.process-step p { font-size: .8375rem; text-align: center; margin: 0 auto; max-width: 22ch; }

/* ================================================================
   SUBPAGE – PROJEKTE/GALERIE
================================================================ */
.projects-section { background: var(--bg); }
.projects-section h2 { margin-bottom: 2.5rem; }

.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.project-card {
  background: var(--surface);
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: transform var(--t), box-shadow var(--t);
}
.project-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.project-card:nth-child(1) { grid-column: span 2; }

.project-visual {
  aspect-ratio: 16/9;
  background: var(--surface-2);
  position: relative;
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.project-card:nth-child(1) .project-visual { aspect-ratio: 21/9; }
.project-visual img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform .5s ease;
  display: block;
}
.project-card:hover .project-visual img { transform: scale(1.04); }

.project-vis-inner {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--f-serif);
  font-size: clamp(3rem,6vw,5rem);
  font-weight: 900;
  color: rgba(90,56,32,.07);
  position: relative;
}
.project-vis-inner::before {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(90,56,32,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(90,56,32,.04) 1px, transparent 1px);
  background-size: 20px 20px;
}

.project-info { padding: 1.25rem 1.5rem 1.5rem; }
.project-tag {
  display: inline-block;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--brick);
  margin-bottom: .375rem;
}
.project-info h4 { font-size: 1rem; margin-bottom: .3rem; }
.project-info p { font-size: .8375rem; max-width: 100%; margin: 0; }

/* ================================================================
   SUBPAGE – FAQ
================================================================ */
.faq-section { background: var(--surface); }
.faq-section h2 { margin-bottom: 2.5rem; }

.faq-list { display: flex; flex-direction: column; gap: 0; }
.faq-item {
  border-top: 1px solid var(--border);
}
.faq-item:last-child { border-bottom: 1px solid var(--border); }
.faq-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  padding: 1.25rem 0;
  text-align: left;
  cursor: pointer;
  transition: color var(--t);
}
.faq-trigger:hover { color: var(--brick); }
.faq-question {
  font-family: var(--f-sans);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  transition: color var(--t);
}
.faq-trigger:hover .faq-question { color: var(--brick); }
.faq-icon {
  width: 28px; height: 28px;
  border: 1.5px solid var(--border);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  color: var(--muted);
  transition: var(--t);
}
.faq-item.open .faq-icon { background: var(--brick); border-color: var(--brick); color: var(--white); transform: rotate(45deg); }
.faq-body { display: none; padding-bottom: 1.25rem; }
.faq-body p { font-size: .9375rem; max-width: 70ch; }
.faq-item.open .faq-body { display: block; }

/* ================================================================
   SUBPAGE – INLINE CTA BANNER
================================================================ */
.cta-banner {
  background: var(--text);
  padding: 4rem 0;
  text-align: center;
}
.cta-banner h2 { color: var(--bg); margin-bottom: .75rem; }
.cta-banner p { color: rgba(255,255,255,.55); margin: 0 auto 2rem; max-width: 52ch; }
.cta-banner .cta-actions { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; }

/* ================================================================
   SIGNATURE ELEMENTS (page-specific decorative graphics)
================================================================ */

/* Grundriss (Innenausbau) */
.sig-grundriss {
  width: 100%;
  max-width: 360px;
  aspect-ratio: 4/3;
  position: relative;
}

/* Pflegekalender (Gartenpflege) */
.sig-kalender {
  width: 100%;
  max-width: 380px;
}
.kalender-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
}
.kalender-season {
  padding: 1.25rem .875rem;
  text-align: center;
  border-right: 1px solid var(--border);
}
.kalender-season:last-child { border-right: none; }
.kalender-season-name {
  font-family: var(--f-serif);
  font-size: .85rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: .75rem;
  padding-bottom: .5rem;
  border-bottom: 2px solid var(--brick);
}
.kalender-tasks { display: flex; flex-direction: column; gap: .375rem; }
.kalender-task {
  font-size: .72rem;
  color: var(--muted);
  padding: .25rem .5rem;
  background: var(--bg);
  border-radius: 3px;
  text-align: left;
  line-height: 1.35;
}
.kalender-months {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: .75rem;
  border-top: 1px solid var(--border);
}
.kalender-month-group {
  display: flex;
  gap: 2px;
  padding: .5rem .375rem;
  justify-content: center;
  border-right: 1px solid var(--border);
}
.kalender-month-group:last-child { border-right: none; }
.kalender-month {
  font-size: .6rem;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--muted);
  background: var(--surface);
  padding: .2rem .3rem;
  border-radius: 2px;
}

/* Checkliste manifest (Entrümpelung) */
.sig-checkliste {
  width: 100%;
  max-width: 320px;
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  font-family: var(--f-sans);
  position: relative;
}
.sig-checkliste::before {
  content: 'AUFTRAGSFORMULAR';
  position: absolute;
  top: -10px; left: 50%;
  transform: translateX(-50%);
  font-size: .6rem;
  font-weight: 700;
  letter-spacing: .18em;
  background: var(--brick);
  color: var(--white);
  padding: .2rem .75rem;
  border-radius: 2px;
}
.check-list { display: flex; flex-direction: column; gap: .75rem; }
.check-row {
  display: flex;
  align-items: center;
  gap: .875rem;
  padding: .625rem .75rem;
  border-radius: var(--r);
  background: var(--bg);
  border: 1px solid var(--border);
}
.check-box {
  width: 18px; height: 18px;
  border: 1.5px solid var(--border);
  border-radius: 3px;
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.check-box.checked { background: var(--brick); border-color: var(--brick); }
.check-box.checked::after {
  content: '';
  width: 8px; height: 5px;
  border-left: 2px solid white;
  border-bottom: 2px solid white;
  transform: rotate(-45deg) translateY(-1px);
  display: block;
}
.check-label { font-size: .8125rem; color: var(--muted); }
.check-label strong { color: var(--text); font-weight: 600; }

/* Fenster-Querschnitt SVG */
.sig-fenster {
  width: 100%;
  max-width: 320px;
}


/* ================================================================
   LEGAL PAGES
================================================================ */
.legal-page { padding-top: calc(var(--nav-h) + 3rem); padding-bottom: 5rem; }
.legal-page h1 { margin-bottom: 2rem; }
.legal-page h2 { font-size: 1.4rem; font-family: var(--f-sans); font-weight: 700; color: var(--text); margin: 2.5rem 0 .75rem; }
.legal-page h3 { font-size: 1.05rem; font-family: var(--f-sans); font-weight: 600; color: var(--text); margin: 1.5rem 0 .5rem; }
.legal-page p, .legal-page li { font-size: .9375rem; color: var(--muted); margin-bottom: .75rem; max-width: 68ch; }
.legal-page ul { padding-left: 1.5rem; list-style: disc; }
.legal-page a { color: var(--brick); }
.legal-page a:hover { text-decoration: underline; }
.legal-page .back-link {
  display: inline-flex; align-items: center; gap: .5rem;
  font-size: .875rem; color: var(--muted); margin-bottom: 2.5rem;
  transition: color var(--t);
}
.legal-page .back-link:hover { color: var(--brick); }

/* ================================================================
   RESPONSIVE
================================================================ */
@media (max-width: 1024px) {
  .about-split { grid-template-columns: 1fr; gap: 3rem; }
  .about-visual { aspect-ratio: 5/3; max-width: 100%; }
  .footer-main { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
  .service-intro-grid { grid-template-columns: 1fr; gap: 3rem; }
}

@media (max-width: 768px) {
  .main-nav, .header-phone { display: none; }
  .hamburger { display: flex; }

  .home-hero-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .home-hero-visual { order: 0; aspect-ratio: 3/2; }
  .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .sub-hero-grid { grid-template-columns: 1fr; }
  .sub-hero-visual { display: none; }
  .projects-grid { grid-template-columns: 1fr 1fr; }
  .project-card:nth-child(1) { grid-column: 1 / -1; }
  .werkbank-item { grid-template-columns: 56px 1fr auto; gap: 1.25rem; }
}

@media (max-width: 540px) {
  .form-row { grid-template-columns: 1fr; }
  .projects-grid { grid-template-columns: 1fr; }
  .process-steps::before { display: none; }
  .process-steps { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
  .footer-main { grid-template-columns: 1fr; }
  .werkbank-arrow { display: none; }
  .kalender-grid { grid-template-columns: 1fr 1fr; }
  .kalender-months { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 360px) {
  .process-steps { grid-template-columns: 1fr; }
  .hero-actions, .sub-hero-actions { flex-direction: column; }
}

/* Focus visible */
:focus-visible { outline: 2px solid var(--brick); outline-offset: 3px; border-radius: var(--r); }
