/* NacenTo visual system - clean mobile app template direction */
:root {
  color-scheme: light;
  --ink: #15172f;
  --ink-2: #25285a;
  --muted: #737896;
  --muted-2: #9aa0b8;
  --page: #f7f8ff;
  --white: #ffffff;
  --lavender: #b9b5df;
  --lavender-2: #dcd9f2;
  --indigo: #302f8f;
  --indigo-2: #24236f;
  --blue: #2f7ed8;
  --mint: #35e4ac;
  --mint-soft: #e8fff7;
  --pink: #ff6aa2;
  --pink-soft: #fff0f6;
  --yellow: #ffcb5c;
  --yellow-soft: #fff7df;
  --line: rgba(48, 47, 143, 0.14);
  --line-strong: rgba(48, 47, 143, 0.24);
  --shadow-soft: 0 18px 44px rgba(37, 36, 99, 0.14);
  --shadow-card: 0 26px 70px rgba(37, 36, 99, 0.17);
  --shadow-button: 0 14px 30px rgba(48, 47, 143, 0.26);
  --radius-page: 34px;
  --radius-card: 28px;
  --radius-field: 22px;
  --radius-button: 18px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background:
    linear-gradient(180deg, var(--lavender) 0 520px, var(--page) 520px 100%);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.45;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: wait;
  opacity: 0.68;
}

.hidden,
[hidden] {
  display: none !important;
}

body.modal-open,
body.processing-open {
  overflow: hidden;
}

.app {
  min-height: 100vh;
  padding: 22px 16px 44px;
}

.app-shell {
  width: min(1120px, 100%);
  margin: 0 auto;
}

.screen {
  display: none;
}

.screen.active {
  display: block;
}

/* Step navigation */
.step-nav {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  width: min(620px, 100%);
  margin: 0 auto 22px;
  padding: 5px 0;
}

.step-nav::before {
  content: "";
  position: absolute;
  top: 28px;
  left: 12%;
  right: 12%;
  height: 2px;
  background: rgba(255, 255, 255, 0.7);
}

.step-tab {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 8px;
  min-height: 74px;
  border: 0;
  padding: 0 6px;
  background: transparent;
  color: rgba(36, 35, 111, 0.55);
  font-size: 13px;
  font-weight: 750;
}

.step-tab span {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: rgba(36, 35, 111, 0.45);
  box-shadow: 0 10px 24px rgba(48, 47, 143, 0.1);
}

.step-tab.active {
  color: #ffffff;
}

.step-tab.active span {
  border-color: transparent;
  background: var(--indigo);
  color: #ffffff;
  box-shadow: 0 16px 32px rgba(48, 47, 143, 0.32);
}

.step-tab:not(.locked):hover span {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.95);
  background: #ffffff;
  color: var(--indigo);
}

/* Shared surfaces */
.card {
  width: min(1060px, 100%);
  margin: 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--radius-page);
  padding: 30px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-card);
}

.card > h1 {
  margin: 0 0 22px;
  color: var(--ink-2);
  font-size: 36px;
  line-height: 1.08;
  font-weight: 850;
}

.start-card {
  border: 0;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

/* Hero */
.hero-intro {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(410px, 1.1fr);
  gap: 44px;
  align-items: center;
  min-height: 620px;
  overflow: hidden;
  border-radius: 42px;
  padding: 58px 58px 72px;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.18) 0 17%, transparent 17% 100%),
    linear-gradient(150deg, rgba(255, 255, 255, 0.12) 0 8%, transparent 8% 100%),
    var(--lavender);
  box-shadow: 0 34px 86px rgba(48, 47, 143, 0.2);
}

.hero-intro::before {
  content: "";
  position: absolute;
  left: -12%;
  right: -12%;
  bottom: -28%;
  height: 52%;
  border-radius: 50% 50% 0 0 / 74% 74% 0 0;
  background: #ffffff;
}

.hero-intro::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.13) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.13) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(120deg, transparent 0 8%, #000 8% 58%, transparent 58% 100%);
  opacity: 0.42;
  pointer-events: none;
}

.hero-copy,
.hero-visual {
  position: relative;
  z-index: 1;
}

.hero-brand {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 26px;
  color: var(--indigo);
  font-size: 23px;
  font-weight: 850;
}

.brand-cube {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--mint), #2f7ed8 78%);
  box-shadow: 0 18px 34px rgba(48, 47, 143, 0.22);
  transform: rotate(45deg);
}

.brand-cube::after {
  content: "";
  position: absolute;
  inset: 11px;
  border-radius: 8px;
  background: #ffffff;
}

