* { box-sizing: border-box; }

:root {
  --bg: #0b1020;
  --panel: rgba(17, 24, 39, .82);
  --panel-strong: #111827;
  --text: #f8fafc;
  --muted: #a9b4c7;
  --line: rgba(148, 163, 184, .22);
  --accent: #7aa2ff;
  --accent-2: #8ff0d2;
  --shadow: 0 24px 80px rgba(0, 0, 0, .34);
}

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 20% 0%, rgba(122, 162, 255, .24), transparent 34rem),
    radial-gradient(circle at 90% 18%, rgba(143, 240, 210, .18), transparent 32rem),
    linear-gradient(180deg, #0b1020 0%, #0f172a 55%, #0b1020 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button, input, select { font: inherit; }
button { cursor: pointer; }

.install-banner {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 12px;
  align-items: center;
  padding: 12px max(14px, env(safe-area-inset-left)) 12px max(14px, env(safe-area-inset-right));
  background: rgba(15, 23, 42, .96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.install-banner p { margin: 2px 0 0; color: var(--muted); font-size: .9rem; }

.hero { max-width: 1360px; margin: 0 auto; padding: 22px 22px 28px; }

.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 18px; margin-bottom: 52px;
}

.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--text); text-decoration: none; }
.brand img { width: 46px; height: 46px; border-radius: 12px; box-shadow: 0 12px 36px rgba(122, 162, 255, .22); }
.brand strong { display: block; font-size: 1.05rem; letter-spacing: .01em; }
.brand small { display: block; color: var(--muted); margin-top: 2px; }

.top-actions { display: flex; gap: 8px; }

.pill {
  border: 1px solid var(--line); background: rgba(15, 23, 42, .7);
  color: var(--text); border-radius: 999px; padding: 8px 12px;
}

.pill.active {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #07111e; border-color: transparent; font-weight: 800;
}

.hero-grid {
  display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(280px, .7fr);
  gap: 34px; align-items: center;
}

.eyebrow {
  color: var(--accent-2); font-weight: 800; letter-spacing: .12em;
  text-transform: uppercase; font-size: .78rem;
}

h1 {
  margin: 0; font-size: clamp(2.2rem, 4vw, 5rem); line-height: .98;
  letter-spacing: -.06em; max-width: 980px;
}

.lead {
  color: var(--muted); font-size: 1.16rem; line-height: 1.65;
  max-width: 780px; margin: 24px 0 0;
}

.privacy-badge {
  display: flex; align-items: center; gap: 12px; max-width: 820px;
  margin-top: 24px; padding: 14px 16px; border: 1px solid rgba(143, 240, 210, .32);
  background: rgba(20, 184, 166, .10); border-radius: 18px;
}

.privacy-badge span {
  display: inline-flex; width: 30px; height: 30px; align-items: center; justify-content: center;
  background: rgba(143, 240, 210, .18); border-radius: 999px; color: var(--accent-2);
  font-weight: 900; flex: 0 0 auto;
}

.privacy-badge p { margin: 0; color: #d7fff5; }

.hero-card {
  min-height: 310px; border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(30, 41, 59, .72), rgba(15, 23, 42, .64));
  border-radius: 32px; padding: 28px; box-shadow: var(--shadow);
  display: grid; place-items: center; text-align: center;
}

.mini-phone {
  width: 130px; aspect-ratio: 9 / 20; padding: 8px; background: #050816;
  border-radius: 28px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), 0 24px 60px rgba(0,0,0,.36);
}

