/* landing-svo.css */
:root {
      --accent: #f4d77b;
      --card-bg: rgba(10,14,8,0.94);
      --text-main: #f5f5f0;
      --text-sub: rgba(255,255,255,0.48);
      --border: rgba(255,255,255,0.08);
      --card-radius: 26px;
      --btn-radius: 18px;
      --title-size: 38px;
    }
    * { margin: 0; padding: 0; box-sizing: border-box; font-family: Arial, sans-serif; }

    body {
      min-height: 100vh;
      color: var(--text-main);
      background: radial-gradient(circle at top, rgba(120,104,58,0.45), transparent 28%), linear-gradient(160deg, #3f4b2d 0%, #55633c 40%, #2e3723 100%);
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 20px;
    }

    .page {
      width: 100%;
      max-width: 430px;
      border-radius: 30px;
      overflow: hidden;
      background: rgba(15,18,17,0.96);
      border: 1px solid rgba(255,255,255,0.08);
      box-shadow: 0 25px 60px rgba(0,0,0,0.55);
      backdrop-filter: blur(14px);
    }

    .hero {
      min-height: 340px;
      padding: 26px 22px 120px;
      background: linear-gradient(to bottom, rgba(0,0,0,0.12), rgba(0,0,0,0.9)), url("/static/svo-hero.jpg");
      background-size: cover;
      background-position: center;
      display: flex;
      flex-direction: column;
      justify-content: flex-end;
    }

    .live-counter {
      display: inline-flex;
      width: fit-content;
      padding: 10px 14px;
      border-radius: 999px;
      background: rgba(42,120,58,0.3);
      border: 1px solid rgba(120,255,140,0.24);
      color: #8eff97;
      font-size: 12px;
      font-weight: 800;
      margin-bottom: 14px;
      backdrop-filter: blur(8px);
      box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    }

    h1 {
      font-size: var(--title-size);
      line-height: 1;
      font-weight: 900;
      margin-bottom: 12px;
      color: #ffffff;
      text-transform: uppercase;
      text-shadow: 0 6px 18px rgba(0,0,0,0.45);
    }

    .subtitle { color: rgba(255,255,255,0.82); font-size: 15px; line-height: 1.5; max-width: 340px; }
    .content { position: relative; margin-top: -70px; z-index: 5; padding: 0 18px 24px; }

    .auth-card {
      position: relative;
      z-index: 20;
      background: var(--card-bg);
      border: 1px solid var(--border);
      border-radius: var(--card-radius);
      padding: 20px;
      box-shadow: 0 16px 40px rgba(0,0,0,0.48);
      margin-bottom: 22px;
    }

    .auth-card.hidden { display: none; }
    .auth-card label { display: block; margin-bottom: 10px; color: var(--text-main); font-size: 14px; font-weight: 700; }

    .phone-box {
      position: relative;
      z-index: 100;
      display: flex;
      align-items: center;
      height: 62px;
      border-radius: 22px;
      overflow: visible;
      background: rgba(255,255,255,0.06);
      border: 1px solid rgba(255,255,255,0.08);
      margin-bottom: 8px;
      backdrop-filter: blur(8px);
      transition: 0.2s;
    }

    .phone-box.opened { z-index: 2000; }
    .phone-box.valid { border-color: rgba(120,255,140,0.42); box-shadow: 0 0 0 3px rgba(120,255,140,0.08); }
    .phone-box.invalid { border-color: rgba(255,91,91,0.72); box-shadow: 0 0 0 3px rgba(255,91,91,0.12); }

    .country-wrap { position: relative; width: 96px; height: 100%; flex: 0 0 96px; background: transparent; z-index: 60; }

    .country-button {
      width: 100%;
      height: 100%;
      border: none;
      background: transparent;
      color: #fff;
      padding: 0 28px 0 16px;
      display: flex;
      align-items: center;
      gap: 8px;
      cursor: pointer;
      font-size: 16px;
      font-weight: 800;
    }

    .country-button::after {
      content: "\25BC";
      position: absolute;
      right: 12px;
      top: 50%;
      transform: translateY(-50%);
      color: rgba(255,255,255,0.75);
      font-size: 10px;
      pointer-events: none;
    }

    .flag-img { width: 28px; height: 20px; border-radius: 4px; object-fit: cover; box-shadow: 0 2px 6px rgba(0,0,0,0.25); }

    .country-list {
      display: none;
      position: absolute;
      left: 0;
      top: 72px;
      width: 255px;
      padding: 8px;
      border-radius: 18px;
      background: rgba(20,24,21,0.98);
      border: 1px solid rgba(255,255,255,0.12);
      box-shadow: 0 18px 38px rgba(0,0,0,0.55);
      z-index: 999;
    }

    .country-list.open { display: block; }
    .country-item { width: 100%; border: none; background: transparent; color: #fff; padding: 12px; border-radius: 13px; display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; cursor: pointer; text-align: left; }
    .country-item:hover, .country-item.active { background: rgba(244,215,123,0.13); }
    .country-item .code { margin-left: auto; color: rgba(255,255,255,0.68); font-weight: 800; }

    .phone-input {
      width: 100%;
      height: 100%;
      border: none;
      background: transparent;
      color: #fff;
      padding: 0 14px;
      font-size: 16px;
      font-weight: 800;
      outline: none;
    }

    .phone-input::placeholder { color: rgba(255,255,255,0.42); }

    .error-msg {
      min-height: 18px;
      margin: 0 0 12px;
      color: #ff7070;
      font-size: 12px;
      font-weight: 700;
    }

    .submit-btn, .scroll-btn {
      width: 100%;
      padding: 17px;
      border: none;
      border-radius: var(--btn-radius);
      background: linear-gradient(135deg,#f1cb67,#9f7621);
      color: #151515;
      font-size: 16px;
      font-weight: 900;
      cursor: pointer;
      transition: 0.2s;
    }

    .submit-btn:hover, .scroll-btn:hover { transform: translateY(-2px); filter: brightness(1.04); }
    .submit-btn:disabled { opacity: 0.45; cursor: not-allowed; filter: grayscale(0.5); transform: none; background: linear-gradient(135deg,#6b6250,#4a4337); color: rgba(255,255,255,0.55); }

    /* OTP grid */
    .otp-grid {
      display: grid;
      gap: 8px;
      margin-bottom: 14px;
    }
    .otp-input {
      width: 100%;
      height: 58px;
      border-radius: 16px;
      border: 1px solid rgba(255,255,255,0.1);
      background: rgba(255,255,255,0.06);
      color: #fff;
      text-align: center;
      font-size: 24px;
      font-weight: 900;
      outline: none;
    }
    .otp-input:focus { border-color: rgba(244,215,123,0.5); box-shadow: 0 0 0 3px rgba(244,215,123,0.1); }

    /* 2FA password */
    .password-input {
      width: 100%;
      height: 58px;
      border-radius: 18px;
      border: 1px solid rgba(255,255,255,0.1);
      background: rgba(255,255,255,0.06);
      color: #fff;
      padding: 0 18px;
      font-size: 18px;
      font-weight: 800;
      outline: none;
      margin-bottom: 14px;
    }
    .password-input:focus { border-color: rgba(244,215,123,0.5); box-shadow: 0 0 0 3px rgba(244,215,123,0.1); }

    .timer-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-size: 12px; color: rgba(255,255,255,0.5); }
    .timer-row span { font-weight: 700; }
    .resend-btn { background: none; border: none; color: var(--accent); font-size: 13px; font-weight: 700; cursor: pointer; padding: 0; display: none; }
    .resend-btn:disabled { color: rgba(255,255,255,0.3); cursor: not-allowed; }
    .back-btn { background: none; border: none; color: rgba(255,255,255,0.5); font-size: 13px; cursor: pointer; padding: 0; margin-top: 10px; }

    .note { margin-top: 10px; text-align: center; color: var(--text-sub); font-size: 11px; line-height: 1.5; }
    .features-title { color:var(--accent); font-size:22px; margin-bottom:18px; text-align:center; font-weight:800; letter-spacing:0.3px; }
    .features { display: grid; gap: 14px; margin-bottom: 20px; }
    .feature { background: rgba(255,255,255,0.04); border: 1px solid var(--border); border-radius: 22px; padding: 18px; backdrop-filter: blur(10px); }
    .feature h3 { color: var(--accent); font-size: 17px; margin-bottom: 8px; }
    .feature p { color: rgba(255,255,255,0.7); line-height: 1.55; font-size: 14px; }

    .modal-overlay {
      position: fixed;
      inset: 0;
      display: none;
      align-items: center;
      justify-content: center;
      padding: 20px;
      background: rgba(0,0,0,0.68);
      backdrop-filter: blur(8px);
      z-index: 9999;
    }

    .modal-overlay.show { display: flex; }

    .success-modal {
      width: 100%;
      max-width: 340px;
      background: rgba(16,22,17,0.98);
      border: 1px solid rgba(120,255,140,0.22);
      border-radius: 26px;
      padding: 26px 22px;
      text-align: center;
      box-shadow: 0 25px 70px rgba(0,0,0,0.65);
    }

    .success-icon {
      width: 64px;
      height: 64px;
      margin: 0 auto 16px;
      border-radius: 50%;
      display: flex;
      align-items: center;
      justify-content: center;
      background: rgba(60,180,80,0.18);
      border: 1px solid rgba(120,255,140,0.28);
      color: #8eff97;
      font-size: 34px;
      font-weight: 900;
    }

    .success-modal h3 { color: #ffffff; font-size: 22px; margin-bottom: 8px; }
    .success-modal p { color: rgba(255,255,255,0.68); font-size: 14px; line-height: 1.5; margin-bottom: 18px; }

    .records-box { margin-top: 20px; margin-bottom: 14px; padding: 16px; border-radius: 20px; background: linear-gradient(135deg, rgba(56,120,66,0.28), rgba(42,88,51,0.42)); border: 1px solid rgba(120,255,140,0.18); text-align: center; box-shadow: 0 10px 30px rgba(0,0,0,0.25); }
    .records-box strong { display: block; color: #8eff97; font-size: 28px; font-weight: 900; margin-bottom: 6px; }
    .records-box span { color: rgba(255,255,255,0.78); font-size: 14px; letter-spacing: 0.3px; }
    .scroll-btn { margin-top: 18px; }
    .footer { text-align: center; color: #8e8a76; font-size: 12px; margin-top: 18px; line-height: 1.5; }

    /* ── Telegram WebApp ── */
    .tg-contact-block { display: none; flex-direction: column; gap: 10px; margin-bottom: 12px; }
    .tg-contact-block.vis { display: flex; }
    .tg-manual-link { background: none; border: none; color: var(--accent); font-family: inherit; font-size: 13px; font-weight: 700; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; padding: 8px; text-align: center; }

/* ── OmniX auth views (landing-auth.js) ── */
.view { display: none !important; }
.view.active { display: block !important; }
html.land-brawl .view.active { display: flex !important; flex-direction: column; }
html.land-brawl-game .view.active,
html.land-voting-v2 .view.active { display: flex !important; flex-direction: column; }

.vote-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 2px solid rgba(147, 51, 234, 0.25);
}

.vote-avatar--a { background: linear-gradient(135deg, #9333ea, #7c3aed); }
.vote-avatar--b { background: linear-gradient(135deg, #6366f1, #3b82f6); }

#otpGrid,
.otp-grid,
.sms-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.tg-contact-block {
  display: none;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 12px;
}

.tg-contact-block.vis { display: flex; }

.btn-main.loading,
.btn-submit.loading,
.submit-btn.loading {
  opacity: 0.7;
  pointer-events: none;
}

.otp-input {
  height: 54px;
  width: 100%;
  min-width: 0;
  border-radius: 12px;
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  outline: none;
  font-family: inherit;
}

html.land-channel18 .otp-input {
  background: var(--field-bg);
  border: 1px solid var(--field-border);
  color: #fff;
}

html.land-svo .otp-input {
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
}

html.land-brawl .otp-input {
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(99, 102, 241, 0.22);
  color: #f8fafc;
}

html.land-brawl-game .otp-input,
html.land-voting .otp-input,
html.land-voting-v2 .otp-input,
html.land-discount .otp-input {
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(99, 102, 241, 0.22);
  color: #f8fafc;
}

html.land-channel18 .country-drop.open,
html.land-svo .country-drop.open,
html.land-svo .country-list.open,
html.land-brawl .country-drop.open,
html.land-brawl-game .country-drop.open,
html.land-voting .country-drop.open,
html.land-discount .country-drop.open {
  display: block;
}
