:root {
  --bg: #eef4fb;
  --panel: #ffffff;
  --text: #0f172a;
  --muted: #617085;
  --line: #dbe4ef;
  --soft-line: #edf3fa;
  --primary: #0b7cff;
  --primary-dark: #075fca;
  --cyan: #06b6d4;
  --violet: #6d5dfc;
  --green: #16a34a;
  --orange: #f59e0b;
  --shadow: 0 16px 42px rgba(15, 23, 42, .08);
  --strong-shadow: 0 24px 70px rgba(15, 23, 42, .12);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 12% 4%, rgba(11, 124, 255, .14), transparent 24%),
    radial-gradient(circle at 90% 12%, rgba(22, 163, 74, .10), transparent 22%),
    linear-gradient(180deg, #f8fbff 0, var(--bg) 250px, #f5f8fc 100%);
  color: var(--text);
  font-family: Inter, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.45;
}

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

.calculator-shell {
  width: min(1440px, calc(100% - 32px));
  margin: 0 auto;
  padding: 12px 0 44px;
}

.hero {
  min-height: 170px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 34px;
  margin-bottom: 18px;
  border-radius: var(--radius);
  background:
    linear-gradient(120deg, rgba(4, 19, 46, .84), rgba(0, 111, 255, .68)),
    url("https://images.unsplash.com/photo-1559028012-481c04fa702d?auto=format&fit=crop&w=1600&q=80") center/cover;
  color: #fff;
  box-shadow: 0 18px 46px rgba(15, 23, 42, .16);
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 32px 0;
  height: 5px;
  background: linear-gradient(90deg, var(--primary), var(--cyan), var(--green), var(--orange));
  border-radius: 999px 999px 0 0;
}

.hero > * {
  position: relative;
  z-index: 1;
}

.eyebrow {
  margin: 0 0 6px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  font-size: 12px;
}

.hero h1 {
  margin: 0;
  max-width: 720px;
  font-size: clamp(30px, 4.2vw, 50px);
  line-height: 1.04;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 650px;
  margin: 10px 0 0;
  color: rgba(255, 255, 255, .86);
  font-size: 16px;
}

.hero-total {
  min-width: 220px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, .3);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .12);
  backdrop-filter: blur(10px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22);
}

.hero-total span {
  display: block;
  color: rgba(255, 255, 255, .8);
  margin-bottom: 8px;
}

.hero-total strong {
  font-size: 28px;
}

.layout-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 18px;
  align-items: start;
}

.form-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  counter-reset: section-count;
}

.section-card,
.summary-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 14px 34px rgba(15, 23, 42, .07);
}

.section-card {
  padding: 0;
  overflow: hidden;
  position: relative;
}

.section-card:not(.type-section) {
  transition: opacity .2s ease, filter .2s ease;
}

body:not(.type-selected) .section-card:not(.type-section) {
  opacity: .58;
  filter: grayscale(.16);
}

body:not(.type-selected) .section-card:not(.type-section)::after {
  content: "Select website type first";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding-top: 72px;
  color: #0f172a;
  font-weight: 800;
  background: rgba(248, 251, 255, .58);
  backdrop-filter: blur(1px);
  z-index: 2;
}

body:not(.type-selected) .section-card:not(.type-section) > * {
  pointer-events: none;
}

.type-section {
  border-color: rgba(11, 124, 255, .34);
  box-shadow: 0 22px 70px rgba(11, 124, 255, .13);
}

.type-section .section-title {
  background: linear-gradient(90deg, #eff6ff, #ffffff);
}

.section-card + .section-card {
  margin-top: 4px;
}

.section-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(180deg, var(--primary), var(--cyan));
}

.section-title {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  margin: 0;
  padding: 17px 22px;
  background: linear-gradient(90deg, #f8fbff, #ffffff);
  border-bottom: 1px solid var(--soft-line);
}

.section-title span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--violet));
  font-weight: 800;
  flex: 0 0 auto;
  box-shadow: 0 8px 18px rgba(11, 124, 255, .22);
}