.hero-kicker {
  display: inline-flex;
  width: fit-content;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  padding: 8px 13px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--indigo);
  font-size: 13px;
  font-weight: 780;
  box-shadow: 0 10px 22px rgba(48, 47, 143, 0.08);
}

.hero-title {
  display: grid;
  gap: 10px;
  margin: 12px 0 18px;
  line-height: 0.98;
}

.hero-title span,
.hero-title strong {
  display: block;
  letter-spacing: 0;
}

.hero-title span {
  color: var(--indigo);
  font-size: 78px;
  font-weight: 920;
}

.hero-title strong {
  color: #ffffff;
  font-size: 52px;
  font-weight: 850;
  text-shadow: 0 15px 30px rgba(48, 47, 143, 0.22);
}

.hero-intro .lead {
  max-width: 560px;
  margin: 0;
  color: rgba(21, 23, 47, 0.76);
  font-size: 20px;
  line-height: 1.58;
}

.hero-app-modules {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  max-width: 560px;
  margin-top: 28px;
}

.hero-app-modules span {
  display: grid;
  align-content: center;
  min-height: 92px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 24px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.72);
  color: #383b68;
  font-size: 13px;
  font-weight: 760;
  box-shadow: 0 18px 34px rgba(48, 47, 143, 0.12);
}

.hero-app-modules strong {
  display: block;
  margin-bottom: 6px;
  color: var(--indigo);
  font-size: 18px;
}

.hero-visual {
  overflow: visible;
  min-width: 0;
}

.phone-showcase {
  position: relative;
  min-height: 570px;
}

.phone-showcase::before {
  content: "";
  position: absolute;
  left: -8%;
  right: -8%;
  bottom: 8px;
  height: 190px;
  border-radius: 50% 50% 0 0 / 82% 82% 0 0;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 -20px 44px rgba(48, 47, 143, 0.08);
}

.phone-card {
  position: absolute;
  overflow: hidden;
  border: 9px solid #202056;
  border-radius: 36px;
  background: #202056;
  box-shadow: 0 36px 74px rgba(32, 32, 86, 0.34);
}

.phone-main {
  top: 6px;
  left: 50%;
  z-index: 3;
  width: 292px;
  height: 522px;
  transform: translateX(-50%);
}

.phone-side {
  top: 98px;
  z-index: 2;
  width: 210px;
  height: 398px;
  opacity: 0.94;
}

.phone-left {
  left: 0;
  transform: rotate(-7deg);
}

.phone-right {
  right: 0;
  transform: rotate(7deg);
}

.phone-screen {
  position: relative;
  height: 100%;
  overflow: hidden;
  border-radius: 27px;
  background: #ffffff;
}

.phone-screen::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 46%;
  background: #302f8f;
}

.phone-topbar {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 18px 0;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
}

.phone-topbar i {
  display: block;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
}

.phone-hero {
  position: relative;
  z-index: 2;
  display: grid;
  gap: 12px;
  padding: 30px 18px 0;
  color: #ffffff;
}

.phone-hero small {
  color: rgba(255, 255, 255, 0.72);
  font-weight: 720;
}

.phone-hero strong {
  font-size: 24px;
  line-height: 1.12;
}

.phone-search {
  border-radius: 17px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
}

.phone-wave {
  position: absolute;
  z-index: 1;
  top: 35%;
  left: -16%;
  width: 132%;
  height: 144px;
  border-radius: 0 0 50% 50% / 0 0 92% 92%;
  background: #ffffff;
}

.phone-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 112px 18px 0;
}

.phone-grid span {
  display: grid;
  gap: 7px;
  align-content: center;
  min-height: 78px;
  border-radius: 20px;
  background: #ffffff;
  color: var(--ink-2);
  font-size: 20px;
  text-align: center;
  box-shadow: 0 14px 28px rgba(48, 47, 143, 0.13);
}

.phone-grid b {
  color: #4b5075;
  font-size: 11px;
  font-weight: 780;
  text-transform: uppercase;
}

.phone-total {
  position: absolute;
  right: 18px;
  bottom: 18px;
  left: 18px;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 22px;
  padding: 14px 16px;
  background: var(--indigo);
  color: #ffffff;
}

.phone-total span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 700;
}

.phone-total strong {
  font-size: 24px;
}

.mini-profile,
.mini-list,
.mini-document {
  position: relative;
  z-index: 2;
}

.mini-profile {
  display: grid;
  justify-items: center;
  gap: 8px;
  margin: 54px auto 18px;
  color: var(--ink-2);
}

