/* Copyright © 2026 S.C. FRATIC S.R.L. All rights reserved. Proprietary — no copying, redistribution or reuse without written permission. */
/* Fratic SRL — light/dark studio theme, vanilla CSS, no build step. Mobile-first.
   Light is the default; [data-theme="dark"] on <html> switches every token. */

:root {
  --color-bg: #fafafa;
  --color-bg-elevated: #ffffff;
  --color-border: #e8e8ed;
  --color-text: #1d1d1f;
  --color-text-secondary: #6e6e73;
  --color-accent: #3b5bdb;
  --color-accent-hover: #4c6ef5;
  --color-accent-glow: rgba(59, 91, 219, 0.06);
  --color-on-accent: #ffffff;
  --color-aurora-1: rgba(59, 91, 219, 0.2);
  --color-aurora-2: rgba(124, 58, 237, 0.14);
  --color-aurora-3: rgba(14, 165, 233, 0.13);
  --color-selection: rgba(59, 91, 219, 0.25);
  --color-card-hover: rgba(59, 91, 219, 0.32);
  --shadow-card: 0 1px 2px rgba(29, 29, 31, 0.04), 0 12px 32px rgba(29, 29, 31, 0.05);
  --shadow-card-hover: 0 2px 4px rgba(29, 29, 31, 0.05), 0 18px 44px rgba(29, 29, 31, 0.08);
  --card-highlight: rgba(255, 255, 255, 0.85);
  --grain-opacity: 0.03;
  --nav-bg: rgba(250, 250, 250, 0.8);
  --nav-bg-scrolled: rgba(250, 250, 250, 0.92);
  --nav-menu-bg: rgba(250, 250, 250, 0.97);
  --nav-height: 48px;
  --content-width: 980px;
  --font-stack: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
    "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --font-display: "New York", ui-serif, Georgia, "Times New Roman", serif;
}

:root[data-theme="dark"] {
  --color-bg: #0a0a10;
  --color-bg-elevated: #0f0f17;
  --color-border: #2a2a36;
  --color-text: #f5f5f7;
  --color-text-secondary: #9b9ba3;
  --color-accent: #748ffc;
  --color-accent-hover: #91a7ff;
  --color-accent-glow: rgba(116, 143, 252, 0.09);
  --color-on-accent: #0b102e;
  --color-aurora-1: rgba(116, 143, 252, 0.18);
  --color-aurora-2: rgba(167, 139, 250, 0.13);
  --color-aurora-3: rgba(56, 189, 248, 0.12);
  --color-selection: rgba(116, 143, 252, 0.35);
  --color-card-hover: rgba(116, 143, 252, 0.35);
  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.5), 0 12px 32px rgba(0, 0, 0, 0.35);
  --shadow-card-hover: 0 2px 4px rgba(0, 0, 0, 0.5), 0 18px 44px rgba(0, 0, 0, 0.45);
  --card-highlight: rgba(255, 255, 255, 0.06);
  --grain-opacity: 0.05;
  --nav-bg: rgba(10, 10, 16, 0.75);
  --nav-bg-scrolled: rgba(10, 10, 16, 0.92);
  --nav-menu-bg: rgba(10, 10, 16, 0.97);
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-stack);
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.022em;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, p { margin: 0; }

a { color: var(--color-accent); text-decoration: none; }
a:hover { text-decoration: underline; }

::selection { background: var(--color-selection); }

body {
  transition: background 0.3s ease, color 0.3s ease;
}

/* Set while re-syncing the theme on bfcache restores: the swap must snap,
   not fade, because it can land after first paint. */
.theme-instant *,
.theme-instant *::before,
.theme-instant *::after { transition: none !important; }

.dot { color: var(--color-accent); }

/* Film grain over the whole page: barely-there SVG noise that gives surfaces
   tooth and stops the aurora gradients from banding. Non-interactive. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 200;
  pointer-events: none;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 160px 160px;
}

/* ---------- Navigation ---------- */

.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  background: var(--nav-bg);
  -webkit-backdrop-filter: saturate(180%) blur(28px);
  backdrop-filter: saturate(180%) blur(28px);
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease;
}

