/* =========================================================
   SimReg UI — CLEAN + BRANDING
   - Один источник правды по кнопкам/инпутам/контейнерам
   - Brand vars: --brand-main / --brand-rgb / --brand-on
   - Mobile headers: без absolute (чтобы не уезжало)
   ========================================================= */

/* ---------- Tokens ---------- */
:root{
  /* base */
  --beeline-yellow: #ffd100;
  --beeline-black:#0B0B0B;
  --beeline-gray:#F5F5F7;

  /* ✅ brand (меняется из JS) */
  --brand-main: var(--beeline-yellow);
  --brand-rgb: 255,209,0;       /* формат: "r,g,b" */
  --brand-on: #111111;          /* ✅ цвет текста на бренд-кнопке */

  /* ui */
  --text:#111827;
  --muted:#6B7280;
  --border:rgba(17,24,39,.10);
  --shadow:0 18px 45px rgba(0,0,0,.08);
  --shadow-sm:0 10px 25px rgba(0,0,0,.06);

  --radius:20px;
  --radius-sm:14px;

  --focus:0 0 0 4px rgba(var(--brand-rgb), .35);

  --btn-h:46px;
  --btn-font: 600 15px/1.15 "Roboto", system-ui, -apple-system, Segoe UI, Arial, sans-serif;

  --font: "Inter", "Roboto", system-ui, -apple-system, Segoe UI, Arial, sans-serif;
}

*{ box-sizing:border-box; }
html,body{ height:100%; }
html,body{ width:100%; overflow-x:hidden; }

body{
  margin:0;
  font-family:var(--font);
  color:var(--text);
  background: var(--beeline-gray);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height:1.45;
}



/* ---------- Typography ---------- */
h1{
  margin: 4px 0 6px;
  font-size: 26px;
  letter-spacing: -0.02em;
  text-align:center;
  color:var(--beeline-black);
}
h2{
  margin: 6px 0;
  font-size: 15px;
  font-weight: 500;
  text-align:center;
  color: var(--muted);
}
p{ margin: 10px 0; color: var(--text); }
a{ color:#0A66C2; text-decoration:none; }
a:hover{ text-decoration:underline; }
strong{ color:#111; }

.mono{
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  color: #0A66C2;
  font-weight: 700;
}

/* ---------- Page / Container ---------- */
.page{
  min-height: 100vh;
  background: var(--beeline-gray);
  padding: 28px 16px;
}

.container{
  width: min(860px, calc(100% - 32px));
  margin: 28px auto;
  padding: 22px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
}

/* ---------- Headers (logo + titles) ---------- */
.consent-header,
.form-header,
.success-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;
  min-height: 56px;
  margin-bottom: 14px;
}

.consent-logo,
.form-logo,
.success-logo{
  height: 40px;
  width:auto;
  opacity: 1;
  filter:none;
  margin:0;
}

.consent-titles,
.form-titles,
.success-titles{
  flex: 1 1 auto;
  text-align:center;
}

.consent-header,
.form-header,
.success-header{
  position: relative;
  display: flex;
  align-items: center;
  min-height: 48px;
}

/* логотип слева */
.consent-logo,
.form-logo,
.success-logo{
  height: 40px;
  width: auto;
  position: absolute;
  left: 0;
}

/* заголовки всегда по центру */
.consent-titles,
.form-titles,
.success-titles{
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  width: 100%;
  pointer-events: none; /* чтобы не мешали кликам */
}


.consent-titles h1,
.form-titles h1{
  margin: 0;
  font-size: 26px;
  letter-spacing: -0.02em;
  color: var(--beeline-black);
}
.consent-titles h2{
  margin: 4px 0 0;
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
}

.success-titles .page-title{
  margin: 0;
  font-size: 26px;
  line-height: 1.15;
  color: var(--beeline-black);
  letter-spacing: -0.2px;
}

/* ---------- Consent ---------- */
.consent-box{
  padding: 6px;
  text-align:center;
}
.consent-text{
  text-align:left;
  margin: 14px 0 18px;
  padding: 14px;
  border-radius: var(--radius);
  background: rgba(0,0,0,.03);
  border: 1px solid var(--border);
  color: var(--text);
}
.consent-text p{
  margin: 10px 0;
  color: #374151;
  font-size: 14px;
}

/* ---------- Notices / Warnings ---------- */
.notice{
  border-radius: var(--radius);
  padding: 14px 16px;
  margin: 14px 0 18px;
  border: 1px solid #eaeaea;
  background: #fff;
  box-shadow: 0 8px 24px rgba(0,0,0,.06);
}
.notice.warning{
  border-color: rgba(var(--brand-rgb), .55);
  background: linear-gradient(180deg, rgba(var(--brand-rgb), .18), rgba(var(--brand-rgb), .06));
}
.notice-warn{
  background: #fffaf0;
  border-color: rgba(var(--brand-rgb),0.35);
}

.form-warning{
  margin: 12px 0 18px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: rgba(var(--brand-rgb),.15);
  border: 1px solid rgba(var(--brand-rgb),.5);
  font-size: 14px;
  line-height: 1.45;
}

.form-warning-2{
  margin: 12px 0 18px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: rgba(220, 38, 38, 0.12);
  border: 1px solid rgba(220, 38, 38, 0.55);
  color: #7f1d1d;
  font-size: 14px;
  line-height: 1.45;
}

.form-warning-3{
  margin: 12px 0 18px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: rgba(220, 38, 38, 0.12);
  border: 1px solid rgba(220, 38, 38, 0.55);
  color: #7f1d1d;
  font-size: 14px;
  line-height: 1.45;
}

.porting-warning{
  display:block;
  margin-top:6px;
  font-weight:800;
  color:#d32f2f;
  text-transform:uppercase;
  letter-spacing:0.4px;
}
.flow-card-warning {
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: #fff8e8;
  border: 1px solid rgba(255, 209, 0, 0.35);
  color: #8a6a00;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  text-transform: uppercase;
}

/* ---------- Form blocks ---------- */
.form-group{
  margin: 18px 0;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255,255,255,.72);
  box-shadow: 0 1px 0 rgba(0,0,0,.02);
}

