.commercial-configurator-grid{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(300px,.75fr);gap:2rem;align-items:start}.commercial-configurator-main{min-width:0}.commercial-summary{position:sticky;top:1.5rem}.catalog-source,.mock-price-note{font-size:.84rem;color:var(--muted,#6c7480)}.commercial-module-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem}.commercial-module-card,.commercial-option-card,.commercial-quantity-card{border:1px solid var(--line,#dce2e8);border-radius:14px;background:var(--surface,#fff);padding:1rem;transition:border-color .2s,box-shadow .2s}.commercial-module-card:has(input:checked),.commercial-option-card:has(input:checked){border-color:var(--accent,#1769aa);box-shadow:0 0 0 2px color-mix(in srgb,var(--accent,#1769aa) 14%,transparent)}.commercial-module-card label,.commercial-option-card label{display:flex;gap:.7rem;align-items:flex-start;cursor:pointer}.commercial-module-card input,.commercial-option-card input{margin-top:.25rem;accent-color:var(--accent,#1769aa)}.commercial-module-card strong,.commercial-option-card strong{display:block}.commercial-module-card small,.commercial-option-card small{display:block;margin-top:.3rem;line-height:1.45;color:var(--muted,#6c7480)}.commercial-module-card p{margin:.7rem 0 0;font-size:.85rem;color:var(--muted,#6c7480)}.commercial-module-card ul,.commercial-option-card ul{margin:.7rem 0 0;padding-left:1.1rem;font-size:.82rem;color:var(--muted,#6c7480)}.commercial-card-price{display:block;margin-top:.75rem;font-size:.83rem;color:var(--accent,#1769aa)}.commercial-option-groups{display:grid;gap:1rem}.commercial-option-group{border-top:1px solid var(--line,#dce2e8);padding-top:1rem}.commercial-option-group h3{margin:0 0 .75rem;font-size:1.05rem}.commercial-option-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.75rem}.commercial-option-card{padding:.85rem}.commercial-quantity-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.75rem}.commercial-quantity-card{display:flex;justify-content:space-between;gap:1rem;align-items:center}.commercial-quantity-card label{font-weight:650}.commercial-quantity-card small{display:block;margin-top:.25rem;color:var(--muted,#6c7480);font-weight:400}.commercial-quantity-card input{width:5rem;border:1px solid var(--line,#cbd3dc);border-radius:8px;padding:.55rem;text-align:center;background:transparent;color:inherit}.commercial-summary .summary-list{max-height:22rem;overflow:auto}.summary-line{display:flex;justify-content:space-between;gap:.75rem;padding:.4rem 0;border-bottom:1px solid color-mix(in srgb,var(--line,#dce2e8) 70%,transparent);font-size:.88rem}.summary-line small{display:block;color:var(--muted,#6c7480)}.summary-line .auto{color:var(--accent,#1769aa);font-size:.72rem}.dependency-alert{padding:.7rem;border-radius:9px;background:color-mix(in srgb,#e9a23b 14%,transparent);font-size:.82rem}.catalog-evidence-note{max-width:850px}.catalog-evidence-note p:last-child{color:var(--muted,#6c7480)}.preset-grid button{cursor:pointer}.preset-grid button.active{border-color:var(--accent,#1769aa);box-shadow:0 0 0 2px color-mix(in srgb,var(--accent,#1769aa) 14%,transparent)}@media(max-width:960px){.commercial-configurator-grid{grid-template-columns:1fr}.commercial-summary{position:static}}@media(max-width:650px){.commercial-module-list,.commercial-option-grid,.commercial-quantity-grid{grid-template-columns:1fr}}

/* Ajustes de leitura do configurador: um módulo por linha e contraste estável nos dois temas. */
.commercial-module-list{grid-template-columns:1fr}
.commercial-module-card{background:#f7fafc;color:#173347}
.commercial-module-card label{color:#173347!important;opacity:1}
.commercial-module-card strong{color:#0b1e2d!important;font-size:1.05rem}
.commercial-module-card small{color:#435a6d!important}
.commercial-module-card ul{color:#435a6d!important}
.commercial-module-card .commercial-card-price{color:#075abf!important;font-weight:750}
.commercial-module-card em{color:#075abf;font-size:.72rem;font-style:normal;font-weight:800}
[data-theme="dark"] .commercial-module-card{background:#f7fafc;color:#173347;border-color:#9ec7e8}
[data-theme="dark"] .commercial-module-card label{color:#173347!important}
[data-theme="dark"] .commercial-module-card strong{color:#0b1e2d!important}
[data-theme="dark"] .commercial-module-card small,[data-theme="dark"] .commercial-module-card ul{color:#435a6d!important}
@media(max-width:650px){.commercial-module-list{grid-template-columns:1fr}}
/* Switches dos módulos: controle visual moderno, mantendo input nativo acessível. */
.commercial-module-selector{align-items:flex-start!important}
.commercial-switch{position:relative;display:inline-flex;flex:0 0 46px;width:46px;height:26px;margin-top:.05rem}
.commercial-switch input{position:absolute;inset:0;z-index:2;width:100%;height:100%;margin:0!important;opacity:0;cursor:pointer}
.commercial-switch-track{position:absolute;inset:0;border-radius:999px;background:#b9c0c6;box-shadow:inset 0 0 0 1px rgba(23,51,71,.18);transition:background .2s ease,box-shadow .2s ease}
.commercial-switch-thumb{position:absolute;top:3px;left:3px;width:20px;height:20px;border-radius:50%;background:#fff;box-shadow:0 2px 5px rgba(7,21,33,.25);transition:transform .2s ease}
.commercial-switch input:checked+.commercial-switch-track{background:#0879da;box-shadow:inset 0 0 0 1px rgba(0,71,145,.35)}
.commercial-switch input:checked+.commercial-switch-track .commercial-switch-thumb{transform:translateX(20px)}
.commercial-switch input:focus-visible+.commercial-switch-track{outline:3px solid rgba(99,230,190,.8);outline-offset:3px}
.commercial-switch input:disabled{cursor:not-allowed}
.commercial-switch input:disabled+.commercial-switch-track{opacity:.7}
[data-theme="dark"] .commercial-switch-track{background:#8f9aa3}
[data-theme="dark"] .commercial-switch input:checked+.commercial-switch-track{background:#0879da}
/* Thumbnails e acabamento visual dos cards. */
.commercial-module-card,.commercial-option-card,.commercial-quantity-card{border-radius:0}
.commercial-module-card{display:grid;grid-template-columns:132px minmax(0,1fr);gap:1rem;align-items:start}
.commercial-module-thumb{width:132px;height:94px;display:block;object-fit:cover;border:1px solid #c6d8e6;background:#dce8f0}
[data-theme="dark"] .commercial-module-card{background:#0b1e2d;color:#e5edf4;border-color:rgba(158,199,232,.7)}
[data-theme="dark"] .commercial-module-card strong{color:#f4f8fb!important}
[data-theme="dark"] .commercial-module-card small,[data-theme="dark"] .commercial-module-card ul{color:#b9cad6!important}
[data-theme="dark"] .commercial-module-card .commercial-card-price{color:#63e6be!important}
[data-theme="dark"] .commercial-module-card .commercial-module-thumb{border-color:rgba(255,255,255,.18);background:#102838}
@media(max-width:650px){.commercial-module-card{grid-template-columns:1fr}.commercial-module-thumb{width:100%;height:130px}}
/* Hierarquia visual: módulo pai como casca e funcionalidades como filhos. */
.commercial-option-group{padding:1rem;border:1px solid #c6d8e6;border-radius:0;background:#eef4f8}
.commercial-option-group-header{display:grid;grid-template-columns:86px minmax(0,1fr);gap:1rem;align-items:center;padding-bottom:1rem;border-bottom:1px solid #c6d8e6}
.commercial-parent-thumb{width:86px;height:58px;display:block;object-fit:cover;border:1px solid #b5cddd;background:#dce8f0}
.commercial-parent-kicker{display:block;margin-bottom:.25rem;color:#1769aa;font-size:.68rem;font-weight:850;letter-spacing:.08em;text-transform:uppercase}
.commercial-option-group h3{margin:0;color:#0b1e2d;font-size:1.1rem}
.commercial-option-group-header p{margin:.3rem 0 0;color:#435a6d;font-size:.8rem;line-height:1.45}
.commercial-option-grid{margin-top:1rem}
.commercial-option-card{display:grid;grid-template-columns:72px minmax(0,1fr);gap:.85rem;align-items:start;background:#fff;color:#173347}
.commercial-option-thumb{width:72px;height:54px;display:block;object-fit:cover;border:1px solid #c6d8e6;background:#dce8f0}
.commercial-option-card label{color:#173347!important}
.commercial-option-card strong{color:#0b1e2d!important}
.commercial-option-card small{color:#435a6d!important}
.commercial-option-card .commercial-card-price{color:#075abf!important;font-weight:750}
[data-theme="dark"] .commercial-option-group{border-color:rgba(158,199,232,.55);background:#071a29}
[data-theme="dark"] .commercial-option-group-header{border-color:rgba(255,255,255,.18)}
[data-theme="dark"] .commercial-parent-thumb,[data-theme="dark"] .commercial-option-thumb{border-color:rgba(255,255,255,.2);background:#102838}
[data-theme="dark"] .commercial-parent-kicker{color:#63e6be}
[data-theme="dark"] .commercial-option-group h3{color:#f4f8fb}
[data-theme="dark"] .commercial-option-group-header p{color:#b9cad6}
[data-theme="dark"] .commercial-option-card{background:#102838;border-color:rgba(255,255,255,.18);color:#e5edf4}
[data-theme="dark"] .commercial-option-card label{color:#e5edf4!important}
[data-theme="dark"] .commercial-option-card strong{color:#f4f8fb!important}
[data-theme="dark"] .commercial-option-card small{color:#b9cad6!important}
[data-theme="dark"] .commercial-option-card .commercial-card-price{color:#63e6be!important}
[data-theme="dark"] .commercial-quantity-card{background:#102838;border-color:rgba(255,255,255,.18);color:#e5edf4}
[data-theme="dark"] .commercial-quantity-card small{color:#b9cad6!important}
@media(max-width:650px){.commercial-option-group-header{grid-template-columns:1fr}.commercial-parent-thumb{width:100%;height:110px}.commercial-option-card{grid-template-columns:60px minmax(0,1fr)}.commercial-option-thumb{width:60px;height:48px}}
/* Filhos na mesma lista do pai, uma linha por funcionalidade. */
.commercial-module-content{min-width:0}
.commercial-child-list{display:grid;gap:.6rem;margin-top:1rem;padding-top:1rem;border-top:1px solid #c6d8e6}
.commercial-child-header{margin-bottom:.15rem;color:#1769aa;font-size:.68rem;font-weight:850;letter-spacing:.08em;text-transform:uppercase}
.commercial-child-card{display:grid;grid-template-columns:64px minmax(0,1fr);gap:.8rem;align-items:start;padding:.7rem;border:1px solid #c6d8e6;border-radius:0;background:#fff}
.commercial-child-thumb{width:64px;height:46px;display:block;object-fit:cover;border:1px solid #c6d8e6;background:#dce8f0}
.commercial-child-selector{align-items:flex-start!important}
.commercial-child-card strong{color:#0b1e2d!important;font-size:.92rem}
.commercial-child-card small{color:#435a6d!important}
.commercial-child-card .commercial-card-price{color:#075abf!important;font-size:.76rem;font-weight:750}
[data-theme="dark"] .commercial-child-list{border-color:rgba(255,255,255,.18)}
[data-theme="dark"] .commercial-child-header{color:#63e6be}
[data-theme="dark"] .commercial-child-card{border-color:rgba(255,255,255,.18);background:#102838;color:#e5edf4}
[data-theme="dark"] .commercial-child-thumb{border-color:rgba(255,255,255,.2);background:#0b1e2d}
[data-theme="dark"] .commercial-child-card strong{color:#f4f8fb!important}
[data-theme="dark"] .commercial-child-card small{color:#b9cad6!important}
[data-theme="dark"] .commercial-child-card .commercial-card-price{color:#63e6be!important}
@media(max-width:650px){.commercial-child-card{grid-template-columns:54px minmax(0,1fr)}.commercial-child-thumb{width:54px;height:42px}}
/* Ajustes pontuais de legibilidade do configurador. */
.config-title p{font-size:.82rem;line-height:1.5}
.preset-grid small{font-size:.72rem}
.preset-grid span{font-size:.8rem;line-height:1.45}
.summary-kicker{font-size:.72rem}
.summary-list span{font-size:.9rem}
.summary-line small{font-size:.78rem;line-height:1.35}
.summary-price>span{font-size:.8rem}
.mock-price-note{font-size:.88rem;line-height:1.5}
.summary-note{font-size:.72rem;line-height:1.4}
.share-button{font-size:.8rem}
/* Thumbnails sem redimensionamento forçado. */
.commercial-module-thumb{width:128px;height:auto;aspect-ratio:auto;object-fit:initial;image-rendering:auto}
.commercial-child-card{grid-template-columns:128px minmax(0,1fr)}
.commercial-child-thumb{width:128px;height:auto;aspect-ratio:auto;object-fit:initial;image-rendering:auto}
.commercial-child-thumb-link{width:128px;min-width:128px}
.commercial-child-card .commercial-child-thumb{width:128px!important;min-width:128px;max-width:none;height:auto!important}
/* Thumbnail como acesso direto aos detalhes do módulo. */
.commercial-module-thumb-link,.commercial-child-thumb-link{display:block;line-height:0;align-self:start}
.commercial-module-thumb-link:focus-visible,.commercial-child-thumb-link:focus-visible{outline:2px solid #63e6be;outline-offset:3px}
.commercial-module-thumb-link:hover .commercial-module-thumb,.commercial-child-thumb-link:hover .commercial-child-thumb{border-color:#63e6be;filter:brightness(1.08)}

@media(max-width:650px){.commercial-module-thumb{width:128px;height:auto}.commercial-child-card{grid-template-columns:128px minmax(0,1fr)}.commercial-child-thumb{width:128px;height:auto}}
/* Estado ativo do ponto de partida. */
.preset-grid button.active{position:relative;border-color:#55e5c3!important;background:#0e3851!important;box-shadow:inset 0 0 0 1px #55e5c3,0 0 0 3px rgba(85,229,195,.22)!important}
.preset-grid button.active small,.preset-grid button.active strong,.preset-grid button.active span{color:#f4fbff!important}
.preset-grid button.active::after{content:"Selecionado";display:inline-block;margin-top:.75rem;color:#071d2b;background:#55e5c3;padding:.22rem .5rem;font-size:.68rem;font-weight:850;letter-spacing:.06em;text-transform:uppercase}

.coupon-entry {
  margin: 1.25rem 0;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(177, 204, 222, 0.24);
}

.coupon-entry > label {
  display: block;
  margin-bottom: 0.55rem;
  color: #dcecff;
  font-size: 0.86rem;
  font-weight: 700;
}

.coupon-entry-controls {
  display: flex;
  gap: 0.55rem;
}

.coupon-entry input {
  min-width: 0;
  flex: 1;
  border: 1px solid #59768d;
  border-radius: 0;
  background: #071927;
  color: #f4f8fc;
  padding: 0.7rem 0.75rem;
  font: inherit;
  text-transform: uppercase;
}

.coupon-entry input:focus {
  outline: 2px solid #36d9bd;
  outline-offset: 1px;
}

.coupon-entry button {
  border: 1px solid #1d7cff;
  border-radius: 0;
  background: #145dd9;
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  padding: 0.7rem 0.85rem;
}

.coupon-entry button:hover { background: #1970fb; }

.coupon-message,
.coupon-summary {
  margin: 0.65rem 0 0;
  font-size: 0.82rem;
  line-height: 1.45;
}

.coupon-message { color: #59e3c3; font-weight: 700; }
.coupon-message.invalid { color: #ff9b9b; }
.coupon-summary { color: #b7cada; }

@media (max-width: 520px) {
  .coupon-entry-controls { flex-direction: column; }
  .coupon-entry button { width: 100%; }
}
/* O resumo comercial permanece completo em janelas baixas. */
@media (min-width: 961px) {
  .commercial-summary {
    max-height: calc(100vh - 3rem);
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }

  .commercial-summary .summary-list {
    max-height: min(20rem, 25vh);
  }
}

@media (min-width: 961px) and (max-height: 760px) {
  .commercial-summary .summary-list {
    max-height: 10rem;
  }

  .coupon-entry {
    margin: 0.85rem 0;
    padding-top: 0.85rem;
  }
}
/* Uma única rolagem vertical no resumo e nenhuma rolagem horizontal. */
@media (min-width: 961px) {
  .commercial-summary {
    overflow-x: hidden;
  }

  .commercial-summary .summary-list {
    max-height: none;
    overflow: visible;
  }
}

.summary-line {
  min-width: 0;
}

.summary-line > span:first-child {
  min-width: 0;
  overflow-wrap: anywhere;
}

.summary-line > span:last-child {
  flex: 0 0 auto;
  white-space: nowrap;
}
