/* Vitola — vitola.my landing page.
   Standalone stylesheet: the legal pages keep using site.css untouched.
   Palette lifted verbatim from lib/app/theme/colors.dart ("embers in the dark"). */

:root {
  --bg: #15100B;
  --bg-glow: #241710;
  --ink: #F4ECDE;
  --ink-hi: #F7EFE1;
  --cream-muted: #D9C3A0;
  --muted: #B6A78F;
  --faint: #9C8E78;
  --ember: #E0552C;
  --ember-hi: #E8632F;
  --ember-lo: #C8431C;
  --gold: #D9B679;
  --hairline: rgba(244, 236, 222, 0.14);
  --glass: rgba(244, 236, 222, 0.045);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
  overflow-x: clip;
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  overflow-x: clip;
  background-color: var(--bg);
  background-image: radial-gradient(120% 55% at 50% -12%, var(--bg-glow) 0%, var(--bg) 62%);
  background-repeat: no-repeat;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.7;
}

::selection { background: rgba(224, 85, 44, 0.35); color: var(--ink-hi); }

a { color: var(--gold); text-decoration: none; }
a:hover, a:focus-visible { color: var(--ember-hi); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 2px; }

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

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 100;
  padding: 0.5rem 1rem;
  background: var(--bg-glow);
  border: 1px solid var(--hairline);
  border-radius: 8px;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 1rem; }

/* ---- Nav ---- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(21, 16, 11, 0.78);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(244, 236, 222, 0.08);
}
.nav-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0.8rem 1.4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--ink-hi);
  font-family: var(--serif);
  font-size: 1.22rem;
  letter-spacing: 0.06em;
}
.brand:hover, .brand:focus-visible { color: var(--gold); }
.brand img {
  width: 28px;
  height: 28px;
  border-radius: 22.5%;
  box-shadow: 0 0 0 1px rgba(244, 236, 222, 0.1);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 3.5vw, 2.2rem);
}
.nav-links a {
  color: var(--muted);
  font-size: 0.92rem;
  letter-spacing: 0.04em;
}
.nav-links a:hover, .nav-links a:focus-visible { color: var(--ink-hi); }

/* ---- Shared section chrome ---- */

.section {
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(4rem, 9vw, 6.5rem) 1.4rem;
  scroll-margin-top: 4.5rem;
}

.eyebrow {
  margin: 0 0 0.9rem;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ember);
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 500;
  color: var(--ink-hi);
  margin: 0;
}

h1, h2 { text-wrap: balance; }

h2 {
  font-size: clamp(1.75rem, 3.8vw, 2.5rem);
  line-height: 1.15;
  letter-spacing: 0.005em;
  margin-bottom: 1rem;
}

/* Arc-gradient section rule — echo of the ember arc in the brand artwork. */
.rule {
  width: min(200px, 40vw);
  height: 1px;
  margin: 0 auto;
  background: linear-gradient(90deg, transparent,
              rgba(232, 99, 47, 0.55) 35%,
              rgba(217, 182, 121, 0.4) 65%,
              transparent);
}
.rule-tight { width: min(120px, 30vw); }

/* ---- Hero ---- */

.hero {
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(3.5rem, 8vw, 6rem) 1.4rem clamp(4rem, 9vw, 6.5rem);
  text-align: center;
}

.hero-art {
  position: relative;
  width: min(300px, 62vw);
  aspect-ratio: 1;
  margin: 0 auto clamp(2rem, 5vw, 3rem);
  display: grid;
  place-items: center;
}

.hero-aura {
  position: absolute;
  inset: -42%;
  background: radial-gradient(closest-side,
              rgba(224, 85, 44, 0.24),
              rgba(224, 85, 44, 0.08) 45%,
              transparent 72%);
  pointer-events: none;
}

/* The ember arc: a thin luminous ring segment, low and to the left,
   as in the app icon's own lit arc. */
.arc {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 150deg,
              transparent 0deg,
              rgba(200, 67, 28, 0.65) 30deg,
              rgba(232, 99, 47, 0.95) 60deg,
              rgba(217, 182, 121, 0.55) 95deg,
              transparent 130deg);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 2.5px), #000 calc(100% - 1px));
  mask: radial-gradient(farthest-side, transparent calc(100% - 2.5px), #000 calc(100% - 1px));
  pointer-events: none;
}
.arc-glow {
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 8px), #000 calc(100% - 2px));
  mask: radial-gradient(farthest-side, transparent calc(100% - 8px), #000 calc(100% - 2px));
  filter: blur(5px);
  opacity: 0.85;
}