label{
  display:block;
  margin-bottom: 10px;
  font-size: 14px;
  font-weight: 600;
  color: #111827;
}

.hint{
  font-weight: 500;
  color: var(--muted);
  font-size: 12px;
}
.hint2{
  font-weight: 500;
  color: #000;
  font-size: 12px;
}

/* ---------- Inputs ---------- */
.beeline-input,
input[type="tel"],
input[type="text"],
input[type="email"],
input[type="password"],
textarea,
select{
  width:100%;
  height: 44px;
  padding: 10px 12px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: #fff;
  font-size: 15px;
  outline: none;
  transition: box-shadow .18s ease, border-color .18s ease, transform .12s ease;
}

.beeline-input:hover,
input[type="tel"]:hover,
input[type="text"]:hover,
input[type="email"]:hover,
input[type="password"]:hover,
textarea:hover,
select:hover{
  border-color: rgba(17,24,39,.18);
}

.beeline-input:focus,
input[type="tel"]:focus,
input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
textarea:focus,
select:focus{
  border-color: rgba(var(--brand-rgb), .95);
  box-shadow: var(--focus);
}

/* hide native file input */
input[type="file"]{ display:none; }

/* Prefix + input (8970199 + хвост / +7 + номер) */
.inline-prefix{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:nowrap;
  width:100%;
}
.inline-prefix .prefix{
  white-space:nowrap;
  flex:0 0 auto;
  font-weight:800;
  color: var(--beeline-black);
}
.inline-prefix .beeline-input,
.inline-prefix input{
  flex:1 1 auto;
  min-width:0;
}

/* ---------- Buttons (single source of truth) ---------- */
.beeline-btn,
.file-upload-btn,
.btn{
  font: var(--btn-font);
  height: var(--btn-h);
  border-radius: var(--radius);
  padding: 0 16px;
  letter-spacing: -0.01em;

  border: 1px solid rgba(0,0,0,.08);
  cursor:pointer;
  user-select:none;

  display:flex;
  align-items:center;
  justify-content:center;
  gap: 10px;
  width:100%;

  transition: transform .12s ease, box-shadow .18s ease, background .18s ease, opacity .18s ease, border-color .18s ease, filter .18s ease;
}

.beeline-btn{
  background: var(--brand-main);
  color: var(--brand-on);              /* ✅ важно для Tele2 */
  box-shadow: 0 10px 20px rgba(var(--brand-rgb),.22);
  margin-top: 12px;
}
.beeline-btn:hover{
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(var(--brand-rgb),.28);
}
.beeline-btn:active{
  transform: translateY(0px);
  opacity: .95;
}