.section-title h2 {
  margin: 0;
  font-size: 20px;
}

.section-title p {
  margin: 4px 0 0;
  color: var(--muted);
}

.section-card > .option-grid,
.section-card > .switch-grid,
.section-card > .addon-grid,
.section-card > .specific-feature-grid,
.section-card > .pill-grid,
.section-card > .page-check-grid,
.section-card > .custom-page-row,
.section-card > .responsive-row,
.section-card > .input-grid {
  padding: 17px 22px 20px;
}

.section-card > .option-grid + .sub-head,
.section-card > .counter-row {
  margin-left: 22px;
  margin-right: 22px;
}

.section-card > .sub-head + .pill-grid {
  padding-top: 0;
}

.section-card > .sub-head + .page-check-grid {
  padding-top: 8px;
}

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

.type-section .option-grid {
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}

.option-grid.compact {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.option-card,
.addon-card,
.specific-feature-card,
.pill,
.page-check {
  cursor: pointer;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #ffffff, #fbfdff);
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease, background .18s ease;
  position: relative;
}

.option-card {
  padding: 16px;
  min-height: 104px;
}

.type-section .option-card {
  min-height: 116px;
  padding: 12px;
  border-color: #d3e5fb;
  background:
    linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
}

.option-card input,
.addon-card input,
.specific-feature-card input,
.pill input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.page-check input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--primary);
}

.option-card strong {
  display: block;
  font-size: 16px;
  margin-bottom: 7px;
  padding-right: 24px;
}

.type-section .option-card strong {
  font-size: 15px;
  line-height: 1.28;
  min-height: auto;
}

.option-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  margin-bottom: 8px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(11, 124, 255, .12), rgba(6, 182, 212, .12));
  color: var(--primary-dark);
  font-weight: 900;
  font-size: 13px;
}

.option-card small,
.addon-card small {
  display: block;
  color: var(--muted);
}

.type-section .option-card small {
  display: -webkit-box;
  min-height: 38px;
  overflow: hidden;
  font-size: 13px;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.option-card em {
  display: block;
  margin-top: 8px;
  color: var(--green);
  font-style: normal;
  font-weight: 900;
}

.muted-box {
  grid-column: 1 / -1;
  padding: 14px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  background: #f8fbff;
  font-weight: 700;
}

.option-card.is-selected,
.addon-card.is-selected,
.specific-feature-card.is-selected,
.pill.is-selected,
.page-check.is-selected {
  border-color: var(--primary);
  background: linear-gradient(180deg, #f2f8ff, #ffffff);
  box-shadow: 0 0 0 3px rgba(11, 124, 255, .12), 0 14px 32px rgba(11, 124, 255, .08);
}

.option-card.is-selected::after,
.addon-card.is-selected::after,
.specific-feature-card.is-selected::after,
.pill.is-selected::after {
  content: "";
  position: absolute;
  top: 12px;
  right: 12px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(22, 163, 74, .12);
}

.page-check.is-selected {
  background: #3f7fd6;
  border-color: #1f5fb8;
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18), 0 8px 20px rgba(31, 95, 184, .18);
}

.page-check.is-selected input {
  accent-color: #fff;
}

.option-card:hover,
.addon-card:hover,
.specific-feature-card:hover,
.pill:hover,
.page-check:hover {
  transform: translateY(-1px);
}

.sub-head {
  margin-top: 0;
  margin-bottom: 0;
  padding: 18px 0 10px;
  font-weight: 800;
  border-top: 1px dashed var(--line);
}

.pill-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.pill {
  padding: 9px 12px;
  color: #334155;
  background: #f8fafc;
}

.tech-pill small {
  margin-left: 6px;
  color: var(--primary);
  font-weight: 900;
}

.page-check-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 7px;
  background: #fff;
}

