/* ================== VARIABLES & BASE ================== */
:root {
  --gap: 16px;
  --radius: 28px;
  --brand: #ff6000;
  --purple: #0e05ff;
  --text: #0b1220;
  --muted: #667085;
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial;
  color: var(--text);
  background:
    radial-gradient(900px 420px at 12% -10%, rgba(255, 255, 255, .18), transparent 65%),
    radial-gradient(700px 360px at 88% -6%, rgba(255, 255, 255, .12), transparent 75%),
    var(--brand);
  -webkit-tap-highlight-color: transparent;
}

.wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: var(--gap);
}

.hidden {
  display: none !important;
}

.muted {
  color: var(--muted);
  font-size: 14px;
}

.grid {
  display: grid;
  gap: 12px;
}

.grid.cols-2 {
  grid-template-columns: 1fr 1fr;
}

.card {
  background: #fff;
  border-radius: 20px;
  padding: 16px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, .08);
}

.step {
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #FFF;
  margin-bottom: 6px;
}

input,
button {
  font-size: 16px;
  border-radius: 12px;
}

input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #dcdcdc;
  background: #fff;
}

input:focus {
  outline: none;
  border-color: #8ec6ff;
  box-shadow: 0 0 0 3px rgba(0, 136, 204, .12);
}

.btn {
  border: none;
  cursor: pointer;
  background: #f2f6fb;
  padding: 12px 14px;
  font-weight: 600;
  transition: transform .12s ease, box-shadow .12s ease, filter .12s ease;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(12, 28, 64, .12);
}

.btn:active {
  transform: translateY(0);
  filter: brightness(.98);
}

.btn.secondary {
  background: #eef3f7;
  border: 1px solid #dfe7ef;
  color: #0a0a0a;
}

/* ================== LOADING ================== */
.loading-screen {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 2*var(--gap));
}

.loading-logo {
  display: block;
  width: 100%;
  height: 200px;
  object-fit: contain;
  margin-top: 8px;
  filter: drop-shadow(0 10px 22px rgba(0, 0, 0, .22));
}

.loading-bottom {
  margin-top: auto;
  padding: 0 0 84px;
  text-align: center;
}

.spinner {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 4px solid #cfd8e3;
  border-top-color: var(--purple);
  animation: spin 1s linear infinite;
  margin: 0 auto 10px;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ===== HERO (логотип + преимущества) ===== */
.hero-wrap {
  margin: 6px 0 12px;
}

.hero-card {
  border-radius: 24px;
  padding: 18px 16px;
  border: 1px solid rgba(255, 255, 255, .28);
  background: linear-gradient(180deg, rgba(255, 255, 255, .18), rgba(255, 255, 255, .08));
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, .18);
}

.hero-logo {
  display: block;
  margin: 0 auto 10px;
  width: clamp(160px, 52vw, 320px);
  height: auto;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, .22));
}

.hero-sub {
  color: #fff;
  text-align: center;
  margin: 0 0 10px;
  font-weight: 600;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.chip {
  color: #fff;
  font-size: 13px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .28);
}

/* ================== TILES LAYOUT ================== */
.tiles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto auto;
  grid-template-areas:
    "tariffs rent"
    "extend  rent"
    "finish  finish";
  gap: 16px;
}

/* Base tile */
.tile {
  position: relative;
  border: none;
  background: #fff;
  border-radius: 28px;
  padding: 22px;
  text-align: left;
  box-shadow: 0 10px 26px rgba(12, 28, 64, .12);
  transition: transform .16s ease, box-shadow .16s ease, filter .16s ease;
  overflow: hidden;
}


.tile:active {
  transform: translateY(0) scale(.995);
}

.tile:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(12, 28, 64, .16);
}

/* White info tile */
.tile--info {
  background:
    radial-gradient(220px 160px at 10% 0%, rgba(143, 169, 255, .18), rgba(255, 255, 255, .88) 55%),
    #fff;
  color: #0d1117;
}

.tile--info .tile__title {
  font-weight: 700;
  line-height: .95;
  letter-spacing: .02em;
  font-size: clamp(20px, 4.4vw, 36px);
  margin: 0 36px 8px 0;
}

.tile--info .tile__subtitle {
  font-size: clamp(14px, 2.8vw, 18px);
  color: #6b7280;
}

.chev {
  position: absolute;
  right: 16px;
  bottom: 16px;
  font-size: 28px;
  color: #9aa4b2;
  opacity: .9;
  transition: transform .16s ease;
}

.tile:hover .chev {
  transform: translateX(2px);
}

