/* =========================================================
   ForBrain UI — Premium Mobile (drop-in full CSS)
   ========================================================= */

/* =========================
   Reset / Base
   ========================= */

* { box-sizing: border-box; }

html, body { height: 100%; }

body{
  margin:0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;

  /* Premium readability */
  font-size:16px;
  line-height:1.5;
  -webkit-text-size-adjust:100%;
  text-rendering: optimizeLegibility;

  color: rgba(242,246,255,.94);

  background:
    radial-gradient(1100px 700px at 18% -12%, rgba(59,130,246,.28), transparent 62%),
    radial-gradient(1000px 560px at 86% 0%, rgba(99,102,241,.20), transparent 62%),
    linear-gradient(180deg, #070A12, #0A0F1D);

  overflow-x:hidden;
}

img{ max-width:100%; display:block; }

/* =========================
   Layout
   ========================= */

.container{
  width:min(760px, calc(100% - 32px));
  margin: 34px auto 60px;
}

.spacer{ height:14px; }

.row{
  display:flex;
  gap:12px;
  align-items:center;
}

.row.space{
  justify-content:space-between;
}

/* =========================
   Card
   ========================= */

.card{
  border-radius:22px;
  padding:20px;

  background: rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.12);

  box-shadow:
    0 28px 78px rgba(0,0,0,.58),
    0 0 0 1px rgba(255,255,255,.07) inset;

  backdrop-filter: blur(12px);
}

/* =========================
   Typography
   ========================= */

h1{
  font-size: clamp(28px, 3.8vw, 38px);
  margin:0 0 12px;
  line-height:1.16;
  letter-spacing:-0.01em;
}

h2{
  font-size: clamp(19px, 2.35vw, 23px);
  margin: 10px 0 16px;
  line-height:1.35;
  font-weight:650;
  letter-spacing:-0.005em;
}

h3{
  margin:0 0 10px;
  font-size:18px;
  font-weight:650;
}

p{
  margin:0 0 10px;
  font-size:16px;
  line-height:1.6;
  color: rgba(242,246,255,.86);
}

.small{
  font-size:14px;
  line-height:1.45;
  color: rgba(242,246,255,.68);
}

/* =========================
   Progress
   ========================= */

.progress{
  height:10px;
  border-radius:999px;
  background: rgba(255,255,255,.07);
  overflow:hidden;
}

.progress > div{
  height:100%;
  width:0%;
  background: linear-gradient(90deg,#3B82F6,#6366F1);
  transition: width .28s ease;
}

/* =========================
   Options
   ========================= */

.option{
  padding:14px 14px;
  border-radius:16px;

  background: rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.12);

  cursor:pointer;
  transition:.15s;

  font-size:16px;
  line-height:1.4;
}

.option + .option{ margin-top:10px; }

.option:hover{
  border-color: rgba(59,130,246,.30);
}

.option.selected{
  border-color: rgba(59,130,246,.62);
  background: rgba(59,130,246,.18);
}

/* =========================
   Buttons
   ========================= */

.btn{
  border-radius:14px;
  padding:13px 16px;

  min-height:44px; /* iOS tap area */
  font-size:16px;
  font-weight:600;

  border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.07);
  color:rgba(242,246,255,.94);

  cursor:pointer;
  transition:.15s;
}

.btn:disabled{
  opacity:.45;
  cursor:not-allowed;
}

.btn.primary{
  background: linear-gradient(135deg,#3B82F6,#6366F1);
  border:none;
  color:#fff;
  font-weight:700;
}

/* =========================
   Input
   ========================= */

.input{
  width:100%;
  padding:14px;

  min-height:44px;
  font-size:16px;

  border-radius:14px;
  background: rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.14);
  color:#fff;
}

/* =========================
   FINAL SCREEN
   ========================= */

.finalPromo{
  padding:16px;
  border-radius:18px;
  background: rgba(59,130,246,.12);
  border:1px solid rgba(59,130,246,.40);
}

.finalModules{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
  margin-top:10px;
}

.finalModule{
  padding:12px;
  border-radius:14px;
  background: rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.12);
  font-size:14px;
  color: rgba(242,246,255,.86);
}

.finalChoices{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin-top:12px;
}

.finalChoice{
  padding:14px;
  border-radius:16px;

  border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.05);

  cursor:pointer;
  min-height:44px;
}

.finalChoice.selected{
  background: rgba(59,130,246,.18);
  border-color: rgba(59,130,246,.62);
}

/* =========================
   GATE (Play Screen)
   ========================= */

.gate{
  min-height:100vh;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#000;
  position:relative;
}

.gateVideo{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
}

.gateShade{
  position:absolute;
  inset:0;
  background: radial-gradient(circle at 50% 40%, rgba(0,0,0,.18), rgba(0,0,0,.82));
}

.gateCenter{
  position:relative;
  z-index:2;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:18px;
}

.playBtn{
  width:92px;
  height:92px;
  border-radius:50%;
  border:2px solid rgba(255,255,255,.45);
  background:rgba(0,0,0,.42);
  color:#fff;
  font-size:34px;
  cursor:pointer;
}

/* =========================
   Responsive
   ========================= */

/* Tablet */
@media (max-width:900px){
  .container{ width:calc(100% - 40px); }
}

/* Mobile */
@media (max-width:600px){
  .container{
    width:calc(100% - 24px);
    margin:18px auto 34px;
  }

  .card{
    padding:18px;
    border-radius:18px;
  }

  h1{
    font-size:24px;
    line-height:1.15;
  }

  h2{ font-size:20px; }

  .btn{
    padding:13px 14px;
  }

  .finalModules{ grid-template-columns:1fr; }
  .finalChoices{ grid-template-columns:1fr; }
}

/* Telegram / very small */
@media (max-width:380px){
  h1{ font-size:22px; }
  .btn{ font-size:15px; }
  .option{ font-size:15px; }
  .small{ font-size:13px; }
}