.nav--scrolled {
  background: var(--nav-bg-scrolled);
  border-bottom-color: var(--color-border);
}

/* Phones: nothing fixed at the top edge. Safari 26 copies the background and
   backdrop-filter of fixed elements at the top onto the status bar, which turned
   the notch "ears" into glass showing page content scrolling past (same fix as
   fratic.io; apple.com's nav is also position: absolute on mobile). */
@media (max-width: 734px) {
  .nav { position: absolute; }
  body::after { display: none; }
}

.nav__inner {
  max-width: var(--content-width);
  margin: 0 auto;
  height: var(--nav-height);
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__brand {
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--color-text);
}
.nav__brand:hover { text-decoration: none; }

.nav__right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav__links a {
  font-size: 12px;
  color: var(--color-text);
  opacity: 0.85;
}
.nav__links a:hover { opacity: 1; text-decoration: none; }

.nav__cta {
  padding: 4px 12px;
  border-radius: 10px;
  background: var(--color-accent);
  color: var(--color-on-accent) !important;
  font-weight: 600;
  opacity: 1 !important;
}
.nav__cta:hover { background: var(--color-accent-hover); }

.lang-toggle {
  padding: 3px 10px;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  background: none;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--color-text);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}
.lang-toggle:hover { border-color: var(--color-text-secondary); color: var(--color-text); }

.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  background: none;
  color: var(--color-text);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}
.theme-toggle:hover { border-color: var(--color-text-secondary); color: var(--color-text); }
.theme-toggle svg { width: 13px; height: 13px; display: none; }
:root:not([data-theme="dark"]) .icon-moon { display: block; }
:root[data-theme="dark"] .icon-sun { display: block; }

.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 0 8px;
  border: 0;
  background: none;
  cursor: pointer;
}

.nav__toggle span {
  display: block;
  height: 1.5px;
  background: var(--color-text);
  transition: transform 0.3s ease;
}

.nav--open .nav__toggle span:first-child { transform: translateY(3.25px) rotate(45deg); }
.nav--open .nav__toggle span:last-child { transform: translateY(-3.25px) rotate(-45deg); }

@media (max-width: 734px) {
  .nav__toggle { display: flex; }

  .nav__links {
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 8px 40px 24px;
    background: var(--nav-menu-bg);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid var(--color-border);
    visibility: hidden;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  }

  .nav--open .nav__links {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
  }

  .nav__links a {
    font-size: 17px;
    padding: 12px 0;
    width: 100%;
  }

  .nav__cta {
    margin-top: 8px;
    text-align: center;
    padding: 10px 12px;
  }
}

/* ---------- Buttons & links ---------- */

.button {
  display: inline-block;
  padding: 10px 22px;
  border-radius: 12px;
  background: var(--color-accent);
  color: var(--color-on-accent);
  font-size: 17px;
  font-weight: 600;
}
.button:hover { background: var(--color-accent-hover); text-decoration: none; }

.button--large { padding: 14px 30px; font-size: 19px; }

