/* Store pages (checkout, confirmation, receipt, order history): EDD's block markup in the Goat look.
   Loaded only on those pages by dg_assets(). */

.qtile:has(.edd-blocks__checkout),.qtile:has([class*="edd-blocks"]){padding:clamp(18px,3vw,34px)}
.qtile [class*="edd-blocks"]{font-size:1rem;color:var(--ink)}

/* ── cart ── */
.edd-blocks-cart{border:1px solid var(--line);border-radius:16px;overflow:hidden;background:rgba(43,10,61,.55);margin:0 0 28px}
.edd-blocks-cart__row{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:18px 22px;border:0;border-bottom:1px solid var(--line-soft)}
.edd-blocks-cart__row:last-child{border-bottom:0}
.edd-blocks-cart__row-header{background:rgba(255,63,174,.08);padding-top:12px;padding-bottom:12px}
.edd-blocks-cart__row-header>*{font-family:'Space Mono',monospace;font-size:.74rem;font-weight:700;letter-spacing:.14em;text-transform:uppercase;color:var(--muted)}
.edd-blocks-cart__row-item .edd_checkout_cart_item_title,.edd-blocks-cart__row-item .edd_cart_item_name{font-weight:700;font-size:1.05rem;line-height:1.35;color:#fff}
.edd-blocks-cart__row-item .eddr-notice,.edd-blocks-cart__row-item .eddr-cart-item-notice{display:block;margin-top:6px;font-style:normal;font-size:.86rem;color:var(--muted)}
.edd-blocks-cart__row-item .edd_cart_item_price,.edd-blocks-cart__row-item .edd_cart_amount{font-family:'Anton',sans-serif;font-size:1.5rem;letter-spacing:.02em;color:#fff;white-space:nowrap}
.edd-blocks-cart__action-remove{color:var(--muted-2);opacity:.8}
.edd-blocks-cart__action-remove:hover{color:var(--pink);opacity:1}
.edd-blocks-cart__row-footer{justify-content:flex-end;background:rgba(255,255,255,.03)}
.edd-blocks-cart__row-footer .edd_cart_total,.edd-blocks-cart__row-footer .edd_cart_amount{font-family:'Anton',sans-serif;font-size:1.6rem;letter-spacing:.03em;color:var(--gold);font-weight:400}
.edd-blocks-cart__row-footer.edd_cart_discount_row:not(:has(.edd_cart_discount:not(:empty))){display:none}

/* ── form sections ── */
.edd-blocks-form fieldset,.edd-blocks__checkout fieldset{border:1px solid var(--line);border-radius:16px;padding:22px 22px 8px;margin:0 0 24px;background:rgba(43,10,61,.45);min-width:0}
.edd-blocks-form legend,.edd-blocks__checkout legend,.edd-blocks__checkout h3{font-family:'Anton',sans-serif;font-weight:400;text-transform:uppercase;letter-spacing:.03em;font-size:1.45rem;color:#fff;padding:0 10px;margin-left:-10px}
.edd-blocks__checkout-user{display:block}
.edd-blocks__checkout-forms--inline{display:flex;flex-wrap:wrap;gap:10px;justify-content:flex-end;margin:0 0 12px}
.edd-blocks__checkout-guest[disabled]{display:none!important}
.edd-blocks-form__group{margin:0 0 18px}
.edd-blocks__checkout .edd-label{display:block;font-weight:700;font-size:.92rem;color:#ffd6ee;margin:0 0 6px}
.edd-blocks__checkout .edd-required-indicator{color:var(--magenta-lt)}
.edd-blocks__checkout .edd-input,.edd-blocks__checkout select,.edd-blocks__checkout input[type="text"],.edd-blocks__checkout input[type="email"],.edd-blocks__checkout input[type="password"]{
  width:100%;background:#2b0a3d;color:var(--ink);border:1px solid rgba(255,110,199,.35);border-radius:12px;padding:.8em 1em;font:inherit;font-size:1rem;line-height:1.3;transition:border-color .15s,box-shadow .15s}
.edd-blocks__checkout .edd-input::placeholder{color:var(--muted-2);opacity:.8}
.edd-blocks__checkout .edd-input:focus,.edd-blocks__checkout input:focus,.edd-blocks__checkout select:focus{outline:0;border-color:var(--magenta-lt);box-shadow:0 0 0 3px rgba(255,63,174,.25)}
.edd-blocks__checkout .edd-description{display:block;margin:6px 0 0;font-size:.82rem;color:var(--muted-2)}
.edd-blocks__checkout .edd-icon-lock,.edd-blocks__checkout .padlock{fill:var(--gold);color:var(--gold)}
#edd_secure_site_wrapper,.edd-blocks__checkout #edd_secure_site_wrapper{display:flex;align-items:center;gap:8px;font-weight:700;color:var(--muted);margin:0 0 14px}

/* ── buttons ── */
.edd-blocks__checkout .edd-button-secondary,.edd-blocks__checkout button.link,.edd-blocks__checkout .edd-blocks__checkout-login{
  display:inline-flex;align-items:center;background:transparent;color:var(--pink);border:1.5px solid rgba(255,110,199,.55);border-radius:999px;
  padding:.45em 1.1em;font:inherit;font-size:.88rem;font-weight:700;cursor:pointer;box-shadow:none;text-decoration:none}
.edd-blocks__checkout .edd-button-secondary:hover,.edd-blocks__checkout button.link:hover{background:rgba(255,63,174,.12);color:#fff;border-color:var(--magenta-lt)}
.edd-blocks__checkout .edd-button-secondary[disabled]{opacity:.45;cursor:default}
#edd-purchase-button,.edd-blocks__checkout .edd-submit,.qtile [class*="edd-blocks"] .edd-submit,.qtile [class*="edd-blocks"] .button{
  -webkit-appearance:none;appearance:none;display:inline-flex;align-items:center;justify-content:center;width:100%;max-width:420px;
  background:var(--magenta-lt);color:#2b0a3d;border:2px solid #2b0a3d;border-radius:12px;padding:.75em 1.6em .7em;
  font-family:'Anton',sans-serif;font-weight:400;font-size:1.3rem;letter-spacing:.05em;text-transform:uppercase;line-height:1.2;
  box-shadow:5px 5px 0 #7a1259,0 0 26px -6px rgba(255,63,174,.75);transition:transform .12s ease,box-shadow .12s ease;cursor:pointer}
#edd-purchase-button:hover,.edd-blocks__checkout .edd-submit:hover{transform:translate(2px,2px);box-shadow:2px 2px 0 #7a1259,0 0 34px -4px rgba(255,63,174,.95)}
#edd-purchase-button:active{transform:translate(5px,5px);box-shadow:0 0 0 #7a1259}
#edd-purchase-button[disabled],#edd-purchase-button.updating{opacity:.6;cursor:progress}
#edd_purchase_submit,.edd-blocks__purchase-form>p:last-child{margin-top:8px}

/* ── login panel (when "Log in" is tapped) ── */
.edd-blocks__checkout #edd_login_fields p,.edd-blocks__checkout .edd-blocks-form__group-user_login{margin-bottom:14px}
.edd-blocks__checkout .edd-lost-password a,.edd-blocks__checkout a{color:var(--pink)}

/* ── notices / errors ── */
.edd_errors,.edd-alert{border-radius:12px;padding:12px 16px;margin:0 0 18px;border:1px solid}
.edd_errors,.edd-alert-error{background:rgba(255,80,80,.12);border-color:rgba(255,107,107,.55);color:#ffd0d0}
.edd-alert-success{background:rgba(64,220,150,.1);border-color:rgba(64,220,150,.5);color:#c9ffe6}
.edd-alert-info,.edd-alert-warn{background:rgba(240,180,41,.1);border-color:rgba(240,180,41,.5);color:#ffe9b3}

/* ── confirmation / receipt / order history ── */
.qtile [class*="edd-blocks"] table,.qtile table.edd-table,.qtile #edd_purchase_receipt,.qtile #edd_purchase_receipt_products,.qtile #edd_user_history{
  width:100%;border-collapse:separate;border-spacing:0;border:1px solid var(--line);border-radius:16px;overflow:hidden;margin:0 0 24px;background:rgba(43,10,61,.55)}
.qtile [class*="edd-blocks"] th,.qtile [class*="edd-blocks"] td,.qtile table.edd-table th,.qtile table.edd-table td,.qtile #edd_purchase_receipt th,.qtile #edd_purchase_receipt td,.qtile #edd_purchase_receipt_products th,.qtile #edd_purchase_receipt_products td,.qtile #edd_user_history th,.qtile #edd_user_history td{
  padding:14px 18px;border:0;border-bottom:1px solid var(--line-soft);text-align:left;vertical-align:top;color:var(--ink)}
.qtile [class*="edd-blocks"] thead th,.qtile table.edd-table thead th,.qtile #edd_purchase_receipt thead th,.qtile #edd_purchase_receipt_products thead th,.qtile #edd_user_history thead th{
  background:rgba(255,63,174,.08);font-family:'Space Mono',monospace;font-size:.74rem;letter-spacing:.14em;text-transform:uppercase;color:var(--muted)}
.qtile [class*="edd-blocks"] tr:last-child>*{border-bottom:0}
.edd-blocks__row{display:flex;justify-content:space-between;gap:16px;padding:12px 0;border-bottom:1px solid var(--line-soft)}
.edd-blocks__row:last-child{border-bottom:0}
.edd-blocks__row-label{color:var(--muted);font-weight:700}
.edd-blocks__row-value{color:#fff;text-align:right}
.edd-blocks__receipt h3,.edd-blocks__receipt h4,.edd-blocks__confirmation h3,.edd-blocks__orders h3{font-family:'Anton',sans-serif;font-weight:400;text-transform:uppercase;font-size:1.4rem;color:#fff;margin:6px 0 12px}
.edd-blocks__receipt .edd-blocks-receipt__items,.edd-blocks__receipt .edd-blocks-receipt__totals,.edd-blocks__confirmation .edd-blocks-receipt__items,.edd-blocks__confirmation .edd-blocks-receipt__totals,.edd-blocks__orders .edd-blocks-orders__order{
  border:1px solid var(--line);border-radius:16px;padding:6px 20px;margin:0 0 22px;background:rgba(43,10,61,.55)}
.qtile [class*="edd-blocks"] a:not(.button):not(.edd-submit){color:var(--pink);text-decoration:underline;text-underline-offset:3px}
.qtile [class*="edd-blocks"] .button,.qtile [class*="edd-blocks"] a.edd-submit{width:auto;font-size:1rem;padding:.55em 1.2em .5em;text-decoration:none}
.edd_sl_license_key,.edd-sl-license-key,code{font-family:'Space Mono',monospace;font-size:.86rem;background:rgba(255,255,255,.06);border:1px solid var(--line-soft);border-radius:8px;padding:.15em .5em;word-break:break-all}

@media(max-width:640px){
  .edd-blocks-cart__row{padding:14px 16px}
  .edd-blocks-cart__row-item{flex-wrap:wrap}
  .edd-blocks-form fieldset,.edd-blocks__checkout fieldset{padding:18px 16px 4px}
  .edd-blocks__checkout-forms--inline{justify-content:flex-start}
  #edd-purchase-button,.edd-blocks__checkout .edd-submit{max-width:none}
  .edd-blocks__row{flex-direction:column;gap:4px}
  .edd-blocks__row-value{text-align:left}
}

/* EDD's block CSS styles these through #edd_purchase_form and grey/white defaults: win over it. */
.wp-block-edd-checkout .edd-blocks-cart,.wp-block-edd-checkout .edd-blocks-cart__row,.wp-block-edd-checkout fieldset,.wp-block-edd-checkout #edd_purchase_form fieldset{border-color:var(--line)!important}
.wp-block-edd-checkout .edd-blocks-cart__row{border-width:0 0 1px!important;border-color:var(--line-soft)!important}
.wp-block-edd-checkout .edd-blocks-cart__row:last-child{border-bottom:0!important}
.wp-block-edd-checkout #edd_purchase_form .edd-button-secondary,.wp-block-edd-checkout .edd-button-secondary{
  background:transparent!important;color:var(--pink)!important;border:1.5px solid rgba(255,110,199,.55)!important;border-radius:999px!important;padding:.45em 1.1em!important;font-weight:700;font-size:.88rem}
.wp-block-edd-checkout #edd_purchase_form .edd-button-secondary:hover,.wp-block-edd-checkout .edd-button-secondary:hover{background:rgba(255,63,174,.14)!important;color:#fff!important;border-color:var(--magenta-lt)!important}
.wp-block-edd-checkout #edd_purchase_form #edd-purchase-button,.wp-block-edd-checkout #edd-purchase-button{background:var(--magenta-lt)!important;color:#2b0a3d!important;border:2px solid #2b0a3d!important;border-radius:12px!important}
.wp-block-edd-checkout #edd_purchase_form .edd-input,.wp-block-edd-checkout .edd-input{background:#2b0a3d!important;color:var(--ink)!important;border:1px solid rgba(255,110,199,.35)!important;border-radius:12px!important;padding:.8em 1em!important}
.wp-block-edd-checkout #edd_purchase_form .edd-input:focus,.wp-block-edd-checkout .edd-input:focus{border-color:var(--magenta-lt)!important;box-shadow:0 0 0 3px rgba(255,63,174,.25)!important}
.wp-block-edd-checkout .edd-description{color:var(--muted-2)!important}
.wp-block-edd-checkout .edd-blocks-cart__row-footer,.wp-block-edd-checkout .edd-blocks-cart__items,.wp-block-edd-checkout .edd-blocks-cart__row-item{border-top-color:var(--line-soft)!important;border-bottom-color:var(--line-soft)!important}
@media(max-width:640px){.wp-block-edd-checkout .edd-blocks-cart__row-header{display:none!important}}
