/* ============================================================
   txts.chat – Apple-Stil: hell, ruhig, große Typografie.
   Nur Light-Mode. Dunkel ist ausschließlich der Hero (Video).
   ============================================================ */

:root {
  --bg: #ffffff;            /* Grundfläche */
  --bg-alt: #f5f5f7;        /* alternierende Sektionen (Apple-Grau) */
  --ink: #1d1d1f;           /* Text */
  --ink-2: #6e6e73;         /* Sekundärtext */
  --hairline: #d2d2d7;      /* feine Linien */
  --card: #ffffff;
  --blue: #0071e3;          /* CTA/Links (Apple-Blau, passt zum Schloss-Ring) */
  --blue-hover: #0077ed;
  --green: #1E6B47;         /* Markengrün: sparsam, z. B. Häkchen */
  --danger: #de4437;
  --radius: 18px;
  --radius-lg: 28px;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.10);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', sans-serif;
  --mono: 'JetBrains Mono', 'SF Mono', ui-monospace, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.5;
  letter-spacing: -0.012em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.mono { font-family: var(--mono); }

h1, h2, h3 { font-weight: 600; letter-spacing: -0.025em; line-height: 1.08; }

/* ============================================================
   Navigation – dunkel-frostig wie die globale Apple-Nav
   ============================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(22, 22, 23, 0.8);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
}
.nav-inner {
  max-width: 1024px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px 22px;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  color: #f5f5f7;
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.nav-logo img { border-radius: 8px; width: 26px; height: 26px; }
.nav-links {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-links a {
  text-decoration: none;
  color: rgba(245, 245, 247, 0.8);
  font-weight: 500;
  font-size: 0.82rem;
  letter-spacing: -0.01em;
  padding: 7px 13px;
  border-radius: 99px;
  transition: color 0.2s;
}
.nav-links a:hover { color: #fff; }
.nav-links a.nav-cta {
  background: var(--blue);
  color: #fff;
  font-weight: 500;
}
.nav-links a.nav-cta:hover { background: var(--blue-hover); }

/* Sprachumschalter (DE/EN) – segmentiertes Control in der dunklen Nav */
.lang-toggle {
  display: inline-flex;
  gap: 2px;
  padding: 2px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.1);
}
.lang-toggle button {
  border: 0;
  background: transparent;
  color: rgba(245, 245, 247, 0.7);
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  padding: 5px 10px;
  border-radius: 99px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.lang-toggle button:hover { color: #fff; }
.lang-toggle button.active { background: #f5f5f7; color: #000; }

/* ============================================================
   Hero: Scroll-Schloss auf Schwarz
   ============================================================ */
.hero {
  position: relative;
  height: 340vh;
  background: #000;
}
.hero-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
}
#lockScrub {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
.hero-phase {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0 24px;
  z-index: 2;
  pointer-events: none;
  will-change: opacity, transform;
}
.hero-phase-1 { justify-content: flex-start; padding-top: max(13vh, 92px); }
.hero-phase-1 h1 {
  color: #f5f5f7;
  font-size: clamp(2.4rem, 5.6vw, 4.4rem);
  font-weight: 700;
}
.hero-phase-1 .hero-sub {
  color: #a1a1a6;
  margin-top: 18px;
  font-size: clamp(1rem, 1.9vw, 1.3rem);
  font-weight: 500;
}
.hero-scrollhint {
  position: absolute;
  bottom: 4.5vh;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: #86868b;
  font-size: 0.8rem;
  font-weight: 500;
  animation: hintBob 2.4s ease-in-out infinite;
}
@keyframes hintBob {
  0%, 100% { transform: translate(-50%, 0); }
  50%      { transform: translate(-50%, 7px); }
}
.hero-phase-2 { justify-content: flex-end; padding-bottom: 10vh; opacity: 0; }
.hero-phase-2 h2 {
  color: #f5f5f7;
  font-size: clamp(1.9rem, 4.2vw, 3.2rem);
  font-weight: 700;
}
.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 28px;
  pointer-events: auto;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 13px 26px;
  border-radius: 99px;
  font-weight: 500;
  font-size: 1rem;
  font-family: var(--font);
  text-decoration: none;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.2s;
}
.btn-hero { background: var(--blue); color: #fff; }
.btn-hero:hover { background: var(--blue-hover); }
.btn-hero-ghost { border: 1px solid #6e6e73; color: #f5f5f7; }
.btn-hero-ghost:hover { border-color: #f5f5f7; }
.btn-ghost { border: 1px solid var(--hairline); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero { height: 100vh; }
  .hero-phase-2, .hero-scrollhint { display: none; }
  .reveal { opacity: 1 !important; transform: none !important; }
}

/* ============================================================
   Sektionen
   ============================================================ */
.section { padding: 120px 24px; }
.section-alt { background: var(--bg-alt); }
.section-inner { max-width: 1024px; margin: 0 auto; }

.section-tag {
  display: block;
  color: var(--ink-2);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 14px;
  text-align: center;
}
.section h2 {
  font-size: clamp(2rem, 4.4vw, 3.2rem);
  text-align: center;
  margin-bottom: 18px;
}
.section-sub {
  max-width: 640px;
  margin: 0 auto 64px;
  text-align: center;
  color: var(--ink-2);
  font-size: clamp(1.05rem, 1.8vw, 1.3rem);
  font-weight: 400;
}

/* Scroll-Reveal */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: none; }
.delay-1 { transition-delay: 0.08s; }
.delay-2 { transition-delay: 0.16s; }
.delay-3 { transition-delay: 0.24s; }

/* ============================================================
   Live-Demo
   ============================================================ */
.demo-stage {
  display: grid;
  grid-template-columns: 1fr auto 1.1fr auto 1fr;
  align-items: center;
  gap: 14px;
  background: var(--bg-alt);
  border-radius: var(--radius-lg);
  padding: 44px 32px;
}
.section-alt .demo-stage { background: var(--card); box-shadow: var(--shadow); }

.demo-device { min-width: 0; }
.device-label {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 12px;
}
.device-label.center { justify-content: center; }
.device-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  display: grid;
  place-items: center;
}
.device-avatar.bob { background: var(--green); }
.device-screen {
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  padding: 18px;
  min-height: 130px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: center;
}
.section .demo-stage .device-screen { background: #fff; }

.chat-bubble {
  max-width: 100%;
  padding: 10px 15px;
  border-radius: 17px;
  font-size: 0.92rem;
  line-height: 1.4;
  width: fit-content;
  word-break: break-word;
  transition: opacity 0.4s, transform 0.4s;
}
.chat-sent { background: var(--blue); color: #fff; border-bottom-right-radius: 5px; align-self: flex-end; }
.chat-received { background: #e9e9eb; color: var(--ink); border-bottom-left-radius: 5px; align-self: flex-start; }
.hidden-bubble { opacity: 0; transform: scale(0.85); }

.caret {
  display: inline-block;
  width: 2px; height: 1em;
  background: #fff;
  margin-left: 2px;
  vertical-align: text-bottom;
  animation: blink 0.9s steps(2) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.device-status {
  font-size: 0.8rem;
  color: var(--ink-2);
  font-weight: 500;
  min-height: 1.2em;
}

.demo-path {
  position: relative;
  width: 130px;
  height: 60px;
  display: flex;
  align-items: center;
}
.path-line {
  width: 100%;
  height: 2px;
  background: repeating-linear-gradient(90deg, var(--hairline) 0 9px, transparent 9px 18px);
}
.packet {
  position: absolute;
  width: 46px; height: 46px;
  transform: scale(0);
  pointer-events: none;
}
.packet-emoji {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  font-size: 1.7rem;
  line-height: 1;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.25));
}
.path-caption {
  position: absolute;
  top: calc(50% + 14px);
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.72rem;
  color: var(--ink-2);
  font-weight: 500;
  text-align: center;
  white-space: nowrap;
  line-height: 1.35;
}

.demo-server {
  background: #0d0d0f;
  border-radius: var(--radius);
  padding: 22px 20px;
  text-align: center;
  color: #f5f5f7;
  position: relative;
  transition: box-shadow 0.4s;
}
.demo-server .device-label { color: #f5f5f7; }
.demo-server.active { box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.45); }
.server-icon { color: #86868b; margin-bottom: 6px; }
.server-sees { margin-top: 8px; }
.server-sees-label { font-size: 0.75rem; color: #86868b; font-weight: 500; margin-bottom: 5px; }
.server-sees code {
  display: block;
  font-size: 0.72rem;
  color: #64d2ff;
  word-break: break-all;
  min-height: 2.1em;
  line-height: 1.5;
}
.server-blind-badge {
  position: absolute;
  top: -11px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #1d1d1f;
  border: 1px solid #3a3a3c;
  color: #f5f5f7;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 4px 11px;
  border-radius: 99px;
}

.demo-footnote {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-top: 28px;
  color: var(--ink-2);
  font-size: 0.9rem;
  font-weight: 500;
}

/* ============================================================
   Architektur
   ============================================================ */
.arch-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
  margin-bottom: 70px;
}
.arch-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 30px 26px;
  transition: transform 0.25s, box-shadow 0.25s;
}
.section:not(.section-alt) .arch-card { background: var(--bg-alt); }
.arch-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.arch-num {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--blue);
  letter-spacing: 0.06em;
  display: block;
  margin-bottom: 12px;
}
.arch-icon {
  width: 48px; height: 48px;
  border-radius: 13px;
  background: #e8f0fe;
  color: var(--blue);
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}
.arch-card h3 { font-size: 1.15rem; margin-bottom: 8px; }
.arch-card p { color: var(--ink-2); font-size: 0.92rem; line-height: 1.55; }

/* Ablauf Alice -> Bob */
.flow {
  background: var(--card);
  border-radius: var(--radius-lg);
  padding: 40px 38px;
  box-shadow: var(--shadow);
}
.flow-title { font-size: 1.25rem; margin-bottom: 26px; text-align: center; }
.flow-steps { display: flex; flex-direction: column; gap: 0; counter-reset: step; }
.flow-step {
  display: flex;
  gap: 16px;
  padding: 15px 0;
  align-items: baseline;
}
.flow-step + .flow-step { border-top: 1px solid var(--bg-alt); }
.flow-dot {
  flex-shrink: 0;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  display: grid;
  place-items: center;
  transform: translateY(4px);
}
.flow-step div:last-child { color: var(--ink-2); font-size: 0.95rem; }
.flow-step strong { color: var(--ink); font-weight: 600; }

/* ============================================================
   Sicherheit
   ============================================================ */
.sec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 18px;
  margin-bottom: 70px;
}
.sec-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 30px 26px;
  box-shadow: var(--shadow);
}
.sec-card h3 { font-size: 1.15rem; margin-bottom: 10px; }
.sec-card p { color: var(--ink-2); font-size: 0.92rem; line-height: 1.55; }
.sec-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.chip {
  font-family: var(--mono);
  font-size: 0.72rem;
  background: var(--bg-alt);
  color: var(--ink-2);
  padding: 5px 11px;
  border-radius: 99px;
  font-weight: 500;
}

.table-title { font-size: 1.25rem; text-align: center; margin-bottom: 22px; }
.sec-table-wrap, .compare-table-wrap {
  overflow-x: auto;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.sec-table, .compare-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.93rem;
}
.sec-table th, .compare-table th {
  text-align: left;
  font-size: 0.75rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-2);
  font-weight: 600;
  padding: 16px 22px;
  border-bottom: 1px solid var(--bg-alt);
}
.sec-table td, .compare-table td {
  padding: 14px 22px;
  border-bottom: 1px solid var(--bg-alt);
  color: var(--ink-2);
}
.sec-table tr:last-child td, .compare-table tr:last-child td { border-bottom: none; }
.sec-table td:first-child, .compare-table td:first-child { color: var(--ink); font-weight: 500; }
.mark { font-weight: 600; }
.mark.no  { color: var(--green); }
.mark.yes { color: var(--ink-2); }