.mini-profile span {
  display: grid;
  width: 72px;
  height: 72px;
  place-items: center;
  border: 5px solid #ffffff;
  border-radius: 999px;
  background: var(--mint);
  color: var(--indigo);
  font-weight: 900;
  box-shadow: 0 14px 26px rgba(48, 47, 143, 0.18);
}

.mini-profile strong {
  font-size: 18px;
}

.mini-list {
  display: grid;
  gap: 10px;
  padding: 0 18px;
}

.mini-list span,
.mini-document span {
  display: block;
  border-radius: 16px;
  background: #f2f4ff;
}

.mini-list span {
  padding: 12px;
  color: #555b83;
  font-size: 12px;
  font-weight: 750;
}

.mini-document {
  display: grid;
  gap: 12px;
  margin: 96px 18px 0;
  border-radius: 22px;
  padding: 18px;
  background: #ffffff;
  box-shadow: 0 16px 32px rgba(48, 47, 143, 0.14);
}

.mini-document strong {
  color: var(--indigo);
  font-size: 19px;
  line-height: 1.1;
}

.mini-document span {
  height: 13px;
}

/* Forms */
.form-stack,
.chat-form,
.activation-form {
  display: grid;
  gap: 18px;
}

.start-card > .form-stack {
  position: relative;
  z-index: 2;
  width: min(960px, calc(100% - 58px));
  margin: -42px auto 0;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 32px;
  padding: 30px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-card);
}

.two-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
  min-width: 0;
}

label > span,
.toggle-line span {
  color: #565b7d;
  font-size: 14px;
  font-weight: 760;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid rgba(48, 47, 143, 0.14);
  border-radius: var(--radius-field);
  background: #fbfbff;
  color: var(--ink);
  outline: 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

input,
select {
  min-height: 58px;
  padding: 0 18px;
}

textarea {
  min-height: 180px;
  padding: 18px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: #b1b6c9;
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(48, 47, 143, 0.48);
  background: #ffffff;
  box-shadow: 0 0 0 5px rgba(48, 47, 143, 0.1);
}

.input-error {
  border-color: var(--pink) !important;
  background: #fff8fb !important;
}

.toggle-line {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 10px;
  min-height: 50px;
  border: 1px solid rgba(48, 47, 143, 0.12);
  border-radius: 999px;
  padding: 0 16px;
  background: #fbfbff;
}

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

.primary,
.secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 56px;
  border: 1px solid transparent;
  border-radius: var(--radius-button);
  padding: 0 22px;
  font-weight: 820;
  text-decoration: none;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, border-color 0.16s ease;
}

.primary {
  background: var(--indigo);
  color: #ffffff;
  box-shadow: var(--shadow-button);
}

.primary:hover {
  background: var(--indigo-2);
  transform: translateY(-1px);
}

.secondary {
  border-color: rgba(48, 47, 143, 0.14);
  background: #ffffff;
  color: var(--indigo);
}

.secondary:hover {
  border-color: transparent;
  background: #f0f1ff;
  transform: translateY(-1px);
}

.huge {
  width: 100%;
  min-height: 66px;
  border-radius: 22px;
  font-size: 18px;
}

.status {
  min-height: 24px;
  margin: 0;
  color: var(--indigo);
  font-weight: 760;
}

.choice-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.choice-row.three-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.icon-button {
  white-space: nowrap;
}

.search-icon {
  position: relative;
  width: 20px;
  height: 20px;
  border: 3px solid currentColor;
  border-radius: 999px;
}

.search-icon::after {
  content: "";
  position: absolute;
  right: -8px;
  bottom: -7px;
  width: 10px;
  height: 3px;
  border-radius: 999px;
  background: currentColor;
  transform: rotate(45deg);
}

/* Processing */
.processing-overlay,
.send-modal,
.preview-modal {
  position: fixed;
  inset: 0;
  z-index: 30;
  overflow: auto;
}

.processing-overlay {
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(32, 32, 86, 0.28);
  backdrop-filter: blur(12px);
}

.processing-card {
  display: grid;
  justify-items: center;
  gap: 16px;
  width: min(360px, 100%);
  border-radius: 34px;
  padding: 34px 28px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-card);
  text-align: center;
}

.processing-spinner {
  position: relative;
  width: 76px;
  height: 76px;
  border-radius: 999px;
  background:
    conic-gradient(from 0deg, var(--mint), var(--pink), var(--yellow), var(--indigo), var(--mint));
  animation: spin 0.9s linear infinite;
}

.processing-spinner::before {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: inherit;
  background: #ffffff;
}