.page-check {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 4px;
  background: #ffffff;
  font-size: 16px;
  font-weight: 600;
}

.page-check span {
  overflow-wrap: anywhere;
}

.custom-page-row {
  display: flex;
  gap: 5px;
  padding-top: 0;
  max-width: 460px;
}

.custom-page-row input {
  flex: 1 1 auto;
  min-width: 0;
  height: 42px;
  border: 1px solid #1f5fb8;
  border-radius: 0;
  padding: 0 13px;
  font-size: 16px;
}

.custom-page-row button {
  width: 72px;
  height: 42px;
  border: 0;
  border-radius: 0;
  background: #07558c;
  color: #fff;
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
  font-weight: 600;
  box-shadow: 0 5px 12px rgba(7, 85, 140, .22);
}

.responsive-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-top: 4px;
  font-weight: 800;
}

.responsive-row label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.responsive-row input {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
}

.switch-grid,
.addon-grid,
.specific-feature-grid,
.input-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.switch-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfdff;
}

.switch-row input {
  width: 18px;
  height: 18px;
}

.service-row {
  grid-template-columns: 1fr auto;
}

.service-choice {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: center;
  cursor: pointer;
}

.switch-row span {
  font-weight: 700;
}

.switch-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-weight: 500;
  font-size: 12px;
}

.service-select {
  width: 100%;
  display: block;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  color: var(--text);
}

.service-config {
  grid-column: 1 / -1;
}

.switch-row strong {
  color: var(--primary);
  text-align: right;
  white-space: nowrap;
}

.switch-row.is-selected {
  border-color: var(--primary);
  background: #f2f8ff;
  box-shadow: 0 0 0 3px rgba(11, 124, 255, .1);
}

.counter-row {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 0;
  margin-bottom: 22px;
  padding: 14px;
  border: 1px dashed #b9d7ff;
  border-radius: var(--radius);
  background: #f4f9ff;
}

.counter-row.is-visible {
  display: flex;
}

.counter-row label {
  font-weight: 700;
}

.counter {
  display: flex;
  align-items: center;
}

.counter button {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  background: #f8fafc;
  cursor: pointer;
  font-weight: 800;
  color: var(--primary-dark);
}

.counter input {
  width: 70px;
  height: 38px;
  border: 1px solid var(--line);
  text-align: center;
}

.addon-card {
  padding: 15px;
}

.addon-card strong,
.specific-feature-card strong {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 15px;
  padding-right: 20px;
}

.addon-card em,
.specific-feature-card em {
  color: var(--primary);
  font-style: normal;
  white-space: nowrap;
}

.specific-feature-card {
  min-height: 92px;
  padding: 15px;
  background: linear-gradient(180deg, #ffffff, #f7fcff);
  border-color: #cde3fb;
}

.specific-feature-card small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
}

.specific-feature-card.is-selected {
  border-color: var(--cyan);
  background: linear-gradient(180deg, #ecfeff, #ffffff);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, .12), 0 14px 32px rgba(6, 182, 212, .08);
}

.input-grid label {
  display: grid;
  gap: 7px;
  font-weight: 700;
}

.input-grid .full {
  grid-column: 1 / -1;
}

.empowerment-note {
  display: grid;
  gap: 5px;
  margin: 0 20px 16px;
  padding: 14px 16px;
  border: 1px solid #bbf7d0;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #f0fdf4, #eff6ff);
  color: #14532d;
}

.empowerment-note strong {
  font-size: 15px;
}

.empowerment-note span {
  color: #315a42;
  line-height: 1.45;
}

.input-grid input,
.input-grid textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  resize: vertical;
  background: #fbfdff;
}

.otp-panel {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px dashed #bfdbfe;
  border-radius: var(--radius);
  background: #f8fbff;
}

