/* Personalisierte Ortskompass-Einladung und Danke-Seite.
   astro-geografie.html lädt site.css nicht. Darum brauchen alle var()-Werte
   feste Fallbacks aus src/styles.css; die Schrift bleibt lokal bei DM Sans.
   Konzept und Änderungshistorie: docs/LEADFUNNEL_INHALTE.md und
   docs/TEXT-ARBEITSSTAND-2026-07-12.md. */

.ortskompass-optin {
  /* Fluss-Karte im astro-page-Grid: spannt über alle Spalten, sitzt direkt am Ergebnis. */
  grid-column: 1 / -1;
  margin: 28px 0 8px;
  scroll-margin-top: 96px;
  padding: 26px 28px 24px;
  box-sizing: border-box;
  position: relative;
  overflow: hidden;
  /* Runde 4 (14.07.2026): Weiss oben links laeuft jetzt sichtbar in kuehles Tuerkis
     aus. Die zwei Radiallichter geben dem Verlauf Tiefe, ohne die Porzellan-Tokens
     der uebrigen Kartenfamilie zu veraendern. Bewusst ohne backdrop-filter wegen
     der bekannten Chromium-Flackerklasse. */
  background:
    radial-gradient(ellipse 78% 68% at 8% 4%, rgba(127, 233, 244, 0.16), transparent 68%),
    radial-gradient(ellipse 62% 72% at 100% 100%, rgba(0, 174, 187, 0.07), transparent 72%),
    linear-gradient(150deg, #ffffff 0%, #edf7f9 40%, #c9e3ea 100%);
  border: var(--porzellan-border);
  border-radius: var(--porzellan-radius);
  box-shadow: var(--porzellan-shadow);
  color: var(--ink, #031420);
}

/* Oberer Zier-Faden: Petrol -> Cyan, seitlich eingerückt, an den Rändern ausblendend. */
.ortskompass-optin::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 24px;
  right: 24px;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--petrol, #006479) 22%,
    var(--cyan, #00b2c2) 78%,
    transparent
  );
  border-radius: 2px;
}

/* Vor der Berechnung unsichtbar (app.js entfernt hidden nach „Karte berechnen"). */
.ortskompass-optin[hidden] {
  display: none;
}

/* Sanftes Einblenden nur, wenn Bewegung erwünscht ist; reduziert-Motion zeigt sofort. */
@media (prefers-reduced-motion: no-preference) {
  .ortskompass-optin:not([hidden]) {
    animation: ok-fade-in 0.5s ease both;
  }
}

@keyframes ok-fade-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Zweispaltig: Funnel-Text links, Porzellan-Kunstkarte rechts, vertikal zentriert. */
.ok-inner {
  display: flex;
  gap: 26px;
  align-items: center;
}

.ok-content {
  flex: 1 1 auto;
  min-width: 0;
  position: relative;
  z-index: 1;
}

.ok-eyebrow {
  margin: 0 0 8px;
  color: var(--petrol, #006479);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* Ruhige Anrede: „DM Sans" Medium (TOPLUXURY ist auf dieser Seite nicht geladen). */
.ok-lead {
  margin: 0 0 6px;
  font-family: "DM Sans", sans-serif;
  font-weight: 500;
  font-size: 1.34rem;
  line-height: 1.28;
  letter-spacing: 0.01em;
  color: var(--ink, #031420);
  text-wrap: balance;
}

.ok-sub {
  margin: 0 0 16px;
  /* 16.07. (Daniel): weitläufiger setzen, damit die Kachel flacher wird — 74ch bleibt lesbar. */
  max-width: 74ch;
  color: var(--muted, #504b5d);
  font-size: 0.92rem;
  line-height: 1.55;
}

/* Formular: keine eigene Optik mehr, nur ein schlanker, klarer Fluss. */
.ortskompass-form {
  margin: 0;
}

.ok-turnstile-note {
  margin: 7px 0 0;
  max-width: 58ch;
  color: #596a74;
  font-size: 0.7rem;
  line-height: 1.4;
}

.ok-turnstile-note a {
  color: var(--petrol, #006479);
  text-underline-offset: 2px;
}

.ok-form-open {
  margin-top: 4px;
}

.ok-form-open[hidden],
.ok-form-open[hidden] + .ok-turnstile-note {
  display: none;
}

.ortskompass-form-panel {
  min-width: 0;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(0, 100, 121, 0.22);
}

/* Schlanker Petrol-Kicker über der Pillen-Eingabe (analog den Panel-Kickern der Seite). */
.ok-fields {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 14px;
  align-items: end;
  max-width: 760px;
}

.ok-email-field {
  min-width: 0;
}

.ok-email-label {
  display: block;
  margin: 0 0 7px;
  color: var(--petrol, #006479);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Das E-Mail-Feld bleibt ruhig und begrenzt; der Submit folgt nach der Einwilligung. */
.ok-email-line {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: stretch;
  max-width: 420px;
}

.ok-email-input {
  flex: 1 1 220px;
  min-width: 0;
  padding: 12px 18px;
  border: 1px solid var(--line, #dde6ea);
  border-radius: 33px;
  background: var(--field-bg, #f6f9fa);
  color: var(--field-text, #090d1c);
  color-scheme: light;
  font: inherit;
  font-size: 16px;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.ok-email-input::placeholder {
  color: var(--field-placeholder, #56616d);
  opacity: 1;
}

.ok-email-input:focus {
  outline: none;
  border-color: var(--petrol, #006479);
  background: var(--field-bg-focus, #ffffff);
  box-shadow: 0 0 0 3px rgba(0, 100, 121, 0.12);
}

@media (hover: hover) {
  .ok-email-input:hover:not(:focus):not(:disabled) {
    border-color: var(--petrol, #006479);
    background: var(--field-bg-hover, #fbfdfe);
    box-shadow: 0 4px 14px rgba(0, 100, 121, 0.12);
    transform: translateY(-1px);
  }
}

/* Tastatur-Fokus braucht mehr als den dezenten Maus-Schein (outline:none oben überstimmt sonst). */
.ok-email-input:focus-visible {
  outline: 3px solid var(--cyan, #00b2c2);
  outline-offset: 2px;
}

.ok-email-input:disabled {
  background: var(--field-bg-disabled, #e9f0f2);
  color: var(--field-disabled-text, #606a75);
  cursor: not-allowed;
  opacity: 1;
  transform: none;
}

.ok-email-input:-webkit-autofill {
  -webkit-text-fill-color: var(--field-text, #090d1c);
  box-shadow: 0 0 0 1000px var(--field-bg-focus, #ffffff) inset;
  caret-color: var(--field-text, #090d1c);
}

/* Runde 4 (14.07.2026): Eine gemeinsame Petrol-Quelle fuer Primaer-CTAs auf hellen
   Karten. Das Ende #0a7688 haelt Weiss auch mit brightness(1.08) bei 4.70:1. */
.btn-petrol {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 12px 24px;
  font-family: inherit;
  background: linear-gradient(100deg, #0a4d68 0%, #006479 45%, #0a7688 100%);
  color: #fff;
  border: none;
  text-transform: uppercase;
  letter-spacing: 1.8px;
  font-weight: 600;
  font-size: 0.74rem;
  border-radius: 33px;
  transition: filter 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.btn-petrol:hover {
  filter: brightness(1.08);
  box-shadow: 0 4px 14px rgba(0, 96, 117, 0.28);
  transform: translateY(-1px);
}

.btn-petrol:focus-visible {
  outline: 3px solid var(--petrol, #006479);
  outline-offset: 2px;
}

.btn-petrol:disabled {
  cursor: not-allowed;
  opacity: 0.62;
  filter: none;
  transform: none;
}

/* FOKUS-Auswahl: seit 16.07.2026 EIN natives Select im Look der Formfelder
   (.ok-email-input als Vorbild), statt der frueheren Radio-Pillen. Der Pfeil ist
   ein eingebetteter Data-URI (Petrol), kein externer Request. */
.ortskompass-fokus {
  min-width: 0;
  margin: 0;
}

.ok-fokus-label {
  display: block;
  margin: 0 0 8px;
  color: var(--petrol, #006479);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.ok-fokus-select {
  display: block;
  width: min(100%, 340px);
  padding: 11px 46px 11px 18px;
  border: 1px solid var(--line, #dde6ea);
  border-radius: 33px;
  background-color: var(--field-bg, #f6f9fa);
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%23006479' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 18px center;
  color: var(--field-text, #090d1c);
  color-scheme: light;
  font: inherit;
  font-size: 16px;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.ok-fokus-select:focus {
  outline: none;
  border-color: var(--petrol, #006479);
  background-color: var(--field-bg-focus, #ffffff);
  box-shadow: 0 0 0 3px rgba(0, 100, 121, 0.12);
}

@media (hover: hover) {
  .ok-fokus-select:hover:not(:focus) {
    border-color: var(--petrol, #006479);
    background-color: var(--field-bg-hover, #fbfdfe);
    box-shadow: 0 4px 14px rgba(0, 100, 121, 0.12);
  }
}

.ok-fokus-select:focus-visible {
  outline: 3px solid var(--cyan, #00b2c2);
  outline-offset: 2px;
}

/* Hinweis + Datenschutz: AA-Farbe mit Reserve auch auf dem kraeftigsten Mischton
   #bbdfe7 aus Endverlauf + rechtem Radiallicht (4.75:1). */
.ortskompass-hinweis {
  margin: 10px 0 0;
  /* 16.07. (Daniel): weitläufiger setzen, siehe .ok-sub. */
  max-width: 74ch;
  color: #4d5e69;
  font-size: 0.74rem;
  line-height: 1.5;
}

.ok-legal-footnote {
  margin: 12px 0 0;
  padding-top: 8px;
  max-width: 760px;
  border-top: 1px solid rgba(0, 100, 121, 0.16);
  color: #4d5e69;
  font-size: 0.72rem;
  line-height: 1.45;
}

.ok-legal-footnote a {
  color: var(--petrol, #006479);
  text-underline-offset: 2px;
}

.ok-honeypot {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.ok-turnstile {
  width: min(100%, 420px);
  min-height: 65px;
  margin: 0;
}

.ok-form-status {
  grid-area: status;
  min-height: 1.5em;
  margin: 6px 0 0;
  color: #4d5e69;
  font-size: 0.78rem;
  line-height: 1.45;
}

.ok-action-row {
  display: grid;
  grid-template-columns: minmax(300px, 420px) max-content;
  grid-template-areas:
    "turnstile submit"
    "status status";
  gap: 0 14px;
  align-items: center;
  max-width: 760px;
  margin-top: 12px;
}

.ok-action-row .ok-turnstile {
  grid-area: turnstile;
}

.ok-action-row .ok-submit {
  grid-area: submit;
  margin: 0;
}

/* Zweitweg: abgesetzt mit feiner Trennlinie – gibt der Karte unten einen sauberen Abschluss. */
.ok-alt {
  margin: 16px 0 0;
  padding-top: 13px;
  border-top: 1px solid var(--line, #dde6ea);
  color: #4d5e69;
  font-size: 0.86rem;
}

.ok-content:has(.ortskompass-form-panel:not([hidden])) > .ok-alt {
  display: none;
}

/* Porzellan-Kunstkarte (rechte Spalte): schwebt mit mehrstufigem 3D-Schatten + Hover-Lift. */
.ok-art {
  flex: 0 0 225px;
  width: 225px;
  height: 300px;
  padding: 0;
  box-sizing: border-box;
  position: relative;
  align-self: center;
  appearance: none;
  border: 0;
  border-radius: 12px;
  background: none;
  color: inherit;
  cursor: pointer;
  font: inherit;
  perspective: 1200px;
  box-shadow:
    0 1px 2px rgba(3, 20, 32, 0.08),
    0 12px 28px rgba(3, 20, 32, 0.14),
    0 30px 60px rgba(3, 20, 32, 0.11),
    0 46px 86px rgba(3, 20, 32, 0.08);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.ok-art:hover {
  transform: translateY(-4px);
  box-shadow:
    0 2px 3px rgba(3, 20, 32, 0.09),
    0 18px 38px rgba(3, 20, 32, 0.18),
    0 38px 72px rgba(3, 20, 32, 0.15),
    0 58px 104px rgba(3, 20, 32, 0.1);
}

.ok-art:focus-visible {
  outline: 3px solid var(--cyan, #00b2c2);
  outline-offset: 4px;
}

/* Flip-Buehne nach dem HD-Rechner: Vorder- und Rueckseite liegen deckungsgleich,
   die Guilloche-Seite ist vorab um 180 Grad gedreht. */
.ok-flip {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.3, 1);
}

.ok-flip.is-flipped {
  transform: rotateY(180deg);
}

.ok-flip-front,
.ok-flip-back {
  position: absolute;
  inset: 0;
  box-sizing: border-box;
  border-radius: inherit;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: hidden;
}

.ok-flip-front {
  padding: 9px;
  border: var(--porzellan-border);
  background: var(--porzellan-bg);
  justify-content: flex-end;
}

.ok-flip-back {
  padding: 9px;
  border: var(--porzellan-border);
  background: var(--porzellan-bg);
  justify-content: center;
  transform: rotateY(180deg);
}

.ok-flip-field {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(165deg, #0a2635 0%, #051a28 55%, #031420 100%);
  background:
    repeating-radial-gradient(
      circle at 50% 50%,
      color-mix(in srgb, var(--ok-sign-color, #00b2c2) 34%, transparent) 0,
      color-mix(in srgb, var(--ok-sign-color, #00b2c2) 34%, transparent) 1px,
      transparent 1px,
      transparent 9px
    ),
    radial-gradient(
      circle at 50% 50%,
      color-mix(in srgb, var(--ok-sign-color, #00b2c2) 22%, transparent),
      transparent 60%
    ),
    linear-gradient(165deg, #0a2635 0%, #051a28 55%, #031420 100%);
}

.ok-flip-field::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid color-mix(in srgb, var(--ok-sign-color, #00b2c2) 58%, #ffffff);
  border-radius: 4px;
  opacity: 0.62;
  pointer-events: none;
}

.ok-flip-emblem {
  position: relative;
  width: 55%;
  aspect-ratio: 1 / 1;
  border: 1px solid color-mix(in srgb, var(--ok-sign-color, #00b2c2) 48%, #ffffff);
  border-radius: 50%;
  background: radial-gradient(circle at 50% 42%, #ffffff 0%, #eef5f7 100%);
  box-shadow:
    0 2px 10px rgba(0, 0, 0, 0.35),
    inset 0 1px 3px rgba(255, 255, 255, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
}

.ok-flip-emblem img {
  display: block;
  width: 70%;
  height: 70%;
  object-fit: contain;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .ok-email-input,
  .ok-fokus-select {
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
  }

  .ok-email-input:hover,
  .ok-art:hover {
    transform: none;
  }

  .ok-art {
    transition: box-shadow 0.18s ease;
  }

  .ok-flip {
    transition: none;
  }
}

/* Das Artwork füllt die Kartenfront; der Porzellanrand entspricht der Rückseite. */
.ok-glyph {
  position: absolute;
  inset: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: auto;
  height: auto;
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: radial-gradient(circle at 50% 40%, #ffffff 0%, #eef5f7 100%);
  box-shadow:
    inset 0 0 0 1px rgba(3, 20, 32, 0.08),
    0 1px 4px rgba(3, 20, 32, 0.08);
  font-size: 6rem;
  line-height: 1;
  color: var(--petrol, #006479);
}

.ok-glyph img {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Zweistufige Kartensignatur: feine Typografie auf einer weich auslaufenden Lesekante. */
.ok-art-name {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 38px 10px 9px;
  border: 0;
  border-radius: 0 0 8px 8px;
  background: linear-gradient(
    180deg,
    rgba(3, 20, 32, 0) 0%,
    rgba(3, 20, 32, 0.18) 42%,
    rgba(3, 20, 32, 0.7) 100%
  );
  box-shadow: none;
  color: #ffffff;
  line-height: 1.05;
  text-transform: uppercase;
  text-align: center;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.86);
  pointer-events: none;
}

.ok-art-label {
  display: block;
  margin-bottom: 2px;
  color: rgba(223, 247, 249, 0.9);
  font-size: 0.4rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  line-height: 1.2;
}

.ok-art-name [data-invite-signature] {
  display: block;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Schlanke Auffang-Zeile am Artikelende (kein zweites Formular). */
.ortskompass-sekundaer {
  grid-column: 1 / -1;
  margin: 24px auto 4px;
  max-width: 640px;
  font-size: 0.92rem;
  text-align: center;
  color: var(--text-muted, #b8b7c6);
}

.ortskompass-sekundaer a {
  color: var(--neon, #35d4e8);
  font-weight: 600;
}

/* Danke-Seite */

.ortskompass-danke-cta {
  margin-top: 26px;
  text-decoration: none;
}

/* Mobil: einspaltig, Kunstkarte NICHT ausblenden. 16.07.2026 (Daniel): Karte rueckt
   per order:-1 GANZ NACH OBEN (kompakt, zentriert), erst danach Anrede, Formular und
   Datenschutz-/Zweitweg-Text. aspect-ratio ist Pflicht, weil .ok-flip-front absolut
   positioniert ist (sonst Höhe 0). */
@media (max-width: 700px) {
  .ok-inner {
    flex-direction: column;
    align-items: stretch;
  }

  .ok-art {
    order: -1;
    align-self: center;
    flex: 0 0 auto;
    width: 156px;
    height: auto;
    aspect-ratio: 225 / 300;
    margin: 0 auto 14px;
  }

  .ok-inner:has(.ortskompass-form-panel:not([hidden])) .ok-art {
    width: 120px;
    margin-bottom: 8px;
  }
}

@media (max-width: 620px) {
  .ok-content:has(.ortskompass-form-panel:not([hidden])) > .ok-sub {
    display: none;
  }

  .ok-fields,
  .ok-action-row {
    grid-template-columns: 1fr;
  }

  .ok-action-row {
    grid-template-areas:
      "turnstile"
      "status"
      "submit";
    gap: 0;
  }

  .ok-action-row .ok-submit {
    width: 100%;
    margin-top: 8px;
  }
}

@media (max-width: 520px) {
  .ortskompass-optin {
    padding: 22px 18px 20px;
  }

  .ok-glyph {
    width: auto;
    height: auto;
    font-size: 5.2rem;
  }

  /* Feld + Button stapeln voll breit, bleiben bedienbar; das Select folgt voll breit. */
  .ok-email-input,
  .ok-email-btn {
    flex: 1 1 100%;
  }

  .ok-fokus-select {
    width: 100%;
  }

  .ok-submit {
    width: 100%;
  }
}

@media (max-width: 380px) {
  .ok-turnstile {
    min-height: 140px;
  }
}

/* V2-Personalisierung (Betreiber-Entscheid 23.07.2026): sichtbare Karten-Kennwerte
   in der Einladungskarte. Feste Farbwerte der Hellcyan-Kachel-Palette, damit die
   Zeile auch ohne site.css-Tokens auf den Karten-Seiten korrekt rendert. */
.ok-profil {
  margin: 2px 0 14px;
}

.ok-profil-label {
  display: block;
  margin: 0 0 6px;
  color: #0a7c8b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ok-profil-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ok-profil-badge {
  display: inline-block;
  padding: 4px 12px;
  border: 1px solid #cfeef2;
  border-radius: 999px;
  background: #eef9fb;
  color: #063d46;
  font-size: 13px;
  font-weight: 600;
}
