:root {
      --bg-top: #0f1435;
      --bg-mid: #161d4b;
      --bg-bottom: #182053;
      --surface: rgba(24, 32, 83, 0.55);
      --surface-hover: rgba(31, 42, 117, 0.65);
      --surface-selected: rgba(39, 53, 146, 0.45);
      --border: rgba(119, 150, 178, 0.35);
      --border-selected: rgba(244, 166, 74, 0.85);
      --accent: #e38b1f;
      --accent-light: #f4a64a;
      --accent-dark: #cb7c1a;
      --accent-gradient: linear-gradient(180deg, #f4a64a 0%, #e38b1f 50%, #cb7c1a 100%);
      --accent-gradient-hover: linear-gradient(180deg, #f6b66b 0%, #e89838 50%, #d4841f 100%);
      --highlight-blue: #598ad4;
      --text: #ffffff;
      --text-muted: #8b90a9;
      --text-faint: #525e8b;
      --card-white: #ffffff;
      --card-white-text: #1a1a2e;
      --card-white-muted: #484e59;
      --light-bg: #f2f2f2;
      --light-surface: #ffffff;
      --light-border: #e8eaef;
      --light-text: #1a1a1a;
      --light-text-muted: #7a7a7a;
      --light-badge-bg: #fae8d4;
      --light-selected-bg: #fffaf5;
      --radius: 12px;
      --radius-lg: 16px;
      --radius-pill: 100px;
      --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.35);
      --shadow-light: 0 4px 20px rgba(0, 0, 0, 0.06);
      --shadow-white: 0 12px 40px rgba(0, 0, 0, 0.25);
      --container: 1140px;
      --font-display: 'Unbounded', sans-serif;
      --color-primary: var(--accent-dark);
      --color-bg: var(--light-bg);
      --color-surface: var(--light-surface);
      --color-border: var(--light-border);
      --color-text: var(--light-text);
      --color-text-muted: var(--light-text-muted);
      --color-error: #c0392b;
      --color-success: #2e7d32;
    }

    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
    html { scroll-behavior: smooth; }

    body {
      font-family: 'Inter', 'Helvetica Neue', Helvetica, Arial, sans-serif;
      font-size: 16px;
      line-height: 1.55;
      color: var(--light-text);
      background: var(--light-bg);
      min-height: 100vh;
      padding-bottom: 130px;
    }

    .container {
      max-width: var(--container);
      margin: 0 auto;
      padding: 0 20px;
    }

    /* Header, светлая */
    .header {
      background: #ffffff;
      border-bottom: 1px solid var(--light-border);
      box-shadow: 0 2px 16px rgba(0, 0, 0, 0.04);
      position: sticky;
      top: 0;
      z-index: 200;
    }

    .header:has(.btn-templates-panel) .header-inner {
      padding-right: 120px;
    }

    .header-inner {
      display: grid;
      grid-template-columns: 1fr auto 1fr;
      align-items: center;
      gap: 20px;
      padding: 16px 0;
    }

    .logo-wrap {
      grid-column: 1;
      grid-row: 1;
    }

    .header-admin-center {
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 16px;
      grid-column: 2;
      grid-row: 1;
      justify-self: center;
    }

    .header-admin-btn {
      background: none;
      border: none;
      cursor: pointer;
      font-size: 15px;
      font-weight: 600;
      color: var(--accent-dark);
      padding: 0;
      letter-spacing: 0.02em;
    }
    .header-admin-btn:hover { text-decoration: underline; }

    .header-admin-logout {
      background: none;
      border: none;
      cursor: pointer;
      font-size: 14px;
      color: var(--light-text-muted, #888);
      padding: 0;
    }
    .header-admin-logout:hover { color: var(--color-error, #c0392b); }

    .header-right {
      grid-column: 3;
      grid-row: 1;
      justify-self: end;
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: 16px;
      flex-wrap: wrap;
      width: 100%;
      max-width: 100%;
    }

    .header-view-bar {
      display: flex;
      align-items: center;
      max-width: 420px;
    }

    .header-view-note {
      font-size: 13px;
      line-height: 1.45;
      color: var(--light-text-muted);
      text-align: right;
    }

    .header-view-logout {
      background: none;
      border: none;
      cursor: pointer;
      font-size: 14px;
      color: var(--light-text-muted);
      padding: 0;
      white-space: nowrap;
      flex-shrink: 0;
    }

    .header-view-logout:hover { color: var(--color-error); }

    .header-guest-contacts {
      display: flex;
      align-items: center;
      gap: 14px;
      flex-wrap: nowrap;
      justify-content: flex-end;
      margin-left: auto;
    }

    .header-guest-contacts-text {
      display: flex;
      flex-direction: column;
      align-items: flex-end;
      gap: 2px;
      text-align: right;
    }

    .header-guest-label {
      font-size: 11px;
      color: var(--light-text-muted);
      line-height: 1.3;
    }

    .header-guest-name {
      font-size: 15px;
      font-weight: 700;
      color: var(--light-text);
      line-height: 1.3;
    }

    .header-guest-phone {
      font-size: 13px;
      color: var(--light-text-muted);
      text-decoration: none;
      line-height: 1.3;
      transition: color 0.15s;
    }

    .header-guest-phone:hover { color: var(--accent-dark); }

    .header-guest-social {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-shrink: 0;
    }

    .header-social-link {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 36px;
      height: 36px;
      border-radius: 50%;
      background: #f5f6fa;
      border: 1px solid var(--light-border);
      color: #229ED9;
      text-decoration: none;
      transition: background 0.15s, border-color 0.15s, transform 0.15s;
    }

    .header-social-link:hover {
      background: #eef0f5;
      border-color: #c0c4d0;
      transform: scale(1.05);
    }

    .header-social-link--max { color: #8B5CF6; }

    .header-actions {
      display: flex;
      align-items: center;
      gap: 20px;
      flex-wrap: wrap;
    }

    .logo-wrap {
      justify-self: start;
      display: flex;
      align-items: center;
      gap: 16px;
      text-decoration: none;
    }

    .logo-img {
      height: 36px;
      width: auto;
      display: block;
    }

    .logo-subtitle {
      font-size: 13px;
      color: var(--light-text-muted);
      max-width: 280px;
      line-height: 1.4;
    }

    .header-price {
      font-size: 14px;
      color: var(--light-text-muted);
    }

    .header-price strong {
      font-size: 26px;
      color: var(--accent-dark);
      font-weight: 800;
      font-family: 'Unbounded', sans-serif;
    }

    .btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 8px;
      padding: 14px 28px;
      border: none;
      border-radius: var(--radius);
      font-family: 'Inter', sans-serif;
      font-size: 15px;
      font-weight: 600;
      cursor: pointer;
      transition: transform 0.15s, box-shadow 0.2s, opacity 0.2s;
      white-space: nowrap;
    }

    .btn:active:not(:disabled) { transform: scale(0.98); }

    .btn-primary {
      background: var(--accent-gradient);
      color: #ffffff;
      box-shadow: 0 4px 16px rgba(227, 139, 31, 0.35);
    }

    .btn-primary:hover:not(:disabled) {
      background: var(--accent-gradient-hover);
      box-shadow: 0 6px 20px rgba(227, 139, 31, 0.45);
    }

    .btn-primary:disabled {
      opacity: 0.4;
      cursor: not-allowed;
      box-shadow: none;
    }

    .btn-pill {
      border-radius: var(--radius-pill);
      padding: 12px 24px;
      font-size: 14px;
    }

    .btn-outline {
      background: transparent;
      color: var(--light-text);
      border: 1px solid var(--light-border);
      font-weight: 500;
      box-shadow: none;
    }

    .btn-outline:hover {
      border-color: #c0c4d0;
      background: #f5f6fa;
    }

    .section-intro {
      font-size: 17px;
      line-height: 1.65;
      margin-bottom: 28px;
      max-width: 820px;
    }

    .section--light .section-intro { color: var(--light-text-muted); }
    .section--dark .section-intro { color: var(--text-muted); }

    .info-box {
      border-radius: var(--radius-lg);
      padding: 20px 24px;
      margin-bottom: 28px;
      font-size: 14px;
      line-height: 1.6;
    }

    .section--light .info-box {
      background: var(--light-surface);
      border: 1px solid var(--light-border);
      box-shadow: var(--shadow-light);
      color: var(--light-text-muted);
    }

    .section--dark .info-box {
      background: var(--surface);
      border: 1px solid var(--border);
      color: var(--text-muted);
    }

    .section--light .info-box.info-box--dark,
    .section--dark .info-box.info-box--dark,
    .info-box.info-box--dark {
      background: linear-gradient(180deg, var(--bg-top) 0%, var(--bg-mid) 50%, var(--bg-bottom) 100%);
      border: 1px solid var(--border);
      box-shadow: none;
      color: var(--text-muted);
    }

    .info-box strong { color: inherit; }
    .section--light .info-box strong { color: var(--light-text); }
    .section--dark .info-box strong { color: var(--text); }
    .section--light .info-box.info-box--dark strong,
    .info-box.info-box--dark strong { color: var(--text); }

    .info-box-title {
      font-family: 'Unbounded', sans-serif;
      font-size: 15px;
      font-weight: 600;
      margin-bottom: 10px;
    }

    .section--light .info-box-title { color: var(--light-text); }
    .section--dark .info-box-title { color: var(--text); }
    .section--light .info-box.info-box--dark .info-box-title,
    .info-box.info-box--dark .info-box-title { color: var(--text); }

    .info-box.info-box--dark .qual-goal-block {
      background: rgba(244, 166, 74, 0.1);
      border-color: rgba(244, 166, 74, 0.28);
    }

    .info-box.info-box--dark .qual-goal-label,
    .info-box.info-box--dark .qual-goal-sep { color: var(--text-muted); }

    .info-box.info-box--dark .qual-goal-value { color: var(--accent-light); }

    .research-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 12px;
      margin-top: 20px;
    }

    .research-item {
      background: var(--light-surface);
      border: 1px solid var(--light-border);
      border-radius: var(--radius-lg);
      padding: 16px;
      box-shadow: var(--shadow-light);
    }

    .research-item-num {
      font-size: 11px;
      font-weight: 700;
      color: var(--accent-dark);
      letter-spacing: 0.08em;
      margin-bottom: 6px;
    }

    .research-item-title {
      font-size: 14px;
      font-weight: 600;
      color: var(--light-text);
      margin-bottom: 6px;
    }

    .research-item-get {
      font-size: 13px;
      color: var(--light-text-muted);
      margin-bottom: 6px;
    }

    .research-item-why {
      font-size: 12px;
      color: var(--accent-dark);
      font-weight: 500;
    }

    .research-item .card-actions {
      margin-top: 12px;
    }

    .research-item--summary {
      background: linear-gradient(145deg, #fff9f2 0%, #ffffff 55%);
      border: 2px solid rgba(227, 139, 31, 0.35);
      box-shadow: 0 8px 24px rgba(227, 139, 31, 0.08);
    }

    .research-item--summary .research-item-num {
      color: var(--accent);
    }

    .research-item--summary .research-item-title {
      font-size: 15px;
    }

    .research-item--summary .research-item-get {
      line-height: 1.55;
    }

    .card-label {
      font-size: 11px;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      margin-top: 12px;
      margin-bottom: 4px;
      opacity: 0.7;
    }

    .section--dark .card-label { color: var(--text-muted); }
    .section--light .card-label { color: var(--light-text-muted); }

    .card-text {
      font-size: 13px;
      line-height: 1.55;
      margin-bottom: 4px;
    }

    .section--dark .card-text { color: var(--text-muted); }
    .section--light .card-text { color: var(--light-text-muted); }

    .card-result {
      font-size: 13px;
      line-height: 1.55;
      font-weight: 500;
      margin-top: 8px;
      padding-top: 10px;
      border-top: 1px solid rgba(127, 127, 127, 0.2);
    }

    .section--dark .card-result { color: var(--accent-light); }
    .section--light .card-result { color: var(--accent-dark); }

    .checkbox-grid.rich { grid-template-columns: repeat(2, 1fr); gap: 16px; }
    .checkbox-grid.rich .checkbox-card { align-items: flex-start; }

    .checkbox-card-desc,
    .checkbox-card-benefit {
      font-size: 13px;
      line-height: 1.5;
      margin-top: 6px;
    }

    .section--dark .checkbox-card-desc { color: var(--text-muted); }
    .section--dark .checkbox-card-benefit { color: var(--accent-light); font-weight: 500; }
    .section--light .checkbox-card-desc { color: var(--light-text-muted); }
    .section--light .checkbox-card-benefit { color: var(--accent-dark); font-weight: 500; }

    .tariff-card .card-label:first-of-type { margin-top: 0; }

    /* Sections, чередование тёмных и светлых блоков */
    .section {
      padding: 64px 0;
    }

    .section--dark {
      background: linear-gradient(180deg, var(--bg-top) 0%, var(--bg-mid) 50%, var(--bg-bottom) 100%);
      color: var(--text);
    }

    .section--light {
      background: var(--light-bg);
      color: var(--light-text);
    }

    .section-header {
      margin-bottom: 28px;
    }

    .section-badge {
      display: inline-block;
      font-size: 11px;
      font-weight: 700;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      margin-bottom: 16px;
    }

    .section--dark .section-badge {
      color: var(--accent-light);
    }

    .section--light .section-badge {
      background: var(--light-badge-bg);
      color: var(--accent-dark);
      border-radius: var(--radius-pill);
      padding: 5px 14px;
      letter-spacing: 0.1em;
    }

    .section-title {
      font-family: var(--font-display);
      font-size: clamp(24px, 3.2vw, 34px);
      font-weight: 600;
      margin-bottom: 16px;
      line-height: 1.2;
      max-width: 900px;
    }

    .section--dark .section-title { color: var(--text); }
    .section--light .section-title { color: var(--light-text); }

    .title-accent { color: var(--accent); }
    .section--dark .title-accent { color: var(--accent-light); }

    .section-subtitle {
      font-size: 17px;
      margin-bottom: 0;
      max-width: 720px;
      line-height: 1.65;
    }

    .section--dark .section-subtitle { color: var(--text-muted); }
    .section--light .section-subtitle { color: var(--light-text-muted); }

    .section--dark .section-subtitle strong { color: var(--text); }
    .section--light .section-subtitle strong { color: var(--light-text); }

    .mark {
      font-weight: 700;
      font-style: inherit;
      box-decoration-break: clone;
      -webkit-box-decoration-break: clone;
    }

    .mark--bg {
      background: rgba(244, 166, 74, 0.22);
      color: var(--accent-light);
      padding: 0.08em 0.42em;
      border-radius: 6px;
    }

    .mark--text { color: var(--accent-light); }

    .section--light .mark--bg {
      background: var(--light-badge-bg);
      color: var(--accent-dark);
    }

    .section--light .mark--text { color: var(--accent-dark); }

    .subsection-title {
      font-size: 12px;
      font-weight: 600;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      margin: 36px 0 16px;
    }

    .section--dark .subsection-title { color: var(--text-muted); }
    .section--light .subsection-title { color: var(--light-text-muted); }

    /* Tariff cards */
    .tariff-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 20px;
      align-items: stretch;
    }

    .tariff-card {
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: var(--radius-lg);
      padding: 24px;
      cursor: pointer;
      transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
      position: relative;
      backdrop-filter: blur(8px);
      display: flex;
      flex-direction: column;
      height: 100%;
      color: var(--text);
    }

    .tariff-card:hover {
      background: var(--surface-hover);
      border-color: rgba(119, 150, 178, 0.55);
    }

    .tariff-card.selected {
      border: 2px solid var(--border-selected);
      background: var(--surface-selected);
      box-shadow: 0 0 0 1px rgba(244, 166, 74, 0.15), var(--shadow-card);
    }

    .tariff-badge {
      display: none;
      position: absolute;
      top: 16px;
      right: 16px;
      background: var(--accent-gradient);
      color: #fff;
      font-size: 11px;
      font-weight: 600;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      padding: 5px 12px;
      border-radius: var(--radius-pill);
    }

    .tariff-card.selected .tariff-badge { display: block; }

    .tariff-card.recommended {
      border-color: rgba(34, 197, 94, 0.28);
      box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.06);
      padding-top: 44px;
    }

    .section--light .tariff-card.recommended {
      border-color: rgba(34, 197, 94, 0.32);
      box-shadow: var(--shadow-light), 0 0 0 1px rgba(34, 197, 94, 0.06);
    }

    .tariff-card.recommended:hover {
      border-color: rgba(34, 197, 94, 0.4);
    }

    .section--light .tariff-card.recommended:hover {
      border-color: rgba(34, 197, 94, 0.45);
    }

    .tariff-recommended-badge {
      position: absolute;
      top: 16px;
      left: 16px;
    }

    .tariff-name {
      font-family: 'Unbounded', sans-serif;
      font-size: 18px;
      font-weight: 600;
      margin-bottom: 8px;
      color: var(--text);
    }

    .tariff-audience {
      font-size: 13px;
      line-height: 1.55;
      color: var(--text-muted);
      margin-bottom: 16px;
    }

    .section--light .tariff-audience {
      color: var(--light-text-muted);
    }

    .tariff-section {
      margin-bottom: 16px;
    }

    .tariff-section-label {
      font-size: 11px;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      color: var(--text-muted);
      margin-bottom: 6px;
    }

    .tariff-section-text {
      font-size: 13px;
      line-height: 1.55;
      color: var(--text);
      margin: 0 0 10px;
    }

    .tariff-landing {
      display: block;
      font-size: 12px;
      line-height: 1.5;
      color: var(--light-text-muted);
      background: #f5f6fa;
      border: 1px solid var(--light-border);
      border-radius: var(--radius);
      padding: 8px 12px;
    }

    .tariff-landing strong {
      font-weight: 600;
      color: var(--light-text);
    }

    .tariff-meta {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 10px;
      margin-bottom: 16px;
    }

    .tariff-meta-item {
      background: #f5f6fa;
      border: 1px solid var(--light-border);
      border-radius: var(--radius);
      padding: 10px 12px;
    }

    .tariff-meta-label {
      display: block;
      font-size: 10px;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      color: var(--light-text-muted);
      margin-bottom: 4px;
    }

    .tariff-meta-value {
      display: block;
      font-size: 13px;
      line-height: 1.4;
      font-weight: 500;
      color: var(--light-text);
    }

    .tariff-outcome {
      font-size: 13px;
      line-height: 1.55;
      font-weight: 600;
      color: var(--accent-dark);
      background: rgba(227, 139, 31, 0.08);
      border: 1px solid rgba(227, 139, 31, 0.18);
      border-radius: var(--radius);
      padding: 12px 14px;
      margin-bottom: 16px;
    }

    .tariff-outcome-label {
      display: block;
      font-size: 10px;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      color: var(--accent-dark);
      opacity: 0.75;
      margin-bottom: 4px;
    }

    .tariff-price-block {
      margin-top: auto;
      padding-top: 16px;
      border-top: 1px solid var(--border);
    }

    .tariff-desc {
      font-size: 14px;
      color: var(--text-muted);
      margin-bottom: 16px;
    }

    .tariff-features {
      list-style: none;
      margin-bottom: 16px;
    }

    .tariff-features li {
      font-size: 14px;
      padding: 4px 0 4px 20px;
      position: relative;
    }

    .tariff-features li::before {
      content: '✓';
      position: absolute;
      left: 0;
      color: var(--highlight-blue);
      font-weight: 700;
      font-size: 12px;
    }

    .tariff-price {
      font-size: 20px;
      font-weight: 800;
      color: var(--accent-light);
      margin-bottom: 0;
      font-family: 'Unbounded', sans-serif;
    }

    .tariff-price-note {
      font-size: 13px;
      font-weight: 400;
      color: var(--text-muted);
      font-family: 'Inter', sans-serif;
    }

    .section--light .tariff-card {
      background: var(--light-surface);
      border: 1px solid var(--light-border);
      box-shadow: var(--shadow-light);
      backdrop-filter: none;
      color: var(--light-text);
    }

    .section--light .tariff-section-label {
      color: var(--light-text-muted);
    }

    .section--light .tariff-section-text {
      color: var(--light-text);
    }

    .section--light .tariff-price-block {
      border-top-color: var(--light-border);
    }

    .section--light .tariff-card:hover {
      border-color: #dde0e8;
      background: var(--light-surface);
      box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
    }

    .section--light .tariff-card.selected {
      border: 2px solid var(--accent);
      background: var(--light-selected-bg);
      box-shadow: 0 4px 16px rgba(227, 139, 31, 0.12);
    }

    .section--light .tariff-name { color: var(--light-text); }
    .section--light .tariff-price { color: var(--accent-dark); }
    .section--light .tariff-price-note { color: var(--light-text-muted); }

    /* Checkbox cards */
    .checkbox-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 12px;
    }

    .checkbox-grid.cols-2 {
      grid-template-columns: repeat(2, 1fr);
    }

    .checkbox-card {
      display: flex;
      align-items: flex-start;
      gap: 12px;
      border-radius: var(--radius-lg);
      padding: 16px;
      cursor: pointer;
      transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
      user-select: none;
    }

    /* Карточки на тёмном фоне */
    .section--dark .checkbox-card {
      background: var(--surface);
      border: 1px solid var(--border);
      backdrop-filter: blur(8px);
    }

    .section--dark .checkbox-card:hover {
      background: var(--surface-hover);
      border-color: rgba(119, 150, 178, 0.55);
    }

    .section--dark .checkbox-card.selected {
      border: 1px solid var(--border-selected);
      background: var(--surface-selected);
    }

    .section--dark .checkbox-card-name { color: var(--text); }
    .section--dark .checkbox-card-price { color: var(--accent-light); }

    /* Карточки на светлом фоне, белые, как отзывы на audit */
    .section--light .checkbox-card {
      background: var(--light-surface);
      border: 1px solid var(--light-border);
      box-shadow: var(--shadow-light);
    }

    .section--light .checkbox-card:hover {
      border-color: #dde0e8;
      box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
    }

    .section--light .checkbox-card.selected {
      border: 2px solid var(--accent);
      background: var(--light-selected-bg);
      box-shadow: 0 4px 16px rgba(227, 139, 31, 0.12);
    }

    .section--light .checkbox-card-name { color: var(--light-text); }
    .section--light .checkbox-card-price { color: var(--accent-dark); }

    .checkbox-card input {
      width: 18px;
      height: 18px;
      margin-top: 2px;
      accent-color: var(--accent);
      flex-shrink: 0;
      cursor: pointer;
    }

    .checkbox-card-content { flex: 1; min-width: 0; }

    .checkbox-card-name {
      font-size: 15px;
      font-weight: 600;
      margin-bottom: 4px;
    }

    .checkbox-card-price {
      font-size: 14px;
      font-weight: 600;
    }

    .checkbox-card-name-row {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 8px;
      margin-bottom: 4px;
    }

    .checkbox-card-name-row .checkbox-card-name { margin-bottom: 0; }

    .badge-recommended {
      display: inline-block;
      background: #22c55e;
      color: #fff;
      font-size: 10px;
      font-weight: 700;
      padding: 3px 9px;
      border-radius: 20px;
      text-transform: uppercase;
      letter-spacing: 0.04em;
      flex-shrink: 0;
    }

    .card-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin-top: 12px;
    }

    .tariff-card .card-actions {
      margin-top: 4px;
      margin-bottom: 16px;
    }

    .btn-example {
      display: inline-flex;
      align-items: center;
      gap: 4px;
      padding: 6px 12px;
      border-radius: 8px;
      border: 1px solid rgba(227, 139, 31, 0.45);
      background: rgba(227, 139, 31, 0.1);
      color: var(--accent-light);
      font-family: inherit;
      font-size: 12px;
      font-weight: 600;
      cursor: pointer;
      transition: background 0.15s;
    }

    .section--light .btn-example {
      color: var(--accent-dark);
      border-color: rgba(227, 139, 31, 0.35);
      background: rgba(227, 139, 31, 0.08);
    }

    .btn-example:hover { background: rgba(227, 139, 31, 0.2); }

    .landing-examples-bar {
      display: flex;
      flex-wrap: wrap;
      gap: 10px;
      margin-bottom: 24px;
    }

    .summary-kpi-note {
      font-size: 10px;
      color: var(--accent-light);
      margin-top: 3px;
      font-weight: 600;
      letter-spacing: 0.02em;
    }

    .example-modal .modal { max-width: 900px; }
    .example-modal-body { padding: 0 28px 28px; }
    .example-caption {
      font-size: 14px;
      color: var(--card-white-muted);
      margin-bottom: 16px;
      line-height: 1.5;
    }
    .example-image-wrap {
      background: #f5f6fa;
      border: 1px solid #e8eaef;
      border-radius: 12px;
      overflow: hidden;
      max-height: 70vh;
      overflow-y: auto;
    }
    .example-image-wrap img {
      width: 100%;
      height: auto;
      display: block;
    }

    .example-pdf {
      display: none;
      width: 100%;
      height: 70vh;
      border: none;
      background: #fff;
    }

    .example-pdf.visible {
      display: block;
    }

    .example-download {
      display: inline-flex;
      margin-top: 12px;
      text-decoration: none;
    }

    .example-download.hidden {
      display: none;
    }
    .example-hint {
      font-size: 12px;
      color: #888;
      margin-top: 12px;
    }
    .summary-panel {
      position: fixed;
      bottom: 0;
      left: 0;
      right: 0;
      background: rgba(15, 20, 53, 0.92);
      backdrop-filter: blur(16px);
      -webkit-backdrop-filter: blur(16px);
      border-top: 1px solid var(--border);
      color: var(--text);
      z-index: 90;
      box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.3);
    }

    .summary-panel.hidden { display: none; }

    /* === KP PANEL (admin, bottom of page) === */

    .kp-panel {
      background: var(--light-surface);
      border-top: 1px solid var(--light-border);
      padding: 40px 0 48px;
      margin-top: 8px;
    }

    .kp-panel.hidden { display: none; }

    .kp-panel-head {
      margin-bottom: 24px;
    }

    .kp-panel-title {
      font-family: 'Unbounded', sans-serif;
      font-size: 22px;
      font-weight: 600;
      color: var(--light-text);
      margin: 0 0 8px;
    }

    .kp-panel-desc {
      margin: 0;
      font-size: 14px;
      color: var(--light-text-muted);
    }

    .kp-panel-preview {
      background: #fff;
      border: 1px solid var(--light-border);
      border-radius: var(--radius);
      padding: 28px;
      margin-bottom: 20px;
    }

    .kp-panel .kp-block-title {
      color: var(--light-text-muted);
    }

    .kp-panel .kp-block-content,
    .kp-panel .kp-title,
    .kp-panel .kp-validity {
      color: var(--light-text);
    }

    .kp-panel-extra-toggle {
      margin-bottom: 12px;
    }

    .kp-panel-extra-toggle button {
      background: none;
      border: none;
      color: var(--accent);
      font-family: inherit;
      font-size: 13px;
      cursor: pointer;
      padding: 0;
      text-decoration: underline;
    }

    .kp-panel-extra {
      display: none;
      background: #fff;
      border: 1px solid var(--light-border);
      border-radius: var(--radius);
      padding: 20px 24px;
      margin-bottom: 20px;
    }

    .kp-panel-extra.open { display: block; }

    .kp-panel-extra label {
      display: block;
      font-size: 12px;
      font-weight: 600;
      color: var(--light-text-muted);
      margin-bottom: 6px;
    }

    .kp-panel-extra .field-row {
      margin-bottom: 12px;
    }

    .kp-panel-extra .field-row.cols-2 {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 12px;
    }

    .kp-panel-field {
      width: 100%;
      padding: 12px 16px;
      border: 1px solid var(--light-border);
      border-radius: 8px;
      font-family: inherit;
      font-size: 14px;
      background: var(--light-bg);
      color: var(--light-text);
    }

    .kp-panel-field:focus {
      outline: none;
      border-color: var(--accent);
    }

    textarea.kp-panel-field {
      resize: vertical;
      min-height: 56px;
    }

    .kp-panel-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 12px;
      align-items: center;
    }

    .kp-panel-client-name {
      flex: 1;
      min-width: 220px;
      max-width: 360px;
    }

    .kp-save-status {
      width: 100%;
      margin: 0;
      font-size: 13px;
    }

    .kp-save-status.success { color: var(--color-success, #2e7d32); }
    .kp-save-status.error { color: var(--color-error, #c0392b); }

    .kp-panel-error {
      width: 100%;
      margin: 0;
      color: #c0392b;
      font-size: 13px;
      display: none;
    }

    .kp-panel-error.visible { display: block; }

    @media (max-width: 560px) {
      .kp-panel-extra .field-row.cols-2 { grid-template-columns: 1fr; }
      .kp-panel-actions { flex-direction: column; align-items: stretch; }
      .kp-panel-client-name { max-width: none; }
    }

    .summary-inner {
      max-width: var(--container);
      margin: 0 auto;
      padding: 16px 20px;
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: 24px;
      flex-wrap: wrap;
    }

    .summary-breakdown {
      display: flex;
      gap: 24px;
      flex-wrap: wrap;
    }

    .summary-breakdown-item {
      text-align: center;
    }

    .summary-breakdown-label {
      font-size: 11px;
      color: var(--text-muted);
      text-transform: uppercase;
      letter-spacing: 0.1em;
    }

    .summary-breakdown-value {
      font-size: 20px;
      font-weight: 700;
      color: var(--accent-light);
      font-family: 'Unbounded', sans-serif;
    }

    /* Modal, белая карточка как форма на audit */
    .modal-overlay {
      display: none;
      position: fixed;
      inset: 0;
      background: rgba(10, 14, 40, 0.75);
      backdrop-filter: blur(4px);
      z-index: 200;
      overflow-y: auto;
      padding: 24px 16px;
    }

    .modal-overlay.open { display: flex; align-items: flex-start; justify-content: center; }

    .modal {
      background: var(--card-white);
      border-radius: 16px;
      max-width: 720px;
      width: 100%;
      margin: auto;
      box-shadow: var(--shadow-white);
      color: var(--card-white-text);
    }

    .modal-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 24px 28px;
      border-bottom: 1px solid #e8eaef;
    }

    .modal-header h2 {
      font-family: 'Unbounded', sans-serif;
      font-size: 20px;
      font-weight: 600;
      color: var(--card-white-text);
    }

    .modal-close {
      background: none;
      border: none;
      font-size: 28px;
      line-height: 1;
      cursor: pointer;
      color: var(--card-white-muted);
      padding: 4px 8px;
    }

    .modal-close:hover { color: var(--card-white-text); }

    .modal-body {
      padding: 28px;
    }

    .kp-block {
      margin-bottom: 24px;
    }

    .kp-block-title {
      font-size: 11px;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.12em;
      color: var(--card-white-muted);
      margin-bottom: 10px;
    }

    .kp-block-content {
      font-size: 15px;
      line-height: 1.6;
      color: var(--card-white-text);
    }

    .kp-block-content ul {
      list-style: none;
      padding-left: 0;
    }

    .kp-block-content li {
      padding: 3px 0 3px 18px;
      position: relative;
    }

    .kp-block-content li::before {
      content: '·';
      position: absolute;
      left: 0;
      color: var(--accent);
    }

    .kp-pricing {
      background: #f5f6fa;
      border: 1px solid #e8eaef;
      border-radius: var(--radius);
      padding: 20px 24px;
      margin-bottom: 24px;
    }

    .kp-pricing-row {
      display: flex;
      justify-content: space-between;
      padding: 8px 0;
      font-size: 15px;
    }

    .kp-pricing-row.total {
      border-top: 1px solid #dde0e8;
      margin-top: 8px;
      padding-top: 16px;
      font-weight: 700;
      font-size: 17px;
    }

    .kp-pricing-row.total span:last-child {
      color: var(--accent-dark);
      font-family: 'Unbounded', sans-serif;
    }

    .kp-next-step {
      background: #faf5ef;
      border: 1px solid rgba(227, 139, 31, 0.2);
      border-radius: var(--radius);
      padding: 20px 24px;
      margin-bottom: 24px;
      font-size: 15px;
      line-height: 1.6;
      color: var(--card-white-muted);
    }

    .kp-next-step strong { color: var(--accent-dark); }

    .kp-title {
      font-family: 'Unbounded', sans-serif;
      font-size: 18px;
      font-weight: 600;
      margin-bottom: 24px;
      color: var(--card-white-text);
    }

    .kp-empty {
      color: var(--card-white-muted);
    }

    .modal-footer .btn-outline {
      color: var(--card-white-text);
      border-color: #dde0e8;
    }

    .modal-footer .btn-outline:hover {
      background: #f5f6fa;
      border-color: #c0c4d0;
    }

    .kp-validity {
      background: #fff8eb;
      border: 1px solid rgba(227, 139, 31, 0.35);
      border-radius: var(--radius);
      padding: 12px 16px;
      margin-bottom: 20px;
      font-size: 14px;
      color: var(--card-white-text);
    }

    .kp-validity strong { color: var(--accent-dark); }

    .modal-client-name,
    .modal-kp-field {
      flex: 1;
      min-width: 200px;
      padding: 12px 16px;
      border: 1px solid #dde0e8;
      border-radius: 8px;
      font-family: inherit;
      font-size: 14px;
    }

    .modal-kp-field {
      width: 100%;
      resize: vertical;
      min-height: 56px;
    }

    .modal-client-name:focus,
    .modal-kp-field:focus {
      outline: none;
      border-color: var(--accent);
    }

    .modal-kp-extra {
      width: 100%;
      padding: 0 28px 16px;
      display: none;
    }

    .modal-kp-extra.open { display: block; }

    .modal-kp-extra-toggle {
      width: 100%;
      padding: 0 28px 12px;
    }

    .modal-kp-extra-toggle button {
      background: none;
      border: none;
      color: var(--accent);
      font-family: inherit;
      font-size: 13px;
      cursor: pointer;
      padding: 0;
      text-decoration: underline;
    }

    .modal-kp-extra label {
      display: block;
      font-size: 12px;
      font-weight: 600;
      color: var(--light-text-muted);
      margin-bottom: 6px;
    }

    .modal-kp-extra .field-row {
      margin-bottom: 12px;
    }

    .modal-kp-extra .field-row.cols-2 {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 12px;
    }

    @media (max-width: 560px) {
      .modal-kp-extra .field-row.cols-2 { grid-template-columns: 1fr; }
    }

    .btn-loading { opacity: 0.7; pointer-events: none; }

    .modal-error {
      color: #c0392b;
      font-size: 13px;
      margin-top: 8px;
      display: none;
    }

    .modal-error.visible { display: block; }

    .modal-footer {
      padding: 0 28px 28px;
      display: flex;
      gap: 12px;
      flex-wrap: wrap;
      align-items: center;
    }

    /* Print */
    @media print {
      body { padding-bottom: 0; background: white; }
      .header, .section, .summary-panel, .modal-header, .modal-footer, .modal-close { display: none !important; }
      .modal-overlay {
        display: block !important;
        position: static;
        background: none;
        padding: 0;
      }
      .modal {
        box-shadow: none;
        max-width: 100%;
      }
      .modal-body { padding: 0; }
    }

    @media (max-width: 900px) {
      .header-actions { gap: 12px; }
      .tariff-grid { grid-template-columns: 1fr; }
      .checkbox-grid { grid-template-columns: repeat(2, 1fr); }
      .checkbox-grid.rich { grid-template-columns: 1fr; }
      .research-grid { grid-template-columns: 1fr; }
    }

    @media (max-width: 560px) {
      .checkbox-grid,
      .checkbox-grid.cols-2 { grid-template-columns: 1fr; }
      .header-inner {
        grid-template-columns: 1fr;
        justify-items: stretch;
      }
      .header-admin-center { order: 2; justify-self: center; }
      .header-right { order: 3; justify-self: stretch; flex-direction: column; align-items: stretch; }
      .header-view-note { text-align: left; }
      .header-guest-contacts { flex-direction: column; align-items: flex-start; }
      .header-guest-contacts-text { align-items: flex-start; text-align: left; }
      .logo-wrap { order: 1; }
      .summary-inner { flex-direction: column; align-items: stretch; }
      .summary-breakdown { justify-content: space-between; width: 100%; }
    }

/* === LOGIN SCREEN === */

#login-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, var(--bg-top) 0%, var(--bg-mid) 50%, var(--bg-bottom) 100%);
  padding: 24px;
}

.login-card {
  background: var(--light-surface);
  border: 1px solid var(--light-border);
  border-radius: var(--radius-lg);
  padding: 44px 40px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-white);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.login-brand {
  text-align: center;
  margin-bottom: 4px;
}

.login-logo-img {
  height: 38px;
  width: auto;
  margin: 0 auto 14px;
  display: block;
}

.login-logo {
  font-family: var(--font-display);
  font-size: clamp(22px, 4vw, 28px);
  font-weight: 700;
  color: var(--light-text);
  text-align: center;
  margin-bottom: 4px;
}

.login-subtitle {
  font-size: 15px;
  color: var(--light-text-muted);
  text-align: center;
  margin-bottom: 20px;
  line-height: 1.55;
}

.login-note {
  font-size: 13px;
  color: var(--light-text-muted);
  text-align: center;
  line-height: 1.5;
  margin-top: 4px;
}

#login-role-select,
#login-admin-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.login-form-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--light-text);
}

.login-card input[type="text"],
.login-card input[type="password"] {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--light-border);
  border-radius: var(--radius);
  font-size: 15px;
  font-family: inherit;
  background: #fff;
  color: var(--light-text);
  transition: border-color 0.15s;
}