/* Secondary */
.beeline-btn.secondary{
  background: #fff;
  color: #111;
  box-shadow: var(--shadow-sm);
}
.beeline-btn.secondary:hover{
  box-shadow: 0 14px 30px rgba(0,0,0,.08);
}

/* File upload button (brand themed) */
.file-upload-btn{
  background: linear-gradient(180deg, rgba(var(--brand-rgb), .22), rgba(var(--brand-rgb), .08));
  color: #111;
  border: 1px solid rgba(0,0,0,.10);
  box-shadow: 0 10px 20px rgba(var(--brand-rgb),.22);
}
.file-upload-btn:hover{
  transform: translateY(-1px);
  filter: brightness(0.98);
  box-shadow: 0 14px 28px rgba(var(--brand-rgb),.28);
}
.file-upload-btn:active{
  transform: translateY(0);
  opacity: .95;
}
.file-upload-btn:focus-visible{
  outline:none;
  box-shadow: 0 0 0 4px rgba(var(--brand-rgb), .35), 0 14px 28px rgba(var(--brand-rgb),.22);
}

/* .btn variants (keep, but brand-aware) */
.btn{
  text-decoration: none;
  border: 1px solid transparent;
  min-height: var(--btn-h);
}
.btn:active{ transform: translateY(1px); }

.btn-primary{
  background: var(--brand-main);       /* ✅ было beeline-yellow */
  color: var(--brand-on);              /* ✅ читабельно на Tele2 */
  box-shadow: 0 10px 20px rgba(var(--brand-rgb),0.20);
}
.btn-primary:hover{ filter: brightness(0.95); }

.btn-secondary{
  background: #fff;
  border-color: rgba(0,0,0,0.10);
  color: #111;
}
.btn-secondary:hover{ background: #fafafa; }

.btn-ghost{
  background: transparent;
  border-color: rgba(0,0,0,0.10);
  color: #111;
}
.btn-ghost:hover{ background: #f7f7f7; }

/* ---------- Preview ---------- */
.preview{
  margin-top: 12px;
  border-radius: var(--radius);
  border: 1px dashed rgba(17,24,39,.14);
  background: rgba(0,0,0,.02);
  min-height: 140px;
  padding: 12px;

  display:flex;
  align-items:center;
  justify-content:center;

  overflow:hidden;
  position: relative;
  color: #777;
}
.preview img{
  max-width:100%;
  max-height: 220px;
  border-radius: var(--radius);
  box-shadow: 0 8px 22px rgba(0,0,0,.08);
}
.preview.has-example::before{
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--example-img);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  opacity: .35;
  filter: grayscale(1);
}
.preview .preview-hint{
  position: relative;
  z-index: 1;
  font-size: 13px;
  text-align: center;
  padding: 8px 12px;
  line-height: 1.4;
  color: rgba(17,24,39,.38);
  background: rgba(255,255,255,.32);
  border-radius: 10px;
}

/* ---------- Signature preview ---------- */
#signature-preview{
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: rgba(0,0,0,.02);
}
#signature-image{
  width: 100%;
  max-height: 140px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  background: #fff;
  border: 1px solid var(--border);
}

