/* newage cart: added-to-cart drawer, age check, cart page, cart panels, shipping dialog */
.field-err { margin-top: 6px; color: var(--orange-cta); font-size: 14px; font-weight: 600; }

/* added-to-cart drawer */
.scrim { position: fixed; inset: 0; z-index: calc(var(--z-drawer) - 1); background: rgba(20, 18, 17, .5); opacity: 0; transition: opacity .3s ease; }
.scrim.open { opacity: 1; }
.scrim[hidden], .side-cart[hidden] { display: none; }
.side-cart {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: var(--z-drawer); width: min(100%, 440px); background: var(--white);
  padding: 24px 22px; overflow-y: auto; transform: translateX(100%); transition: transform .32s cubic-bezier(.3, .7, .3, 1);
  box-shadow: 0 0 60px rgba(20, 18, 17, .4);
}
.side-cart.open { transform: none; }
.side-cart-close { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; border: 0; border-radius: 50%; background: var(--offwhite); color: var(--charcoal); display: grid; place-items: center; }
.side-cart-title { font-size: 26px; text-transform: uppercase; margin-bottom: 16px; padding-right: 50px; }
.side-cart-target { display: flex; gap: 14px; align-items: center; padding: 14px; background: var(--offwhite); border: 1px solid var(--line); border-radius: 6px; }
.side-cart-target img { width: 96px; height: 96px; object-fit: contain; background: #fff; border-radius: 4px; }
.side-cart-target a { font-weight: 600; }
.side-cart-price { font-family: var(--head); font-size: 22px; margin-top: 4px; }
.side-cart-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0 24px; }
.side-cart-actions .btn { justify-content: center; padding: 14px 12px; }
.side-cart-sub { font-size: 18px; text-transform: uppercase; margin-bottom: 12px; }
.side-cart-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.side-cart-grid .pcard h3 { font-size: 14px; }

/* age check */
.age-dialog, .ship-dialog { border: 0; border-radius: 8px; padding: 28px; width: min(92vw, 520px); box-shadow: 0 30px 80px rgba(20, 18, 17, .45); }
.age-dialog::backdrop, .ship-dialog::backdrop { background: rgba(20, 18, 17, .55); }
.age-dialog h2, .ship-dialog h2 { font-size: 24px; text-transform: uppercase; margin-bottom: 12px; }
.age-dialog p { margin: 0 0 16px; font-size: 15.5px; color: #454341; }
.age-dialog .btn { margin-top: 16px; }

/* cart page */
.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: var(--g-lg); align-items: start; margin-top: 18px; }
#cart-heading { font-size: clamp(28px, 3.4vw, 42px); text-transform: uppercase; }
.citems { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.cart-item { display: grid; overflow: hidden; grid-template-columns: 96px minmax(0, 1fr) auto auto; gap: 8px 18px; align-items: center; padding: 14px; background: var(--white); border: 1px solid var(--line); border-radius: 6px; }
.cimg img { width: 96px; height: 96px; object-fit: contain; background: #F3EEE9; border-radius: 4px; }
.cinfo { display: grid; gap: 3px; min-width: 0; }
.cname { font-weight: 600; font-size: 16px; }
.cname:hover { color: var(--orange-text); }
.cmodel, .cinfo small { font-size: 13.5px; color: #6b6764; }
.cnote { font-size: 13.5px; color: #2f6b3d; font-weight: 600; }
.cnote.bad { color: var(--orange-cta); }
.cqty { display: grid; gap: 6px; justify-items: start; }
.cart-item .cqty input[type="number"], .cart-item .cprice input { width: 76px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 4px; font-family: var(--body); font-size: 16px; }
.btn-link { border: 0; background: none; padding: 0; font-size: 13.5px; font-weight: 600; color: var(--charcoal); text-decoration: underline; text-underline-offset: 3px; }
.btn-link:hover { color: var(--orange-text); }
.btn-link.danger { color: var(--orange-cta); }
.cprice { display: grid; gap: 4px; justify-items: end; text-align: right; }
.cunit { font-size: 14px; color: #6b6764; }
.ctotal { font-family: var(--head); font-size: 24px; font-weight: 500; }
.cart-continue { margin-top: var(--g-md); }
.cart-summary { position: sticky; top: 100px; background: var(--white); border: 1px solid var(--line); border-radius: 6px; padding: 22px; }
.cart-summary h2 { font-size: 22px; text-transform: uppercase; }
.cart-count { margin: 4px 0 14px; color: #6b6764; font-size: 14.5px; }
.ctotals { margin: 0 0 18px; display: grid; gap: 8px; }
.ctotals div { display: flex; justify-content: space-between; gap: 12px; font-size: 15.5px; }
.ctotals div:last-child { padding-top: 10px; border-top: 1px solid var(--line); font-weight: 700; font-size: 18px; }
.ctotals dt, .ctotals dd { margin: 0; }
.btn-checkout { width: 100%; justify-content: center; }
.fpanels { margin-top: 18px; display: grid; gap: 10px; }
.fpanel { border: 1px solid var(--line); border-radius: 4px; }
.fpanel summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; font-weight: 600; font-size: 15px; }
.fpanel summary::-webkit-details-marker { display: none; }
.fpanel summary .icon { transition: transform .25s ease; stroke-width: 2; color: #8a837c; }
.fpanel[open] summary .icon { transform: rotate(180deg); }
.fpanel-body { padding: 0 14px 14px; display: grid; gap: 8px; }
.fpanel-body label { font-size: 14px; color: #454341; }
.fpanel-row { display: flex; gap: 8px; }
.fpanel-row input { flex: 1; min-width: 0; padding: 11px 12px; border: 1px solid var(--line); border-radius: 4px; font-family: var(--body); font-size: 16px; }
.fpanel-row .btn { padding: 11px 16px; font-size: 13px; }
.ship-option { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.ship-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }

@media (max-width: 960px) {
  .cart-layout { grid-template-columns: minmax(0, 1fr); }
  .cart-summary { position: static; }
}
@media (max-width: 560px) {
  .cart-item { grid-template-columns: 72px minmax(0, 1fr); }
  .cimg img { width: 72px; height: 72px; }
  .cqty, .cprice { grid-column: 2; justify-items: start; text-align: left; }
  .cprice { grid-auto-flow: column; justify-content: space-between; align-items: baseline; }
}