.login-card input:focus {
  outline: none;
  border-color: var(--accent);
}

.btn-full { width: 100%; }

.btn-back {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 14px;
  color: var(--color-text-muted, #888);
  padding: 0;
  text-align: left;
  margin-bottom: 4px;
  transition: color 0.2s;
}
.btn-back:hover { color: var(--color-text, #1a1a1a); }

.login-error {
  color: var(--color-error, #c0392b);
  font-size: 13px;
  text-align: center;
  margin: 0;
}

/* Плашки режима просмотра */
#client-banner {
  position: sticky;
  top: 0;
  z-index: 150;
  background: linear-gradient(145deg, #fff9f2 0%, #fff 55%);
  border-bottom: 2px solid rgba(227, 139, 31, 0.25);
  padding: 12px 20px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--light-text);
  text-align: center;
}

#client-banner a {
  color: var(--accent-dark);
  font-weight: 600;
  text-decoration: none;
}

#client-banner a:hover { text-decoration: underline; }

/* Shake-анимация для неверного пароля */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%       { transform: translateX(-8px); }
  40%       { transform: translateX(8px); }
  60%       { transform: translateX(-6px); }
  80%       { transform: translateX(6px); }
}
.shake { animation: shake 0.4s ease; }

/* Бейджи роли в хедере */
.role-badge {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 99px;
  letter-spacing: 0.02em;
}
.role-badge.client { background: #e3f2fd; color: #1565c0; }
.role-badge.admin  { background: #e8f5e9; color: #2e7d32; }

.btn-logout {
  font-size: 13px;
  padding: 4px 12px;
  border: 1px solid var(--color-border, #ddd);
  border-radius: 6px;
  cursor: pointer;
  background: none;
  color: var(--color-text-muted, #888);
  transition: all 0.2s;
}
.btn-logout:hover { border-color: var(--color-error, #c0392b); color: var(--color-error, #c0392b); }

/* === ONBOARDING SCREEN === */

#onboarding-screen {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, var(--bg-top) 0%, var(--bg-mid) 50%, var(--bg-bottom) 100%);
  padding: 24px;
  overflow-y: auto;
}

#onboarding-screen.onboarding-screen--modal {
  z-index: 10000;
  background: rgba(0, 0, 0, 0.45);
  align-items: flex-start;
  padding-top: 48px;
}

#onboarding-screen.onboarding-screen--modal .onboarding-card {
  max-height: calc(100vh - 96px);
  overflow-y: auto;
  position: relative;
}

.onboarding-close {
  position: absolute;
  top: 12px;
  right: 14px;
  background: none;
  border: none;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  color: var(--color-text-muted, #888);
  padding: 0;
}
.onboarding-close:hover { color: var(--color-text, #1a1a1a); }

.onboarding-card {
  position: relative;
  background: var(--light-surface);
  border: 1px solid var(--light-border);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  width: 100%;
  max-width: 560px;
  box-shadow: var(--shadow-white);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.onboarding-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--light-badge-bg);
  color: var(--accent-dark);
  border-radius: var(--radius-pill);
  padding: 5px 14px;
  margin-bottom: 12px;
}

.onboarding-header h2 {
  font-family: var(--font-display);
  font-size: clamp(20px, 3vw, 26px);
  font-weight: 600;
  line-height: 1.25;
  margin-bottom: 6px;
  color: var(--light-text);
}
.onboarding-header p {
  font-size: 15px;
  color: var(--light-text-muted);
  line-height: 1.55;
}

.onboarding-templates { display: flex; flex-direction: column; gap: 8px; }
.templates-row { display: flex; gap: 8px; }
.templates-row select { flex: 1; }

.field-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--light-text);
}

.field-hint {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
  color: var(--light-text-muted);
}

.onboarding-divider {
  text-align: center;
  font-size: 13px;
  color: var(--light-text-muted);
  position: relative;
}
.onboarding-divider::before,
.onboarding-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 38%;
  height: 1px;
  background: var(--light-border);
}
.onboarding-divider::before { left: 0; }
.onboarding-divider::after  { right: 0; }

.onboarding-fields { display: flex; flex-direction: column; gap: 14px; }

.onboarding-funnel-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-dark);
  margin-top: 4px;
}

.fields-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.field-group { display: flex; flex-direction: column; gap: 5px; }

.onboarding-card input[type="text"],
.onboarding-card input[type="number"],
.onboarding-card select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--light-border);
  border-radius: var(--radius);
  font-size: 15px;
  font-family: inherit;
  background: #fff;
  color: var(--light-text);
  transition: border-color 0.15s;
}
.onboarding-card select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%237a7a7a' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}
.onboarding-card input:focus,
.onboarding-card select:focus {
  outline: none;
  border-color: var(--accent);
}

