/* =============================================================================
   ADD Coffee — storefront (cart drawer + checkout)
   Marketplace tokens, scoped so nothing collides with the Craft/Elementor theme.
   ========================================================================== */

.ac-sf{
  --ts-cream:#F1EAE0; --ts-cream-deep:#E7DECF; --ts-terracotta:#C18B57;
  --ts-terracotta-dk:#A8723F; --ts-ink:#1C1A17; --ts-body:#5C564D; --ts-gold:#D8A24A;
  --r-sm:3px; --r-md:7px; --ease:cubic-bezier(.22,.61,.36,1);
  font-family:'Inter',Helvetica,Arial,sans-serif;
}

/* ------------------------------------------------------------ cart drawer */
.ac-cart[hidden]{ display:none; }
.ac-cart{ position:fixed; inset:0; z-index:9000; }
.ac-cart__scrim{ position:absolute; inset:0; background:rgba(28,26,23,.55); opacity:0; transition:opacity .26s var(--ease); }
.ac-cart.is-open .ac-cart__scrim{ opacity:1; }
.ac-cart__panel{
  position:absolute; top:0; right:0; bottom:0; width:428px; max-width:92vw;
  background:#fff; display:flex; flex-direction:column;
  transform:translateX(102%); transition:transform .28s var(--ease);
  box-shadow:-18px 0 50px rgba(28,26,23,.18);
}
.ac-cart.is-open .ac-cart__panel{ transform:none; }
.ac-cart__head{
  display:flex; align-items:center; justify-content:space-between;
  padding:20px 24px; border-bottom:1px solid var(--ts-cream-deep);
}
.ac-cart__title{ font-family:'Fraunces',Georgia,serif; font-weight:400; font-size:21px; color:var(--ts-ink); margin:0; }
.ac-cart__x{ background:none; border:0; cursor:pointer; font-size:19px; color:var(--ts-body); padding:4px 6px; }
.ac-cart__body{ flex:1; overflow-y:auto; padding:18px 24px; }
.ac-cart__foot{ padding:20px 24px; border-top:1px solid var(--ts-cream-deep); background:#FCFAF7; }

.ac-cart__group{ margin-bottom:22px; }
.ac-cart__group-head{
  font-family:'IBM Plex Mono',monospace; font-size:9.5px; letter-spacing:.15em;
  text-transform:uppercase; color:var(--ts-terracotta-dk);
  padding-bottom:8px; margin-bottom:12px; border-bottom:1px solid var(--ts-cream-deep);
}
.ac-cart__line{ display:flex; gap:13px; padding:12px 0; border-bottom:1px solid var(--ts-cream); }
.ac-cart__line img, .ac-cart__noimg{
  width:58px; height:58px; flex:none; object-fit:cover; border-radius:var(--r-sm); background:var(--ts-cream-deep);
}
.ac-cart__line-body{ flex:1; min-width:0; }
.ac-cart__line-body a{ display:block; font-size:14px; font-weight:600; color:var(--ts-ink); text-decoration:none; line-height:1.4; }
.ac-cart__line-body a:hover{ color:var(--ts-terracotta-dk); }
.ac-cart__variant, .ac-cart__meta{ display:block; font-size:11.5px; color:var(--ts-body); margin-top:3px; }
.ac-cart__qty{ display:flex; align-items:center; gap:7px; margin-top:9px; }
.ac-cart__qty button{
  width:26px; height:26px; border:1px solid var(--ts-cream-deep); background:#fff;
  border-radius:var(--r-sm); cursor:pointer; color:var(--ts-ink); font-size:14px; line-height:1;
}
.ac-cart__qty button:hover{ border-color:var(--ts-terracotta); }
.ac-cart__qty span{ min-width:26px; text-align:center; font-size:13.5px; }
.ac-cart__rm{ width:auto!important; padding:0 9px; font-size:10px!important; letter-spacing:.1em; text-transform:uppercase; color:var(--ts-body)!important; }
.ac-cart__line-total{ font-family:'Fraunces',Georgia,serif; font-size:15px; color:var(--ts-ink); white-space:nowrap; }

.ac-cart__problems{
  background:#FDF8F2; border:1px solid var(--ts-cream-deep); border-left:3px solid var(--ts-terracotta);
  border-radius:0 var(--r-md) var(--r-md) 0; padding:14px 16px; margin-bottom:18px;
}
.ac-cart__problems b{ display:block; font-size:13px; color:var(--ts-ink); margin-bottom:7px; }
.ac-cart__problems ul{ margin:0; padding-left:17px; }
.ac-cart__problems li{ font-size:12.5px; color:var(--ts-body); line-height:1.65; margin-bottom:4px; }

.ac-cart__empty{ text-align:center; padding:52px 20px; }
.ac-cart__empty h4{ font-family:'Fraunces',Georgia,serif; font-weight:400; font-size:20px; color:var(--ts-ink); margin:0 0 10px; }
.ac-cart__empty p{ font-size:13.5px; color:var(--ts-body); line-height:1.75; margin:0 0 20px; }
.ac-cart__cta{
  display:inline-block; padding:12px 24px; background:var(--ts-ink); color:var(--ts-cream);
  border:0; cursor:pointer; text-decoration:none; border-radius:var(--r-sm);
  font-family:'IBM Plex Mono',monospace; font-size:10.5px; letter-spacing:.15em; text-transform:uppercase;
}
.ac-cart__cta:hover{ background:var(--ts-terracotta-dk); color:#fff; }
.ac-cart__skel{ height:74px; margin-bottom:12px; border-radius:var(--r-md);
  background:linear-gradient(90deg,var(--ts-cream) 25%,var(--ts-cream-deep) 37%,var(--ts-cream) 63%);
  background-size:400% 100%; animation:acShimmer 1.3s ease-in-out infinite; }
@keyframes acShimmer{ 0%{background-position:100% 0} 100%{background-position:0 0} }
@media (prefers-reduced-motion:reduce){ .ac-cart__skel{ animation:none } .ac-cart__panel{ transition:none } }

.ac-cart__totals{ display:flex; justify-content:space-between; align-items:baseline; margin-bottom:14px; }
.ac-cart__totals span:first-child{ font-family:'IBM Plex Mono',monospace; font-size:10px; letter-spacing:.14em; text-transform:uppercase; color:var(--ts-body); }
.ac-cart__totals span:last-child{ font-family:'Fraunces',Georgia,serif; font-size:24px; color:var(--ts-ink); }
.ac-cart__note{ font-size:11.5px; color:var(--ts-body); line-height:1.6; margin:10px 0 0; text-align:center; }

/* cart badge in the site header */
.ac-cart-badge{
  display:inline-flex; align-items:center; justify-content:center; min-width:18px; height:18px;
  padding:0 5px; margin-left:5px; border-radius:9px; background:var(--ts-terracotta); color:#fff;
  font-family:'IBM Plex Mono',monospace; font-size:10px;
}

/* ---------------------------------------------------------------- checkout */
.ac-co{ background:var(--ts-cream); padding:0 0 90px; }
.ac-co__hero{ background:var(--ts-ink); padding:64px 24px 74px; text-align:center; color:#fff; }
.ac-co__eyebrow{ font-family:'IBM Plex Mono',monospace; font-size:10.5px; letter-spacing:.26em; text-transform:uppercase; color:var(--ts-gold); margin-bottom:12px; }
.ac-co__title{ font-family:'Fraunces',Georgia,serif; font-weight:300; font-size:38px; margin:0; color:#fff; }
.ac-co__wrap{ max-width:1100px; margin:-40px auto 0; padding:0 20px; display:grid; grid-template-columns:1fr 372px; gap:26px; align-items:start; }
@media (max-width:900px){ .ac-co__wrap{ grid-template-columns:1fr; } }

.ac-card{ background:#fff; border:1px solid var(--ts-cream-deep); border-radius:var(--r-md); padding:28px 30px; margin-bottom:22px; }
.ac-card h2{ font-family:'Fraunces',Georgia,serif; font-weight:500; font-size:19px; color:var(--ts-ink); margin:0 0 6px; }
.ac-card p.lede{ font-size:13.5px; color:var(--ts-body); line-height:1.7; margin:0 0 22px; }

.ac-grid{ display:grid; grid-template-columns:1fr 1fr; gap:0 18px; }
@media (max-width:600px){ .ac-grid{ grid-template-columns:1fr; } }
.ac-f{ margin-bottom:18px; }
.ac-f label{ display:block; font-family:'IBM Plex Mono',monospace; font-size:9.5px; letter-spacing:.15em; text-transform:uppercase; color:var(--ts-body); margin-bottom:6px; }
.ac-f input, .ac-f select, .ac-f textarea{
  width:100%; padding:12px 14px; font-size:14px; color:var(--ts-ink); background:#FCFAF7;
  border:1px solid var(--ts-cream-deep); border-radius:var(--r-sm); font-family:inherit;
}
.ac-f input:focus, .ac-f select:focus, .ac-f textarea:focus{ outline:none; border-color:var(--ts-terracotta); background:#fff; }
.ac-f input.is-invalid{ border-color:#A8442F; }
.ac-f .err{ display:block; margin-top:6px; font-size:12.5px; color:#A8442F; }
.ac-f .hint{ display:block; margin-top:6px; font-size:12px; color:var(--ts-body); line-height:1.55; }
.ac-req{ color:var(--ts-terracotta-dk); }

/* escrow toggle */
.ac-escrow{ border:1px solid var(--ts-cream-deep); border-radius:var(--r-md); overflow:hidden; }
.ac-escrow__head{ display:flex; gap:14px; align-items:flex-start; padding:20px 22px; background:#FCFAF7; cursor:pointer; }
.ac-escrow__head input{ width:auto; margin-top:3px; }
.ac-escrow__head b{ display:block; font-family:'Fraunces',Georgia,serif; font-size:17px; font-weight:500; color:var(--ts-ink); margin-bottom:5px; }
.ac-escrow__head span{ display:block; font-size:13px; color:var(--ts-body); line-height:1.7; }
.ac-escrow__detail{ padding:18px 22px; border-top:1px solid var(--ts-cream-deep); font-size:12.5px; color:var(--ts-body); line-height:1.75; }
.ac-escrow__detail b{ color:var(--ts-ink); }

/* signup nudge — never a dark pattern */
.ac-nudge{ background:var(--ts-ink); color:var(--ts-cream); border-radius:var(--r-md); padding:22px 24px; margin-bottom:22px; }
.ac-nudge b{ display:block; font-family:'Fraunces',Georgia,serif; font-size:17px; font-weight:400; color:#fff; margin-bottom:8px; }
.ac-nudge p{ font-size:13px; line-height:1.75; color:rgba(241,234,224,.76); margin:0 0 16px; }
.ac-nudge__actions{ display:flex; gap:10px; flex-wrap:wrap; align-items:center; }
.ac-nudge a.primary{ display:inline-block; padding:11px 22px; background:var(--ts-gold); color:var(--ts-ink); text-decoration:none; border-radius:var(--r-sm); font-family:'IBM Plex Mono',monospace; font-size:10.5px; letter-spacing:.14em; text-transform:uppercase; }
.ac-nudge a.ghost{ font-size:12.5px; color:rgba(241,234,224,.72); text-decoration:underline; }

/* summary */
.ac-sum{ position:sticky; top:20px; }
.ac-sum__line{ display:flex; justify-content:space-between; gap:12px; padding:9px 0; font-size:13.5px; color:var(--ts-body); }
.ac-sum__line strong{ color:var(--ts-ink); }
/* A bundle saving reads as money coming OFF, so it is the one green line in the
   summary — a discount printed in the same grey as everything else is easy to miss. */
.ac-sum__line--save{ color:#3D6642; font-weight:600; }
.ac-sum__line--save span:last-child{ font-variant-numeric:tabular-nums; }
.ac-sum__total{ display:flex; justify-content:space-between; align-items:baseline; padding-top:14px; margin-top:8px; border-top:1px solid var(--ts-cream-deep); }
.ac-sum__total span:first-child{ font-family:'IBM Plex Mono',monospace; font-size:10px; letter-spacing:.14em; text-transform:uppercase; color:var(--ts-body); }
.ac-sum__total span:last-child{ font-family:'Fraunces',Georgia,serif; font-size:26px; color:var(--ts-ink); }
.ac-sum__group{ margin-bottom:16px; }
.ac-sum__group-head{ font-family:'IBM Plex Mono',monospace; font-size:9px; letter-spacing:.14em; text-transform:uppercase; color:var(--ts-terracotta-dk); margin-bottom:8px; }

.ac-btn{
  display:inline-flex; align-items:center; justify-content:center; gap:9px; width:100%;
  padding:16px 26px; border:0; border-radius:var(--r-sm); cursor:pointer;
  background:var(--ts-ink); color:var(--ts-cream);
  font-family:'IBM Plex Mono',monospace; font-size:11.5px; letter-spacing:.16em; text-transform:uppercase;
}
.ac-btn:hover{ background:var(--ts-terracotta-dk); color:#fff; }
.ac-btn[disabled]{ opacity:.45; cursor:not-allowed; }
.ac-btn--ghost{ background:transparent; color:var(--ts-ink); border:1px solid var(--ts-cream-deep); }

.ac-alert{ display:flex; gap:11px; padding:15px 18px; margin-bottom:22px; border-radius:0 var(--r-md) var(--r-md) 0;
  background:#FDF8F2; border:1px solid var(--ts-cream-deep); border-left:3px solid var(--ts-terracotta);
  font-size:13.5px; color:var(--ts-ink); line-height:1.7; }
.ac-alert--error{ background:#FBF1EE; border-left-color:#A8442F; }
.ac-alert--success{ background:#F3F7F3; border-left-color:#4E7A52; }

/* confirmation / status pages */
.ac-state{ display:inline-flex; align-items:center; gap:7px; font-family:'IBM Plex Mono',monospace; font-size:10px; letter-spacing:.13em; text-transform:uppercase; }
.ac-state::before{ content:''; width:6px; height:6px; border-radius:50%; background:currentColor; }
.ac-state--live{ color:#4E7A52; } .ac-state--pending{ color:#B07C22; }
.ac-state--action{ color:var(--ts-terracotta-dk); } .ac-state--rejected{ color:#A8442F; }
.ac-state--draft{ color:var(--ts-body); }

.ac-narrow{ max-width:720px; margin:-40px auto 0; padding:0 20px; }
.ac-timeline{ list-style:none; margin:0; padding:0; }
.ac-timeline li{ display:flex; gap:14px; padding:13px 0; border-top:1px solid var(--ts-cream); }
.ac-timeline li:first-child{ border-top:0; }
.ac-timeline time{ font-family:'IBM Plex Mono',monospace; font-size:9.5px; letter-spacing:.12em; text-transform:uppercase; color:var(--ts-body); min-width:104px; }

/* ============================================================================
   Payment method chooser + bank transfer panel (B8)
   Offline payments need real estate: the buyer has to read account details,
   go elsewhere to make the transfer, then come back and upload proof.
   ========================================================================= */
.ac-pay { display: grid; gap: 10px; margin-bottom: 4px; }
.ac-pay__opt { cursor: pointer; }
.ac-pay__opt input { position: absolute; opacity: 0; pointer-events: none; }
.ac-pay__box {
  display: flex; align-items: flex-start; gap: 13px;
  padding: 15px 17px; border: 1px solid var(--ts-cream-deep, #E7DECF);
  border-radius: 5px; background: #FCFAF7;
  transition: border-color .2s, background .2s;
}
.ac-pay__box > i { font-size: 17px; color: var(--ts-terracotta, #C18B57); margin-top: 2px; }
/* Official scheme artwork (Google Pay). Never recoloured, never redrawn — the SVG
   carries its own clear space, so height is the only thing we set. 34px renders the
   capsule at ~18px, matching the glyphs beside it as Google's guidelines require. */
.ac-pay__box > .ac-pay__mark { display: block; flex: none; height: 34px; width: auto; margin-top: -6px; }
.ac-pay__box b { display: block; font-size: 14.5px; color: var(--ts-ink, #1C1A17); margin-bottom: 3px; }
.ac-pay__box small { display: block; font-size: 12.5px; line-height: 1.6; color: var(--ts-body, #5C564D); }
.ac-pay__opt input:checked + .ac-pay__box {
  border-color: var(--ts-terracotta, #C18B57); background: #fff;
  box-shadow: inset 0 0 0 1px var(--ts-terracotta, #C18B57);
}
.ac-pay__opt input:focus-visible + .ac-pay__box {
  outline: 2px solid var(--ts-terracotta, #C18B57); outline-offset: 2px;
}

.ac-bank {
  margin-top: 20px; padding: 20px 22px;
  border: 1px solid var(--ts-cream-deep, #E7DECF); border-radius: 5px; background: #FCFAF7;
}
.ac-bank__head { margin-bottom: 13px; }
.ac-bank__head b {
  display: block; font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 10.5px; letter-spacing: .15em; text-transform: uppercase;
  color: var(--ts-terracotta-dk, #A8723F); margin-bottom: 5px;
}
.ac-bank__head span { display: block; font-size: 12.5px; line-height: 1.65; color: var(--ts-body, #5C564D); }

.ac-bank__dl {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px; margin: 0 0 14px; padding: 15px 17px;
  background: #fff; border: 1px solid var(--ts-cream-deep, #E7DECF); border-radius: 4px;
}
.ac-bank__dl dt {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 9.5px; letter-spacing: .13em; text-transform: uppercase;
  color: var(--ts-body, #5C564D); margin-bottom: 4px;
}
.ac-bank__dl dd {
  margin: 0; font-size: 14px; font-weight: 600; color: var(--ts-ink, #1C1A17);
  word-break: break-word;
}
.ac-bank__note {
  margin: 0 0 4px; font-size: 12.5px; line-height: 1.7; color: var(--ts-body, #5C564D);
}
.ac-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 560px) { .ac-field-row { grid-template-columns: 1fr; } }

/* Card payment panel — mirrors .ac-bank so the two methods feel like one system. */
.ac-cardpay {
  margin-top: 20px; padding: 20px 22px;
  border: 1px solid var(--ts-cream-deep, #E7DECF); border-radius: 5px; background: #FCFAF7;
}
.ac-card-el {
  background: #fff; border: 1px solid var(--ts-cream-deep, #E7DECF);
  border-radius: 4px; padding: 14px 15px; margin-top: 4px;
}
.ac-card-el.StripeElement--focus { border-color: var(--ts-terracotta, #C18B57); }
.ac-card-el.StripeElement--invalid { border-color: #A8442F; }


/* A provider running in its own sandbox takes no real money. The badge exists so an
   admin testing checkout can never mistake a test payment for a real one and dispatch
   against it. */
.ac-pay__sandbox {
    display: inline-block;
    margin-left: 7px;
    padding: 2px 7px;
    border-radius: 999px;
    background: #F1EAE0;
    color: #A5713F;
    border: 1px solid #E7DECF;
    font-family: 'IBM Plex Mono', ui-monospace, monospace;
    font-size: 8.5px;
    letter-spacing: .12em;
    text-transform: uppercase;
    vertical-align: middle;
    cursor: help;
}

/* The wallet buttons render their own chrome; they only need room to breathe. */
#ac-paypal-buttons { margin-top: 14px; }
#ac-gpay-button { margin-top: 14px; min-height: 48px; }
