/* Astraea Beyond: full shared stylesheet. */
:root {
  --ink:#14201d; --paper:#f7f5ef; --surface:#ffffff;
  --gold:#b88a43; --gold-deep:#8d672d; --line:#d8d3c8;
  --muted:#66716c; --danger:#a43f32; --success:#29704f;
  --surface-alt:#ece8df; --shadow-soft:0 10px 28px rgba(20,32,29,.08);
}
* { box-sizing:border-box; }
html { scroll-behavior:smooth; }
body { margin:0; background:var(--paper); color:var(--ink); font-family:Arial,Helvetica,sans-serif; line-height:1.5; }
a { color:var(--gold-deep); }
button,input,select,textarea { font:inherit; }
button { cursor:pointer; }
button:disabled { cursor:not-allowed; }
/* Header */
.site-header { display:flex; align-items:center; justify-content:space-between; padding:16px 24px; border-bottom:1px solid var(--line); background:var(--surface); }
.brand { color:var(--ink); font-family:Georgia,serif; font-weight:700; letter-spacing:.08em; text-decoration:none; }
.site-nav { display:flex; flex-wrap:wrap; align-items:center; gap:18px; }
.site-nav a { margin-left:0; color:var(--ink); font-size:14px; text-decoration:none; }
.site-nav a:hover { color:var(--gold-deep); }
/* Global layout */
main { max-width:1100px; margin:0 auto; padding:32px 20px 64px; }
.hero h1 { max-width:760px; margin:0 0 12px; font-family:Georgia,serif; font-size:clamp(28px,4vw,44px); line-height:1.15; }
.hero p { max-width:680px; margin:0; color:var(--muted); font-size:17px; }
/* Buttons */
.btn-primary,.btn-secondary { padding:9px 14px; border:1px solid var(--gold-deep); border-radius:4px; font-weight:700; cursor:pointer; }
.btn-primary { border-color:var(--gold-deep); background:var(--gold-deep); color:#fff; }
.btn-primary:hover { border-color:var(--gold); background:var(--gold); }
.btn-secondary { border-color:var(--line); background:#fff; color:var(--ink); }
.btn-secondary:hover { background:#f4f1e9; }
/* Storefront catalogue */
.catalogue { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:24px; margin-top:36px; }
.loading-note { grid-column:1/-1; color:var(--muted); }
.product-card { display:flex; flex-direction:column; min-width:0; min-height:100%; overflow:hidden; border:1px solid var(--line); background:var(--surface); color:var(--ink); text-decoration:none; transition:border-color 160ms ease,box-shadow 160ms ease,transform 160ms ease; }
.product-card:hover { border-color:#c5b79d; box-shadow:var(--shadow-soft); transform:translateY(-2px); }
.product-card-link { display:flex; flex:1; flex-direction:column; min-width:0; color:inherit; text-decoration:none; }
/* Show the entire image, including tall product photos and diagrams. */
.product-card-link > img,.product-image-placeholder { display:block; width:100%; height:280px; margin:0; background:#fff; object-fit:contain; object-position:center; }
.product-card-link > img { padding:16px; }
.product-card-link > img[src*="logo"],.product-card-link > img[alt*="logo" i] { padding:16px; object-fit:contain; }
.product-card-link h2 { margin:18px 18px 7px; color:var(--ink); font-family:Georgia,serif; font-size:20px; line-height:1.22; overflow-wrap:break-word; }
.product-card-link:hover h2 { color:var(--gold-deep); }
.product-card-link p { display:-webkit-box; min-height:48px; margin:0 18px 14px; overflow:hidden; color:var(--muted); font-size:14px; line-height:1.55; -webkit-box-orient:vertical; -webkit-line-clamp:2; }
.product-card-link .price-line,.price-line { margin:auto 18px 18px; color:var(--ink); font-family:Georgia,serif; font-size:20px; font-weight:700; }
.product-actions { display:flex; align-items:center; gap:10px; padding:0 18px 18px; }
.quantity-control { display:inline-flex; flex:0 0 auto; align-items:center; height:42px; overflow:hidden; border:1px solid var(--line); border-radius:4px; background:var(--surface); }
.qty-btn { display:inline-flex; align-items:center; justify-content:center; width:36px; height:40px; padding:0; border:0; border-radius:0; background:transparent; color:var(--ink); font-size:18px; line-height:1; cursor:pointer; }
.qty-btn:hover:not(:disabled) { background:#f1ede4; }
.qty-btn:disabled { color:#a9ada9; cursor:not-allowed; }
.qty-display { display:inline-flex; align-items:center; justify-content:center; min-width:28px; height:40px; color:var(--ink); font-size:14px; font-weight:700; text-align:center; }
.add-btn { flex:1; min-height:42px; padding:10px 14px; border:1px solid var(--gold-deep); border-radius:4px; background:var(--gold-deep); color:#fff; font-size:14px; font-weight:700; line-height:1; cursor:pointer; transition:background 160ms ease,border-color 160ms ease; }
.add-btn:hover { border-color:var(--gold); background:var(--gold); }
.add-btn:active { transform:translateY(1px); }
.qty-btn:focus-visible,.add-btn:focus-visible,.cart-qty-btn:focus-visible,.cart-remove-btn:focus-visible,.product-thumbnail:focus-visible { outline:3px solid rgba(184,138,67,.38); outline-offset:2px; }
/* Product detail: gallery and text stack on small screens. */
.product-detail-layout { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:32px; align-items:start; }
.product-detail-gallery,.product-detail-content { min-width:0; }
.product-main-image { display:flex; align-items:center; justify-content:center; width:100%; aspect-ratio:1 / 1; padding:18px; overflow:hidden; border:1px solid var(--line); border-radius:10px; background:#fff; }
.product-main-image > img { display:block; width:100%; height:100%; min-width:0; min-height:0; object-fit:contain; object-position:center; }
.product-image-unavailable { margin:0; color:var(--muted); text-align:center; }
.product-thumbnails { display:flex; gap:10px; margin-top:12px; padding:3px 2px 8px; overflow-x:auto; }
.product-thumbnail { display:flex; flex:0 0 76px; align-items:center; justify-content:center; width:76px; height:76px; margin:0; padding:5px; overflow:hidden; border:1px solid var(--line); border-radius:6px; background:#fff; }
.product-thumbnail > img { display:block; width:100%; height:100%; object-fit:contain; object-position:center; }
.product-thumbnail[aria-pressed="true"] { border:2px solid var(--gold-deep); box-shadow:0 0 0 1px rgba(141,103,45,.12); }
.product-detail-title { margin:0 0 16px; font-family:Georgia,serif; font-size:clamp(26px,3.2vw,36px); line-height:1.18; overflow-wrap:break-word; }
.product-detail-short { margin:0 0 18px; color:var(--muted); }
.product-detail-price { margin:0 0 16px; font-size:24px; font-weight:700; }
.product-stock { margin:0 0 16px; color:var(--success); }
.product-stock.is-unavailable { color:var(--danger); }
.product-detail-add { min-height:44px; }
.product-detail-add:disabled { opacity:.55; }
.product-detail-description { margin-top:24px; white-space:pre-line; overflow-wrap:anywhere; }
.product-specifications { table-layout:fixed; }
.product-specifications td { vertical-align:top; overflow-wrap:anywhere; }
.product-specifications th { width:38%; vertical-align:top; overflow-wrap:anywhere; }
/* Generic content and legal pages */
.legal-page { max-width:760px; }
.legal-page h1 { font-family:Georgia,serif; }
.legal-page h2 { margin-top:28px; font-size:20px; }
.contact-list { padding:0; list-style:none; }
.contact-list li { margin-bottom:8px; }
.policy-table { width:100%; margin-top:12px; border-collapse:collapse; }
.policy-table th,.policy-table td { padding:8px; border:1px solid var(--line); font-size:14px; text-align:left; }
/* Checkout: existing payment-card styles remain in checkout.html. */
.checkout-layout { display:grid; grid-template-columns:minmax(0,1.4fr) minmax(280px,.9fr); gap:28px; }
.checkout-form-container h1,.checkout-summary h2 { margin-top:0; font-family:Georgia,serif; }
fieldset { margin-bottom:18px; padding:16px; border:1px solid var(--line); background:var(--surface); }
legend { color:var(--muted); font-size:13px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; }
label { display:block; margin:10px 0 4px; color:#47524d; font-size:12px; font-weight:700; text-transform:uppercase; }
input,select,textarea { width:100%; padding:9px; border:1px solid #cfc9bc; border-radius:3px; background:#fff; color:var(--ink); }
input:focus,select:focus,textarea:focus { border-color:var(--gold); outline:3px solid rgba(184,138,67,.18); }
.consent-block { margin:18px 0; padding:14px; border:1px solid var(--line); background:#fbfaf7; }
.checkbox-row { display:flex; gap:10px; align-items:flex-start; margin-bottom:10px; color:var(--ink); font-size:13px; font-weight:400; letter-spacing:normal; line-height:1.45; text-transform:none; }
.checkbox-row input { width:auto; margin-top:3px; }
.help-note { margin-top:12px; color:var(--muted); font-size:13px; }
.checkout-summary { align-self:flex-start; padding:18px; border:1px solid var(--line); background:var(--surface); }
.summary-row { display:flex; justify-content:space-between; gap:14px; padding:8px 0; border-bottom:1px solid #ece8df; font-size:14px; }
/* Editable cart summary */
.summary-item { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:14px; padding:14px 0; border-bottom:1px solid #ece8df; }
.summary-item-details { display:flex; flex-direction:column; gap:3px; min-width:0; }
.summary-item-details strong { color:var(--ink); font-size:14px; line-height:1.35; }
.summary-item-details span { color:var(--muted); font-size:12px; }
.summary-item-actions { display:flex; flex-wrap:wrap; justify-content:flex-end; gap:8px; align-items:center; }
.cart-quantity-control { display:inline-flex; align-items:center; height:34px; overflow:hidden; border:1px solid var(--line); border-radius:4px; background:#fff; }
.cart-qty-btn { width:30px; height:32px; padding:0; border:0; background:transparent; color:var(--ink); font-size:17px; line-height:1; }
.cart-qty-btn:hover { background:#f1ede4; }
.cart-qty-value { display:inline-flex; align-items:center; justify-content:center; min-width:26px; color:var(--ink); font-size:13px; font-weight:700; }
.summary-item-total { min-width:84px; color:var(--ink); font-size:14px; text-align:right; }
.cart-remove-btn { padding:3px 0; border:0; background:transparent; color:var(--danger); font-size:12px; font-weight:700; text-decoration:underline; }
.cart-remove-btn:hover { color:#7d2e25; }
.empty-cart-message { margin:0 0 8px; color:var(--muted); }
/* Confirmation */
.confirmation-wrap { display:flex; justify-content:center; }
.card { max-width:560px; padding:26px; border:1px solid var(--line); background:var(--surface); }
.status-pill { display:inline-block; padding:3px 8px; border-radius:99px; background:#efe9dc; font-size:12px; font-weight:700; }
.support-notice { margin-top:20px; color:var(--muted); font-size:13px; }
/* Footer and cookie banner */
.site-footer { padding:28px 20px; border-top:1px solid var(--line); background:var(--surface); color:var(--muted); font-size:13px; }
.footer-links a { margin-right:14px; }
.cookie-banner { position:fixed; right:0; bottom:0; left:0; z-index:80; display:flex; flex-wrap:wrap; gap:14px; align-items:center; justify-content:space-between; padding:16px 20px; background:#1c2a26; color:#fff; }
.cookie-banner a { color:#e8cf9f; }
.cookie-actions { display:flex; gap:10px; }
/* Responsive */
@media(max-width:900px) { .catalogue { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:760px) {
  .site-header { flex-direction:column; align-items:flex-start; gap:10px; }
  .checkout-layout { grid-template-columns:1fr; }
  .checkout-summary { order:-1; }
  .product-detail-layout { grid-template-columns:minmax(0,1fr); gap:24px; }
  .product-detail-title { font-size:clamp(26px,6vw,32px); }
  .product-main-image { max-width:520px; margin-inline:auto; }
}
@media(max-width:620px) {
  main { padding:26px 16px 48px; }
  .catalogue { grid-template-columns:1fr; gap:16px; margin-top:24px; }
  .product-card-link > img,.product-image-placeholder { height:300px; }
  .summary-item { grid-template-columns:1fr; }
  .summary-item-actions { justify-content:flex-start; }
  .site-nav { gap:12px; }
  .product-main-image { padding:12px; }
  .product-thumbnail { flex-basis:68px; width:68px; height:68px; }
  .product-detail-add { width:100%; }
}
@media(prefers-reduced-motion:reduce) {
  html { scroll-behavior:auto; }
  .product-card,.add-btn { transition:none; }
  .product-card:hover { transform:none; }
}