.processing-spinner::after {
  content: "";
  position: absolute;
  inset: 25px;
  border-radius: inherit;
  background: var(--indigo);
}

@keyframes spin {
  to {
    transform: rotate(1turn);
  }
}

.processing-card strong {
  color: var(--ink-2);
  font-size: 22px;
}

.processing-card span {
  color: var(--muted);
}

/* Clarification screen */
.processing-required,
.clarification-offer {
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.processing-required-box,
.clarification-box {
  display: grid;
  gap: 18px;
  border-radius: var(--radius-card);
  padding: 28px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.processing-required-box span {
  width: fit-content;
  border-radius: 999px;
  padding: 7px 11px;
  background: var(--mint-soft);
  color: #168660;
  font-size: 12px;
  font-weight: 820;
}

.processing-required-box strong,
.clarification-box h2 {
  margin: 0;
  color: var(--ink-2);
  font-size: 34px;
  line-height: 1.08;
  font-weight: 880;
}

.processing-required-box p {
  max-width: 680px;
  margin: 0;
  color: var(--muted);
}

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

.clarification-question {
  display: grid;
  gap: 13px;
  border: 1px solid rgba(48, 47, 143, 0.1);
  border-radius: 24px;
  padding: 18px;
  background: #fbfbff;
}

.question-title {
  color: var(--ink);
  font-size: 18px;
  line-height: 1.35;
  font-weight: 540;
}

.clarification-options {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.check-option {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 46px;
  border: 1px solid rgba(48, 47, 143, 0.12);
  border-radius: 999px;
  padding: 0 14px;
  background: #ffffff;
}

.check-option input {
  width: 19px;
  min-height: 19px;
  accent-color: var(--indigo);
}

.check-option span {
  color: var(--ink);
  font-size: 15px;
  font-weight: 560;
}

.check-option:has(input:checked) {
  border-color: rgba(53, 228, 172, 0.7);
  background: var(--mint-soft);
}

.measure-answer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 9px;
  max-width: 430px;
}

.measure-answer input {
  min-height: 58px;
}

.measure-unit {
  display: grid;
  min-width: 64px;
  min-height: 58px;
  place-items: center;
  border: 1px solid rgba(48, 47, 143, 0.12);
  border-radius: 20px;
  background: #ffffff;
  color: var(--indigo);
  font-weight: 820;
}

.chat-box {
  margin-top: 18px;
  border-radius: var(--radius-card);
  padding: 18px;
  background: #f4f5ff;
}

.chat-form {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

/* Template selection */
.template-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.template-card {
  display: grid;
  gap: 7px;
  min-height: 132px;
  border: 1px solid rgba(48, 47, 143, 0.13);
  border-radius: 26px;
  padding: 20px;
  background: #ffffff;
  color: var(--ink);
  text-align: left;
  box-shadow: 0 14px 34px rgba(37, 36, 99, 0.08);
}

.template-card strong {
  font-size: 24px;
  font-weight: 850;
}

.template-card span {
  color: var(--indigo);
  font-weight: 850;
}

.template-card small {
  color: var(--muted);
  font-size: 14px;
  font-weight: 650;
}

.template-card.selected {
  border-color: transparent;
  background:
    linear-gradient(135deg, rgba(53, 228, 172, 0.28) 0 24%, transparent 24% 100%),
    var(--indigo);
  color: #ffffff;
  box-shadow: var(--shadow-button);
}

.template-card.selected span,
.template-card.selected small {
  color: rgba(255, 255, 255, 0.84);
}

.template-card[data-template="pro"].selected {
  background:
    linear-gradient(135deg, rgba(255, 106, 162, 0.34) 0 18%, transparent 18% 100%),
    linear-gradient(145deg, var(--indigo), #514de0);
}

.variant-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin: 0 0 18px;
}

.variant-chip,
.preview-template-button {
  min-height: 44px;
  border: 1px solid rgba(48, 47, 143, 0.13);
  border-radius: 999px;
  padding: 0 17px;
  background: #ffffff;
  color: var(--indigo);
  font-weight: 780;
}

.variant-chip.selected,
.preview-template-button.selected {
  border-color: transparent;
  background: var(--indigo);
  color: #ffffff;
}

/* Offers */
.offer {
  display: grid;
  gap: 18px;
  min-width: 0;
  border-radius: 30px;
  padding: 26px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.card > .offer:first-child,
.template-grid + .variant-picker + .offer,
#templateOffer {
  margin-top: 0;
}

.doc-label {
  display: inline-flex;
  width: fit-content;
  border-radius: 999px;
  padding: 7px 11px;
  background: #f0f1ff;
  color: var(--indigo);
  font-size: 12px;
  font-weight: 820;
  text-transform: uppercase;
}

.simple-offer {
  background:
    linear-gradient(135deg, rgba(255, 203, 92, 0.16) 0 21%, transparent 21% 100%),
    #ffffff;
}

.simple-head,
.pro-cover,
.section-head,
.pro-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.simple-head {
  border-radius: 26px;
  padding: 18px;
  background: var(--indigo);
  color: #ffffff;
}

.simple-head strong,
.simple-head time {
  display: block;
}

.simple-head strong {
  margin-top: 6px;
  font-size: 25px;
  line-height: 1.1;
}

.simple-head time {
  color: rgba(255, 255, 255, 0.75);
  font-size: 13px;
  font-weight: 720;
}

.simple-head .doc-label {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.simple-price {
  display: grid;
  gap: 7px;
  border-radius: 28px;
  padding: 22px;
  background: var(--yellow-soft);
  color: var(--ink);
}

.simple-price span,
.simple-price small,
.simple-tile span,
.simple-tile small,
.pro-meta-grid span,
.brand-block span,
.doc-number span,
.pro-price span,
.pro-notes span,
.pro-total span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.simple-price strong {
  font-size: 54px;
  line-height: 1;
}

.simple-summary-grid,
.pro-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.simple-tile,
.pro-meta-grid div,
.pro-notes div {
  min-width: 0;
  border: 1px solid rgba(48, 47, 143, 0.1);
  border-radius: 22px;
  padding: 16px;
  background: #fbfbff;
}

.simple-tile strong,
.pro-meta-grid strong,
.pro-notes strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.simple-tile.labor {
  background: #f0f1ff;
}

.simple-tile.material {
  background: var(--mint-soft);
}

.simple-tile.transport {
  background: var(--pink-soft);
}

.included {
  display: grid;
  gap: 8px;
  border-top: 1px solid rgba(48, 47, 143, 0.1);
  padding-top: 16px;
}

.included > strong {
  color: var(--ink-2);
  font-size: 18px;
}

.included p {
  max-width: 720px;
  margin: 0;
  color: var(--muted);
}

.pro-offer,
.review-offer {
  --accent: var(--indigo);
  --accent-soft: #f0f1ff;
  --accent-line: rgba(48, 47, 143, 0.16);
  background: #ffffff;
}

.pro-cover {
  border-radius: 28px;
  padding: 18px;
  background: var(--accent-soft);
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}

.brand-block strong {
  display: block;
  margin-top: 4px;
  color: var(--accent);
  font-size: 23px;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.doc-number {
  flex: 0 0 auto;
  text-align: right;
}

.doc-number strong {
  color: var(--ink);
}

.logo-mark {
  position: relative;
  display: grid;
  flex: 0 0 auto;
  width: 58px;
  height: 58px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(48, 47, 143, 0.12);
  border-radius: 20px;
  background: #ffffff;
  color: var(--accent);
  font-weight: 850;
}

button.logo-mark {
  padding: 0;
}

.logo-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 7px;
}

.logo-upload:hover {
  border-color: var(--accent);
  box-shadow: 0 12px 26px rgba(48, 47, 143, 0.12);
}

.logo-upload small {
  position: absolute;
  right: 4px;
  bottom: 4px;
  border-radius: 999px;
  padding: 2px 6px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 9px;
  font-weight: 820;
}

.pro-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.38fr);
  gap: 16px;
  align-items: stretch;
}

.pro-hero h2 {
  margin: 8px 0 0;
  color: var(--accent);
  font-size: 42px;
  line-height: 1.05;
  font-weight: 850;
}

.pro-price {
  display: grid;
  align-content: center;
  border-radius: 28px;
  padding: 20px;
  background: var(--accent);
  color: #ffffff;
}

.pro-price span {
  color: rgba(255, 255, 255, 0.72);
}

.pro-price strong {
  display: block;
  margin-top: 8px;
  font-size: 42px;
  line-height: 1;
}

.pro-meta-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.workflow,
.pro-group {
  overflow: hidden;
  border: 1px solid rgba(48, 47, 143, 0.1);
  border-radius: 26px;
  background: #ffffff;
}

.section-head {
  padding: 15px 17px;
  background: #f0f1ff;
}

.section-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 820;
  text-transform: uppercase;
}

.section-head strong {
  color: var(--ink-2);
}

.workflow-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: rgba(48, 47, 143, 0.1);
}