.honesty {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  max-width: 760px;
  margin: 56px auto 0;
  background: var(--card);
  border-radius: var(--radius);
  padding: 22px 26px;
  box-shadow: var(--shadow);
  color: var(--ink-2);
  font-size: 0.92rem;
  line-height: 1.55;
}
.honesty-icon { flex-shrink: 0; color: var(--blue); transform: translateY(2px); }
.honesty strong { color: var(--ink); font-weight: 600; }

/* ============================================================
   Features
   ============================================================ */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
  margin-bottom: 70px;
}
.feature-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 30px 26px;
  transition: transform 0.25s, box-shadow 0.25s;
}
.section-alt .feature-card { box-shadow: var(--shadow); }
.section:not(.section-alt) .feature-card { background: var(--bg-alt); }
.feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.feature-icon {
  width: 48px; height: 48px;
  border-radius: 13px;
  background: #e8f0fe;
  color: var(--blue);
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}
.feature-card h3 { font-size: 1.1rem; margin-bottom: 8px; }
.feature-card p { color: var(--ink-2); font-size: 0.92rem; line-height: 1.55; }

.highlight-col { background: rgba(0, 113, 227, 0.05); }

/* ============================================================
   Download
   ============================================================ */
.download-section { background: var(--bg-alt); }
.download-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
  margin-bottom: 36px;
}
.dl-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 40px 28px 34px;
  text-align: center;
  transition: transform 0.25s, box-shadow 0.25s;
}
.dl-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.dl-card.available { box-shadow: 0 0 0 2px var(--blue), var(--shadow); }
.dl-icon {
  width: 64px; height: 64px;
  border-radius: 18px;
  background: var(--bg-alt);
  color: var(--ink);
  display: grid;
  place-items: center;
  margin: 0 auto 18px;
}
.dl-card.available .dl-icon { background: #e8f0fe; color: var(--blue); }
.dl-card h3 { font-size: 1.25rem; margin-bottom: 6px; }
.dl-card p { color: var(--ink-2); font-size: 0.9rem; font-weight: 400; margin-bottom: 20px; }
.dl-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-alt);
  color: var(--ink-2);
  font-weight: 500;
  font-size: 0.85rem;
  padding: 9px 20px;
  border-radius: 99px;
}
.pulse-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--blue);
  animation: pulse 2.2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0, 113, 227, 0.4); }
  50%      { box-shadow: 0 0 0 7px transparent; }
}
.dl-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--blue);
  color: #fff;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 12px 26px;
  border-radius: 99px;
  text-decoration: none;
  transition: background 0.2s;
}
.dl-btn:hover { background: var(--blue-hover); }
.dl-meta { display: block; margin-top: 12px; font-size: 0.78rem; color: var(--ink-2); font-weight: 400; }
.dl-note {
  max-width: 620px;
  margin: 0 auto 26px;
  padding: 18px 22px;
  background: var(--card);
  border-radius: var(--radius);
  font-size: 0.86rem;
  line-height: 1.55;
  color: var(--ink-2);
}
.dl-note strong { color: var(--ink); font-weight: 600; }
.notify { text-align: center; color: var(--ink-2); font-size: 0.92rem; }

