/* House of Elki: checkout, order tracking, account dashboard and the printable invoice.
   Builds on styles.css, pages.css and forms.css. Light surfaces, navy text, terracotta for the one main action. */

.shop-hero .container { gap: 14px; }
.shop-hero h1 { font-size: clamp(2.25rem, 4.6vw, 3.5rem); max-width: none; }
.shop-body { min-height: 50vh; }
.shop-loading { padding-block: 48px; text-align: center; color: var(--text-muted); }

/* empty states */
.shop-empty { max-width: 520px; margin: clamp(16px, 4vw, 48px) auto; display: grid; gap: 14px; justify-items: center; text-align: center; }
.shop-empty__ico { display: grid; place-items: center; width: 72px; height: 72px; border-radius: 50%; background: color-mix(in srgb, var(--navy) 8%, var(--paper)); color: var(--navy); }
.shop-empty__ico .icon { width: 30px; height: 30px; }
.shop-empty h2 { font-size: clamp(1.75rem, 3vw, 2.25rem); }
.shop-empty p { color: var(--text-muted); }
.shop-empty a:not(.btn) { text-decoration: underline; text-underline-offset: 3px; }

/* status pills */
.elki-pill { display: inline-flex; align-items: center; font-style: normal; font-size: .8125rem; font-weight: 600; padding: 6px 12px; border-radius: var(--r-pill); white-space: nowrap; background: color-mix(in srgb, var(--navy) 8%, var(--paper)); color: var(--navy); }
.elki-pill--good { background: #e3f3ea; color: #1f5f3f; }
.elki-pill--warn { background: #fbefd5; color: #7a4f08; }
.elki-pill--bad { background: #fbe3e1; color: #8c1c14; }

/* ---------- checkout ---------- */
.co-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.co-form { display: grid; gap: 20px; }
.co-card { padding: clamp(18px, 3vw, 28px); border-radius: var(--r-md); background: #fff; border: 1px solid var(--hairline); display: grid; gap: 16px; }
.co-card h2, .co-summary h2 { font-size: 1.625rem; }
.co-signed { font-size: .9375rem; color: var(--text-muted); }
.co-signed a { text-decoration: underline; text-underline-offset: 3px; color: var(--terracotta); }
.co-gst summary { cursor: pointer; font-weight: 500; min-height: 32px; display: flex; align-items: center; }
.co-gst[open] summary { margin-bottom: 14px; }
.co-gst .fields { margin-top: 4px; }
.co-pay { width: 100%; min-height: 56px; font-size: 1.0625rem; }
.co-pay[disabled] { opacity: .55; cursor: not-allowed; }
.co-secure { font-size: .8125rem; color: var(--text-muted); text-align: center; }
.co-testmode { margin: 12px 0 0; padding: 12px 14px; border-radius: 10px; border: 1px solid color-mix(in srgb, var(--terracotta) 45%, transparent); background: color-mix(in srgb, var(--terracotta) 8%, var(--paper)); color: var(--navy); font-size: .875rem; line-height: 1.5; }
.co-summary { position: sticky; top: 112px; padding: clamp(18px, 3vw, 28px); border-radius: var(--r-md); background: color-mix(in srgb, var(--navy) 5%, var(--paper)); border: 1px solid var(--hairline); display: grid; gap: 14px; }
.co-lines { display: grid; gap: 14px; }
.co-lines li { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.co-lines img, .co-noimg { width: 64px; height: 64px; border-radius: 12px; object-fit: cover; background: color-mix(in srgb, var(--navy) 8%, var(--paper)); display: block; }
.co-lines b { font-weight: 600; line-height: 1.25; display: block; }
.co-lines small { display: block; font-size: .8125rem; color: var(--text-muted); }
.co-lines li > span:last-child { font-variant-numeric: tabular-nums; font-weight: 500; }
.co-totals { display: grid; gap: 8px; padding-top: 14px; border-top: 1px solid var(--hairline); }
.co-totals div { display: flex; justify-content: space-between; gap: 16px; font-size: .9375rem; }
.co-totals dd { margin: 0; font-variant-numeric: tabular-nums; }
.co-total { padding-top: 10px; border-top: 1px solid var(--hairline); font-size: 1.125rem !important; font-weight: 600; }
.co-total small { font-weight: 400; color: var(--text-muted); font-size: .8125rem; }
.co-hint { font-size: .875rem; color: var(--terracotta); font-weight: 500; }
.co-gst-note { font-size: .8125rem; color: var(--text-muted); }
.co-issues { padding: 12px 14px; border-radius: var(--r-sm); background: #fbefd5; color: #5d3d06; font-size: .875rem; display: grid; gap: 6px; }
.co-issues ul { padding-left: 18px; list-style: disc; }
.co-mock { max-width: 520px; margin: 24px auto; padding: 32px; border-radius: var(--r-md); background: #fff; border: 1px dashed var(--ochre); display: grid; gap: 12px; justify-items: center; text-align: center; }
.co-mock__amt { font-family: var(--font-display); font-size: 3rem; font-weight: 600; line-height: 1; }
.err--form ul { padding-left: 18px; list-style: disc; margin-top: 4px; }

/* ---------- order page ---------- */
.ord-thanks { display: flex; gap: 18px; align-items: flex-start; padding: 22px 24px; margin-bottom: 28px; border-radius: var(--r-md); background: #e3f3ea; color: #174d33; }
.ord-thanks .tick { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: #1f6f4a; color: #fff; }
.ord-thanks h2 { font-size: 1.75rem; color: inherit; }
.ord-thanks p { margin-top: 4px; }
.ord-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 28px; }
.ord-head__r { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.ord-eyebrow { font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: var(--text-muted); font-weight: 600; }
.ord-number { font-size: clamp(2rem, 4vw, 2.75rem); }
.ord-meta { color: var(--text-muted); font-size: .9375rem; }
.ord-steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; margin: 8px 0 20px; position: relative; }
.ord-steps li { display: grid; justify-items: center; gap: 10px; text-align: center; font-size: .875rem; color: var(--text-muted); position: relative; }
.ord-steps li::before { content: ""; position: absolute; top: 15px; left: -50%; width: 100%; height: 3px; background: color-mix(in srgb, var(--navy) 14%, transparent); z-index: 0; }
.ord-steps li:first-child::before { display: none; }
.ord-steps li.is-done::before, .ord-steps li.is-now::before { background: var(--navy); }
.ord-dot { position: relative; z-index: 1; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: #fff; border: 3px solid color-mix(in srgb, var(--navy) 18%, transparent); color: #fff; }
.ord-dot .icon { width: 16px; height: 16px; stroke-width: 2.4; }
.ord-steps .is-done .ord-dot, .ord-steps .is-now .ord-dot { background: var(--navy); border-color: var(--navy); }
.ord-steps .is-now { color: var(--navy); font-weight: 600; }
.ord-steps .is-now .ord-dot { box-shadow: 0 0 0 5px color-mix(in srgb, var(--gold) 45%, transparent); }
.ord-banner { padding: 14px 18px; border-radius: var(--r-sm); background: color-mix(in srgb, var(--navy) 8%, var(--paper)); margin-bottom: 16px; }
.ord-banner--bad { background: #fbe3e1; color: #8c1c14; }
.ord-msg { margin-bottom: 28px; color: var(--text-muted); }
.ord-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(20px, 3vw, 40px); align-items: start; }
.ord-grid > div { display: grid; gap: 20px; }
.ord-card { padding: clamp(18px, 3vw, 26px); border-radius: var(--r-md); background: #fff; border: 1px solid var(--hairline); display: grid; gap: 14px; }
.ord-card h2 { font-size: 1.5rem; }
.ord-dl { display: grid; gap: 10px; }
.ord-dl div { display: flex; justify-content: space-between; gap: 16px; }
.ord-dl dt { color: var(--text-muted); }
.ord-dl dd { margin: 0; font-weight: 500; text-align: right; }
.ord-addr { line-height: 1.6; }
.ord-timeline { display: grid; gap: 14px; border-left: 2px solid var(--hairline); margin-left: 6px; padding-left: 18px; }
.ord-timeline li { position: relative; display: grid; gap: 2px; }
.ord-timeline li::before { content: ""; position: absolute; left: -25px; top: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--navy); }
.ord-timeline small { color: var(--text-muted); }
.ord-help { font-size: .9375rem; color: var(--text-muted); }

/* ---------- account ---------- */
.acc-login { display: grid; grid-template-columns: minmax(0, 520px) minmax(0, 1fr); gap: clamp(28px, 5vw, 80px); align-items: start; max-width: 1040px; margin-inline: auto; }
.acc-card { padding: clamp(22px, 4vw, 36px); border-radius: var(--r-md); background: #fff; border: 1px solid var(--hairline); display: grid; gap: 18px; align-content: start; }
.acc-card h2 { font-size: 1.875rem; }
.acc-lead, .acc-note { color: var(--text-muted); font-size: .9375rem; }
.acc-code { font-size: 1.75rem; letter-spacing: .5em; text-align: center; font-variant-numeric: tabular-nums; }
.acc-sent { padding: 12px 14px; border-radius: var(--r-sm); background: color-mix(in srgb, var(--gold) 20%, var(--paper)); font-size: .9375rem; }
.acc-alt { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.acc-alt .link-arrow:disabled { opacity: .6; cursor: default; }
.acc-why { padding-top: 8px; display: grid; gap: 12px; }
.acc-why h3 { font-size: 1.5rem; }
.acc-why ul { display: grid; gap: 10px; }
.acc-why li { padding-left: 28px; position: relative; }
.acc-why li::before { content: ""; position: absolute; left: 0; top: .45em; width: 14px; height: 8px; border-left: 2px solid var(--terracotta); border-bottom: 2px solid var(--terracotta); transform: rotate(-45deg); }
.acc-why p { color: var(--text-muted); font-size: .9375rem; }
.acc-why a { text-decoration: underline; text-underline-offset: 3px; }
.acc-top { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.acc-hello { font-size: clamp(2rem, 4vw, 2.75rem); }
.acc-email { color: var(--text-muted); }
.acc-tabs { display: flex; gap: 6px; margin-bottom: 24px; border-bottom: 1px solid var(--hairline); overflow-x: auto; scrollbar-width: none; }
.acc-tabs [role=tab] { background: none; border: 0; padding: 0 18px; min-height: 48px; font-weight: 500; color: var(--text-muted); border-bottom: 3px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.acc-tabs [role=tab]:hover { color: var(--navy); }
.acc-tabs [aria-selected=true] { color: var(--navy); border-bottom-color: var(--terracotta); }
.acc-orders { display: grid; gap: 12px; }
.acc-order a, .acc-order--static { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; gap: 16px; align-items: center; padding: 16px 18px; border-radius: var(--r-md); background: #fff; border: 1px solid var(--hairline); transition: border-color .2s var(--ease), box-shadow .2s var(--ease); }
.acc-order--static { grid-template-columns: minmax(0, 1fr) auto; }
.acc-order a:hover { border-color: var(--navy); box-shadow: 0 14px 30px -22px rgba(34, 47, 77, .55); }
.acc-order__imgs { display: flex; }
.acc-order__imgs img, .acc-order__imgs .co-noimg { width: 56px; height: 56px; border-radius: 12px; object-fit: cover; border: 2px solid #fff; margin-left: -14px; background: color-mix(in srgb, var(--navy) 8%, var(--paper)); }
.acc-order__imgs > :first-child { margin-left: 0; }
.acc-order__main { display: grid; gap: 2px; min-width: 0; }
.acc-order__main b { font-weight: 600; }
.acc-order__main small { color: var(--text-muted); font-size: .875rem; }
.acc-order__go { color: var(--text-muted); }
.acc-profile { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.acc-check { display: flex; gap: 10px; align-items: center; text-transform: none !important; letter-spacing: 0 !important; font-size: .9375rem !important; min-height: 44px; }
.acc-addrs { display: grid; gap: 12px; }
.acc-addr { display: grid; gap: 8px; padding: 14px 16px; border-radius: var(--r-sm); border: 1px solid var(--hairline); }
.acc-addr p { font-size: .9375rem; color: var(--text-muted); margin-top: 2px; }
.acc-addr__act { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.acc-addr-form { margin-block: 16px; padding-top: 16px; border-top: 1px solid var(--hairline); display: grid; gap: 14px; }

/* ---------- invoice ---------- */
.inv-actions { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; margin-bottom: 20px; }
.inv { background: #fff; border: 1px solid var(--hairline); border-radius: var(--r-md); padding: clamp(20px, 4vw, 44px); display: grid; gap: 24px; max-width: 880px; margin-inline: auto; }
.inv-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px; }
.inv-top h2 { font-size: 2rem; margin-bottom: 8px; }
.inv-meta { display: grid; gap: 6px; align-content: start; }
.inv-meta div { display: flex; gap: 16px; justify-content: space-between; }
.inv-meta dt { color: var(--text-muted); } .inv-meta dd { margin: 0; font-weight: 600; }
.inv-parties { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.inv-parties h3 { font-family: var(--font-body); font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 6px; }
.inv-table { width: 100%; border-collapse: collapse; font-size: .9375rem; }
.inv-table th { text-align: left; font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); padding: 8px 6px; border-bottom: 2px solid var(--navy); }
.inv-table td { padding: 10px 6px; border-bottom: 1px solid var(--hairline); vertical-align: top; }
.inv-table .n { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.inv-table small { color: var(--text-muted); }
.inv-table tfoot td { border-bottom: 0; padding-block: 6px; }
.inv-grand td { font-weight: 700; font-size: 1.0625rem; border-top: 2px solid var(--navy); padding-top: 12px !important; }
.inv-note { font-size: .8125rem; color: var(--text-muted); }

@media (max-width: 1023px) {
  .co-grid, .ord-grid, .acc-login, .acc-profile { grid-template-columns: minmax(0, 1fr); }
  .co-summary { position: static; order: -1; }
}
@media (max-width: 599px) {
  .ord-steps li { font-size: .75rem; }
  .ord-dot { width: 28px; height: 28px; } .ord-steps li::before { top: 12px; }
  .acc-order a { grid-template-columns: auto minmax(0, 1fr); } .acc-order a .elki-pill { grid-column: 2; justify-self: start; } .acc-order__go { display: none; }
  .inv-parties { grid-template-columns: 1fr; }
  .ord-head__r .btn { width: 100%; }
}
@media print {
  body { background: #fff; }
  .site-header, .site-footer, .announce, .no-print, .shop-hero, .toast, .drawer, .skip-link { display: none !important; }
  .shop-body { padding: 0; } .inv { border: 0; padding: 0; max-width: none; }
}
