/* =========================================================
   posch Gebäudetechnik — Warteseite
   Brand: Cool Cyan ↔ Warm Red | Dark industrial
   ========================================================= */

:root {
  --cool: #00a8e8;
  --cool-deep: #0077b6;
  --cool-glow: rgba(0, 168, 232, 0.55);
  --warm: #e6392e;
  --warm-deep: #b91c1c;
  --warm-glow: rgba(230, 57, 46, 0.55);
  --ink: #070809;
  --ink-2: #0e1114;
  --ink-3: #161b20;
  --fog: #c8d0d8;
  --snow: #f4f7fa;
  --muted: rgba(200, 208, 216, 0.62);
  --line: rgba(255, 255, 255, 0.08);
  --radius: 999px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.4, 0, 0.2, 1);
  --font-display: "Outfit", system-ui, sans-serif;
  --font-body: "Manrope", system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  min-height: 100%;
}

body {
  font-family: var(--font-body);
  color: var(--snow);
  background: var(--ink);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* --- Atmosphere --- */

.concrete {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 60% 45% at 50% 24%, rgba(8, 9, 10, 0.35), rgba(5, 6, 7, 0.96) 72%),
    url("../concrete.jpg") center / 520px 520px repeat;
  opacity: 0.18;
  filter: contrast(1.05) brightness(0.35);
}

.noise {
  position: fixed;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

#field {
  position: fixed;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.aurora {
  position: fixed;
  inset: -20%;
  z-index: 0;
  pointer-events: none;
  filter: blur(90px);
  opacity: 0.7;
}

.aurora__cool,
.aurora__warm {
  position: absolute;
  width: 55vmax;
  height: 55vmax;
  border-radius: 50%;
  opacity: 0;
  transition: opacity 1.4s var(--ease-soft);
}

.aurora__cool {
  left: -10%;
  top: 10%;
  background: radial-gradient(circle, var(--cool) 0%, transparent 68%);
}

.aurora__warm {
  right: -12%;
  bottom: 5%;
  background: radial-gradient(circle, var(--warm) 0%, transparent 68%);
}

body.is-ready .aurora__cool,
body.is-ready .aurora__warm {
  opacity: 0.16;
  animation: auroraDrift 14s ease-in-out infinite alternate;
}

body.is-ready .aurora__warm {
  animation-delay: -4s;
  animation-duration: 18s;
}

@keyframes auroraDrift {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(4%, -6%) scale(1.12); }
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 75% 48% at 50% 18%, rgba(255, 255, 255, 0.035), transparent 58%),
    linear-gradient(180deg, rgba(10, 11, 12, 0.55) 0%, rgba(7, 8, 9, 0.75) 42%, #050607 100%);
  pointer-events: none;
}

/* --- Stage --- */

.stage {
  position: relative;
  z-index: 2;
  min-height: 100dvh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  align-items: center;
  justify-items: center;
  padding: clamp(1.25rem, 4vw, 3rem) clamp(1.25rem, 5vw, 4rem) 1.5rem;
  gap: clamp(1.5rem, 4vh, 3rem);
}

/* --- Boot / preload ring --- */

.boot {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-content: center;
  gap: 1.25rem;
  background: var(--ink);
  transition: opacity 0.7s var(--ease-soft), visibility 0.7s;
}

.boot.is-done {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.boot__ring {
  width: 72px;
  height: 72px;
  margin: 0 auto;
}

.boot__ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.boot__track {
  fill: none;
  stroke: rgba(255, 255, 255, 0.08);
  stroke-width: 3;
}

.boot__progress {
  fill: none;
  stroke: url(#bootGrad);
  stroke: var(--cool);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-dasharray: 289;
  stroke-dashoffset: 289;
  animation: bootFill 2.4s var(--ease-out) forwards;
  filter: drop-shadow(0 0 8px var(--cool-glow));
}

@keyframes bootFill {
  0% { stroke-dashoffset: 289; stroke: var(--cool); }
  55% { stroke: var(--cool); }
  100% { stroke-dashoffset: 0; stroke: var(--warm); filter: drop-shadow(0 0 10px var(--warm-glow)); }
}

.boot__label {
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  animation: pulseLabel 1.6s ease-in-out infinite;
}

@keyframes pulseLabel {
  0%, 100% { opacity: 0.45; }
  50% { opacity: 1; }
}

/* --- Brand / Logo --- */

.brand {
  position: relative;
  width: min(96vw, 720px);
  margin-top: clamp(0.35rem, 2vh, 1.25rem);
  z-index: 4;
  opacity: 0;
  display: grid;
  place-items: center;
}

.brand > * {
  grid-area: 1 / 1;
}

body.is-ready .brand {
  animation: brandIn 0.8s var(--ease-out) 0.2s both;
}

@keyframes brandIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Soft halo that follows the letter shapes */
.brand__glow {
  display: block;
  width: 100%;
  height: auto;
  pointer-events: none;
  user-select: none;
  z-index: 0;
  /* white silhouette of the exact logo, then blurred */
  filter:
    brightness(0)
    invert(1)
    blur(10px);
  opacity: 0.72;
  transform: scale(1.03);
}

.brand__logo {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: auto;
  border: 0;
  /* tight rim light around glyphs */
  filter:
    drop-shadow(0 0 1px rgba(255, 255, 255, 0.95))
    drop-shadow(0 0 6px rgba(255, 255, 255, 0.55))
    drop-shadow(0 0 18px rgba(255, 255, 255, 0.28));
}

/* --- Content reveal --- */

.reveal {
  width: min(100%, 640px);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1.1rem, 2.5vh, 1.75rem);
}

.eyebrow,
.headline,
.lede,
.pillars,
.hours,
.cta,
.foot {
  opacity: 0;
  transform: translateY(28px);
}

body.is-ready .eyebrow {
  animation: riseIn 0.9s var(--ease-out) 0.55s forwards;
}

body.is-ready .headline {
  animation: riseIn 1s var(--ease-out) 0.75s forwards;
}

body.is-ready .lede {
  animation: riseIn 1s var(--ease-out) 0.95s forwards;
}

body.is-ready .pillars {
  animation: riseIn 1s var(--ease-out) 1.15s forwards;
}

body.is-ready .hours {
  animation: riseIn 1s var(--ease-out) 1.25s forwards;
}

body.is-ready .cta {
  animation: riseIn 1s var(--ease-out) 1.4s forwards;
}

body.is-ready .foot {
  animation: riseIn 0.9s var(--ease-out) 1.6s forwards;
}

@keyframes riseIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--fog);
}

