/* ============================================================
   Kangru — landing site styles
   Palette mirrors the app's Theme.swift
   ============================================================ */

:root {
  --color-blood: #c0271f;
  --color-blood-dark: #9c1d16;
  --color-ink: #1a1a1a;
  --color-muted-rose: #b06058;
  --color-faint-rose: #d98a85;
  --color-border-rose: #f1d4d2;
  --color-avatar-bg: #fbe0dd;
  --color-coral: #e46258;
  --color-blush: #f1aca7;
  --color-ok-green: #1f9d6b;
  --color-cream: #fdf8f5;
  --color-cream-deep: #f9ede9;
  --color-card: #ffffff;

  --font-display: ui-serif, "New York", Georgia, "Times New Roman", serif;
  --font-body: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI",
    Roboto, "Helvetica Neue", Arial, sans-serif;

  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-hero: clamp(2.6rem, 1.4rem + 5.5vw, 5.5rem);
  --text-section: clamp(1.9rem, 1.4rem + 2vw, 3rem);

  --space-section: clamp(4.5rem, 3rem + 6vw, 9rem);
  --radius-card: 20px;

  --duration-fast: 150ms;
  --duration-normal: 300ms;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  color: var(--color-ink);
  background: var(--color-cream);
  -webkit-font-smoothing: antialiased;
}

/* --- language switching ------------------------------------ */
/* Default: Turkish. html[data-lang] flips visibility.          */

html[data-lang="tr"] [lang="en"],
html[data-lang="en"] [lang="tr"] {
  display: none !important;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--color-blood);
}

/* --- header ------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding: 0.7rem clamp(1rem, 4vw, 3rem);
  background: color-mix(in srgb, var(--color-cream) 88%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border-rose);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-ink);
  text-decoration: none;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 8px;
}

.header-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: clamp(0.6rem, 2vw, 1.6rem);
}

.header-nav a {
  color: var(--color-ink);
  text-decoration: none;
  font-size: 0.95rem;
  border-bottom: 2px solid transparent;
  transition: border-color var(--duration-fast) ease;
}

.header-nav a:hover,
.header-nav a:focus-visible {
  border-bottom-color: var(--color-blood);
}

.lang-toggle {
  display: inline-flex;
  border: 1.5px solid var(--color-border-rose);
  border-radius: 999px;
  overflow: hidden;
  background: var(--color-card);
}

.lang-toggle button {
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.3rem 0.85rem;
  cursor: pointer;
  color: var(--color-muted-rose);
  transition: background var(--duration-fast) ease, color var(--duration-fast) ease;
}

.lang-toggle button:hover {
  background: var(--color-avatar-bg);
}

.lang-toggle button[aria-pressed="true"] {
  background: var(--color-blood);
  color: #fff;
}

/* --- hero ---------------------------------------------------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: var(--space-section) clamp(1rem, 4vw, 3rem) calc(var(--space-section) * 0.8);
  text-align: center;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -40% -20% auto;
  height: 120%;
  background:
    radial-gradient(38% 55% at 22% 30%, var(--color-avatar-bg) 0%, transparent 70%),
    radial-gradient(30% 45% at 80% 22%, #fbeae2 0%, transparent 70%);
  z-index: -1;
}

.hero-logo {
  width: clamp(88px, 14vw, 132px);
  height: auto;
  filter: drop-shadow(0 14px 30px rgba(192, 39, 31, 0.22));
}

.hero h1 {
  font-family: var(--font-display);
  font-size: var(--text-hero);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 1.2rem auto 0;
  max-width: 17ch;
}

.hero h1 em {
  font-style: normal;
  color: var(--color-blood);
}

.hero-sub {
  max-width: 44ch;
  margin: 1.4rem auto 0;
  font-size: clamp(1.05rem, 1rem + 0.4vw, 1.3rem);
  color: #5c4a47;
}

.hero-actions {
  margin-top: 2.4rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}

.store-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  background: var(--color-ink);
  color: #fff;
  text-decoration: none;
  border-radius: 14px;
  padding: 0.65rem 1.3rem;
  line-height: 1.15;
  transition: transform var(--duration-fast) var(--ease-out),
    box-shadow var(--duration-fast) var(--ease-out);
}

.store-badge:hover,
.store-badge:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(26, 26, 26, 0.28);
}

.store-badge svg {
  width: 26px;
  height: 26px;
  flex: none;
}

.store-badge .small {
  display: block;
  font-size: 0.68rem;
  opacity: 0.8;
}

.store-badge .big {
  display: block;
  font-size: 1.05rem;
  font-weight: 600;
}

.store-note {
  font-size: 0.85rem;
  color: var(--color-muted-rose);
}

.hero-privacy-line {
  margin-top: 2.6rem;
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.4rem;
  font-size: 0.9rem;
  color: var(--color-muted-rose);
}

.hero-privacy-line span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.hero-privacy-line svg {
  width: 15px;
  height: 15px;
  color: var(--color-ok-green);
}

/* --- shared section shell ------------------------------------ */