/* Big CTA tile (blue) */
.tile--cta {
  background: linear-gradient(180deg, #3a33ff, var(--purple));
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
}

.cta__text {
  margin-top: 28px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .01em;
  font-size: clamp(25px, 4.5vw, 56px);
  text-shadow: 0 6px 16px rgba(0, 0, 0, .25);
}

.arrow-circle {
  position: absolute;
  left: 30%;
  bottom: 22px;
  transform: translateX(-50%);
  width: clamp(40px, 18vw, 140px);
  height: clamp(40px, 18vw, 140px);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 20px 40px rgba(0, 0, 0, .25);
  display: grid;
  place-items: center;
  transition: transform .18s ease, box-shadow .18s ease;
}

.arrow {
  color: #0a14ff;
  font-size: clamp(28px, 5vw, 44px);
  line-height: 1;
  transform: translateX(0);
  transition: transform .18s ease;
}

.tile--cta:hover .arrow-circle {
  transform: translateX(-50%) scale(1.04);
  box-shadow: 0 26px 54px rgba(0, 0, 0, .30);
}

.tile--cta:hover .arrow {
  transform: translateX(3px);
}

/* Wide tile */
.tile--wide {
  background:
    radial-gradient(180px 140px at 8% 10%, rgba(143, 169, 255, .18), rgba(255, 255, 255, .9) 55%),
    #f3f2f8;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 12px;
}

.tile--wide .chev--right {
  font-size: clamp(70px, 6.5vw, 48px);
  /* ↑ размер стрелки */
  right: 20px;
  /* чуть правее */
  bottom: 10px;
  /* чуть ниже */
}

/* бейдж слева в широкой плитке */
.brand-dot {
  flex: 0 0 auto;
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: var(--brand);
  /* оранжевый квадрат */
  box-shadow: 0 10px 24px rgba(255, 96, 0, .35);
  display: grid;
  place-items: center;
  overflow: hidden;
  /* ничего не вылезает за скругления */
}

/* сама картинка "W" внутри бейджа */
.brand-dot__img {
  display: block;
  width: 60%;
  /* масштаб логотипа внутри квадрата */
  height: auto;
}

.wide__text {
  font-weight: 700;
  line-height: .98;
  letter-spacing: .01em;
  font-size: clamp(23px, 4.8vw, 40px);
}

.chev--right {
  right: 18px;
  bottom: 18px;
}

/* Grid areas */
[style*="grid-area: tariffs"] {
  grid-area: tariffs;
}

[style*="grid-area: rent"] {
  grid-area: rent;
}

[style*="grid-area: extend"] {
  grid-area: extend;
}

[style*="grid-area: finish"] {
  grid-area: finish;
}

/* ================== LEGAL MINI-FOOTER ================== */
.legal-mini {
  background: linear-gradient(180deg, #ffffff, #f7fbff);
  border: 1px solid #e6eef6;
  border-radius: 18px;
  padding: 12px 14px;
  box-shadow: 0 8px 20px rgba(12, 28, 64, .10);
}

.legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  justify-content: center;
}

.legal-links a {
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 13px;
  border-bottom: 1px dashed rgba(11, 18, 32, .35);
}

.legal-links a:hover {
  border-bottom-color: rgba(11, 18, 32, .6);
}

/* ================== SUMMARY ================== */
.summary div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px dashed #e6e6e6;
}

.summary div:last-child {
  border-bottom: none;
}

/* ================== MODAL ================== */
.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, .45);
  padding: 16px;
  z-index: 10000;
}

.modal.show {
  display: flex;
}

.modal__card {
  width: 100%;
  max-width: 720px;
  max-height: 80vh;
  overflow: auto;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, .25);
  padding: 16px;
}

.modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.modal__title {
  font-size: 18px;
  font-weight: 800;
}

.modal__close {
  border: 1px solid #e1e6ef;
  background: #f0f4f9;
  padding: 8px 12px;
  border-radius: 10px;
  cursor: pointer;
}

.modal__close:hover {
  filter: brightness(1.03);
}

.modal__body {
  color: #222;
  font-size: 14px;
  line-height: 1.5;
}

.modal__body p {
  margin: 0 0 10px;
}

.modal__body h3 {
  margin: 14px 0 8px;
  font-size: 16px;
}

.modal__body code {
  background: #f5f7fb;
  padding: 2px 6px;
  border-radius: 6px;
}

/* ================== RESPONSIVE TWEAKS ================== */
@media (max-width: 380px) {
  .tile {
    border-radius: 22px;
    padding: 18px;
  }

  .brand-dot {
    width: 54px;
    height: 54px;
    font-size: 26px;
  }
}

/* Больше отступа между формой (summary) и кнопками на экране подтверждения */
#scr-confirm .summary {
  margin-bottom: 28px;
  /* подбери значение: 24–40px */
}

/* (необязательно) можно чуть добавить воздуха у контейнера с кнопками */
#scr-confirm .grid.cols-2 {
  margin-top: 6px;
  /* или убери, если не нужно */
}