:root {
  --bg: #F7F6F3;
  --surface: #FFFFFF;
  --ink: #12141B;
  --text: #2B2F3A;
  --muted: #646A7A;
  --line: #E4E2DC;
  --accent: #A92EE6;
  --accent-soft: #F4E8FC;
  --dark: #0B0C12;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0B0C12; --surface: #151821; --ink: #F1EFEA; --text: #D5D3CE; --muted: #9196A5;
    --line: #262A36; --accent: #C86BFF; --accent-soft: #241A30; --dark: #05060A;
  }
  :root:not([data-theme="light"]) .logo-light { display: none; }
  :root:not([data-theme="light"]) .logo-dark { display: block; }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.65 "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: var(--accent); }
img { max-width: 100%; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* header */
.top { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 16px; }
.brand { display: flex; align-items: center; }
.brand img { height: 30px; width: auto; display: block; }
.logo-dark { display: none; }
.nav { display: flex; gap: 22px; font-size: .95rem; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 500; }
.nav a:hover { color: var(--accent); }
@media (max-width: 560px) { .nav { gap: 14px; font-size: .9rem; } .brand img { height: 24px; } }

/* hero */
.hero { padding: 88px 0 64px; }
.eyebrow { display: inline-block; font-size: .8rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); padding: 6px 12px; border-radius: 999px; }
.hero h1 { color: var(--ink); font-size: clamp(2.2rem, 5.4vw, 3.8rem); line-height: 1.08; letter-spacing: -.025em; margin: 22px 0 0; max-width: 15em; }
.hero p { font-size: 1.15rem; color: var(--muted); max-width: 36em; margin: 22px 0 0; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: 10px; font-weight: 600; text-decoration: none; border: 1px solid var(--line); color: var(--ink); background: var(--surface); }
.btn.primary { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* sections */
section { padding: 56px 0; }
.sec-title { color: var(--ink); font-size: 1.6rem; letter-spacing: -.01em; margin: 0 0 8px; }
.sec-lead { color: var(--muted); margin: 0 0 32px; max-width: 40em; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 24px; display: flex; flex-direction: column; }
.card .icon { width: 64px; height: 64px; border-radius: 16px; }
.card h3 { color: var(--ink); margin: 18px 0 4px; font-size: 1.2rem; }
.card .tag { font-size: .85rem; color: var(--accent); font-weight: 600; }
.card p { color: var(--muted); margin: 10px 0 18px; flex: 1; }
.card .links { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: .92rem; }
.card .links a { text-decoration: none; font-weight: 500; }
.values { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 28px; }
.values h4 { color: var(--ink); margin: 0 0 6px; font-size: 1.05rem; }
.values p { color: var(--muted); margin: 0; }
.contact-box { background: var(--dark); color: #EFECE6; border-radius: 22px; padding: 40px 32px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.contact-box h2 { margin: 0; font-size: 1.6rem; color: #fff; }
.contact-box p { margin: 6px 0 0; color: #A7AAB6; }
.contact-box a.btn { background: #fff; color: #0B0C12; border-color: #fff; }

/* app page */
.app-head { display: flex; gap: 24px; align-items: center; padding: 64px 0 24px; flex-wrap: wrap; }
.app-head img { width: 104px; height: 104px; border-radius: 24px; box-shadow: 0 8px 30px rgba(0,0,0,.12); }
.app-head h1 { color: var(--ink); margin: 0; font-size: clamp(2rem, 4.5vw, 2.8rem); letter-spacing: -.02em; }
.app-head p { margin: 4px 0 0; color: var(--muted); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin: 24px 0 8px; }
.fact { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; }
.fact b { display: block; color: var(--ink); }
.fact span { color: var(--muted); font-size: .92rem; }

/* legal */
.legal { max-width: 760px; padding: 56px 20px 80px; }
.legal h1 { color: var(--ink); font-size: clamp(1.8rem, 4vw, 2.4rem); letter-spacing: -.02em; margin: 0 0 6px; }
.legal .meta { color: var(--muted); font-size: .92rem; margin: 0 0 28px; }
.legal h2 { color: var(--ink); font-size: 1.25rem; margin: 36px 0 8px; }
.legal h3 { color: var(--ink); font-size: 1.05rem; margin: 24px 0 6px; }
.legal ul, .legal ol { padding-left: 1.3em; }
.legal li { margin: 4px 0; }
.legal table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: .95rem; }
.legal th, .legal td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.legal th { color: var(--ink); }
.lang-switch { display: flex; gap: 8px; margin: 0 0 28px; }
.lang-switch a { text-decoration: none; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); font-size: .9rem; }
.note { background: var(--accent-soft); border-radius: 12px; padding: 14px 16px; margin: 16px 0; }
hr.split { border: 0; border-top: 1px solid var(--line); margin: 56px 0; }
.crumbs { font-size: .9rem; color: var(--muted); margin: 0 0 18px; }
.crumbs a { color: var(--muted); }

/* footer */
footer { border-top: 1px solid var(--line); padding: 48px 0 36px; margin-top: 24px; font-size: .92rem; }
.foot { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 28px; }
.foot h5 { color: var(--ink); margin: 0 0 10px; font-size: .9rem; }
.foot a { display: block; color: var(--muted); text-decoration: none; margin: 4px 0; }
.foot a:hover { color: var(--accent); }
.foot p { color: var(--muted); margin: 10px 0 0; max-width: 22em; }
.copy { color: var(--muted); margin-top: 32px; font-size: .85rem; }
@media (max-width: 760px) { .foot { grid-template-columns: 1fr 1fr; } }

/* ---- home: film ---- */
.film { position: relative; background: #020306; display: flex; justify-content: center; }
.film video { display: block; width: 100%; max-height: 82vh; aspect-ratio: 16 / 9; object-fit: contain; background: #020306; }
@media (orientation: portrait) { .film video { aspect-ratio: 9 / 16; max-height: 78vh; } }
.replay { position: absolute; right: 16px; bottom: 16px; background: rgba(255,255,255,.08); color: #EFECE6; border: 1px solid rgba(255,255,255,.18); border-radius: 999px; padding: 8px 14px; font: 500 .85rem Inter, system-ui, sans-serif; cursor: pointer; }
.replay:hover { background: rgba(255,255,255,.16); }

/* ---- home: hero + stats ---- */
.hero h1 em { font-style: normal; background: linear-gradient(90deg, #C33BFF, #7A5CFF); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-top: 56px; border-top: 1px solid var(--line); }
.stat { padding: 22px 18px 0 0; }
.stat b { display: block; color: var(--ink); font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 800; letter-spacing: -.03em; }
.stat span { color: var(--muted); font-size: .95rem; }
@media (max-width: 680px) { .stats { grid-template-columns: repeat(2, 1fr); } }

/* ---- studio ---- */
.studio { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.split { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: start; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; gap: 32px; } }
.sec-title.big { font-size: clamp(1.9rem, 4vw, 2.6rem); letter-spacing: -.02em; margin-top: 16px; }
.sec-sub { color: var(--ink); font-size: 1.1rem; margin: 6px 0 22px; }
.studio p { font-size: 1.05rem; }

/* ---- apps showcase ---- */
.app-row { display: grid; grid-template-columns: 1fr 1.25fr; gap: 40px; align-items: center; padding: 40px 0; border-top: 1px solid var(--line); }
.app-row:nth-of-type(even) .app-copy { order: 2; }
.app-copy .icon { width: 72px; height: 72px; border-radius: 18px; box-shadow: 0 6px 24px rgba(0,0,0,.12); display: block; }
.app-copy .tag { display: block; margin-top: 18px; color: var(--accent); font-weight: 600; font-size: .9rem; }
.app-copy h3 { color: var(--ink); font-size: 1.9rem; letter-spacing: -.02em; margin: 4px 0 10px; }
.app-copy p { color: var(--muted); font-size: 1.05rem; margin: 0 0 16px; }
.app-copy .links { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin-top: 18px; font-size: .92rem; }
.app-copy .links a { text-decoration: none; font-weight: 500; }
.pill { display: inline-block; font-size: .8rem; font-weight: 600; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; margin-top: 8px; }
.btn.small { padding: 9px 16px; font-size: .92rem; }
.app-shots { display: flex; gap: 14px; justify-content: center; }
.app-shots img { width: 31%; border-radius: 18px; border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(0,0,0,.10); background: #000; }
.app-row.wide .app-shots { display: grid; grid-template-columns: 1fr 1fr; }
.app-row.wide .app-shots img { width: 100%; border-radius: 14px; }
.app-row.wide .app-shots img:first-child { grid-column: 1 / -1; }
@media (max-width: 860px) {
  .app-row { grid-template-columns: 1fr; gap: 24px; }
  .app-row:nth-of-type(even) .app-copy { order: 0; }
}

/* ---- brand kit + contact ---- */
.brand-box { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 32px; }
.brand-box h2 { color: var(--ink); margin: 0; font-size: 1.4rem; }
.brand-box p { color: var(--muted); margin: 6px 0 0; }
.contact-box .mail { color: #fff; font-weight: 600; font-size: 1.15rem; margin-top: 14px; }
.brandkit { padding-bottom: 0; }

/* ---- inner pages ---- */
.page-h { color: var(--ink); font-size: clamp(2rem, 4.5vw, 2.8rem); letter-spacing: -.02em; margin: 0; }
.lead { color: var(--muted); font-size: 1.15rem; max-width: 42em; }
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.gallery img { width: 100%; border-radius: 16px; border: 1px solid var(--line); background: #000; }
.gallery.wide { grid-template-columns: 1fr 1fr; }
@media (max-width: 760px) { .gallery { grid-template-columns: 1fr 1fr; } .gallery.wide { grid-template-columns: 1fr; } }
.card h3 { margin-top: 0; }
.kit-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; margin-top: 28px; }
.kit { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: var(--surface); }
.kit-img { height: 150px; display: flex; align-items: center; justify-content: center; padding: 24px; }
.kit.light .kit-img { background: #F7F6F3; }
.kit.dark .kit-img { background: #07080D; }
.kit-img img { max-height: 100%; max-width: 100%; }
.kit-meta { display: flex; justify-content: space-between; gap: 12px; padding: 12px 16px; font-size: .9rem; border-top: 1px solid var(--line); }
.kit-meta a { text-decoration: none; font-weight: 600; white-space: nowrap; }
.swatches { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.sw i { display: block; height: 72px; border-radius: 12px; border: 1px solid var(--line); }
.sw b { display: block; color: var(--ink); margin-top: 8px; }
.sw span { color: var(--muted); font-size: .88rem; }
.nav .lang { border: 1px solid var(--line); border-radius: 999px; padding: 2px 10px; }
@media (max-width: 560px) { .nav a:not(.lang):nth-child(1) { display: none; } }

/* ---- fixes ---- */
img.logo-dark { display: none !important; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) img.logo-light { display: none !important; }
  :root:not([data-theme="light"]) img.logo-dark { display: block !important; }
}
.app-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); }
.app-row > * { min-width: 0; }
.app-shots img { flex: 1 1 0; min-width: 0; width: auto; }
@media (max-width: 860px) { .app-row { grid-template-columns: minmax(0, 1fr); } }
.legal section { padding: 0; }
