/* Cedarwick Press — AIPUH commerce density + storefront CTA polish */

/* Keep checkout transactional rather than hero-sized. */
.cedarwick-site [data-aipuh-cart-dialog] {
  width: min(760px, calc(100vw - 2rem));
  max-width: 760px;
}

.cedarwick-site [data-aipuh-cart-checkout-dialog] {
  width: min(820px, calc(100vw - 2rem));
  max-width: 820px;
}

.cedarwick-site [data-aipuh-cart-dialog],
.cedarwick-site [data-aipuh-cart-checkout-dialog] {
  max-height: min(88dvh, 820px);
}

.cedarwick-site [data-aipuh-cart-view] > header,
.cedarwick-site [data-aipuh-checkout-form] > header {
  padding: 1.35rem clamp(1.1rem, 3vw, 1.8rem) 1.15rem;
}

.cedarwick-site [data-aipuh-cart-view] > header::after,
.cedarwick-site [data-aipuh-checkout-form] > header::after {
  left: clamp(1.1rem, 3vw, 1.8rem);
  width: 72px;
  height: 2px;
}

.cedarwick-site [data-aipuh-cart-view] > header .eyebrow,
.cedarwick-site [data-aipuh-checkout-form] > header .eyebrow {
  margin-bottom: .35rem;
  font-size: .66rem;
  letter-spacing: .15em;
}

.cedarwick-site [data-aipuh-cart-view] > header h2,
.cedarwick-site [data-aipuh-checkout-form] > header h2 {
  font-size: clamp(1.9rem, 4vw, 3.15rem);
  line-height: 1;
}

.cedarwick-site [data-aipuh-cart-view] > header > p:last-child,
.cedarwick-site [data-aipuh-checkout-form] > header > p:last-child {
  margin-top: .55rem;
  font-size: .88rem;
}

.cedarwick-site [data-aipuh-checkout-form] > fieldset,
.cedarwick-site [data-aipuh-after-quote] fieldset {
  gap: .72rem .85rem;
  margin: 1.1rem clamp(1.1rem, 3vw, 1.8rem) 0;
  padding: 1rem;
  box-shadow: 0 8px 20px rgba(32,39,36,.035);
}

.cedarwick-site [data-aipuh-checkout-form] fieldset > legend {
  font-size: .98rem;
}

.cedarwick-site [data-aipuh-checkout-form] fieldset > label {
  gap: .3rem;
  font-size: .76rem;
}

.cedarwick-site [data-aipuh-checkout-form] input:not([type="checkbox"]),
.cedarwick-site [data-aipuh-checkout-form] select,
.cedarwick-site [data-aipuh-cart-view] input[type="number"] {
  min-height: 42px;
  padding: .58rem .68rem;
  font-size: .9rem;
}

.cedarwick-site [data-aipuh-checkout-form] .license-acceptance,
.cedarwick-site [data-aipuh-after-quote] > .license-acceptance {
  gap: .5rem;
  padding: .62rem .72rem;
  font-size: .8rem;
  line-height: 1.38;
}

.cedarwick-site [data-aipuh-checkout-form] > .dialog-actions,
.cedarwick-site [data-aipuh-after-quote] > .dialog-actions,
.cedarwick-site [data-aipuh-cart-view] > .dialog-actions {
  gap: .6rem;
  margin: 1rem clamp(1.1rem, 3vw, 1.8rem) 1.15rem;
}

.cedarwick-site [data-aipuh-cart-dialog] .button,
.cedarwick-site [data-aipuh-cart-checkout-dialog] .button,
.cedarwick-site [data-aipuh-cart-toggle] {
  min-height: 42px;
  padding: .66rem .95rem;
  font-size: .82rem;
}

.cedarwick-site [data-aipuh-checkout-status],
.cedarwick-site [data-aipuh-cart-status] {
  margin: .7rem clamp(1.1rem, 3vw, 1.8rem) 0;
  padding: .62rem .76rem;
  font-size: .8rem;
}

.cedarwick-site [data-aipuh-after-quote] {
  margin: 1rem clamp(1.1rem, 3vw, 1.8rem) 1.25rem;
  padding: 1rem;
}

.cedarwick-site [data-aipuh-after-quote] .license-sandbox-note {
  margin: .7rem 0;
  padding: .65rem .75rem;
  font-size: .8rem;
}

