/* ==========================================================================
   PikaSSH website — styles.css
   Single hand-written stylesheet. All assets self-hosted. No external requests.
   ========================================================================== */

/* ---------- Self-hosted fonts (OFL) ---------- */
@font-face {
  font-family: "Sora";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("assets/fonts/sora-600.woff2") format("woff2");
}
@font-face {
  font-family: "Sora";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("assets/fonts/sora-700.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("assets/fonts/jetbrains-mono-500.woff2") format("woff2");
}

/* ---------- Design tokens ---------- */
:root {
  /* palette (from the app) */
  --gold: #ffd93d;
  --gold-dim: #e5c236;
  --gold-soft: #fff1a8;
  --navy: #0f172a;
  --navy-deep: #0b1220;
  --slate: #1e293b;
  --slate-2: #18233a;
  --text: #f1f5f9;
  --muted: #94a3b8;
  --line: rgba(148, 163, 184, 0.14);
  --success: #34d399;

  /* type */
  --font-display: "Sora", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* layout */
  --maxw: 1080px;
  --radius: 16px;
  --radius-sm: 10px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; }

body {
  font-family: var(--font-body);
  color: var(--text);
  line-height: 1.65;
  background-color: var(--navy-deep);
  /* atmospheric depth — pure CSS gradients, no image requests */
  background-image:
    radial-gradient(1200px 600px at 50% -10%, rgba(255, 217, 61, 0.10), transparent 60%),
    radial-gradient(900px 500px at 85% 8%, rgba(52, 211, 153, 0.06), transparent 55%),
    linear-gradient(180deg, #0b1220 0%, #0c1426 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ---------- Typography ---------- */
h1, h2, h3 { font-family: var(--font-display); font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; overflow-wrap: break-word; hyphens: auto; }
h1 { font-size: clamp(2.4rem, 5vw + 1rem, 4rem); }
h2 { font-size: clamp(1.7rem, 2.5vw + 1rem, 2.5rem); }
h3 { font-size: 1.15rem; font-weight: 600; letter-spacing: -0.01em; }
p { color: var(--muted); }

/* eyebrow / mono accent label */
.eyebrow {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
}
.mono { font-family: var(--font-mono); }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 24px; }
section { padding-block: clamp(56px, 9vw, 104px); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.55em;
  font-family: var(--font-display); font-weight: 600; font-size: 1rem;
  padding: 0.85em 1.4em; border-radius: 999px; border: 1px solid transparent;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}
.btn-primary {
  background: var(--gold); color: #1a1505;
  box-shadow: 0 10px 30px -8px rgba(255, 217, 61, 0.5);
}
.btn-primary:hover { background: var(--gold-soft); transform: translateY(-2px); box-shadow: 0 16px 40px -10px rgba(255, 217, 61, 0.6); }
.btn-secondary { background: transparent; color: var(--text); border-color: var(--line); }
.btn-secondary:hover { border-color: var(--gold); color: var(--gold); transform: translateY(-2px); }

/* ---------- Accessibility ---------- */
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 4px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* ==========================================================================
   Landing page
   ========================================================================== */

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(12px);
  background: rgba(11, 18, 32, 0.72);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; gap: 24px; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-display); font-weight: 700; }
.brand-mark { border-radius: 8px; }
.brand-name { font-size: 1.1rem; letter-spacing: -0.01em; }
.nav-links { margin-left: auto; display: flex; gap: 26px; }
.nav-links a { color: var(--muted); text-decoration: none; font-size: 0.95rem; transition: color 0.18s ease; }
.nav-links a:hover { color: var(--gold); }
.btn-sm { padding: 0.55em 1.1em; font-size: 0.9rem; }
.btn-lg { padding: 1em 1.7em; font-size: 1.1rem; }

/* ---------- Hero ---------- */
.hero { padding-top: clamp(48px, 8vw, 88px); padding-bottom: 0; text-align: center; }
.hero-inner { display: flex; flex-direction: column; align-items: center; }
.hero h1 { margin-top: 18px; max-width: 16ch; }
.hero h1 .accent { color: var(--gold); }
.hero-tag { margin-top: 22px; font-size: clamp(1.05rem, 1.2vw + 0.8rem, 1.35rem); max-width: 46ch; color: var(--muted); }
.hero-tag strong { color: var(--text); font-weight: 600; }
.hero-cta { margin-top: 34px; display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.hero-meta { margin-top: 18px; font-size: 0.82rem; color: var(--muted); letter-spacing: 0.04em; }

.hero-shot { margin-top: clamp(44px, 6vw, 72px); position: relative; width: 100%; max-width: 980px; }
.hero-shot::before {
  content: ""; position: absolute; inset: -8% -4% 12%;
  background: radial-gradient(60% 50% at 50% 0%, rgba(255, 217, 61, 0.22), transparent 70%);
  filter: blur(20px); z-index: -1;
}
.hero-shot img {
  width: 100%; border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.02) inset;
}

/* ---------- Section titles ---------- */
.section-title { margin-top: 12px; margin-bottom: 14px; max-width: 22ch; }
.accent { color: var(--gold); }

/* ---------- Features ---------- */
.feature-grid { margin-top: 40px; display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card {
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.55), rgba(24, 35, 58, 0.35));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 24px; transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}
.card:hover { transform: translateY(-4px); border-color: rgba(255, 217, 61, 0.4); }
.card-ic { display: inline-flex; padding: 10px; border-radius: 12px; color: var(--gold); background: rgba(255, 217, 61, 0.1); border: 1px solid rgba(255, 217, 61, 0.2); }
.card-ic svg { width: 22px; height: 22px; }
.card h3 { margin-top: 16px; color: var(--text); }
.card p { margin-top: 8px; font-size: 0.95rem; }
.card .mono { color: var(--gold-soft); font-size: 0.85em; }