.eyebrow__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  animation: dotPulse 2s ease-in-out infinite;
}

.eyebrow__dot--cool {
  background: var(--cool);
  box-shadow: 0 0 12px var(--cool-glow);
}

.eyebrow__dot--warm {
  background: var(--warm);
  box-shadow: 0 0 12px var(--warm-glow);
  animation-delay: 1s;
}

@keyframes dotPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.35); opacity: 0.7; }
}

.headline {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: clamp(1.65rem, 4.2vw, 2.55rem);
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: rgba(244, 247, 250, 0.94);
  text-wrap: balance;
}

.headline__accent {
  font-weight: 700;
  color: #fff;
  background: linear-gradient(100deg, var(--cool) 0%, #7ec8e8 42%, #fff 50%, #f08a80 58%, var(--warm) 100%);
  background-size: 180% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: accentShift 8s ease-in-out infinite;
}

@keyframes accentShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.lede {
  max-width: 38rem;
  font-size: clamp(0.98rem, 2.1vw, 1.125rem);
  line-height: 1.65;
  color: var(--muted);
  font-weight: 450;
  text-wrap: pretty;
}

/* --- Pillars --- */

.pillars {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem 1.1rem;
  margin-top: 0.25rem;
}

.pillar {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.15rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  color: var(--snow);
  position: relative;
}

.pillar + .pillar::before {
  content: "";
  position: absolute;
  left: -0.7rem;
  top: 50%;
  width: 1px;
  height: 1.1em;
  background: var(--line);
  transform: translateY(-50%);
}

.pillar__icon {
  display: grid;
  place-items: center;
  width: 1.35rem;
  height: 1.35rem;
}

.pillar__icon svg {
  width: 100%;
  height: 100%;
}

.pillar--heat { color: #ff8f86; }
.pillar--heat .pillar__icon { color: var(--warm); filter: drop-shadow(0 0 8px var(--warm-glow)); }

.pillar--water { color: #7fd4f5; }
.pillar--water .pillar__icon { color: var(--cool); filter: drop-shadow(0 0 8px var(--cool-glow)); }

.pillar--air { color: var(--fog); }
.pillar--air .pillar__icon { color: var(--fog); }

@media (max-width: 520px) {
  .pillar + .pillar::before { display: none; }
  .pillars { gap: 0.35rem 1.5rem; }
}

/* --- Öffnungszeiten --- */

.hours {
  width: min(100%, 320px);
  text-align: center;
}

.hours__label {
  margin-bottom: 0.65rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(200, 208, 216, 0.5);
}

.hours__list {
  margin: 0;
  display: grid;
  gap: 0.4rem;
}

.hours__row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 1rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--line);
}

.hours__row:last-child {
  border-bottom: 0;
}

.hours__row dt {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.92rem;
  color: var(--fog);
  text-align: left;
}

.hours__row dd {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  color: var(--snow);
  font-variant-numeric: tabular-nums;
}

/* --- CTA / Kontaktformular --- */

.cta {
  width: min(100%, 560px);
  margin-top: 0.5rem;
  padding: 1.35rem 1.25rem 1.4rem;
  text-align: left;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  border-radius: 1.35rem;
  backdrop-filter: blur(14px);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.3) inset,
    0 24px 50px rgba(0, 0, 0, 0.35);
}

.cta__head {
  margin-bottom: 1.1rem;
  text-align: center;
}