.cedarwick-site [data-aipuh-cart-line] {
  grid-template-columns: minmax(0,1fr) 90px auto;
  gap: .75rem;
  margin: .8rem clamp(1.1rem, 3vw, 1.8rem) 0;
  padding: .78rem .85rem;
}

.cedarwick-site [data-aipuh-cart-line] strong {
  font-size: .96rem;
}

/* Make the license signature visibly part of the agreement rather than a generic text field. */
.cedarwick-site .aipuh-license-signature-note {
  grid-column: 1 / -1;
  margin: .15rem 0 0;
  padding: .7rem .8rem;
  border-left: 3px solid var(--cw-brass, #a77c3f);
  background: rgba(167,124,63,.08);
  color: rgba(32,39,36,.82);
  font-size: .79rem;
  line-height: 1.45;
}

.cedarwick-site [data-aipuh-checkout-form] fieldset > .aipuh-license-signature-field {
  grid-column: 1 / -1;
  max-width: 430px;
  margin-top: .1rem;
  color: var(--cw-oxblood, #6b3037);
}

.cedarwick-site .aipuh-license-signature-field input {
  border-color: rgba(107,48,55,.45) !important;
  background: #fff !important;
}

/* Storefront commerce CTAs should look intentional and branded. */
.cedarwick-site .aipuh-price-card > .button-row,
.cedarwick-site .aipuh-config-panel + .button-row,
.cedarwick-site [data-aipuh-config] .button-row {
  margin-top: .85rem;
}

.cedarwick-site [data-aipuh-add-to-cart],
.cedarwick-site [data-aipuh-training-add-to-cart] {
  min-height: 42px;
  padding: .68rem 1rem;
  border: 1px solid var(--cw-cedar, #29453d);
  background: var(--cw-cedar, #29453d);
  color: #fffaf2;
  box-shadow: inset 0 -2px 0 rgba(199,155,79,.28), 0 6px 14px rgba(41,69,61,.12);
  font-size: .84rem;
  font-weight: 700;
  letter-spacing: .028em;
  transition: transform 140ms ease, background 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

.cedarwick-site [data-aipuh-add-to-cart]:hover,
.cedarwick-site [data-aipuh-training-add-to-cart]:hover {
  transform: translateY(-1px);
  border-color: var(--cw-oxblood, #6b3037);
  background: var(--cw-oxblood, #6b3037);
  color: #fffaf2;
  box-shadow: inset 0 -2px 0 rgba(224,189,121,.26), 0 9px 18px rgba(107,48,55,.16);
}

.cedarwick-site [data-aipuh-add-to-cart]:focus-visible,
.cedarwick-site [data-aipuh-training-add-to-cart]:focus-visible {
  outline: 3px solid rgba(199,155,79,.35);
  outline-offset: 3px;
}

.cedarwick-site .aipuh-price-card [data-aipuh-cart-add-status],
.cedarwick-site [data-aipuh-config] [data-aipuh-cart-add-status] {
  margin: .55rem 0 0;
  padding: .42rem 0 .42rem .7rem;
  border-left: 2px solid var(--cw-brass, #a77c3f);
  background: transparent;
  font-size: .78rem;
  line-height: 1.35;
}

.cedarwick-site [data-aipuh-cart-toggle] {
  min-height: 40px;
  padding: .58rem .82rem;
  font-size: .78rem;
}

@media (max-width: 760px) {
  .cedarwick-site [data-aipuh-cart-dialog],
  .cedarwick-site [data-aipuh-cart-checkout-dialog] {
    width: calc(100vw - .75rem);
    max-height: calc(100dvh - .75rem);
  }

  .cedarwick-site [data-aipuh-cart-view] > header,
  .cedarwick-site [data-aipuh-checkout-form] > header {
    padding: 1.05rem 1rem .95rem;
  }

  .cedarwick-site [data-aipuh-cart-view] > header h2,
  .cedarwick-site [data-aipuh-checkout-form] > header h2 {
    font-size: clamp(1.7rem, 9vw, 2.45rem);
  }

  .cedarwick-site [data-aipuh-checkout-form] > fieldset,
  .cedarwick-site [data-aipuh-after-quote] fieldset {
    margin-inline: .85rem;
    padding: .8rem;
  }

  .cedarwick-site [data-aipuh-checkout-form] fieldset > .aipuh-license-signature-field {
    max-width: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cedarwick-site [data-aipuh-add-to-cart],
  .cedarwick-site [data-aipuh-training-add-to-cart] {
    transition: none;
  }
}


/* 2026-10-20: match the readable Last Person shipping form without weakening AIPUH terms. */
.cedarwick-site [data-aipuh-cart-checkout-dialog] {
  width: min(920px, calc(100vw - 1rem));
  max-width: 920px;
  max-height: min(94dvh, 1000px);
  border-radius: 10px;
}

.cedarwick-site [data-aipuh-checkout-form] fieldset > label,
.cedarwick-site [data-aipuh-after-quote] fieldset > label {
  min-width: 0;
  max-width: 100%;
  gap: .45rem;
  font-size: .9rem;
  letter-spacing: normal;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.cedarwick-site [data-aipuh-checkout-form] input:not([type="checkbox"]),
.cedarwick-site [data-aipuh-checkout-form] select,
.cedarwick-site [data-aipuh-after-quote] input:not([type="checkbox"]),
.cedarwick-site [data-aipuh-after-quote] select {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 52px;
  padding: .8rem .9rem;
  border-radius: 8px;
  font-size: max(16px, 1rem);
  line-height: 1.35;
  text-overflow: clip;
  overflow: visible;
}

.cedarwick-site [data-aipuh-checkout-form] input:focus-visible,
.cedarwick-site [data-aipuh-after-quote] input:focus-visible,
.cedarwick-site [data-aipuh-checkout-form] select:focus-visible,
.cedarwick-site [data-aipuh-after-quote] select:focus-visible {
  outline: 2px solid var(--cw-brass, #a77c3f);
  outline-offset: 2px;
}

.cedarwick-site [data-aipuh-checkout-form] > fieldset,
.cedarwick-site [data-aipuh-after-quote] fieldset {
  column-gap: 1rem;
  row-gap: .85rem;
}

@media (max-width: 760px) {
  .cedarwick-site [data-aipuh-cart-checkout-dialog] {
    width: calc(100vw - .75rem);
    max-width: none;
    max-height: calc(100dvh - .75rem);
    border-radius: 10px;
  }

  .cedarwick-site [data-aipuh-checkout-form] > fieldset,
  .cedarwick-site [data-aipuh-after-quote] fieldset {
    display: grid;
    grid-template-columns: minmax(0,1fr);
    margin-inline: .8rem;
    padding: 1rem .85rem;
  }

  .cedarwick-site [data-aipuh-checkout-form] fieldset > label,
  .cedarwick-site [data-aipuh-after-quote] fieldset > label,
  .cedarwick-site [data-aipuh-checkout-form] fieldset > label:has([name]),
  .cedarwick-site [data-aipuh-after-quote] fieldset > label:has([name]) {
    grid-column: 1 / -1;
    width: 100%;
    max-width: none;
  }

  .cedarwick-site [data-aipuh-checkout-form] input:not([type="checkbox"]),
  .cedarwick-site [data-aipuh-after-quote] input:not([type="checkbox"]),
  .cedarwick-site [data-aipuh-checkout-form] select,
  .cedarwick-site [data-aipuh-after-quote] select {
    font-size: 16px;
    min-height: 52px;
  }
}


/* Provider shipping + Stripe Tax breakdown mirrors the fiction store's cart totals. */
.cedarwick-site [data-aipuh-quote-summary] {
  padding: 1rem 1.15rem;
  border-left: 3px solid var(--cw-brass, #a77c3f);
  background: #fffdf8;
  line-height: 1.55;
}

.cedarwick-site [data-aipuh-quote-summary] .aipuh-quote-grid {
  display: grid;
  gap: .15rem;
  margin: 0;
  font-family: Arial, sans-serif;
}

.cedarwick-site [data-aipuh-quote-summary] .aipuh-quote-grid > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: .4rem 0;
  min-width: 0;
}

.cedarwick-site [data-aipuh-quote-summary] dt {
  min-width: 0;
  overflow-wrap: anywhere;
}

.cedarwick-site [data-aipuh-quote-summary] dd {
  margin: 0;
  font-weight: 700;
  text-align: right;
  white-space: nowrap;
}

.cedarwick-site [data-aipuh-quote-summary] .aipuh-quote-total {
  margin-top: .45rem;
  padding-top: .8rem !important;
  border-top: 1px solid rgba(32,39,36,.2);
  font-size: 1rem;
}

.cedarwick-site [data-aipuh-quote-summary] small {
  display: block;
  margin-top: .65rem;
  font-size: .82rem;
  line-height: 1.4;
}