/* ---------- Privacy ---------- */
.privacy-inner {
  display: grid; gap: 40px; grid-template-columns: 1fr 1fr; align-items: center;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.5), rgba(11, 18, 32, 0.2));
  border: 1px solid var(--line); border-radius: 24px; padding: clamp(28px, 4vw, 52px);
}
.privacy-lead { margin-top: 16px; font-size: 1.05rem; }
.privacy-points { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 20px; }
.privacy-points li { display: flex; gap: 14px; align-items: flex-start; }
.privacy-points strong { color: var(--text); }
.privacy-points div { color: var(--muted); }
.tick { flex: none; width: 24px; height: 24px; border-radius: 999px; margin-top: 2px; background: rgba(52, 211, 153, 0.14); position: relative; }
.tick::after { content: ""; position: absolute; left: 8px; top: 5px; width: 6px; height: 11px; border: solid var(--success); border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* ---------- Download ---------- */
.download { text-align: center; }
.download-inner { display: flex; flex-direction: column; align-items: center; }
.download .btn { margin-top: 10px; }
.download-req { margin-top: 18px; color: var(--muted); font-size: 0.85rem; letter-spacing: 0.04em; }
.download-note { margin-top: 18px; max-width: 56ch; font-size: 0.95rem; color: var(--muted); }
.download-note .mono { color: var(--gold-soft); }

/* ---------- FAQ ---------- */
.faq-list { margin-top: 36px; max-width: 760px; }
.faq details { border-bottom: 1px solid var(--line); padding: 6px 0; }
.faq summary {
  cursor: pointer; list-style: none; padding: 16px 40px 16px 0; position: relative;
  font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; color: var(--text);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  font-family: var(--font-mono); font-size: 1.4rem; color: var(--gold); transition: transform 0.2s ease;
}
.faq details[open] summary::after { content: "−"; }
.faq details p { padding: 0 0 18px; color: var(--muted); max-width: 64ch; }
.faq .mono { color: var(--gold-soft); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: 36px; margin-top: 40px; }
.footer-inner { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.footer-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 600; }
.footer-links { margin-left: auto; display: flex; gap: 24px; }
.footer-links a { color: var(--muted); text-decoration: none; transition: color 0.18s ease; }
.footer-links a:hover { color: var(--gold); }
.footer-copy { color: var(--muted); font-size: 0.9rem; }

/* ---------- Entrance animation (page-load stagger) ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.reveal { opacity: 0; animation: rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.d0 { animation-delay: 0.02s; } .d1 { animation-delay: 0.10s; } .d2 { animation-delay: 0.18s; }
.d3 { animation-delay: 0.26s; } .d4 { animation-delay: 0.34s; } .d5 { animation-delay: 0.44s; }

/* ==========================================================================
   Legal pages (Impressum, Datenschutz)
   ========================================================================== */
.legal { max-width: 760px; padding-top: clamp(40px, 6vw, 72px); padding-bottom: 80px; }
.legal h1 { margin-top: 10px; margin-bottom: 28px; }
.legal h2 { font-size: 1.25rem; margin-top: 36px; margin-bottom: 10px; color: var(--text); }
.legal p { color: var(--muted); margin-bottom: 12px; }
.legal ul { color: var(--muted); margin: 0 0 16px; padding-left: 22px; }
.legal li { margin-bottom: 6px; }
.legal a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }
.legal a:hover { color: var(--gold-soft); }
.legal code { font-family: var(--font-mono); font-size: 0.85em; color: var(--gold-soft); background: rgba(255, 217, 61, 0.08); padding: 1px 6px; border-radius: 6px; }
.legal-note { border: 1px dashed rgba(255, 217, 61, 0.35); background: rgba(255, 217, 61, 0.05); border-radius: var(--radius-sm); padding: 12px 16px; color: var(--muted); font-size: 0.92rem; }
.legal-meta { margin-top: 32px; font-size: 0.85rem; color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 760px) {
  /* Header: brand + download on row 1, nav links centered on row 2 */
  .nav { flex-wrap: wrap; row-gap: 12px; column-gap: 12px; padding-block: 12px; }
  .header-cta { margin-left: auto; }
  .nav-links {
    order: 3; flex-basis: 100%; margin-left: 0;
    justify-content: center; gap: 22px;
    padding-top: 12px; border-top: 1px solid var(--line);
  }

  /* Hero: let the headline use full width and scale fluidly with the viewport
     so "Your SSH connections," stays on one line instead of wrapping.
     hyphens:none so it never breaks mid-word. */
  .hero h1 { max-width: 100%; font-size: clamp(1.4rem, 6.2vw, 2.2rem); hyphens: none; white-space: nowrap; }
  .hero h1 .accent { white-space: nowrap; }
  .hero-tag { font-size: 1.05rem; }
  .hero-cta { flex-direction: column; align-items: stretch; width: 100%; max-width: 360px; gap: 12px; }
  .hero-cta .btn { width: 100%; justify-content: center; }

  /* Section titles shouldn't be boxed narrow on mobile */
  .section-title { max-width: 100%; }

  /* Long German compound headings (e.g. Datenschutzerklärung) need a smaller
     size on phones so the hyphenated first line can't force horizontal scroll */
  .legal h1 { font-size: 1.9rem; }

  /* Consistent, full-width download CTA — drop the oversized btn-lg sizing so
     it matches the hero buttons and the label stays on one line. */
  .download .btn { width: 100%; max-width: 360px; justify-content: center; }
  .btn-lg { font-size: 1rem; padding: 0.85em 1.4em; }

  .privacy-inner { grid-template-columns: 1fr; gap: 26px; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 14px; }
  .footer-links { margin-left: 0; flex-wrap: wrap; }
}