/* ---------- Tariffs ---------- */
.tariff-grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 10px;
}
.tariff-card{
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255,255,255,.92);
  padding: 14px;
  cursor:pointer;
  box-shadow: 0 10px 24px rgba(0,0,0,.06);
  transition: transform .12s ease, box-shadow .18s ease, border-color .18s ease;
}
.tariff-card:hover{
  transform: translateY(-1px);
  border-color: rgba(var(--brand-rgb), .75);
  box-shadow: 0 16px 34px rgba(0,0,0,.08);
}
.tariff-card.selected{
  border-color: rgba(var(--brand-rgb), .95);
  box-shadow: 0 0 0 4px rgba(var(--brand-rgb), .22), 0 18px 35px rgba(0,0,0,.10);
}
.tariff-title{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.tariff-name{
  font-weight: 750;
  color: #111;
  line-height: 1.15;
  font-size: 15px;
}
.tariff-badge{
  font-size: 12px;
  font-weight: 650;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(0,0,0,.05);
  color: #111;
}
.tariff-meta{ display:flex; flex-wrap:wrap; gap:8px; }
.tariff-chip{
  font-size: 12px;
  font-weight: 600;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(0,0,0,.04);
  border: 1px solid rgba(0,0,0,.06);
  color: #111;
}
.tariff-hint{
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
}

/* ---------- Steps ---------- */
.step-block { margin-top: 10px; }
.step-head { margin: 4px 0 14px; text-align:center; }
.step-title { font-weight: 800; font-size: 14px; color: #111; }
.step-subtitle { font-size: 13px; color: var(--muted); margin-top: 4px; }

.step-actions{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}

/* Step 2 forms spacing */
#step-data input,
#step-data textarea{
  text-transform: uppercase;
}
#step-data .section-title{
  display:block;
  margin: 0 0 12px 0;
}
#step-data .mini-label{
  display:block;
  margin: 0 0 6px 0;
  line-height: 1.2;
}
#step-data .mini-label .hint{
  margin-left: 6px;
  font-weight: 400;
  color: var(--muted);
}
#step-data .grid-2,
#step-data .grid-3,
#step-data .grid-4{
  display:grid;
  gap: 12px;
  margin-top: 12px;
}
#step-data .grid-2{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
#step-data .grid-3{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
#step-data .grid-4{ grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* ---------- Success page ---------- */
.success-box{
  text-align: center;
  padding: 18px 10px 6px;
}
.subtle{
  margin: 0 0 14px;
  color: #666;
}
.success-list{
  text-align: left;
  margin: 12px 0 16px;
  padding-left: 18px;
  color: #333;
  font-size: 14px;
  line-height: 1.6;
}
.actions-row{
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-top: 18px;
  flex-wrap: wrap;
}
.actions-row .btn{
  min-width: 220px;
  text-align: center;
}

/* Promo card */
.promo-card{
  margin: 14px 0 10px;
  padding: 14px;
  border-radius: var(--radius);
  border: 1px solid rgba(0,0,0,.08);
  background: linear-gradient(180deg, rgba(var(--brand-rgb),.22), rgba(var(--brand-rgb),.08));
  box-shadow: 0 10px 24px rgba(0,0,0,.06);

  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  text-align: left;
}
.promo-badge{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 12px;
  background: rgba(0,0,0,.10);
  color: #111;
}
.promo-title{
  margin-top: 8px;
  font-weight: 900;
  font-size: 16px;
  letter-spacing: -0.01em;
  color: #111;
}
.promo-sub{
  margin-top: 4px;
  font-size: 13px;
  color: rgba(17,24,39,.70);
  line-height: 1.35;
}
.promo-btn{
  width: auto !important;
  min-width: 180px;
  white-space: nowrap;
}

/* ---------- Modal (signature) ---------- */
.modal{
  display:none;
  position:fixed;
  inset:0;
  background: rgba(0,0,0,.55);
  z-index: 9999;
  padding: 18px;

  align-items: center;
  justify-content: center;
}
.modal-content{
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,.35);
  box-shadow: 0 30px 70px rgba(0,0,0,.25);
  width: min(96vw, 900px);
  height: min(82vh, 720px);
  padding: 18px;
  position: relative;

  display:flex;
  flex-direction: column;
}
.close{
  position:absolute;
  top: 12px;
  right: 14px;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,.10);
  background: rgba(255,255,255,.85);
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  color:#111;
  font-size: 22px;
  line-height: 1;
}
.close:hover{ box-shadow: 0 12px 24px rgba(0,0,0,.10); }

#signature-pad{
  flex: 1 1 auto;
  width:100%;
  min-height: 55vh;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #fff;
  touch-action: none;
}

/* ---------- Responsive ---------- */
@media (max-width: 720px){
  #step-data .grid-4{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px){
  .container{ margin: 14px auto; padding: 16px; }
  .tariff-grid{ grid-template-columns: 1fr; }
}
@media (max-width: 520px){
  .container{
    width: calc(100% - 24px);
    margin: 14px auto;
    padding: 16px;
  }

  .consent-logo,
  .form-logo,
  .success-logo{
    height: 32px;
  }

  /* Headers stacked */
  .consent-header,
  .form-header,
  .success-header{
    flex-direction: column;
    align-items: center;
    min-height: auto;
    gap: 10px;
  }

  .consent-titles h1,
  .form-titles h1,
  .success-titles .page-title{
    font-size: 20px;
  }
  .form-titles h1{
    white-space: nowrap;
  }

  .step-actions{ grid-template-columns: 1fr; }

  .promo-card{
    grid-template-columns: 1fr;
    text-align: center;
  }
  .promo-btn{
    width: 100% !important;
    min-width: 0;
  }
}
/* ===== FIX: Кнопка "Далее" на шаге 2 — во всю ширину ===== */
#step-data .step-actions{
  grid-template-columns: 1fr;   /* одна колонка */
}