/* ============================================================
   Footer
   ============================================================ */
.footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--hairline);
  padding: 44px 24px 36px;
  text-align: center;
}
.footer-inner { max-width: 1024px; margin: 0 auto; }
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 8px;
}
.footer-brand img { border-radius: 7px; width: 24px; height: 24px; }
.footer-tag { color: var(--ink-2); font-size: 0.85rem; margin-bottom: 18px; }
.footer-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 4px 22px;
  margin-bottom: 18px;
}
.footer-links a {
  color: var(--ink-2);
  text-decoration: none;
  font-size: 0.82rem;
}
.footer-links a:hover { color: var(--ink); text-decoration: underline; }
.footer-note { color: #86868b; font-size: 0.75rem; }

/* ============================================================
   Unterseiten (Datenschutz, Support)
   ============================================================ */
.subpage { max-width: 720px; margin: 0 auto; padding: 130px 24px 90px; }
.subpage h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); margin-bottom: 10px; }
.subpage-updated { color: var(--ink-2); font-size: 0.85rem; margin-bottom: 34px; }
.subpage-intro { color: var(--ink-2); font-size: 1.05rem; margin-bottom: 30px; }
.subpage-card {
  background: var(--bg-alt);
  border-radius: var(--radius);
  padding: 26px 28px;
  margin-bottom: 18px;
}
.subpage-card h2 { font-size: 1.15rem; margin-bottom: 10px; text-align: left; }
.subpage-card p, .subpage-card li { color: var(--ink-2); font-size: 0.94rem; line-height: 1.6; }
.subpage-card ul { padding-left: 20px; margin-top: 8px; }
.subpage-mail {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--blue);
  font-weight: 500;
  text-decoration: none;
}
.subpage-mail:hover { text-decoration: underline; }
.subpage-back { margin-top: 34px; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
  .section { padding: 90px 20px; }
  .demo-stage {
    grid-template-columns: 1fr;
    gap: 26px;
    padding: 30px 22px;
  }
  .demo-path {
    width: 100%;
    height: 54px;
    justify-content: center;
  }
  .path-line {
    width: 2px;
    height: 100%;
    background: repeating-linear-gradient(180deg, var(--hairline) 0 9px, transparent 9px 18px);
  }
  .path-caption {
    top: 50%;
    left: calc(50% + 32px);
    transform: translateY(-50%);
    text-align: left;
  }
  .demo-server { max-width: 340px; margin: 0 auto; width: 100%; }
}

@media (max-width: 640px) {
  .nav-links a:not(.nav-cta) { display: none; }
  .flow { padding: 26px 20px; }
  .packet { width: 40px; height: 40px; }
}