.otp-verify {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.secondary-btn {
  border: 0;
  border-radius: var(--radius);
  padding: 11px 14px;
  background: #0f766e;
  color: #fff;
  cursor: pointer;
  font-weight: 800;
}

.secondary-btn:disabled,
.primary-btn:disabled,
.whatsapp-btn:disabled {
  opacity: .55;
  cursor: not-allowed;
  filter: grayscale(.2);
}

.otp-status {
  grid-column: 1 / -1;
  color: #92400e;
  font-weight: 800;
}

.otp-status.verified {
  color: #15803d;
}

.discount-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
  border: 1px solid #f9c5d5;
  border-radius: var(--radius);
  background: #fff7fb;
  color: #831843;
}

.discount-check input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
}

.summary-panel {
  position: sticky;
  top: 18px;
}

.summary-card {
  overflow: hidden;
  border-color: #cbd8e8;
  box-shadow: var(--strong-shadow);
}

.summary-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
  background: linear-gradient(135deg, #0f172a, #1d4ed8);
  color: #fff;
}

.summary-head p {
  margin: 0 0 4px;
  color: rgba(255, 255, 255, .7);
}

.summary-head h2 {
  margin: 0;
  font-size: 20px;
}

.ghost-btn,
.primary-btn,
.whatsapp-btn {
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
  font-weight: 800;
}

.ghost-btn {
  padding: 9px 12px;
  background: rgba(255, 255, 255, .14);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .22);
}

.summary-list {
  max-height: 520px;
  overflow: auto;
  padding: 8px 20px;
  background: #fff;
}

.summary-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--soft-line);
}

.summary-row b {
  display: block;
  overflow-wrap: anywhere;
}

.summary-row span {
  color: var(--muted);
  font-size: 13px;
}

.summary-row strong {
  text-align: right;
}

.empty-summary {
  display: grid;
  gap: 8px;
  padding: 22px 0;
}

.empty-summary b {
  font-size: 17px;
}

.empty-summary span {
  color: var(--muted);
}

.grand-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 22px 20px;
  background: linear-gradient(135deg, #08111f, #0f766e);
  color: #fff;
}

.grand-total span {
  color: rgba(255, 255, 255, .72);
}

.grand-total strong {
  font-size: 28px;
}

.summary-actions {
  display: grid;
  gap: 10px;
  padding: 20px;
  background: #f8fbff;
}

.primary-btn,
.whatsapp-btn {
  padding: 13px 16px;
  color: #fff;
}

.primary-btn {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
}

.whatsapp-btn {
  background: linear-gradient(135deg, var(--green), #0f8a3b);
}

.primary-btn:hover,
.whatsapp-btn:hover,
.ghost-btn:hover {
  filter: brightness(.97);
}

@media (max-width: 1100px) {
  .layout-grid {
    grid-template-columns: 1fr;
  }

  .summary-panel {
    position: static;
  }
}

@media (max-width: 760px) {
  .calculator-shell {
    width: min(100% - 20px, 1440px);
    padding-top: 14px;
  }

  .hero {
    flex-direction: column;
    align-items: stretch;
    padding: 24px;
  }

  .hero-total {
    min-width: 0;
  }

  .option-grid,
  .option-grid.compact,
  .type-section .option-grid,
  .page-check-grid,
  .switch-grid,
  .addon-grid,
  .specific-feature-grid,
  .input-grid {
    grid-template-columns: 1fr;
  }

  .counter-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .section-title {
    padding: 18px;
  }

  .section-card > .option-grid,
  .section-card > .switch-grid,
  .section-card > .addon-grid,
  .section-card > .specific-feature-grid,
  .section-card > .pill-grid,
  .section-card > .page-check-grid,
  .section-card > .custom-page-row,
  .section-card > .responsive-row,
  .section-card > .input-grid {
    padding: 18px;
  }

  .custom-page-row {
    max-width: none;
  }

  .otp-panel,
  .otp-verify {
    grid-template-columns: 1fr;
  }

  .secondary-btn {
    width: 100%;
  }
}