#step-data .step-actions #to-step-docs{
  width: 100%;
}

/* (опционально) Шаг 3 тоже одной колонкой */
#step-docs .step-actions{
  grid-template-columns: 1fr;
}

#step-docs .step-actions #back-to-step-data{
  width: 100%;
}
/* =========================
   Page Preloader — SOLID FIX
   ========================= */
#page-preloader{
  position: fixed !important;
  inset: 0 !important;
  z-index: 2147483647 !important;

  /* 🔥 ГЛАВНОЕ: НЕ прозрачный фон */
  background-color: #ffffff !important;

  display: flex !important;
  align-items: center !important;
  justify-content: center !important;

  opacity: 1;
  pointer-events: all;
  transition: opacity .25s ease;
}

#page-preloader.hidden{
  opacity: 0;
  pointer-events: none;
}

#page-preloader .pp-inner{
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

#page-preloader .pp-spinner{
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 4px solid rgba(var(--brand-rgb), .25);
  border-top-color: rgba(var(--brand-rgb), 1);
  animation: ppSpin .85s linear infinite;
}

#page-preloader .pp-text{
  display: flex;
  align-items: center;
  justify-content: center;

  height: 20px;           /* фиксируем высоту */
  line-height: 1;         /* убираем метрики шрифта */
  margin-top: 6px;

  font-weight: 800;
  font-size: 14px;
  color: #111;
  text-align: center;
}


@keyframes ppSpin{
  to{ transform: rotate(360deg); }
}

/* =========================
   FIX: Headers on mobile (disable absolute layout)
   ========================= */
@media (max-width: 520px){
  /* ВАЖНО: на мобиле НЕ absolute */
  .consent-header{
    position: static !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    min-height: auto !important;
  }

  .consent-logo{
    position: static !important;  /* отключили absolute */
    left: auto !important;
    height: 32px !important;
    margin: 0 !important;
  }

  .consent-titles,
  .form-titles,
  .success-titles{
    position: static !important;  /* отключили absolute */
    left: auto !important;
    transform: none !important;
    width: 100% !important;
    pointer-events: auto !important; /* чтобы ссылки внутри работали */
    text-align: center !important;
  }
}
/* =========================
   FIX: Mobile inputs grid (make it 1 column)
   ========================= */
@media (max-width: 520px){

  /* все сетки ввода — в одну колонку */
  #step-data .grid-2,
  #step-data .grid-3,
  #step-data .grid-4{
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  /* лейбл: аккуратнее переносы */
  #step-data .mini-label{
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    margin: 0 0 6px 0 !important;
    line-height: 1.2;
  }

  /* подсказки справа — не ломают строку */
  #step-data .mini-label .hint{
    margin-left: 0 !important;
    white-space: nowrap;
    flex: 0 0 auto;
  }
}
/* =========================
   FIX: выравнивание полей в grid (одинаковая высота label)
   ========================= */

/* каждая ячейка сетки = колонка */
#step-data .grid-2 > div,
#step-data .grid-3 > div,
#step-data .grid-4 > div{
  display: flex;
  flex-direction: column;
}

/* одинаковая высота заголовка поля, чтобы инпуты стартовали на одной линии */
#step-data .mini-labell{
  line-height: 1.2;
  min-height: 34px;      /* 2 строки по ~16-17px */
  margin: 0 0 6px 0 !important;
}

/* если вдруг где-то mini-label был flex (на мобиле) — сохраняем норм вид */
@media (max-width: 520px){
  #step-data .mini-label{
    min-height: 0;       /* на 1 колонке выравнивание не нужно */
  }
}

.support-phone {
    margin-left: 6px;          /* отступ от "Поддержка:" */
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;       /* номер не переносится */
}

.support-phone:hover {
    text-decoration: underline;
}



/* =========================
   Flow start
   ========================= */