.hero-icon {
  width: 61%;
  height: auto;
  border-radius: 22.5%;
  box-shadow:
    0 0 0 1px rgba(244, 236, 222, 0.09),
    0 18px 50px rgba(0, 0, 0, 0.55),
    0 6px 18px rgba(0, 0, 0, 0.4);
}

h1 {
  font-size: clamp(2.35rem, 7vw, 3.9rem);
  line-height: 1.08;
  letter-spacing: 0.005em;
  margin-bottom: 1.25rem;
}
h1 em {
  font-style: italic;
  color: var(--cream-muted);
}

.hero-sub {
  max-width: 34em;
  margin: 0 auto 2.4rem;
  color: var(--muted);
  font-size: clamp(1rem, 2.4vw, 1.14rem);
  line-height: 1.75;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.8rem;
  margin-bottom: 1.9rem;
}
.badge {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.1rem;
  padding: 0.6rem 1.25rem 0.65rem;
  border: 1px solid var(--hairline);
  border-radius: 14px;
  background: var(--glass);
  text-align: left;
}
.badge-kicker {
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
}
.badge-store {
  font-size: 1rem;
  font-weight: 500;
  color: var(--ink-hi);
  letter-spacing: 0.01em;
}

.hero-privacy { margin: 0; font-size: 0.95rem; }

/* ---- Features ---- */

.grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1.1rem;
  margin-top: clamp(1.8rem, 4vw, 2.8rem);
}
.card { grid-column: span 2; }
.card:nth-child(4) { grid-column: 1 / span 3; }
.card:nth-child(5) { grid-column: 4 / span 3; }

.card {
  position: relative;
  padding: 1.7rem 1.6rem 1.8rem;
  border: 1px solid var(--hairline);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(244, 236, 222, 0.03), transparent 45%),
    var(--glass);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  transition: border-color 0.35s ease, transform 0.35s ease;
}
.card:hover {
  border-color: rgba(224, 85, 44, 0.35);
  transform: translateY(-2px);
}

.card-icon {
  width: 24px;
  height: 24px;
  color: var(--gold);
  opacity: 0.9;
  margin-bottom: 1rem;
}

.card h3 {
  font-size: 1.24rem;
  line-height: 1.3;
  margin-bottom: 0.55rem;
}
.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.97rem;
  line-height: 1.65;
}
.card p a { white-space: nowrap; }
.card p a::after { content: " \2193"; }

/* Flavor-signature mini chart (the catalog's real data, in miniature). */
.flavor-sig { margin-top: 1.3rem; }
.fs-label {
  display: block;
  margin-bottom: 0.55rem;
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--faint);
}
.fs-row {
  display: grid;
  grid-template-columns: 3.6rem 1fr;
  align-items: center;
  gap: 0.6rem;
  margin: 0.35rem 0;
}
.fs-row span {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--muted);
}
.fs-row i {
  display: block;
  height: 3px;
  border-radius: 2px;
  width: var(--w, 50%);
  background: linear-gradient(90deg, var(--ember-lo), var(--ember-hi) 70%, var(--gold));
}

/* ---- Köz ---- */

.koz {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(2.2rem, 5vw, 4.5rem);
  align-items: center;
}
.koz-copy p {
  margin: 0 0 1.1rem;
  color: var(--muted);
  line-height: 1.75;
}
.koz-copy h2 { margin-bottom: 1.1rem; }
.koz-note {
  font-size: 0.92rem;
  color: var(--faint);
  padding-left: 0.9rem;
  border-left: 2px solid rgba(224, 85, 44, 0.5);
}

.koz-visual { position: relative; }
.koz-visual::before {
  content: "";
  position: absolute;
  inset: -18% -12%;
  background: radial-gradient(closest-side,
              rgba(224, 85, 44, 0.13),
              transparent 72%);
  pointer-events: none;
}

.chat {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  padding: clamp(1.2rem, 3vw, 1.8rem);
  border: 1px solid var(--hairline);
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(244, 236, 222, 0.035), transparent 55%),
    rgba(21, 16, 11, 0.55);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

