/* ==========================================================================
   Blickensdorf Immobilien
   Single stylesheet. No framework, no build step.
   Sections: tokens · base · frame · hero · buttons · header · page ·
             form · footer · utilities
   ========================================================================== */

/* --- 1. Design tokens ---------------------------------------------------- */
:root {
  /* Palette — adjust these four to retune the whole site */
  --bg:              #f6f3ec;
  --fg:              #2b2925;
  --muted:           #8b8578;
  --accent:          #a08a5f;

  --hairline:        rgb(43 41 37 / 0.18);
  --hairline-strong: rgb(43 41 37 / 0.30);
  --fg-soft:         rgb(43 41 37 / 0.80);

  /* Type */
  --font-display: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --font-body:    "Jost", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --tracking-title:  0.12em;
  --tracking-button: 0.35em;
  --tracking-micro:  0.30em;

  /* Layout */
  --frame-inset: 1rem;
  --pad-x:       1.5rem;
  --measure:     34rem;

  /* Motion */
  --duration: 300ms;
  --ease:     cubic-bezier(0.4, 0, 0.2, 1);
}

@media (min-width: 640px) {
  :root {
    --frame-inset: 1.5rem;
    --pad-x:       2.5rem;
  }
}

/* --- 2. Base ------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

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

body {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  padding-inline: var(--pad-x);
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 1px;
}

/* --- 3. Decorative frame + skip link ------------------------------------- */
.frame {
  position: fixed;
  inset: var(--frame-inset);
  border: 1px solid var(--hairline);
  pointer-events: none;
  z-index: 1;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: 0.75rem 1.25rem;
  background: var(--fg);
  color: var(--bg);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
}
.skip-link:focus {
  left: 50%;
  top: 0.5rem;
  transform: translateX(-50%);
}

/* --- 4. Hero ------------------------------------------------------------- */
.hero {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-block: 6rem;
  text-align: center;
  animation: fade-in 1s var(--ease) both;
}

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.hero__mark {
  width: 8rem;
  color: var(--fg);
  opacity: 0.85;
}
@media (min-width: 640px) { .hero__mark { width: 10rem; } }

.hero__title {
  margin-top: 2.5rem;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 5vw, 3rem);
  font-weight: 300;
  line-height: 1.15;
  text-transform: uppercase;
  letter-spacing: var(--tracking-title);
  /* To match the logo wordmark instead, swap the two lines below:
     font-family: var(--font-body);
     font-weight: 400; letter-spacing: 0.14em; */
}

.hero__rule {
  width: 3rem;
  height: 1px;
  margin-top: 2rem;
  background: var(--accent);
}

.hero__subtitle {
  margin-top: 2rem;
  font-family: var(--font-display);
  font-size: clamp(1.125rem, 2.5vw, 1.25rem);
  font-style: italic;
  font-weight: 300;
  letter-spacing: 0.02em;
  color: var(--muted);
}

/* --- 5. Buttons ---------------------------------------------------------- */
.btn {
  display: inline-block;
  margin-top: 4rem;
  padding: 0.75rem 2.5rem;
  border: 1px solid var(--hairline-strong);
  border-radius: 2px;
  background: none;
  color: var(--fg-soft);
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: var(--tracking-button);
  text-decoration: none;
  cursor: pointer;
  transition: border-color var(--duration) var(--ease),
              color var(--duration) var(--ease);
}
@media (min-width: 640px) { .btn { font-size: 0.75rem; } }

.btn:hover,
.btn:focus-visible {
  border-color: var(--accent);
  color: var(--fg);
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.btn--submit { margin-top: 0; }

/* --- 6. Site header (inner pages) ---------------------------------------- */
.site-header {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 2rem;
}

.site-header__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.site-header__mark { width: 3rem; color: var(--fg); opacity: 0.85; }

.site-header__wordmark {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.site-nav { display: flex; gap: 1.5rem; }

.site-nav a {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
  text-decoration: none;
  transition: color var(--duration) var(--ease);
}
.site-nav a:hover,
.site-nav a[aria-current="page"] { color: var(--fg); }

/* --- 7. Page content ----------------------------------------------------- */
.page {
  position: relative;
  z-index: 2;
  flex: 1;
  padding-block: 2rem 5rem;
}

.page__inner {
  max-width: var(--measure);
  margin-inline: auto;
}

.page__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.page__lead {
  margin-top: 1.25rem;
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-style: italic;
  color: var(--muted);
}

.page__aside {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--hairline);
  font-size: 0.85rem;
  color: var(--muted);
}

.prose > * + * { margin-top: 1.25rem; }

.prose h2 {
  margin-top: 2.5rem;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.prose ul { padding-left: 1.25rem; }
.prose li + li { margin-top: 0.4rem; }
.prose a { text-underline-offset: 3px; }

/* --- 8. Form ------------------------------------------------------------- */
.form {
  display: grid;
  gap: 1.75rem;
  margin-top: 3rem;
}

.field { display: grid; gap: 0.5rem; }

.field__label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
}

.field__optional { text-transform: none; letter-spacing: 0; }

.field__control {
  width: 100%;
  padding: 0.7rem 0.25rem;
  border: 0;
  border-bottom: 1px solid var(--hairline-strong);
  border-radius: 0;
  background: transparent;
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 300;
  transition: border-color var(--duration) var(--ease),
              background-color var(--duration) var(--ease);
}

.field__control:focus {
  border-bottom-color: var(--accent);
  background-color: rgb(160 138 95 / 0.05);
}

textarea.field__control {
  min-height: 8rem;
  resize: vertical;
}

.field--check {
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 0.75rem;
}

.field--check input {
  margin-top: 0.35rem;
  accent-color: var(--accent);
}

.field--check label {
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--muted);
}

.honeypot {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form__actions {
  display: grid;
  gap: 1.25rem;
  justify-items: start;
}

.form__status {
  min-height: 1.5rem;
  font-size: 0.85rem;
  color: var(--muted);
}
.form__status[data-state="success"] { color: #3f6b46; }
.form__status[data-state="error"]   { color: #9b3b2f; }

/* --- 9. Footer ----------------------------------------------------------- */
.site-footer {
  position: relative;
  z-index: 2;
  padding-block: 2.5rem;
  text-align: center;
  font-size: 0.63rem;
  text-transform: uppercase;
  letter-spacing: var(--tracking-micro);
  color: var(--muted);
}

.site-footer__links {
  margin-top: 0.75rem;
  display: flex;
  justify-content: center;
  gap: 0.6rem;
}

.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--fg); }

/* --- 10. Motion preferences ---------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .hero { animation: none; }
}

/* --- 11. 404 additions --------------------------------------------------- */

/* Small uppercase label above a hero title */
.hero__eyebrow {
  margin-bottom: 1.25rem;
  font-family: var(--font-body);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: var(--tracking-micro);
  color: var(--muted);
}

/* Side-by-side hero buttons */
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-top: 4rem;
}

/* Reset the stacked margin when buttons sit inside a row */
.hero__actions .btn { margin-top: 0; }

/* Secondary, lower-emphasis button */
.btn--quiet {
  border-color: transparent;
  color: var(--muted);
}
.btn--quiet:hover,
.btn--quiet:focus-visible {
  border-color: var(--hairline-strong);
  color: var(--fg);
}