/* newage checkout: two-column flow, form fields, order summary, dialogs */
.co { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: clamp(20px, 3vw, 48px); align-items: start; margin-top: 12px; }
.co-main { display: grid; gap: var(--g-md); min-width: 0; }
.co-section { background: var(--white); border: 1px solid var(--line); border-radius: 6px; padding: clamp(18px, 2.4vw, 28px); display: flex; flex-wrap: wrap; gap: 16px; }
.co-section > * { flex: 1 1 100%; min-width: 0; }
.co-section > .co-field.half { flex: 1 1 calc(50% - 8px); }
.co-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.co-head h2 { font-size: 22px; text-transform: uppercase; }
.co-aside { margin: 0; font-size: 14.5px; color: #6b6764; }
.co-aside a { color: var(--orange-cta); font-weight: 600; text-decoration: underline; }

.co-field { display: grid; gap: 6px; position: relative; }
.co-field label, .co-field legend { font-size: 14px; font-weight: 600; color: #3b3937; }
.co-field .req { color: var(--orange-cta); }
.co-field input[type="text"], .co-field input[type="password"], .co-field select, .co-field textarea {
  width: 100%; padding: 13px 14px; border: 1px solid var(--line); border-radius: 4px; background: var(--white);
  font-family: var(--body); font-size: 16px; color: var(--charcoal);
}
.co-field input:focus, .co-field select:focus, .co-field textarea:focus { border-color: var(--orange); outline: none; box-shadow: 0 0 0 3px rgba(255, 90, 31, .12); }
.co-field.has-error input, .co-field.has-error select { border-color: var(--orange-cta); }
.text-danger { color: var(--orange-cta); font-size: 14px; font-weight: 600; }
.co-checks { display: grid; gap: 8px; }
.co-same { margin-top: 4px; }

.co-suggest { position: absolute; left: 0; right: 0; top: 100%; z-index: 20; background: #fff; border: 1px solid var(--line); border-radius: 6px; box-shadow: 0 26px 50px -26px rgba(32, 32, 32, .35); margin-top: 4px; }
.co-suggest[hidden] { display: none; }
.co-suggest-bar { display: flex; justify-content: space-between; align-items: center; padding: 8px 14px; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #6b6764; border-bottom: 1px solid var(--line); }
.co-suggest-bar button { border: 0; background: none; font-size: 22px; line-height: 1; color: var(--charcoal); }
.suggestion-item { display: block; width: 100%; text-align: left; padding: 12px 14px; border: 0; background: none; font-family: var(--body); font-size: 15px; color: var(--charcoal); }
.suggestion-item:hover, .suggestion-item:focus-visible { background: var(--offwhite); color: var(--orange-text); }
.co-suggest-power { padding: 8px 14px; border-top: 1px solid var(--line); }

.co-nav { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.co-back { font-size: 14.5px; font-weight: 600; color: #454341; }
.co-back:hover { color: var(--orange-text); }
#checkout-continue-button { padding: 17px 34px; }
#checkout-continue-button:disabled { opacity: .6; cursor: default; transform: none; }

/* order summary */
.co-side { position: sticky; top: 100px; background: var(--white); border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.checkout-sidebar-collapse-title { display: none; width: 100%; align-items: center; justify-content: space-between; padding: 16px 18px; border: 0; background: var(--offwhite); font-size: 15px; font-weight: 600; color: var(--orange-cta); }
.checkout-sidebar-collapse-title .icon { stroke-width: 2; transition: transform .25s ease; }
.checkout-sidebar-collapse-title[aria-expanded="true"] .icon { transform: rotate(180deg); }
#checkout-sidebar-collapse { padding: 20px; }
#checkout-sidebar-collapse[hidden] { display: none; }
.co-lines { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 14px; max-height: 360px; overflow-y: auto; }
.co-lines li { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.co-thumb img { width: 64px; height: 64px; object-fit: contain; border: 1px solid var(--line); border-radius: 4px; background: #F3EEE9; }
.co-line-info { font-size: 14.5px; display: grid; gap: 2px; }
.co-line-info a { font-weight: 600; }
.co-qty { color: #6b6764; }
.co-line-info small, .co-note { font-size: 13px; color: #6b6764; }
.co-note { color: #2f6b3d; font-weight: 600; }
.co-note.bad { color: var(--orange-cta); }
.co-line-price { font-weight: 600; font-size: 15px; }
.co-coupon { display: flex; gap: 8px; padding: 14px 0; border-top: 1px solid var(--line); }
.co-coupon input { flex: 1; min-width: 0; padding: 11px 12px; border: 1px solid var(--line); border-radius: 4px; font-family: var(--body); font-size: 16px; }
.co-coupon .btn { padding: 11px 18px; font-size: 13px; }
.co-totals { margin: 0; padding-top: 14px; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.co-totals > div { display: flex; justify-content: space-between; gap: 12px; font-size: 15.5px; }
.co-totals dt, .co-totals dd { margin: 0; }
.co-totals small { display: block; font-size: 12px; color: #6b6764; }
.co-totals .total { padding-top: 12px; margin-top: 4px; border-top: 1px solid var(--line); font-weight: 700; font-size: 20px; }
.co-totals .total dd { text-align: right; }
.co-totals .total small { font-weight: 400; }

/* completed steps */
.co-summary { margin: 0; display: grid; gap: 0; }
.co-summary > div { display: grid; grid-template-columns: 130px minmax(0, 1fr) auto; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.co-summary > div:last-child { border-bottom: 0; }
.co-summary dt { font-weight: 600; color: #6b6764; }
.co-summary dd { margin: 0; }
.co-summary a { color: var(--orange-cta); font-weight: 600; text-decoration: underline; }

/* dialogs */
.co-dialog { border: 0; border-radius: 8px; padding: 28px; width: min(92vw, 460px); box-shadow: 0 30px 80px rgba(20, 18, 17, .45); }
.co-dialog::backdrop { background: rgba(20, 18, 17, .55); }
.co-dialog h2 { font-size: 24px; text-transform: uppercase; margin-bottom: 14px; }
.co-dialog .co-field { margin-bottom: 14px; }
.co-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.co-msg:empty { display: none; }
.co-msg { margin-top: 10px; color: var(--orange-cta); font-weight: 600; font-size: 14.5px; }

@media (max-width: 860px) {
  .co { grid-template-columns: minmax(0, 1fr); }
  .co-side { position: static; order: -1; }
  .checkout-sidebar-collapse-title { display: flex; }
  .co-section > .co-field.half { flex-basis: 100%; }
  .co-summary > div { grid-template-columns: minmax(0, 1fr) auto; }
  .co-summary dt { grid-column: 1 / -1; }
  .co-nav { flex-direction: column-reverse; align-items: stretch; }
  #checkout-continue-button { width: 100%; justify-content: center; }
}

/* choice rows: shipping methods and payment methods */
.co-choice { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 16px; border: 1px solid var(--line); border-radius: 6px; background: var(--white); cursor: pointer; }
.co-choice + .co-choice { margin-top: 10px; }
.co-choice:has(input:checked) { border-color: var(--orange); background: #FFF8F4; }
.co-choice input[type="radio"] { width: 20px; height: 20px; accent-color: var(--orange-cta); }
.co-choice label { display: grid; gap: 2px; cursor: pointer; }
.co-choice-title { font-weight: 600; font-size: 16px; }
.co-choice-sub { font-size: 14px; color: #6b6764; }
.checkout-quote-price { font-weight: 700; font-size: 16px; }
.checkout-shipping-comment-section textarea { resize: vertical; }
#checkout-shipping-cover[hidden] { display: none; }

/* payment step */
.co-wallets { margin: 0 0 18px; }
#wallet-wrapper { display: flex; gap: 12px; flex-wrap: wrap; }
#wallet-wrapper .wallet-item { flex: 1 1 200px; min-height: 44px; }
#or-pay-with { display: flex; align-items: center; gap: 14px; margin-top: 16px; color: #6b6764; font-size: 14px; text-transform: uppercase; letter-spacing: .08em; }
#or-pay-with::before, #or-pay-with::after { content: ""; flex: 1; height: 1px; background: var(--line); }
#or-pay-with[hidden] { display: none; }
.co-paybox { margin: -4px 0 10px; padding: 16px; border: 1px solid var(--line); border-top: 0; border-radius: 0 0 6px 6px; background: #FAFAFA; }
.co-paybox[hidden] { display: none; }
.co-paybox p { margin: 0; font-size: 14.5px; color: #454341; }
.co-terms { margin-top: 14px; font-size: 14px; color: #454341; }
.co-complete { margin-top: 16px; display: grid; gap: 12px; justify-items: end; }
.co-complete[hidden], #eway-complete[hidden] { display: none; }
.co-complete h2 { font-size: 20px; text-transform: uppercase; justify-self: start; }
.co-note-box { padding: 14px 16px; background: var(--offwhite); border: 1px solid var(--line); border-radius: 4px; justify-self: stretch; }
.loader { width: 28px; height: 28px; border: 3px solid var(--line); border-top-color: var(--orange); border-radius: 50%; animation: na-spin .8s linear infinite; }
.loader[hidden] { display: none; }
@keyframes na-spin { to { transform: rotate(360deg); } }
.co-processing { display: flex; align-items: center; justify-content: center; gap: 12px; font-weight: 600; }
#cba-powerboard-widget iframe, #cba-powerboard-widget-3ds iframe { border: 0; width: 100%; }
#cba-powerboard-widget iframe { height: 245px; }
#cba-powerboard-widget-3ds iframe { height: 411px; }
.cba-wallet { position: relative; }
.co-wallet-busy { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0, 0, 0, .5); color: #fff; font-weight: 600; border-radius: 4px; }
#cba-googlepay-widget button { height: 50px; border-radius: 5px; outline: none; }

/* order confirmation */
.co-done h1 { font-size: clamp(26px, 3.2vw, 38px); text-transform: none; margin: 8px 0 18px; }
.co-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.co-details > div { flex: none; }
.co-details .wide { grid-column: 1 / -1; }
.co-details h2 { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; font-family: var(--body); font-weight: 700; color: #6b6764; margin-bottom: 6px; }
.co-details p, .co-details address { margin: 0; font-style: normal; font-size: 15.5px; line-height: 1.6; }
@media (max-width: 560px) { .co-details { grid-template-columns: 1fr; } }