.msg {
  max-width: 88%;
  padding: 0.8rem 1.05rem;
  border-radius: 14px;
  font-size: 0.95rem;
  line-height: 1.6;
}
.msg p { margin: 0; }

.msg.user {
  align-self: flex-end;
  background: rgba(244, 236, 222, 0.07);
  border: 1px solid rgba(244, 236, 222, 0.09);
  border-bottom-right-radius: 5px;
  color: var(--ink);
}
.msg.koz-msg {
  align-self: flex-start;
  background: rgba(224, 85, 44, 0.08);
  border: 1px solid rgba(224, 85, 44, 0.2);
  border-bottom-left-radius: 5px;
  color: var(--ink);
}
.msg-name {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.35rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
}
.flame-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--ember-hi), var(--ember-lo));
  box-shadow: 0 0 6px rgba(232, 99, 47, 0.8);
}

.chat-caption {
  position: relative;
  margin: 0.9rem 0 0;
  text-align: center;
  font-size: 0.8rem;
  color: var(--faint);
}

/* ---- Responsibility ---- */

.responsibility {
  max-width: 640px;
  text-align: center;
  padding-top: clamp(2rem, 5vw, 3rem);
  padding-bottom: clamp(2rem, 5vw, 3rem);
}
.resp-lead {
  margin: 2.6rem 0 0.9rem;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.3rem;
  color: var(--cream-muted);
}
.resp-body {
  margin: 0 0 2.6rem;
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--faint);
}

/* ---- Footer ---- */

.footer {
  border-top: 1px solid var(--hairline);
  padding: 2.2rem 1.4rem 2.8rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--faint);
}
.footer p {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem 1.6rem;
}
.footer a { color: var(--muted); }
.footer a:hover, .footer a:focus-visible { color: var(--ember-hi); }

/* ---- Motion (opt-in only) ---- */

@media (prefers-reduced-motion: no-preference) {
  .hero-aura { animation: breathe 7s ease-in-out infinite alternate; }

  @keyframes breathe {
    from { opacity: 0.75; }
    to   { opacity: 1; transform: scale(1.04); }
  }

  /* Page-load: hero rises once. */
  .hero > * { animation: rise 0.9s cubic-bezier(0.22, 0.8, 0.3, 1) both; }
  .hero > *:nth-child(2) { animation-delay: 0.08s; }
  .hero > *:nth-child(3) { animation-delay: 0.16s; }
  .hero > *:nth-child(4) { animation-delay: 0.24s; }
  .hero > *:nth-child(5) { animation-delay: 0.32s; }
  .hero > *:nth-child(6) { animation-delay: 0.4s; }

  @keyframes rise {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: none; }
  }

  /* Scroll reveals — only when JS is present; content is untouched otherwise. */
  .js .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.7s ease, transform 0.7s ease;
  }
  .js .reveal.in { opacity: 1; transform: none; }

  .js .grid .card:nth-child(2) { transition-delay: 0.08s; }
  .js .grid .card:nth-child(3) { transition-delay: 0.16s; }
  .js .grid .card:nth-child(5) { transition-delay: 0.08s; }

  .js .chat .msg:nth-child(2) { transition-delay: 0.15s; }
  .js .chat .msg:nth-child(3) { transition-delay: 0.3s; }
  .js .chat .msg:nth-child(4) { transition-delay: 0.45s; }
}

/* ---- Responsive ---- */

@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .card,
  .card:nth-child(4),
  .card:nth-child(5) { grid-column: auto; }
  .card:nth-child(5) { grid-column: 1 / -1; }

  .koz { grid-template-columns: 1fr; align-items: start; }
}

@media (max-width: 560px) {
  .grid { grid-template-columns: 1fr; }
  .card:nth-child(5) { grid-column: auto; }

  .nav-inner { padding: 0.7rem 1rem; }
  .brand { font-size: 1.1rem; gap: 0.5rem; }
  .brand img { width: 24px; height: 24px; }
  .nav-links { gap: 1rem; }
  .nav-links a { font-size: 0.84rem; }

  .badges { flex-direction: column; align-items: center; }
  .badge { min-width: 220px; align-items: center; }

  .msg { max-width: 94%; }
}