.mini-phone div {
  height: 100%; border-radius: 22px;
  background:
    radial-gradient(circle at 65% 22%, rgba(255,255,255,.8), transparent 8px),
    linear-gradient(155deg, #7aa2ff, #111827 44%, #8ff0d2);
}

.hero-card p { color: var(--muted); margin: 18px 0 0; }

.app-shell {
  max-width: 1360px; margin: 0 auto; padding: 24px 22px 60px;
  display: grid; grid-template-columns: 380px minmax(320px, 1fr) 360px;
  gap: 22px; align-items: start;
}

.panel {
  border: 1px solid var(--line); background: var(--panel); backdrop-filter: blur(18px);
  border-radius: 28px; padding: 20px; box-shadow: var(--shadow);
}

.panel h2 { font-size: 1.02rem; margin: 22px 0 12px; }
.panel h2:first-child { margin-top: 0; }

.drop-zone {
  position: relative; display: grid; place-items: center; min-height: 140px;
  border: 1.5px dashed rgba(122, 162, 255, .55);
  background: rgba(122, 162, 255, .08); border-radius: 22px;
  text-align: center; padding: 18px; transition: .2s ease;
}

.drop-zone.drag-over { background: rgba(143, 240, 210, .12); border-color: var(--accent-2); transform: translateY(-2px); }
.drop-zone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.drop-zone strong { display: block; font-size: 1rem; }
.drop-zone span { display: block; margin-top: 7px; color: var(--muted); }

.auto-card {
  display: flex; gap: 13px; align-items: flex-start; padding: 16px; border-radius: 22px;
  border: 1px solid rgba(143, 240, 210, .28);
  background: linear-gradient(135deg, rgba(143, 240, 210, .10), rgba(122, 162, 255, .08));
  margin-bottom: 12px;
}

.auto-icon {
  width: 42px; height: 42px; border-radius: 15px; display: grid; place-items: center;
  background: rgba(143, 240, 210, .14); color: var(--accent-2);
  font-weight: 900; font-size: 1.35rem; flex: 0 0 auto;
}

.auto-card strong { display: block; margin-bottom: 4px; }

.advanced, .details-row {
  margin-top: 14px; border: 1px solid var(--line); border-radius: 18px;
  background: rgba(2, 6, 23, .30); overflow: hidden;
}

.advanced summary, .details-row summary {
  cursor: pointer; padding: 13px 14px; font-weight: 900; color: #dbeafe;
}

.advanced-inner { padding: 0 14px 14px; }
.details-row { margin: 8px 0 16px; }
.details-row details[open] { padding-bottom: 8px; }
.details-row .slider-field { padding: 0 14px; }

.tabs {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 7px; margin: 14px 0;
  padding: 5px; border-radius: 16px; background: rgba(2, 6, 23, .42); border: 1px solid var(--line);
}

.tab-btn {
  border: none; border-radius: 12px; padding: 10px 8px;
  background: transparent; color: var(--muted); font-weight: 800;
}

.tab-btn.active {
  background: linear-gradient(135deg, rgba(122, 162, 255, .95), rgba(143, 240, 210, .95));
  color: #07111e;
}

.tab-panel { display: none; }
.tab-panel.active { display: block; }

.field { display: grid; gap: 7px; margin: 12px 0; }

.field span, .slider-field span, .toggle-row span {
  color: #dbeafe; font-weight: 700; font-size: .9rem;
}

input[type="text"], input[type="number"], select {
  width: 100%; border: 1px solid var(--line); background: rgba(2, 6, 23, .78);
  color: var(--text); border-radius: 14px; padding: 12px 12px; outline: none;
}

select.device-list { min-height: 180px; padding: 8px; }
select.device-list option { padding: 8px 9px; border-radius: 8px; }

input[type="text"]:focus, input[type="number"]:focus, select:focus {
  border-color: rgba(122, 162, 255, .78);
  box-shadow: 0 0 0 4px rgba(122, 162, 255, .12);
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.slider-field { margin: 16px 0; }
.slider-field div { display: flex; justify-content: space-between; gap: 14px; margin-bottom: 8px; }
.slider-field b { color: var(--accent-2); font-size: .88rem; }

input[type="range"] {
  width: 100%; accent-color: var(--accent); min-height: 32px;
}

.toggle-row {
  display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 10px;
  margin: 12px 0 14px; padding: 12px; border: 1px solid var(--line);
  border-radius: 16px; background: rgba(2, 6, 23, .24);
}

.toggle-row input { width: 20px; height: 20px; accent-color: var(--accent); }

.buttons-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.primary, .secondary, .ghost {
  border: none; border-radius: 16px; padding: 13px 14px; font-weight: 900;
}

.primary {
  width: 100%; background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #07111e; box-shadow: 0 16px 40px rgba(122, 162, 255, .22);
}

.secondary {
  background: rgba(148, 163, 184, .12); color: var(--text); border: 1px solid var(--line);
}

.ghost { background: transparent; color: var(--muted); border: 1px solid var(--line); }
.small { padding: 9px 12px; border-radius: 12px; width: auto; }

.download-main {
  min-height: 56px; font-size: 1.05rem;
}

.muted { color: var(--muted); font-size: .92rem; line-height: 1.5; }
.center { text-align: center; }

.ready-info {
  margin: 0; color: #d7fff5; background: rgba(20, 184, 166, .13);
  border: 1px solid rgba(143, 240, 210, .25); padding: 10px 14px; border-radius: 14px;
}

.preview-panel {
  display: grid; justify-items: center; gap: 12px; min-height: 700px;
}

.phone-frame {
  position: sticky; top: 18px; width: min(100%, 410px); aspect-ratio: 1080 / 2408;
  background: #050816; border-radius: 46px; padding: 13px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.15), 0 38px 100px rgba(0,0,0,.55);
}

.phone-frame canvas {
  display: block; width: 100%; height: 100%;
  border-radius: 34px; background: #111827;
}

.phone-notch {
  position: absolute; top: 25px; left: 50%; transform: translateX(-50%);
  width: 92px; height: 14px; border-radius: 999px;
  background: rgba(0,0,0,.72); z-index: 3;
}

.safe-zone {
  position: absolute; left: 26px; right: 26px; z-index: 4;
  border: 1px dashed rgba(255,255,255,.42);
  background: rgba(15, 23, 42, .20);
  color: rgba(255,255,255,.78); font-size: .72rem;
  display: none; align-items: center; justify-content: center;
  pointer-events: none; text-transform: uppercase; letter-spacing: .08em;
}

.show-safe-zones .safe-zone { display: flex; }
.top-zone { top: 42px; height: 12%; border-radius: 24px 24px 8px 8px; }
.bottom-zone { bottom: 26px; height: 9%; border-radius: 8px 8px 24px 24px; }

.note, .brand-note {
  margin-top: 18px; border: 1px solid var(--line);
  background: rgba(2, 6, 23, .36); border-radius: 18px; padding: 15px;
}

.note.soft { background: rgba(122, 162, 255, .07); }
.note p, .brand-note p { color: var(--muted); margin-bottom: 0; line-height: 1.55; }
.brand-note a { display: inline-block; margin-top: 9px; color: var(--accent-2); font-weight: 800; text-decoration: none; }

.seo-section {
  max-width: 1360px; margin: 0 auto 48px; padding: 0 22px;
}

.seo-section h2 { font-size: clamp(1.7rem, 3vw, 3rem); letter-spacing: -.04em; }

.faq-list {
  display: grid; gap: 12px;
}

.faq-list details {
  border: 1px solid var(--line); background: rgba(17, 24, 39, .58);
  border-radius: 20px; padding: 0;
}

.faq-list summary {
  cursor: pointer; padding: 16px 18px; font-weight: 900;
}

.faq-list p {
  color: var(--muted); line-height: 1.65; margin: 0; padding: 0 18px 18px;
}

.privacy-section p {
  color: var(--muted); font-size: 1.05rem; line-height: 1.75;
  border: 1px solid var(--line); background: rgba(17, 24, 39, .58);
  border-radius: 24px; padding: 20px;
}

footer { color: var(--muted); text-align: center; padding: 36px 18px 48px; }

@media (max-width: 1180px) {
  .app-shell { grid-template-columns: 1fr; }
  .controls-panel, .export-panel { max-width: 760px; width: 100%; justify-self: center; }
  .phone-frame { position: relative; top: 0; max-height: 78vh; width: min(100%, 350px); }
  .hero-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .hero { padding: 16px 14px 24px; }
  .topbar { margin-bottom: 34px; }
  .brand small { display: none; }
  .app-shell { padding: 10px 12px 42px; }
  .panel { padding: 16px; border-radius: 22px; }
  .grid-2, .buttons-row, .tabs { grid-template-columns: 1fr; }
  h1 { font-size: clamp(2rem, 13vw, 3rem); }
  select.device-list { min-height: 220px; }
  input[type="range"] { min-height: 42px; }
  .primary, .secondary { min-height: 48px; }
  .phone-frame { width: min(100%, 318px); }
  .install-banner { grid-template-columns: 1fr auto auto; }
  .install-banner p { display: none; }
}