.onboarding-save-row {
  display: flex;
  gap: 8px;
}
.onboarding-save-row input { flex: 1; }

.save-status {
  font-size: 13px;
  text-align: center;
  margin-top: -8px;
}
.save-status.success { color: var(--color-success, #2e7d32); }
.save-status.error   { color: var(--color-error, #c0392b); }

@media (max-width: 480px) {
  .fields-grid-2 { grid-template-columns: 1fr; }
  .onboarding-save-row { flex-direction: column; }
}

/* === DECLENSION PREVIEW === */

.declension-preview {
  background: color-mix(in oklch, var(--color-primary, #01696f) 5%, var(--color-bg, #f7f6f2));
  border: 1px solid color-mix(in oklch, var(--color-primary, #01696f) 20%, transparent);
  border-radius: 8px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: -4px;
}

.declension-preview-title {
  font-size: 12px;
  color: var(--color-text-muted, #888);
  font-weight: 500;
}

.declension-grid {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.declension-row {
  display: grid;
  grid-template-columns: 160px 1fr;
  align-items: center;
  gap: 8px;
}

.decl-label {
  font-size: 12px;
  color: var(--color-text-muted, #888);
  white-space: nowrap;
}

.decl-label em {
  font-style: normal;
  color: var(--color-text-faint, #bbb);
  font-size: 11px;
}

.decl-input {
  width: 100%;
  padding: 5px 8px;
  font-size: 13px;
  border: 1px solid var(--color-border, #ddd);
  border-radius: 6px;
  background: var(--color-surface, #fff);
  color: var(--color-text, #1a1a1a);
  font-family: inherit;
  transition: border-color 0.2s;
}

.decl-input:focus {
  outline: none;
  border-color: var(--color-primary, #01696f);
}

@media (max-width: 480px) {
  .declension-row { grid-template-columns: 1fr; gap: 3px; }
}

/* === ADMIN PAGE === */

#admin-page {
  min-height: 100dvh;
  background: var(--color-bg, #f7f6f2);
  display: flex;
  flex-direction: column;
}

.admin-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-surface, #fff);
  border-bottom: 1px solid var(--color-border, #e0e0e0);
  padding: 0 32px;
  height: 60px;
  display: flex;
  align-items: center;
  gap: 24px;
  max-width: 860px;
  width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.admin-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.admin-logo {
  font-family: var(--font-display, 'Unbounded', sans-serif);
  font-size: 16px;
  font-weight: 700;
}

.admin-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 99px;
  background: #e8f5e9;
  color: #2e7d32;
}

.admin-nav {
  display: flex;
  gap: 4px;
  flex: 1;
}

.admin-nav-item {
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 500;
  border-radius: 6px;
  color: var(--color-text-muted, #888);
  background: none;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
}

.admin-nav-item:hover {
  background: var(--color-surface-offset, #f3f0ec);
  color: var(--color-text, #1a1a1a);
}

.admin-nav-item.active {
  background: var(--color-surface-offset, #f3f0ec);
  color: var(--color-text, #1a1a1a);
  font-weight: 600;
}

.admin-header-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.admin-body {
  flex: 1;
  padding: 32px;
  max-width: 860px;
  width: 100%;
  margin: 0 auto;
}

.admin-section-header {
  margin-bottom: 28px;
}

.admin-section-title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 6px;
}

.admin-section-desc {
  font-size: 14px;
  color: var(--color-text-muted, #888);
}

.admin-section-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.admin-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.admin-form-block {
  background: var(--color-surface, #fff);
  border: 1px solid var(--color-border, #e0e0e0);
  border-radius: 12px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.admin-form-block-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-text, #1a1a1a);
  margin-bottom: 4px;
}

.funnel-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.funnel-stage {
  background: var(--color-surface-offset, #f7f6f2);
  border: 1px solid var(--color-border, #e0e0e0);
  border-radius: 10px;
  padding: 16px;
}

.funnel-stage-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-primary, #01696f);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.funnel-stage-hint {
  margin: 0 0 10px;
  font-size: 12px;
  line-height: 1.45;
}

.funnel-arrow {
  text-align: center;
  color: var(--color-text-faint, #bbb);
  font-size: 18px;
  padding: 4px 0;
  line-height: 1;
  flex-shrink: 0;
  width: 28px;
}

.funnel-conv-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 0 6px 8px;
}

.funnel-conv-field {
  flex: 1;
  min-width: 0;
}

.funnel-conv-field .field-label {
  font-size: 12px;
  margin-bottom: 4px;
  color: var(--color-text-muted, #888);
}

.funnel-conv-input-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: 140px;
}

.funnel-conv-input {
  width: 72px;
  padding: 8px 10px;
  border: 1px solid var(--color-border, #ddd);
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  background: var(--color-bg, #f9f9f9);
  color: var(--color-text, #1a1a1a);
  text-align: center;
}

.funnel-conv-input:focus {
  outline: none;
  border-color: var(--color-primary, #01696f);
}

.funnel-conv-suffix {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text-muted, #888);
}

.company-input-row {
  display: flex;
  align-items: stretch;
  gap: 8px;
}

.company-input-row .company-input {
  flex: 1;
  min-width: 0;
}

.business-type-toggle {
  display: flex;
  flex-shrink: 0;
  background: var(--color-surface-offset, #f3f0ec);
  border-radius: 8px;
  padding: 3px;
  border: 1px solid var(--color-border, #e0e0e0);
  gap: 2px;
}

.business-type-btn {
  padding: 8px 12px;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  background: transparent;
  color: var(--color-text-muted, #888);
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
  white-space: nowrap;
}

.business-type-btn:hover {
  color: var(--color-text, #1a1a1a);
}

.business-type-btn.active[data-type="b2c"] {
  background: linear-gradient(135deg, #e38b1f, #f4a64a);
  color: #fff;
  box-shadow: 0 2px 8px rgba(227, 139, 31, 0.25);
}

.business-type-btn.active[data-type="b2b"] {
  background: linear-gradient(135deg, #01696f, #018a92);
  color: #fff;
  box-shadow: 0 2px 8px rgba(1, 105, 111, 0.25);
}

.cycle-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cycle-preset-btn {
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  border: 1.5px solid var(--color-border, #ddd);
  background: var(--color-bg, #f9f9f9);
  color: var(--color-text-muted, #666);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.cycle-preset-btn:hover {
  border-color: var(--color-primary, #01696f);
  color: var(--color-primary, #01696f);
}

.cycle-preset-btn.active {
  border-color: var(--color-primary, #01696f);
  background: color-mix(in oklch, var(--color-primary, #01696f) 10%, #fff);
  color: var(--color-primary, #01696f);
}

.funnel-stage--budget {
  background: color-mix(in oklch, var(--color-primary, #01696f) 6%, var(--color-surface-offset, #f7f6f2));
  border-color: color-mix(in oklch, var(--color-primary, #01696f) 25%, var(--color-border, #e0e0e0));
}

.funnel-conv-row--spacer {
  padding: 2px 0;
}

.field-group--full {
  grid-column: 1 / -1;
}

.input-sum--readonly {
  background: var(--color-surface-offset, #f0efeb) !important;
  color: var(--color-text-muted, #666) !important;
  cursor: default;
  border-style: dashed;
}

.funnel-economics {
  margin-top: 20px;
  padding: 16px 18px;
  border-radius: 10px;
  background: color-mix(in oklch, var(--color-primary, #01696f) 5%, #fff);
  border: 1px solid color-mix(in oklch, var(--color-primary, #01696f) 18%, var(--color-border, #e0e0e0));
}

.funnel-economics-title {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-primary, #01696f);
  margin-bottom: 8px;
}

.funnel-economics-period {
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  color: var(--color-text-muted, #888);
  font-size: 12px;
}

.funnel-economics-cycle-hint {
  font-size: 12px;
  color: var(--color-primary, #01696f);
  margin: 0 0 10px;
  line-height: 1.45;
}

.funnel-economics-cycle-hint:empty {
  display: none;
}

.funnel-period-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: lowercase;
  color: var(--color-text-muted, #888);
  background: color-mix(in oklch, var(--color-border, #e0e0e0) 55%, #fff);
  vertical-align: middle;
}

.funnel-period-badge--accent {
  color: var(--color-primary, #01696f);
  background: color-mix(in oklch, var(--color-primary, #01696f) 12%, #fff);
}

.funnel-economics-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.funnel-economics-grid--extended {
  grid-template-columns: repeat(3, 1fr);
}

.funnel-economics-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 14px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed color-mix(in oklch, var(--color-primary, #01696f) 20%, var(--color-border, #e0e0e0));
  font-size: 12px;
  color: var(--color-text-muted, #888);
}

.funnel-economics-footer strong {
  color: var(--color-primary, #01696f);
}

.funnel-economics-footer-note {
  font-size: 11px;
  color: var(--color-text-faint, #aaa);
}

.funnel-economics-retainer-note,
.economics-retainer-note {
  margin: 10px 0 0;
  font-size: 11px;
  color: var(--color-text-faint, #aaa);
  line-height: 1.45;
}

.cac-breakdown {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 8px;
  background: color-mix(in oklch, var(--color-primary, #01696f) 4%, #fff);
  border: 1px solid color-mix(in oklch, var(--color-primary, #01696f) 14%, var(--color-border, #e0e0e0));
}

.cac-breakdown:empty {
  display: none;
}

.cac-breakdown--inline {
  margin-top: 8px;
  padding: 10px 12px;
}

.cac-breakdown-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-primary, #01696f);
  margin-bottom: 8px;
}

.cac-breakdown-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.cac-breakdown-row {
  display: grid;
  grid-template-columns: minmax(110px, 130px) 1fr auto;
  gap: 6px 10px;
  align-items: baseline;
  font-size: 12px;
  line-height: 1.4;
}

.cac-breakdown-row--pending {
  grid-template-columns: minmax(110px, 130px) 1fr;
  color: var(--color-text-muted, #888);
  font-style: italic;
}

.cac-breakdown-row--muted .cac-breakdown-formula {
  color: var(--color-text-faint, #aaa);
}

.cac-breakdown-label {
  font-weight: 600;
  color: var(--color-text, #1a1a1a);
}

.cac-breakdown-formula {
  color: var(--color-text-muted, #666);
}

.cac-breakdown-per-sale {
  font-weight: 700;
  color: var(--color-primary, #01696f);
  white-space: nowrap;
  font-size: 11px;
}

.cac-breakdown-total {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: flex-end;
  gap: 6px 10px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed color-mix(in oklch, var(--color-primary, #01696f) 18%, var(--color-border, #e0e0e0));
  font-size: 12px;
  color: var(--color-text-muted, #888);
}

.cac-breakdown-total strong {
  font-size: 15px;
  font-weight: 800;
  color: var(--color-primary, #01696f);
  font-family: var(--font-display, 'Unbounded', sans-serif);
}

@media (max-width: 640px) {
  .cac-breakdown-row {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  .cac-breakdown-row--pending {
    grid-template-columns: 1fr;
  }
}

.client-economics {
  margin-top: 28px;
  margin-bottom: 0;
}

.client-economics .economics-panel {
  border: none;
  padding: 0;
  background: transparent;
}

.economics-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.economics-panel-head {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.economics-panel-title {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-primary, #01696f);
}

.economics-panel-period {
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  color: var(--color-text-muted, #888);
  font-size: 12px;
}

.economics-assumptions {
  margin: 0;
  font-size: 12px;
  color: var(--color-text-muted, #666);
  line-height: 1.45;
}

.economics-funnel-path {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--color-primary, #01696f);
  line-height: 1.45;
}

.economics-hero {
  padding: 14px 16px;
  border-radius: 10px;
  background: color-mix(in oklch, var(--color-primary, #01696f) 7%, #fff);
  border: 1px solid color-mix(in oklch, var(--color-primary, #01696f) 22%, var(--color-border, #e0e0e0));
}

.economics-hero-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-primary, #01696f);
  margin-bottom: 10px;
}

.economics-hero-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px 14px;
}

.economics-hero-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.economics-hero-label {
  font-size: 11px;
  color: var(--color-text-muted, #888);
}

.economics-hero-item strong {
  font-size: 16px;
  font-weight: 800;
  color: var(--color-text, #1a1a1a);
  font-family: var(--font-display, 'Unbounded', sans-serif);
}

.economics-hero-value--profit {
  color: #2e7d32 !important;
}

.economics-hero-value--roi {
  color: var(--color-primary, #01696f) !important;
}

.economics-hero-note {
  font-size: 10px;
  color: var(--color-text-faint, #aaa);
  line-height: 1.35;
}

.econ-scenarios {
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px solid var(--color-border, #e0e0e0);
  background: #fff;
}

.econ-scenarios-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-text, #333);
  margin-bottom: 4px;
}

.econ-scenarios-intro {
  margin: 0 0 12px;
  font-size: 11px;
  color: var(--color-text-muted, #888);
  line-height: 1.45;
}

.econ-scenarios-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.econ-scenario {
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid var(--color-border, #e0e0e0);
}

.econ-scenario--launch {
  background: color-mix(in oklch, #cb7c1a 4%, #fff);
  border-color: color-mix(in oklch, #cb7c1a 28%, var(--color-border, #e0e0e0));
}

.econ-scenario--ongoing {
  background: color-mix(in oklch, var(--color-primary, #01696f) 3%, #fff);
  border-color: color-mix(in oklch, var(--color-primary, #01696f) 20%, var(--color-border, #e0e0e0));
}

.econ-scenario--pending {
  font-style: italic;
  color: var(--color-text-muted, #888);
}

.econ-scenario-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 6px;
}

.econ-scenario-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-text, #1a1a1a);
}

.econ-scenario-head strong {
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
  font-family: var(--font-display, 'Unbounded', sans-serif);
}

.econ-scenario-desc {
  margin: 0 0 10px;
  font-size: 11px;
  color: var(--color-text-muted, #888);
  line-height: 1.4;
}

.econ-scenario-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.econ-scenario-metric {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.econ-scenario-metric-label {
  font-size: 10px;
  color: var(--color-text-muted, #888);
}

.econ-scenario-metric strong {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text, #1a1a1a);
}

.econ-scenario-metric-note {
  font-size: 9px;
  color: var(--color-text-faint, #aaa);
  line-height: 1.3;
}

.econ-scenario-footnote {
  margin: 10px 0 0;
  font-size: 10px;
  color: var(--color-primary, #01696f);
  line-height: 1.4;
}

.economics-longterm-note {
  margin: 0;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 11px;
  line-height: 1.5;
  color: #7a4d0f;
  background: color-mix(in oklch, #cb7c1a 8%, #fff);
  border: 1px solid color-mix(in oklch, #cb7c1a 22%, var(--color-border, #e0e0e0));
}

.cac-breakdown-period {
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  color: var(--color-text-muted, #888);
  font-size: 10px;
}

.cac-breakdown-cycle-note {
  margin: 0 0 8px;
  font-size: 11px;
  color: var(--color-text-muted, #666);
  line-height: 1.45;
}

.monthly-cost-card-badge--forecast {
  background: color-mix(in oklch, var(--color-primary, #01696f) 10%, #fff) !important;
  color: var(--color-primary, #01696f) !important;
}

@media (max-width: 900px) {
  .economics-hero-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .economics-hero-grid,
  .econ-scenarios-grid,
  .econ-scenario-metrics {
    grid-template-columns: 1fr;
  }
}

.monthly-costs {
  margin-bottom: 16px;
}

.monthly-costs-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-primary, #01696f);
  margin-bottom: 10px;
}

.monthly-costs-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.monthly-cost-card {
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--color-border, #e0e0e0);
  background: #fff;
}

.monthly-cost-card--launch {
  border-color: color-mix(in oklch, #cb7c1a 35%, var(--color-border, #e0e0e0));
  background: color-mix(in oklch, #cb7c1a 4%, #fff);
}

.monthly-cost-card--ongoing {
  border-color: color-mix(in oklch, var(--color-primary, #01696f) 25%, var(--color-border, #e0e0e0));
  background: color-mix(in oklch, var(--color-primary, #01696f) 3%, #fff);
}

.monthly-cost-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 8px;
}

.monthly-cost-card-head-left {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.monthly-cost-card-head-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  text-align: right;
}

.monthly-cost-card-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text, #1a1a1a);
}

.monthly-cost-card-badge {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 2px 7px;
  border-radius: 999px;
  background: color-mix(in oklch, var(--color-border, #e0e0e0) 50%, #fff);
  color: var(--color-text-muted, #888);
}

.monthly-cost-card--launch .monthly-cost-card-badge {
  background: color-mix(in oklch, #cb7c1a 15%, #fff);
  color: #9a5f0f;
}

.monthly-cost-card--ongoing .monthly-cost-card-badge {
  background: color-mix(in oklch, var(--color-primary, #01696f) 12%, #fff);
  color: var(--color-primary, #01696f);
}

.monthly-cost-card-head strong {
  font-size: 16px;
  font-weight: 800;
  color: var(--color-text, #1a1a1a);
  font-family: var(--font-display, 'Unbounded', sans-serif);
  white-space: nowrap;
}

.monthly-cost-card-sub {
  font-size: 10px;
  color: var(--color-text-faint, #aaa);
}

.monthly-cost-lines {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.monthly-cost-line {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  color: var(--color-text-muted, #666);
}

.monthly-cost-line span:last-child {
  font-weight: 600;
  color: var(--color-text, #333);
  white-space: nowrap;
}

.monthly-cost-line--highlight span:last-child {
  color: #9a5f0f;
}

.monthly-cost-line--muted {
  font-style: italic;
  color: var(--color-text-faint, #aaa);
}

.monthly-cost-line--pending span:last-child {
  font-style: italic;
  font-weight: 500;
  color: var(--color-text-muted, #888);
}

.monthly-cost-saving,
.monthly-cost-cycle-note {
  margin: 8px 0 0;
  padding: 6px 8px;
  border-radius: 6px;
  font-size: 11px;
  line-height: 1.45;
  color: var(--color-primary, #01696f);
  background: color-mix(in oklch, var(--color-primary, #01696f) 8%, #fff);
}

.monthly-cost-cycle-note {
  color: var(--color-text-muted, #888);
  background: color-mix(in oklch, var(--color-border, #e0e0e0) 40%, #fff);
}

.monthly-costs-footer {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--color-text-muted, #888);
  text-align: right;
}

.monthly-costs-footer strong {
  color: var(--color-primary, #01696f);
}

@media (max-width: 720px) {
  .monthly-costs-cards {
    grid-template-columns: 1fr;
  }
}

.economics-summary {
  padding: 18px 20px;
  border-radius: 12px;
  background: linear-gradient(135deg, color-mix(in oklch, var(--color-primary, #01696f) 8%, #fff), #fff);
  border: 1px solid color-mix(in oklch, var(--color-primary, #01696f) 22%, var(--color-border, #e0e0e0));
}

.economics-summary-title {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-primary, #01696f);
  margin-bottom: 12px;
}

.economics-summary-period {
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  color: var(--color-text-muted, #888);
  font-size: 12px;
}

.economics-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px 16px;
}

.economics-summary-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.economics-summary-label {
  font-size: 11px;
  color: var(--color-text-muted, #888);
}

.economics-summary-item strong {
  font-size: 17px;
  font-weight: 800;
  color: var(--color-text, #1a1a1a);
  font-family: var(--font-display, 'Unbounded', sans-serif);
}

.economics-summary-value--profit {
  color: #2e7d32 !important;
}

.economics-summary-value--roi {
  color: var(--color-primary, #01696f) !important;
}

.economics-summary-hint {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--color-primary, #01696f);
  line-height: 1.45;
}

@media (max-width: 640px) {
  .funnel-economics-grid,
  .funnel-economics-grid--extended,
  .economics-summary-grid { grid-template-columns: 1fr; }
}

.funnel-economics-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.funnel-economics-label {
  font-size: 12px;
  color: var(--color-text-muted, #888);
}

.funnel-economics-value {
  font-size: 20px;
  font-weight: 800;
  color: var(--color-text, #1a1a1a);
  font-family: var(--font-display, 'Unbounded', sans-serif);
}

.funnel-economics-value--profit {
  color: #2e7d32;
}

.funnel-economics-value--roi {
  color: var(--color-primary, #01696f);
}

.funnel-economics-note {
  font-size: 11px;
  color: var(--color-text-faint, #aaa);
}

.admin-form-block--save {
  border-color: color-mix(in oklch, var(--color-primary, #01696f) 30%, transparent);
  background: color-mix(in oklch, var(--color-primary, #01696f) 3%, var(--color-surface, #fff));
}

.admin-save-row {
  display: flex;
  gap: 12px;
  align-items: flex-end;
}

.templates-list-page {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.admin-form input[type="text"],
.admin-form input[type="number"],
.admin-form input.input-sum {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--color-border, #ddd);
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  background: var(--color-bg, #f9f9f9);
  color: var(--color-text, #1a1a1a);
  transition: border-color 0.2s;
}

.admin-form input:focus {
  outline: none;
  border-color: var(--color-primary, #01696f);
}

.admin-form input.field-empty:not(:focus),
.admin-form .decl-input.field-empty:not(:focus) {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px rgba(227, 139, 31, 0.15);
}

@media (max-width: 768px) {
  .admin-header { padding: 0 16px; gap: 12px; max-width: none; }
  .admin-body   { padding: 20px 16px; }
  .admin-save-row { flex-direction: column; }
}

/* === GUEST LINK === */

.guest-link-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px 18px;
  background: linear-gradient(145deg, #fff9f2 0%, #fff 55%);
  border: 2px solid rgba(227, 139, 31, 0.25);
  border-radius: var(--radius);
}

.guest-link-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-dark);
}

.guest-link-row {
  display: flex;
  gap: 8px;
}

.guest-link-input {
  flex: 1;
  font-size: 13px;
  color: var(--light-text-muted);
  background: #fff;
  border: 1px solid var(--light-border);
  border-radius: var(--radius);
  padding: 10px 12px;
  cursor: default;
  font-family: monospace;
}

.guest-link-hint {
  font-size: 12px;
  color: var(--light-text-muted);
  margin: 0;
  line-height: 1.5;
}

.role-badge.guest {
  background: var(--light-badge-bg);
  color: var(--accent-dark);
}

.guest-loader {
  width: 32px;
  height: 32px;
  border: 3px solid var(--light-border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 480px) {
  .guest-link-row { flex-direction: column; }
}

/* === GUEST HERO === */

.guest-hero {
  padding: 48px 0 36px;
  margin-bottom: 0;
  background: linear-gradient(180deg, var(--bg-top) 0%, var(--bg-mid) 50%, var(--bg-bottom) 100%);
  color: var(--text);
}

.guest-hero-inner {
  text-align: center;
}

.guest-hero-title {
  font-size: clamp(24px, 4vw, 40px);
  font-weight: 700;
  font-family: var(--font-display);
  line-height: 1.25;
  color: var(--text);
  margin-bottom: 24px;
}

.guest-hero-company {
  color: var(--accent-light);
}

.guest-hero-meta {
  display: flex;
  align-items: baseline;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 24px;
  text-align: center;
}

.guest-hero-niche,
.guest-hero-region,
.guest-hero-date {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.4;
}

.guest-hero-niche strong,
.guest-hero-region strong,
.guest-hero-date strong {
  color: var(--text);
  font-weight: 600;
}

@media (max-width: 600px) {
  .guest-hero { padding: 32px 0 24px; }
  .guest-hero-meta { flex-direction: column; align-items: center; gap: 8px; }
}

/* === TEMPLATES PANEL === */

.templates-overlay {
  position: fixed;
  inset: 0;
  background: oklch(0 0 0 / 0.4);
  z-index: 9990;
  backdrop-filter: blur(2px);
}

.templates-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(480px, 100vw);
  background: var(--light-surface);
  border-left: 1px solid var(--light-border);
  z-index: 9991;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: -8px 0 32px oklch(0 0 0 / 0.1);
}

.templates-panel.open {
  transform: translateX(0);
}

.templates-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--light-border);
  flex-shrink: 0;
}

.templates-panel-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  margin: 0;
  color: var(--light-text);
}

.templates-panel-close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: var(--light-text-muted);
  border-radius: 6px;
  display: flex;
  align-items: center;
  transition: color 0.2s, background 0.2s;
}

.templates-panel-close:hover {
  color: var(--light-text);
  background: var(--light-bg);
}

.templates-panel-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  border-bottom: 1px solid var(--light-border);
  flex-shrink: 0;
}

.templates-count {
  font-size: 13px;
  color: var(--light-text-muted);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 13px;
  border-radius: var(--radius);
}

.templates-list {
  flex: 1;
  overflow-y: auto;
  padding: 16px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.templates-loading {
  display: flex;
  justify-content: center;
  padding: 40px;
}

.templates-empty {
  text-align: center;
  padding: 40px 16px;
  color: var(--light-text-muted);
}

.templates-empty-hint {
  font-size: 13px;
  margin-top: 8px;
}

.template-item {
  border: 1px solid var(--light-border);
  border-radius: 10px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: opacity 0.3s, transform 0.3s;
  background: var(--light-surface);
}

.template-item:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-light);
}

.template-item.deleting {
  opacity: 0;
  transform: translateX(20px);
}

.template-item-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 10px;
  margin-bottom: 6px;
}

.template-item-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--light-text);
}

.template-item-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.template-item-tag {
  font-size: 12px;
  font-weight: 500;
  color: var(--light-text-muted);
  background: var(--light-bg);
  border: 1px solid var(--light-border);
  border-radius: 6px;
  padding: 2px 8px;
  line-height: 1.4;
}

.template-item-tag--company {
  color: var(--accent-dark);
  background: var(--light-badge-bg);
  border-color: rgba(227, 139, 31, 0.2);
}

.template-item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-size: 12px;
  color: var(--light-text-muted);
  margin-bottom: 4px;
}

.template-meta-company,
.template-meta-region {
  font-weight: 500;
}

.template-meta-company {
  color: var(--accent-dark);
}

.template-item-url {
  font-size: 11px;
  font-family: monospace;
  color: var(--light-text-muted);
  opacity: 0.7;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.template-item-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.btn-delete-tpl {
  margin-left: auto;
  color: var(--light-text-muted);
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 6px 8px;
  display: flex;
  align-items: center;
  background: none;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}

.btn-delete-tpl:hover {
  color: var(--color-error);
  border-color: var(--color-error);
}

/* === CONFIRM DIALOG === */

.confirm-overlay {
  z-index: 10001;
  align-items: center;
}

.confirm-overlay.open {
  display: flex;
}

.confirm-modal {
  max-width: 420px;
}

.confirm-modal-body {
  padding: 28px 28px 20px;
}

.confirm-modal-title {
  font-family: var(--font-display, 'Unbounded', sans-serif);
  font-size: 18px;
  font-weight: 600;
  color: var(--card-white-text, #1a1a1a);
  margin-bottom: 10px;
}

.confirm-modal-text {
  font-size: 15px;
  line-height: 1.55;
  color: var(--card-white-muted, #484e59);
}

.confirm-modal-text strong {
  color: var(--card-white-text, #1a1a1a);
  font-weight: 600;
}

.confirm-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 28px 24px;
  border-top: 1px solid var(--light-border, #e8eaef);
}

.btn-danger {
  background: var(--color-error, #c0392b);
  color: #fff;
  border: none;
  border-radius: var(--radius-pill, 100px);
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-danger:hover {
  background: #a93226;
}

.btn-templates-panel {
  position: absolute;
  top: 50%;
  right: 20px;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  padding: 6px 12px;
  border: 1px solid var(--light-border);
  border-radius: var(--radius);
  color: var(--light-text);
  background: #fff;
  cursor: pointer;
  transition: all 0.2s;
  z-index: 10;
}

.btn-templates-panel:hover {
  border-color: var(--accent);
  color: var(--accent-dark);
}

@media (max-width: 768px) {
  .header:has(.btn-templates-panel) .header-inner { padding-right: 20px; }
  .btn-templates-panel {
    position: static;
    transform: none;
    width: calc(100% - 40px);
    margin: 8px 20px 0;
    justify-content: center;
  }
}

/* === CONSTRUCTOR PERSONALIZATION === */

.goal-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: linear-gradient(145deg, #fff9f2 0%, #fff 55%);
  border: 2px solid rgba(227, 139, 31, 0.25);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
  padding: 14px 18px;
  font-size: 14px;
  margin-bottom: 28px;
  line-height: 1.55;
}
.goal-banner-edit {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 13px;
  color: var(--accent-dark);
  font-weight: 600;
  white-space: nowrap;
  padding: 0;
}
.goal-banner-edit:hover { text-decoration: underline; }

.recommended {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius);
  position: relative;
}
.recommend-badge {
  position: absolute;
  top: -10px;
  left: 12px;
  background: var(--accent-gradient);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 10px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  z-index: 1;
}

/* === CONTENT PERSONALIZATION === */

.tariff-forecast {
  font-size: 13px;
  color: var(--light-text-muted);
  background: var(--light-badge-bg);
  border-radius: var(--radius);
  padding: 8px 10px;
  margin-top: 8px;
  line-height: 1.5;
}
.forecast-saving {
  color: var(--color-success, #2e7d32);
  font-weight: 600;
}

.research-niche-label {
  font-size: 13px;
  color: var(--color-text-muted, #888);
  margin-bottom: 12px;
  grid-column: 1 / -1;
}

.qual-goal-block {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 16px;
  background: linear-gradient(145deg, #fff9f2 0%, #fff 55%);
  border: 1px solid rgba(227, 139, 31, 0.2);
  border-radius: var(--radius);
  margin-bottom: 12px;
  font-size: 14px;
}
.qual-goal-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted, #888);
}
.qual-goal-value { font-weight: 600; color: var(--color-text, #1a1a1a); }
.qual-goal-sep   { color: var(--color-text-muted, #aaa); }

.recommended-hv {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius);
  position: relative;
}

.goal-banner-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
}
.goal-metric {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.goal-metric-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--light-text-muted);
}
.goal-metric strong { font-size: 14px; color: var(--light-text); }
.goal-metric--accent strong { color: var(--accent-dark); }

@media (max-width: 600px) {
  .goal-banner { flex-direction: column; align-items: flex-start; }
  .goal-banner-metrics { gap: 10px; }
}

/* === CASES BLOCK === */

.cases-section {
  padding-top: 48px;
  padding-bottom: 48px;
}

.cases-section-header {
  margin-bottom: 28px;
}

.cases-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
  margin-bottom: 24px;
}

.cases-grid .case-card {
  flex: 0 1 300px;
  max-width: 300px;
  width: 100%;
}

.case-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--light-border);
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  background: #fff;
  transition: box-shadow 0.2s, transform 0.2s;
}

.case-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.case-card-image {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--light-bg);
}

.case-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.case-card:hover .case-card-image img {
  transform: scale(1.03);
}

.case-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.case-card-category {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-dark);
}

.case-card-title {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--light-text);
  margin: 0;
}

.case-card-stats {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-dark);
  background: rgba(227, 139, 31, 0.1);
  padding: 3px 8px;
  border-radius: 6px;
  width: fit-content;
}

.case-card-desc {
  font-size: 13px;
  color: var(--light-text-muted);
  line-height: 1.5;
  flex: 1;
  margin: 0;
}

.case-card-link {
  font-size: 13px;
  font-weight: 500;
  color: var(--accent-dark);
  margin-top: 4px;
}

.cases-all-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--accent-dark);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}

.cases-all-link:hover {
  border-bottom-color: var(--accent-dark);
}

@media (max-width: 640px) {
  .cases-grid .case-card {
    flex: 1 1 100%;
    max-width: 100%;
  }
}

/* === ADMIN CASES PICKER === */

.cases-picker-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 12px;
  align-items: center;
  margin-bottom: 12px;
}

.cases-picker-search {
  flex: 1;
  min-width: 200px;
  padding: 10px 12px;
  border: 1px solid var(--light-border);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  background: var(--light-bg);
}

.cases-picker-search:focus {
  outline: none;
  border-color: var(--accent);
}

.cases-picker-count {
  font-size: 13px;
  font-weight: 600;
  color: var(--light-text-muted);
  margin-left: auto;
}

.cases-picker-count--limit {
  color: var(--accent-dark);
}

.cases-picker-list {
  max-height: 320px;
  overflow-y: auto;
  border: 1px solid var(--light-border);
  border-radius: 10px;
  background: #fff;
}

.cases-picker-empty {
  padding: 20px 16px;
  margin: 0;
  font-size: 14px;
  color: var(--light-text-muted);
  text-align: center;
}

.cases-picker-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 14px;
  border-bottom: 1px solid var(--light-border);
  cursor: pointer;
  transition: background 0.15s;
}

.cases-picker-item:last-child {
  border-bottom: none;
}

.cases-picker-item:hover {
  background: var(--light-bg);
}

.cases-picker-item input[type="checkbox"] {
  margin-top: 3px;
  flex-shrink: 0;
  accent-color: var(--accent-dark);
}

.cases-picker-item-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.cases-picker-item-title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--light-text);
}

.cases-picker-item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  font-size: 12px;
  color: var(--light-text-muted);
}

.cases-picker-item-meta span:first-child {
  color: var(--accent-dark);
  font-weight: 600;
}