.workflow-step {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-width: 0;
  padding: 14px;
  background: #ffffff;
}

.workflow-step span {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 12px;
  font-weight: 850;
}

.workflow-step strong {
  font-size: 15px;
  line-height: 1.28;
  overflow-wrap: anywhere;
}

.pro-groups {
  display: grid;
  gap: 13px;
}

.pro-group.labor .section-head {
  background: #f0f1ff;
}

.pro-group.material .section-head {
  background: var(--mint-soft);
}

.pro-group.transport .section-head {
  background: var(--pink-soft);
}

.pro-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  border-top: 1px solid rgba(48, 47, 143, 0.08);
  padding: 14px 17px;
}

.pro-line strong,
.pro-line small {
  display: block;
  overflow-wrap: anywhere;
}

.pro-line strong {
  line-height: 1.28;
}

.pro-line small {
  margin-top: 4px;
  color: var(--muted);
}

.line-total {
  white-space: nowrap;
  color: var(--ink-2);
  font-weight: 850;
}

.pro-notes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.pro-total {
  border-radius: 28px;
  padding: 18px 20px;
  background: var(--accent);
  color: #ffffff;
}

.pro-total div {
  display: grid;
  gap: 4px;
}

.pro-total span {
  color: rgba(255, 255, 255, 0.72);
}