.cta__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.15rem, 2.8vw, 1.4rem);
  letter-spacing: -0.02em;
  color: var(--snow);
}

.cta__sub {
  margin-top: 0.35rem;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.45;
}

.cta__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem 0.85rem;
}

.cta__field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.cta__field--full {
  grid-column: 1 / -1;
}

.cta__field label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(200, 208, 216, 0.55);
}

.cta__field input,
.cta__field select,
.cta__field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 0.85rem;
  outline: 0;
  background: rgba(0, 0, 0, 0.28);
  color: var(--snow);
  font: 500 0.95rem/1.35 var(--font-body);
  padding: 0.75rem 0.9rem;
  transition: border-color 0.25s var(--ease-soft), box-shadow 0.25s var(--ease-soft);
}

.cta__field textarea {
  resize: vertical;
  min-height: 96px;
}

.cta__field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, rgba(200, 208, 216, 0.7) 50%),
    linear-gradient(135deg, rgba(200, 208, 216, 0.7) 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 2.2rem;
  cursor: pointer;
}

.cta__field select option {
  background: #12161a;
  color: var(--snow);
}

.cta__field input::placeholder,
.cta__field textarea::placeholder {
  color: rgba(200, 208, 216, 0.4);
}

.cta__field input:focus,
.cta__field select:focus,
.cta__field textarea:focus {
  border-color: rgba(0, 168, 232, 0.5);
  box-shadow: 0 0 0 3px rgba(0, 168, 232, 0.12);
}

.cta__field.is-invalid input,
.cta__field.is-invalid select,
.cta__field.is-invalid textarea {
  border-color: rgba(230, 57, 46, 0.65);
}

.cta__check {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin: 1rem 0 1.1rem;
  font-size: 0.84rem;
  line-height: 1.4;
  color: var(--muted);
  cursor: pointer;
}

.cta__check input {
  margin-top: 0.2rem;
  width: 1rem;
  height: 1rem;
  accent-color: var(--cool);
  flex-shrink: 0;
}

.cta__btn {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  border: 0;
  border-radius: var(--radius);
  padding: 0.95rem 1.35rem;
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.02em;
  color: #fff;
  background: linear-gradient(115deg, var(--cool-deep) 0%, var(--cool) 35%, var(--warm) 70%, var(--warm-deep) 100%);
  background-size: 200% 100%;
  background-position: 0% 50%;
  box-shadow:
    0 0 24px rgba(0, 168, 232, 0.25),
    0 8px 24px rgba(230, 57, 46, 0.2);
  transition:
    transform 0.35s var(--ease-out),
    background-position 0.55s var(--ease-soft),
    box-shadow 0.35s var(--ease-soft);
}

.cta__btn:hover {
  background-position: 100% 50%;
  transform: translateY(-1px);
  box-shadow:
    0 0 32px rgba(230, 57, 46, 0.35),
    0 10px 28px rgba(0, 168, 232, 0.25);
}

.cta__btn:active {
  transform: translateY(0) scale(0.98);
}

.cta__btn-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
  transform: translateX(-120%);
  animation: shineSweep 4.5s ease-in-out infinite;
  pointer-events: none;
}

@keyframes shineSweep {
  0%, 60% { transform: translateX(-120%); }
  80%, 100% { transform: translateX(120%); }
}

.cta__hint {
  margin-top: 0.75rem;
  text-align: center;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: rgba(200, 208, 216, 0.42);
}

.cta__success,
.cta__error {
  margin-top: 0.85rem;
  text-align: center;
  font-size: 0.92rem;
  font-weight: 600;
  animation: riseIn 0.6s var(--ease-out) forwards;
}

.cta__success {
  color: var(--cool);
  text-shadow: 0 0 20px var(--cool-glow);
}

.cta__error {
  color: #ff8f86;
}

.cta.is-sent .cta__grid,
.cta.is-sent .cta__check,
.cta.is-sent .cta__btn,
.cta.is-sent .cta__hint {
  opacity: 0.35;
  pointer-events: none;
}

@media (max-width: 560px) {
  .cta {
    padding: 1.15rem 1rem 1.25rem;
    border-radius: 1.15rem;
  }

  .cta__grid {
    grid-template-columns: 1fr;
  }
}

/* --- Footer --- */

.foot {
  width: min(100%, 640px);
  text-align: center;
  padding-bottom: 0.5rem;
}

.foot__line {
  display: block;
  width: 100%;
  height: 1px;
  margin: 0 auto 1rem;
  background: linear-gradient(90deg, transparent, var(--cool), var(--warm), transparent);
  opacity: 0.45;
}

.foot p {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(200, 208, 216, 0.38);
}

.foot__hours {
  margin-top: 0.45rem;
  letter-spacing: 0.08em !important;
  text-transform: none !important;
  color: rgba(200, 208, 216, 0.32) !important;
}

/* --- Reduced motion --- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .brand,
  .eyebrow,
  .headline,
  .lede,
  .pillars,
  .hours,
  .cta,
  .foot {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }

  .boot { display: none; }
}
