/* hifaaz – Website. Aufbau nach der Vorlage boringdice.app, Farben und
   Schrift wie in der App. Breakpoints: 521 px, 691 px, 1080 px.
   Arabisch und Kurdisch (dir="rtl") nutzen logische Eigenschaften
   (inline-start/-end), damit sich alles von selbst spiegelt. */

@import url('fonts/fonts.css');

:root {
  /* Auf iPhone, iPad und Mac: SF Pro Rounded (Systemschrift wie in der App),
     sonst Nunito (selbst gehostet). */
  --primary-font: ui-rounded, 'SF Pro Rounded', 'Nunito', system-ui, -apple-system, sans-serif;
  --secondary-font: var(--primary-font);
  --bg: #ffffff;
  --bg-top: #f4f5f7;
  --text: #6b6b73;
  --heading: #141414;
  --accent: #12806a;
  --accent-dot: #1a9e7a;
  --muted: #6b6b73;
  --faq-question: #2a2a30;
  --card: #f4f5f7;
  --dashed: #d9dce1;
  --hover: #e9ebef;
  --menu: #ffffff;
  --icon-bg: #ddf0e9;
}

*, *::before, *::after { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  font-family: var(--primary-font);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg) linear-gradient(var(--bg-top) 0%, var(--bg) 100vh) no-repeat;
  font-kerning: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-size-adjust: 100%;
}

h1, h2, h3, p, ul, li, figure { margin: 0; padding: 0; }
ul { list-style: none; }
img { max-width: 100%; }
a { color: var(--accent); text-decoration: none; }

h1, h2, h3 {
  font-family: var(--secondary-font);
  text-wrap: balance;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -.3px;
  color: var(--heading);
}
h1 { font-size: 40px; }
h2 { font-size: 32px; }
h3 { font-size: 18px; }

.container { width: 100%; margin: 0 auto; padding: 0 20px; }
.container-small { max-width: 560px; }
.container-medium { max-width: 760px; }
.container-large { max-width: 1080px; }

/* Überschrift mit Unterzeile */
.title { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 100%; text-align: center; font-size: 18px; }
.title-large { margin-bottom: 40px; }
.title .post { max-width: 280px; margin-top: 8px; font-size: 18px; font-weight: 600; line-height: 1.4; color: var(--text); }

/* ---------- Navigation ---------- */
.nav { width: 100%; }
.nav-grid {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  grid-template-rows: 64px;
  align-items: center;
  width: 100%;
}
.logo { display: inline-flex; align-items: center; gap: 10px; font-family: var(--secondary-font); font-size: 20px; font-weight: 800; letter-spacing: -.4px; color: var(--heading); transition: opacity .2s ease-out; }
.logo svg { display: block; width: auto; height: 24px; }
.logo:hover { opacity: .7; }
.menu { display: flex; justify-content: flex-end; }
.menu-home { display: none; }
.menu ul { display: flex; flex-direction: row; }
.menu li { margin: 0 12px; }
.menu a { font-family: var(--secondary-font); color: var(--text); }
.menu a.active, .menu a:hover { color: var(--accent); }
.nav-end { display: flex; justify-content: flex-end; align-items: center; gap: 4px; }
.social { display: none; }
.social ul { display: flex; flex-direction: row; justify-content: center; align-items: center; }
.social li { padding: 4px; }
.social a { display: block; width: 40px; height: 40px; padding: 4px; }
.social svg { display: block; width: 32px; height: 32px; padding: 4px; color: var(--heading); transition: color .2s; }
.social a:hover svg { color: var(--accent); }