.pro-total strong {
  font-size: 30px;
}

.pro-technical {
  --accent: #17436f;
  --accent-soft: #eaf4ff;
  --accent-line: rgba(23, 67, 111, 0.2);
  grid-template-columns: minmax(220px, 0.68fr) minmax(0, 1.32fr);
  align-items: start;
  background: #f8fbff;
}

.pro-technical .pro-cover {
  grid-column: 1;
  grid-row: 1 / span 4;
  display: grid;
  align-content: start;
  gap: 18px;
  min-height: 100%;
  background: #17436f;
  color: #ffffff;
}

.pro-technical .brand-block,
.pro-technical .doc-number {
  display: grid;
  text-align: left;
}

.pro-technical .brand-block strong,
.pro-technical .doc-number strong {
  color: #ffffff;
}

.pro-technical .brand-block span,
.pro-technical .doc-number span {
  color: rgba(255, 255, 255, 0.72);
}

.pro-technical .logo-mark {
  color: #17436f;
}

.pro-technical .pro-hero,
.pro-technical .workflow,
.pro-technical .inline-editor-head,
.pro-technical .pro-groups,
.pro-technical .pro-total {
  grid-column: 2;
}

.pro-technical .pro-meta-grid,
.pro-technical .pro-notes {
  grid-column: 1;
  grid-template-columns: 1fr;
}

.pro-fresh {
  --accent: #17615c;
  --accent-soft: #effbf4;
  --accent-line: rgba(23, 97, 92, 0.18);
  background:
    linear-gradient(135deg, rgba(53, 228, 172, 0.18) 0 18%, transparent 18% 100%),
    #fffdfa;
}

.pro-fresh .pro-cover {
  background: #ffffff;
}

.pro-fresh .pro-price,
.pro-fresh .pro-total {
  background: #17615c;
}

.pro-fresh .doc-label {
  background: var(--mint-soft);
  color: #17615c;
}

.pro-studio {
  --accent: var(--indigo);
  --accent-soft: #f0f1ff;
}

.review-offer {
  --accent: var(--indigo);
  --accent-soft: #f0f1ff;
}

/* Inline editing */
.inline-editor-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-radius: 24px;
  padding: 14px 16px;
  background: #f0f1ff;
}

.inline-editor-head strong {
  color: var(--indigo);
  font-size: 20px;
}

.mini-button {
  min-height: 42px;
  border-radius: 15px;
  padding: 0 15px;
}

.editable-groups {
  margin-top: 0;
}

.editable-line {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  background: #ffffff;
}

.line-edit-main {
  display: grid;
  gap: 9px;
  min-width: 0;
}

.line-edit-name,
.line-edit-grid input,
.line-edit-grid select {
  min-height: 44px;
  border-radius: 15px;
  font-size: 14px;
  box-shadow: none;
}

.line-edit-grid {
  display: grid;
  grid-template-columns: 0.72fr 0.58fr 0.8fr 1fr;
  gap: 8px;
}

.line-edit-side {
  display: grid;
  gap: 8px;
  justify-items: end;
  min-width: 118px;
}

.delete-line {
  display: grid;
  width: 42px;
  min-height: 42px;
  place-items: center;
  border: 1px solid rgba(255, 106, 162, 0.24);
  border-radius: 15px;
  background: #fff8fb;
  color: #bf315f;
  font-size: 24px;
  line-height: 1;
}