.flow-start-box{
  padding: 6px;
}

.flow-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.flow-card{
  appearance:none;
  border:1px solid var(--border);
  border-radius: var(--radius);
  background:#fff;
  padding:18px 16px;
  text-align:left;
  cursor:pointer;
  box-shadow: 0 10px 24px rgba(0,0,0,.06);
  transition: transform .12s ease, box-shadow .18s ease, border-color .18s ease;
}
.flow-card:hover{
  transform: translateY(-2px);
  border-color: rgba(var(--brand-rgb), .8);
  box-shadow: 0 18px 34px rgba(0,0,0,.08);
}
.flow-card-title{
  display:block;
  font-size:18px;
  font-weight:800;
  color:#111;
  margin-bottom:8px;
}
.flow-card-text{
  display:block;
  font-size:14px;
  color: var(--muted);
  line-height:1.45;
}

@media (max-width: 900px){
  .flow-grid{
    grid-template-columns: 1fr;
  }
}

.flow-grid[data-flow-count="1"]{
  grid-template-columns: minmax(280px, 520px);
  justify-content: center;
}
.flow-grid[data-flow-count="2"]{
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
/* мобильная версия */
@media (max-width: 640px){

  .flow-grid[data-flow-count="1"],
  .flow-grid[data-flow-count="2"],
  .flow-grid[data-flow-count="3"]{
    grid-template-columns: 1fr;
  }

}

.support-block{
  margin-top:16px;
  padding:18px;
  border-radius:14px;
  background:#fff8e8;
  border:1px solid rgba(0,0,0,0.08);
}

.support-title{
  font-weight:800;
  font-size:16px;
  margin-bottom:12px;
}

.support-phone{
  display:block;
  text-decoration:none;
  font-weight:700;
  color:#111;
  margin-bottom:14px;
  font-size:15px;
}

/* кнопки */

.support-buttons{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:8px;
}

.support-btn{
  display:flex;
  justify-content:center;
  align-items:center;
  height:44px;
  border-radius:10px;
  text-decoration:none;
  font-weight:700;
  font-size:14px;
  transition:0.2s;
}

/* WhatsApp */

.support-btn.whatsapp{
  border:2px solid #25D366;
  color:#25D366;
  background:white;
}

.support-btn.whatsapp:hover{
  background:#25D366;
  color:white;
}

/* Telegram */

.support-btn.telegram{
  border:2px solid #229ED9;
  color:#229ED9;
  background:white;
}

.support-btn.telegram:hover{
  background:#229ED9;
  color:white;
}

/* MAX */

.support-btn.max{
  border:2px solid #111;
  color:#111;
  background:white;
}

.support-btn.max:hover{
  background:#111;
  color:white;
}



/* ===== Tariff system help ===== */
.tariff-title-row{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}
.tariff-help-btn{
  border:none;
  background:transparent;
  color:#0A66C2;
  font-size:12px;
  font-weight:700;
  cursor:pointer;
  padding:0;
}
.tariff-system-help{
  margin-top:10px;
  padding:12px 14px;
  border-radius:14px;
  border:1px solid rgba(17,24,39,.10);
  background:rgba(0,0,0,.03);
  font-size:13px;
  line-height:1.45;
}

.tariff-submeta{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-top:10px;
}
.tariff-subchip{
  font-size:12px;
  font-weight:700;
  padding:7px 10px;
  border-radius:999px;
  background:rgba(var(--brand-rgb),.14);
  border:1px solid rgba(var(--brand-rgb),.35);
}
.tariff-info-inline{
  margin-top:10px;
  font-size:12px;
  color:var(--muted);
}

@media (max-width: 520px){
  .tariff-title-row{
    align-items:flex-start;
  }
}


/* ===== MNP extra fields ===== */
.mnp-consent-box{
  display:flex;
  align-items:flex-start;
  gap:12px;
  margin:14px 0 6px;
  padding:14px;
  border-radius: var(--radius);
  border:1px solid rgba(220, 38, 38, 0.25);
  background: rgba(220, 38, 38, 0.08);
  font-size:14px;
  line-height:1.45;
}
.mnp-consent-box input[type="checkbox"]{
  display:block;
  width:18px;
  height:18px;
  margin-top:2px;
  flex:0 0 18px;
}
#porting-operator-group select{
  text-transform:none;
}