/* Sprachauswahl (details/summary – funktioniert auch ohne JavaScript) */
.lang { position: relative; }
.lang summary { display: flex; align-items: center; gap: 6px; height: 40px; padding: 0 10px; list-style: none; font-size: 15px; font-weight: 700; color: var(--heading); border-radius: 20px; cursor: pointer; user-select: none; transition: background .2s; }
.lang summary::-webkit-details-marker { display: none; }
.lang summary:hover, .lang[open] summary { background: var(--hover); }
.lang summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.lang .flag { display: block; flex: none; width: 22px; height: 16px; object-fit: cover; border-radius: 4px; box-shadow: 0 0 0 1px rgba(20, 20, 30, .08); }
.lang .chev { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; transition: transform .2s; }
.lang[open] .chev { transform: rotate(180deg); }
.lang-menu { position: absolute; top: calc(100% + 6px); inset-inline-end: 0; z-index: 10; min-width: 210px; padding: 6px; background: var(--menu); border-radius: 18px; box-shadow: 0 12px 32px rgba(20, 20, 30, .12), 0 0 0 1px rgba(20, 20, 30, .06); }
.lang-menu a { display: flex; align-items: center; gap: 12px; padding: 9px 12px; font-weight: 600; color: var(--heading); border-radius: 12px; }
.lang-menu a:hover { background: var(--card); }
.lang-menu a[aria-current] { color: var(--accent); }
.lang-menu .check { width: 16px; height: 16px; margin-inline-start: auto; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Kopfbereich ---------- */
.header { display: flex; padding: 80px 0; }
.header .container { display: flex; flex-direction: column; align-items: center; justify-content: center; }
.header .title { max-width: 480px; margin-bottom: 40px; padding: 0 20px; }
.header h1 { font-size: 28px; line-height: 1.2; color: var(--accent); }
.header .post { max-width: 440px; text-wrap: balance; font-size: 20px; font-weight: 600; line-height: 1.4; letter-spacing: -.2px; }

/* App Store (QR-Code + Abzeichen) und Google Play (bald) nebeneinander */
.stores { display: flex; justify-content: center; align-items: flex-start; gap: 20px; }
.store { display: flex; flex-direction: column; align-items: center; min-width: 160px; }
.store .qr { display: block; width: 144px; max-width: 100%; aspect-ratio: 1; margin-bottom: 6px; padding: 6px; background: #000; border-radius: 16px; }
.store .qr img { display: block; width: 100%; height: 100%; }
.store .badge { margin-bottom: 6px; }
.store .badge img { display: block; width: auto; height: 48px; }
.store .requires { font-size: 14px; line-height: 1.4; text-align: center; }
.store .qr.soon { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 8px; padding: 12px; font-size: 14px; font-weight: 700; line-height: 1.3; text-align: center; color: var(--muted); background: transparent; border: 2px dashed var(--dashed); }
.store .qr.soon svg { width: 28px; height: 28px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.store .badge.soon { display: flex; justify-content: center; align-items: center; height: 48px; padding: 0 22px; font-size: 18px; font-weight: 700; letter-spacing: -.2px; color: var(--muted); border: 2px dashed var(--dashed); border-radius: 10px; }

/* App-Vorschau */
.preview { display: flex; flex-direction: column; align-items: center; justify-content: center; }
.preview img { display: block; width: 100%; max-width: 600px; height: auto; }

/* ---------- Einleitung ---------- */
.note { padding: 64px 0; }
.note .container { display: flex; justify-content: center; }
.note p { max-width: 480px; text-wrap: pretty; font-size: 18px; text-align: center; color: var(--muted); }

/* ---------- Funktionen ---------- */
.features { display: flex; width: 100%; padding: 40px 0; }
.feature-list { display: flex; flex-direction: column; }
.feature-list > * { margin-bottom: 40px; }
.feature { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 24px; width: 100%; }
.feature > * { flex: 1; }
.feature .image { width: 100%; max-width: 320px; aspect-ratio: 1; margin: 0; overflow: hidden; background: var(--card); border-radius: 60px; }
.feature .image img { display: block; width: 100%; height: auto; }
.feature .text { display: flex; flex-direction: column; justify-content: center; align-items: center; }
.feature .text h2 { max-width: 300px; margin: 0 0 8px; font-size: 24px; text-align: center; }
.feature .text p { max-width: 300px; font-size: 20px; text-align: center; }

/* ---------- Werte ---------- */
.values { display: flex; width: 100%; padding: 40px 0; }
.value-list { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 40px; }
.value { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 24px; width: 100%; max-width: 360px; }
.value .icon { display: flex; justify-content: center; align-items: center; width: 64px; height: 64px; aspect-ratio: 1; margin: 0; overflow: hidden; color: var(--accent); background: var(--icon-bg); border-radius: 24px; }
.value .icon svg { display: block; width: 32px; height: 32px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.value .text { display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; }
.value .text h3 { max-width: 300px; margin: 0 0 8px; font-size: 24px; }
.value .text p { font-size: 18px; }

/* ---------- Download ---------- */
.download { display: flex; width: 100%; padding: 40px 0; }
.download-card { display: flex; flex-direction: column; justify-content: center; align-items: center; width: 100%; padding: 80px 0; background: var(--accent); border-radius: 60px; }
.download-card h2 { font-size: 32px; color: #fff; }
.download-card .title { margin-bottom: 24px; padding: 0 20px; }
.download-card .post { color: #ffffffcc; max-width: 340px; text-wrap: balance; }
.download-card .requires { color: #fff; }
.download-card .qr.soon, .download-card .badge.soon { color: #fff; border-color: #ffffff80; }

/* ---------- FAQ ---------- */
.faq { display: flex; width: 100%; padding: 40px 0; }
.faq-list { column-count: 1; }
.faq-list li { display: inline-flex; flex-direction: column; margin-bottom: 24px; }
.faq-list h3 { margin: 0 0 4px; font-size: 18px; color: var(--faq-question); }
.faq-list p { font-size: 18px; }

/* ---------- Kontakt ---------- */
.contact { display: flex; width: 100%; padding: 40px 0; }
.contact .container { display: flex; justify-content: center; align-items: center; }
.contact-button { display: inline-flex; justify-content: center; align-items: center; height: 48px; padding: 0 24px; font-size: 16px; border: 2px dashed var(--dashed); border-radius: 24px; }
.contact-button > * { margin-inline-start: 4px; }

/* ---------- Fußzeile ---------- */
.footer { display: flex; width: 100%; margin-top: 40px; padding: 40px 0 80px; }
.footer .container { display: flex; flex-direction: column; justify-content: center; gap: 8px; }
.footer p { font-size: 16px; }

/* ---------- Breakpoints ---------- */
@media (min-width: 521px) {
  .footer .container { flex-direction: row; gap: 24px; }
}

@media (min-width: 691px) {
  .nav-grid { grid-template-columns: 1fr auto 1fr; grid-template-rows: 80px; }
  .menu { justify-content: center; }
  .menu-home { display: list-item; }
  .social { display: flex; justify-content: flex-end; }
  .stores { gap: 32px; }
  .logo { font-size: 20px; }
  .header h1 { font-size: 32px; }
  .feature { flex-direction: row; gap: 40px; }
  .feature.reverse { flex-direction: row-reverse; }
  .feature .image { max-width: 100%; }
  .feature .text h2 { font-size: 32px; }
  .value-list { flex-direction: row; justify-content: flex-start; align-items: flex-start; }
  .value { justify-content: flex-start; align-items: flex-start; max-width: 100%; }
  .value .text { text-align: start; justify-content: flex-start; align-items: flex-start; }
  .download-card h2 { font-size: 40px; }
  .faq { padding: 80px 0; }
  .faq-list { column-count: 2; column-gap: 40px; padding: 0 40px; }
}

@media (min-width: 1080px) {
  .nav-grid { grid-template-rows: 100px; }
  .header h1 { font-size: 40px; }
  .note { padding: 80px 0; }
  .feature-list { padding: 0 40px; }
  .value-list { padding: 0 40px; }
}

/* ---------- Rechtliche Seiten (Datenschutz, Impressum) ---------- */
.legal { padding: 40px 0 0; }
.legal h1 { margin-bottom: 8px; font-size: 32px; }
.legal h2 { margin: 40px 0 12px; font-size: 22px; }
.legal h3 { margin: 28px 0 8px; font-size: 18px; }
.legal p, .legal li { font-size: 17px; line-height: 1.65; }
.legal p { margin: 0 0 14px; }
.legal ul, .legal ol { margin: 0 0 14px; padding-inline-start: 22px; list-style: disc; }
.legal ol { list-style: decimal; }
.legal li { margin: 4px 0; }
.legal strong { color: var(--heading); font-weight: 700; }
.legal hr { border: 0; border-top: 1px solid var(--dashed); margin: 32px 0; }
.legal .stand { color: var(--muted); font-size: 15px; }
.legal table { width: 100%; margin: 0 0 18px; border-collapse: collapse; font-size: 15px; }
.legal th, .legal td { padding: 10px 12px; text-align: start; vertical-align: top; border-bottom: 1px solid var(--dashed); }
.legal th { color: var(--heading); font-weight: 700; background: var(--card); }
.legal .table-wrap { overflow-x: auto; }

/* ---------- Rechts nach links (Arabisch, Kurdisch) ---------- */
/* Arabische Schrift verträgt keine engere Laufweite (Buchstaben reißen ab)
   und braucht mehr Zeilenhöhe für die Vokalzeichen. */
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, [dir="rtl"] .title .post { letter-spacing: 0; line-height: 1.45; }
[dir="rtl"] body { line-height: 1.75; }
[dir="rtl"] .logo span, [dir="rtl"] .badge.soon { direction: ltr; }