/* Preview and send modals */
.preview-modal,
.send-modal {
  padding: 22px;
  background: rgba(32, 32, 86, 0.34);
  backdrop-filter: blur(14px);
}

.preview-modal {
  display: grid;
  place-items: start center;
}

.send-modal {
  display: grid;
  place-items: center;
}

.preview-shell {
  position: relative;
  width: min(980px, 100%);
  border-radius: 34px;
  padding: 18px;
  background: #ffffff;
  box-shadow: var(--shadow-card);
}

.preview-close {
  position: sticky;
  top: 0;
  z-index: 2;
  float: right;
  width: 44px;
  height: 44px;
  margin: 0 0 12px 12px;
  border: 1px solid rgba(48, 47, 143, 0.13);
  border-radius: 999px;
  background: #ffffff;
  color: var(--ink);
  font-size: 26px;
}

.preview-template-tools {
  display: grid;
  gap: 10px;
  margin: 0 58px 14px 0;
}

.preview-template-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.preview-variant-picker {
  margin: 0;
}

.preview-shell .offer {
  margin: 0;
  box-shadow: none;
}

.send-modal-card {
  display: grid;
  justify-items: center;
  gap: 14px;
  width: min(430px, 100%);
  border-radius: 34px;
  padding: 34px 30px;
  background: #ffffff;
  box-shadow: var(--shadow-card);
  text-align: center;
}

.send-done-icon {
  display: grid;
  width: 76px;
  height: 76px;
  place-items: center;
  border-radius: 999px;
  background: var(--mint-soft);
  font-size: 34px;
}