.section {
  padding: calc(var(--space-section) * 0.75) clamp(1rem, 4vw, 3rem);
  max-width: 1100px;
  margin: 0 auto;
}

.section-kicker {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-blood);
  margin-bottom: 0.8rem;
}

.section h2 {
  font-family: var(--font-display);
  font-size: var(--text-section);
  line-height: 1.12;
  letter-spacing: -0.015em;
  max-width: 24ch;
}

.section-lead {
  margin-top: 1rem;
  max-width: 56ch;
  color: #5c4a47;
}

/* --- features ------------------------------------------------- */

.feature-grid {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 1.2rem;
}

.feature-card {
  background: var(--color-card);
  border: 1px solid var(--color-border-rose);
  border-radius: var(--radius-card);
  padding: 1.6rem 1.5rem;
  transition: transform var(--duration-normal) var(--ease-out),
    box-shadow var(--duration-normal) var(--ease-out);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 38px rgba(176, 96, 88, 0.16);
}

.feature-card .icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: var(--color-avatar-bg);
  color: var(--color-blood);
  margin-bottom: 1rem;
}

.feature-card .icon svg {
  width: 24px;
  height: 24px;
}

.feature-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
}

.feature-card p {
  font-size: 0.95rem;
  color: #5c4a47;
}

/* --- privacy band --------------------------------------------- */

.privacy-band {
  background: linear-gradient(160deg, var(--color-blood-dark), var(--color-blood) 65%, #d63a30);
  color: #fff;
  border-radius: calc(var(--radius-card) * 1.4);
  padding: clamp(2rem, 4vw, 3.6rem);
  margin-top: 3rem;
}

.privacy-band h2,
.privacy-band .section-kicker {
  color: #fff;
}

.privacy-band .section-kicker {
  color: var(--color-blush);
}

.privacy-points {
  margin-top: 2.2rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.6rem 2rem;
  list-style: none;
}

.privacy-points li {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 0.8rem;
  align-items: start;
}

.privacy-points .p-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.14);
}

.privacy-points .p-icon svg {
  width: 18px;
  height: 18px;
}

.privacy-points strong {
  display: block;
  font-size: 1rem;
  margin-bottom: 0.15rem;
}

.privacy-points p {
  font-size: 0.9rem;
  opacity: 0.88;
}

.privacy-band .fineprint {
  margin-top: 2rem;
  font-size: 0.85rem;
  opacity: 0.75;
  max-width: 70ch;
}

.privacy-band .fineprint a {
  color: #fff;
}

/* --- mascot / support ----------------------------------------- */

.mascot {
  display: grid;
  grid-template-columns: minmax(120px, 200px) 1fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
  background: var(--color-cream-deep);
  border: 1px solid var(--color-border-rose);
  border-radius: calc(var(--radius-card) * 1.4);
  padding: clamp(1.6rem, 3.5vw, 3rem);
}

.mascot img {
  width: 100%;
  max-width: 200px;
  filter: drop-shadow(0 12px 24px rgba(192, 39, 31, 0.18));
}

.mascot h2 {
  font-size: clamp(1.5rem, 1.2rem + 1.4vw, 2.2rem);
}

.mascot p {
  margin-top: 0.8rem;
  color: #5c4a47;
  max-width: 52ch;
}

@media (max-width: 560px) {
  .mascot {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .mascot img {
    margin: 0 auto;
  }
}

/* --- footer ---------------------------------------------------- */

.site-footer {
  margin-top: var(--space-section);
  border-top: 1px solid var(--color-border-rose);
  padding: 2.2rem clamp(1rem, 4vw, 3rem) 3rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2.4rem;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--color-muted-rose);
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.4rem;
}

.site-footer a {
  color: var(--color-muted-rose);
}

.site-footer a:hover {
  color: var(--color-blood);
}

/* --- legal pages (privacy / support) ---------------------------- */

.legal {
  max-width: 760px;
  margin: 0 auto;
  padding: calc(var(--space-section) * 0.6) clamp(1rem, 4vw, 2rem);
}

.legal h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 1.5rem + 2.4vw, 3.2rem);
  line-height: 1.1;
  margin-bottom: 0.6rem;
}

.legal .updated {
  color: var(--color-muted-rose);
  font-size: 0.9rem;
  margin-bottom: 2.4rem;
}

.legal h2 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  margin: 2.4rem 0 0.7rem;
}

.legal h3 {
  font-size: 1.08rem;
  margin: 1.8rem 0 0.4rem;
}

.legal p,
.legal li {
  color: #3d3230;
}

.legal ul {
  padding-left: 1.3rem;
  margin: 0.6rem 0;
}

.legal .callout {
  background: var(--color-cream-deep);
  border: 1px solid var(--color-border-rose);
  border-left: 4px solid var(--color-blood);
  border-radius: 12px;
  padding: 1rem 1.2rem;
  margin: 1.4rem 0;
  font-size: 0.95rem;
}

/* --- motion preferences ------------------------------------------ */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .feature-card,
  .store-badge {
    transition: none;
  }
}