.link-arrow { font-size: 17px; white-space: nowrap; }
.link-arrow::after { content: " \203A"; }
.link-arrow--light { color: var(--color-accent); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: calc(var(--nav-height) + 88px) 22px 72px;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, var(--color-accent-glow), transparent 60%),
    var(--color-bg);
  text-align: center;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -25%;
  background:
    radial-gradient(ellipse 38% 30% at 30% 32%, var(--color-aurora-1), transparent 70%),
    radial-gradient(ellipse 32% 26% at 70% 24%, var(--color-aurora-2), transparent 70%),
    radial-gradient(ellipse 44% 32% at 52% 48%, var(--color-aurora-3), transparent 72%);
  animation: aurora-drift 22s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes aurora-drift {
  from { transform: translate3d(-2.5%, -1.5%, 0) scale(1); }
  to { transform: translate3d(2.5%, 2.5%, 0) scale(1.08); }
}
.hero__inner { position: relative; max-width: var(--content-width); margin: 0 auto; }
.hero__eyebrow {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--color-text-secondary);
  margin-bottom: 14px;
}
.hero__icon {
  width: 96px;
  height: 96px;
  margin: 0 auto 26px;
  padding: 22px;
  color: var(--color-text);
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: 26px;
  box-shadow: var(--shadow-card), inset 0 1px 0 var(--card-highlight);
}
.hero__icon svg { width: 100%; height: 100%; }
.hero__title {
  font-family: var(--font-display);
  font-size: clamp(44px, 8vw, 80px);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.008em;
}
.hero__lede {
  max-width: 620px;
  margin: 18px auto 0;
  font-size: clamp(19px, 2.5vw, 26px);
  line-height: 1.3;
  color: var(--color-text-secondary);
}
.hero__actions {
  margin-top: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  flex-wrap: wrap;
}
.hero__platforms {
  margin-top: 26px;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--color-text-secondary);
}
.hero__shot {
  position: relative;
  max-width: 900px;
  margin: 64px auto 0;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-card-hover);
  background: #22403f;
}
.hero__shot img { display: block; width: 100%; height: auto; }

/* ---------- Sections ---------- */
.section {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 124px 22px;
}
.section--after-hero { padding-top: 96px; }
.section__head { text-align: center; margin-bottom: 64px; }
.section__head h2 {
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 600;
  letter-spacing: -0.008em;
}
.section__head p {
  margin-top: 8px;
  font-size: clamp(19px, 2.5vw, 24px);
  color: var(--color-text-secondary);
}
.section__note {
  max-width: 640px;
  margin: 56px auto 0;
  text-align: center;
  font-size: 17px;
  color: var(--color-text-secondary);
}

/* ---------- Screenshot gallery ---------- */
/* Each App Store shot already carries its headline and backdrop, so the
   gallery only frames them: rounded cards, three across, two on tablets. */
.shots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.shot {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-card), inset 0 1px 0 var(--card-highlight);
  background: var(--color-bg-elevated);
  transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}
.shot img { display: block; width: 100%; height: auto; aspect-ratio: 1320 / 2868; }
.shot__pro {
  position: absolute;
  top: 14px;
  right: 14px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
}
@media (hover: hover) {
  .shot:hover {
    transform: translateY(-4px);
    border-color: var(--color-card-hover);
    box-shadow: var(--shadow-card-hover), inset 0 1px 0 var(--card-highlight);
  }
}
@media (max-width: 900px) { .shots { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .shots { grid-template-columns: 1fr; max-width: 360px; margin: 0 auto; } }

/* ---------- Feature list ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 48px 40px;
}
.feature__num {
  display: block;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--color-text-secondary);
  margin-bottom: 10px;
}
.feature h3 { font-size: 21px; font-weight: 600; }
.feature p { margin-top: 8px; color: var(--color-text-secondary); }

/* ---------- Free / Pro ---------- */
.plans {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  max-width: 820px;
  margin: 0 auto;
}
.plan {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: 20px;
  padding: 40px 32px;
  box-shadow: var(--shadow-card), inset 0 1px 0 var(--card-highlight);
}
.plan--pro { border-color: var(--color-card-hover); }
.plan__eyebrow {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--color-text-secondary);
}
.plan h3 { margin-top: 6px; font-size: 28px; font-weight: 700; letter-spacing: -0.015em; }
.plan__price { margin-top: 4px; font-size: 17px; color: var(--color-text-secondary); }
.plan ul { margin: 22px 0 0; padding: 0; list-style: none; }
.plan li {
  position: relative;
  padding: 7px 0 7px 26px;
  color: var(--color-text);
  border-top: 1px solid var(--color-border);
}
.plan li:first-child { border-top: 0; }
.plan li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 14px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-accent);
}
@media (max-width: 640px) { .plans { grid-template-columns: 1fr; } }