.success-check {
  position: relative;
  display: inline-grid;
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(180deg, #5bd889, #22b46a);
  box-shadow: 0 12px 24px rgba(34, 180, 106, 0.24);
}

.success-check::before {
  content: "";
  width: 18px;
  height: 10px;
  border-bottom: 4px solid #ffffff;
  border-left: 4px solid #ffffff;
  transform: rotate(-45deg) translate(1px, -1px);
}

.success-check.mini {
  width: 20px;
  height: 20px;
}

.success-check.mini::before {
  width: 8px;
  height: 5px;
  border-bottom-width: 2px;
  border-left-width: 2px;
}

.send-modal-card h2 {
  margin: 0;
  color: var(--indigo);
  font-size: 34px;
  line-height: 1.08;
}

.send-modal-card p {
  margin: 0;
  color: var(--muted);
}

.activation-card {
  justify-items: stretch;
  width: min(500px, 100%);
  text-align: left;
}

.activation-card .send-done-icon,
.activation-card h2,
.activation-card > p,
.activation-card > .status,
.activation-card > .secondary {
  justify-self: center;
  text-align: center;
}

.activation-form {
  width: 100%;
}

.activation-form input {
  text-align: center;
  letter-spacing: 0.04em;
}

.sms-help {
  display: grid;
  gap: 8px;
  border-radius: 24px;
  padding: 16px;
  background: #f0f1ff;
}

.sms-help span {
  color: var(--indigo);
  font-weight: 820;
}

.sms-help p {
  margin: 0;
  color: var(--muted);
}

.sms-help .secondary {
  justify-self: start;
}

/* Responsive */
@media (max-width: 980px) {
  body {
    background:
      linear-gradient(180deg, var(--lavender) 0 680px, var(--page) 680px 100%);
  }

  .hero-intro {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 46px 34px 62px;
  }

  .hero-title span {
    font-size: 64px;
  }

  .hero-title strong {
    font-size: 44px;
  }

  .phone-showcase {
    min-height: 520px;
  }

  .phone-left {
    left: 9%;
  }

  .phone-right {
    right: 9%;
  }

  .pro-technical {
    grid-template-columns: 1fr;
  }

  .pro-technical .pro-cover,
  .pro-technical .pro-hero,
  .pro-technical .workflow,
  .pro-technical .inline-editor-head,
  .pro-technical .pro-groups,
  .pro-technical .pro-total,
  .pro-technical .pro-meta-grid,
  .pro-technical .pro-notes {
    grid-column: auto;
    grid-row: auto;
  }

  .pro-technical .pro-meta-grid,
  .pro-technical .pro-notes {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  body {
    background:
      linear-gradient(180deg, var(--lavender) 0 630px, var(--page) 630px 100%);
  }

  .app {
    padding: 0 0 30px;
  }

  .app-shell {
    width: 100%;
  }

  .step-nav {
    width: calc(100% - 42px);
    margin: 14px auto 10px;
  }

  .step-nav::before {
    top: 24px;
    left: 13%;
    right: 13%;
    background: rgba(255, 255, 255, 0.62);
  }

  .step-tab {
    min-height: 58px;
    font-size: 0;
  }

  .step-tab span {
    width: 44px;
    height: 44px;
  }

  .hero-intro {
    border-radius: 0 0 36px 36px;
    padding: 28px 26px 52px;
  }

  .hero-intro::before {
    bottom: -18%;
    height: 38%;
  }

  .hero-brand {
    margin-bottom: 22px;
    font-size: 21px;
  }

  .brand-cube {
    width: 42px;
    height: 42px;
  }

  .hero-title {
    gap: 8px;
    margin-top: 10px;
  }

  .hero-title span {
    font-size: 42px;
    white-space: nowrap;
  }

  .hero-title strong {
    font-size: 34px;
  }

  .hero-intro .lead {
    font-size: 17px;
  }

  .hero-app-modules {
    grid-template-columns: 1fr;
    gap: 8px;
    margin-top: 20px;
  }

  .hero-app-modules span {
    grid-template-columns: auto 1fr;
    align-items: center;
    min-height: 50px;
    padding: 11px 13px;
  }

  .hero-app-modules strong {
    margin: 0;
  }

  .phone-showcase {
    min-height: 432px;
    margin-top: 8px;
  }

  .phone-main {
    top: 10px;
    width: min(252px, 74vw);
    height: 400px;
  }

  .phone-side {
    top: 86px;
    width: 150px;
    height: 300px;
    opacity: 0.38;
  }

  .phone-left {
    left: -46px;
  }

  .phone-right {
    right: -46px;
  }

  .phone-grid {
    gap: 8px;
    padding: 78px 16px 0;
  }

  .phone-grid span {
    min-height: 62px;
    border-radius: 17px;
    font-size: 18px;
  }

  .phone-hero {
    padding-top: 26px;
  }

  .phone-hero strong {
    font-size: 21px;
  }

  .phone-wave {
    top: 36%;
    height: 112px;
  }

  .phone-total {
    right: 16px;
    bottom: 16px;
    left: 16px;
    padding: 12px 14px;
  }

  .phone-total strong {
    font-size: 22px;
  }

  .start-card > .form-stack {
    width: calc(100% - 28px);
    margin-top: -28px;
    border-radius: 30px;
    padding: 20px;
  }

  .card {
    width: calc(100% - 28px);
    border-radius: 30px;
    padding: 20px;
  }

  .card > h1 {
    font-size: 30px;
  }

  .two-fields,
  .choice-row,
  .choice-row.three-actions,
  .template-grid,
  .simple-summary-grid,
  .pro-hero,
  .pro-meta-grid,
  .workflow-list,
  .pro-notes,
  .pro-total,
  .chat-form,
  .line-edit-grid,
  .editable-line {
    grid-template-columns: 1fr;
  }

  textarea {
    min-height: 166px;
  }

  .huge,
  .primary,
  .secondary {
    width: 100%;
  }

  .offer,
  .processing-required-box,
  .clarification-box {
    border-radius: 28px;
    padding: 18px;
  }

  .simple-head,
  .pro-cover,
  .pro-total {
    align-items: flex-start;
    flex-direction: column;
  }

  .simple-price strong {
    font-size: 44px;
  }

  .pro-hero h2 {
    font-size: 34px;
  }

  .pro-price strong {
    font-size: 38px;
  }

  .pro-line {
    grid-template-columns: 1fr;
  }

  .line-total {
    white-space: normal;
  }

  .inline-editor-head {
    display: grid;
  }

  .line-edit-side {
    justify-items: stretch;
    min-width: 0;
  }

  .delete-line {
    width: 100%;
  }

  .preview-modal,
  .send-modal {
    padding: 10px;
  }

  .preview-shell {
    border-radius: 28px;
    padding: 10px;
  }

  .preview-template-tools {
    margin-right: 54px;
  }

  .preview-template-grid {
    grid-template-columns: 1fr;
  }

  .send-modal-card {
    border-radius: 30px;
    padding: 30px 22px;
  }
}

@media (max-width: 380px) {
  .hero-intro {
    padding-right: 20px;
    padding-left: 20px;
  }

  .hero-title span {
    font-size: 38px;
  }

  .hero-title strong {
    font-size: 31px;
  }

  .phone-main {
    width: min(238px, 76vw);
  }

  .phone-left {
    left: -58px;
  }

  .phone-right {
    right: -58px;
  }
}