/* ---------- Prose pages (support, privacy) ---------- */
.prose {
  max-width: 680px;
  margin: 0 auto;
  padding: 64px 22px 124px;
  font-size: 17px;
  line-height: 1.55;
}
.prose h2 {
  margin-top: 48px;
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 28px; font-size: 20px; font-weight: 600; }
.prose p, .prose ul { margin-top: 12px; }
.prose p.muted { color: var(--color-text-secondary); }
.prose ul { padding-left: 22px; }
.prose li { margin-top: 6px; }
.prose li::marker { color: var(--color-accent); }
.prose .updated {
  margin-top: 0;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--color-text-secondary);
}
.faq { margin-top: 8px; }
.faq details {
  border-top: 1px solid var(--color-border);
  padding: 14px 0;
}
.faq details:last-child { border-bottom: 1px solid var(--color-border); }
.faq summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--color-text-secondary); font-family: var(--font-mono); }
.faq details[open] summary::after { content: "\2212"; }
.faq details p { color: var(--color-text-secondary); }
.page-hero {
  position: relative;
  padding: calc(var(--nav-height) + 72px) 22px 24px;
  text-align: center;
}
.page-hero__back { margin-bottom: 28px; }
.back-link {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--color-text-secondary);
}
.back-link::before { content: "\2039 "; }
.back-link:hover { color: var(--color-text); text-decoration: none; }
.page-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(40px, 7vw, 64px);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.008em;
}
.page-hero__lede {
  max-width: 600px;
  margin: 16px auto 0;
  font-size: clamp(19px, 2.5vw, 24px);
  line-height: 1.3;
  color: var(--color-text-secondary);
}

/* ---------- Contact ---------- */
.contact {
  background: var(--color-bg-elevated);
  border-top: 1px solid var(--color-border);
  text-align: center;
  padding: 120px 22px;
}
.contact h2 {
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 600;
  letter-spacing: -0.008em;
}
.contact p {
  margin: 12px 0 30px;
  font-size: clamp(19px, 2.5vw, 24px);
  color: var(--color-text-secondary);
}
.contact__alt { margin-top: 24px !important; font-size: 17px !important; }

/* ---------- Footer ---------- */
.footer {
  background: var(--color-bg);
  border-top: 1px solid var(--color-border);
  font-size: 12px;
  color: var(--color-text-secondary);
}
.footer__brand {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 44px 22px 10px;
}
.footer__wordmark {
  margin: 0;
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--color-text);
}
.footer__wordmark a { color: inherit; }
.footer__tagline {
  margin: 4px 0 0;
  font-family: var(--font-display);
  font-size: 15px;
  color: var(--color-text-secondary);
}
.footer__inner {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 18px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.footer__legal p { margin: 2px 0; }
.footer nav { display: flex; gap: 24px; flex-wrap: wrap; }
.footer nav a { color: var(--color-text-secondary); }
.footer nav a:hover { color: var(--color-text); text-decoration: none; }

/* ---------- Scroll reveals ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.js .reveal--visible { opacity: 1; transform: translateY(0); }
.js .reveal--instant { transition: none; }

/* ---------- Page transitions ---------- */
@view-transition { navigation: auto; }
.nav { view-transition-name: site-nav; }
::view-transition-old(root) { animation: vt-page-out 0.35s cubic-bezier(0.4, 0, 1, 1) both; }
::view-transition-new(root) { animation: vt-page-in 0.7s cubic-bezier(0.32, 0.72, 0, 1) both; }
@keyframes vt-page-out { to { opacity: 0; transform: translateY(-12px) scale(0.995); } }
@keyframes vt-page-in { from { opacity: 0; transform: translateY(20px) scale(0.995); } 40% { opacity: 1; } }
.no-vt body { animation: page-enter 0.85s cubic-bezier(0.32, 0.72, 0, 1); }
.page-leaving body {
  opacity: 0;
  transform: translateY(-10px) scale(0.995);
  transition: opacity 0.38s cubic-bezier(0.4, 0, 1, 1), transform 0.38s cubic-bezier(0.4, 0, 1, 1);
}
@keyframes page-enter { from { opacity: 0; transform: translateY(18px); } }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .hero::before { animation: none; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
  .no-vt body { animation: none; }
  .page-leaving body { opacity: 1; transform: none; transition: none; }
}
