/* cyhn shop — shared base: product archives, cart, checkout, account (and child-theme pages: add the cyw-scope class to their wrapper and bars).
   Tokens and shared rules match single-product.css (the product page does not load this file);
   keep both in sync. */

.cyw-scope,
.cyw-archive,
.cyw-loop,
.cyw-cbar,
.cyw-toast {
	--cyw-cream: var(--cy-color-background, #f6f3ec); /* alternate section colour (palette: background) */
	--cyw-white: var(--cy-color-surface, #ffffff); /* main section colour (palette: surface) */
	--cyw-page: var(--cy-color-background, var(--cyw-cream)); /* page background the footer sits on */
	--cyw-amber: var(--cy-color-primary, #2f3b2f); /* primary buttons, links (palette: primary) */
	--cyw-amber-h: color-mix(in srgb, var(--cyw-amber) 82%, #000);
	--cyw-dark: var(--cyw-amber); /* dark surfaces: band, bars, dark buttons, selected chip */
	--cyw-dark-h: color-mix(in srgb, var(--cyw-dark) 82%, #000);
	--cyw-on-pri: #fff; /* text on primary / dark */
	--cyw-yellow: var(--cy-color-accent, #e5b53b); /* highlights, stars (palette: accent) */
	--cyw-yellow-soft: color-mix(in srgb, var(--cyw-yellow) 60%, var(--cyw-white));
	--cyw-yellow-d: color-mix(in srgb, var(--cyw-yellow) 82%, #000);
	--cyw-paper: color-mix(in srgb, var(--cyw-yellow) 10%, var(--cyw-white));
	--cyw-ink: var(--cy-color-text, #1c1c1a); /* (palette: text) */
	--cyw-ink-2: color-mix(in srgb, var(--cyw-ink) 85%, var(--cyw-white));
	--cyw-muted: color-mix(in srgb, var(--cyw-ink) 66%, var(--cyw-white));
	--cyw-soft: color-mix(in srgb, var(--cyw-ink) 30%, var(--cyw-white)); /* separators, empty stars, hover borders */
	--cyw-line: var(--cy-color-border, #e4ddcf); /* (palette: border) */
	--cyw-leaf: var(--cy-color-secondary, #3d6a2a); /* success, "best value" (palette: secondary) */
	--cyw-leaf-soft: color-mix(in srgb, var(--cyw-leaf) 15%, var(--cyw-white));
	--cyw-red: #b3261e;
	--cyw-red-soft: #fbe3df;
	--cyw-r: 14px;
	--cyw-r-sm: 10px;
	--cyw-shadow: 0 1px 2px rgba(27, 26, 22, .06), 0 6px 24px rgba(27, 26, 22, .07);
	--cyw-gutter: 16px;
	--cyw-max: 1240px;
	--cyw-bottomnav: 0px;
	color: var(--cyw-ink);
	font-family: inherit;
}

body.cyw-full #content { max-width: none; }
.cyw-scope, .cyw-archive { font-size: 16px; line-height: 1.6; }
.cyw-scope *, .cyw-scope *::before, .cyw-scope *::after, .cyw-archive *, .cyw-archive *::before, .cyw-archive *::after, .cyw-loop *, .cyw-loop *::before, .cyw-loop *::after { box-sizing: border-box; }
.cyw-scope img, .cyw-archive img { max-width: 100%; height: auto; }
/* Card images fill their box (the generic height:auto rule must not override the cover). */
.cyw-scope .cyw-rcard__im img, .cyw-archive .cyw-rcard__im img, .cyw-archive .cyw-pcard__im img { width: 100%; height: 100%; object-fit: cover; }
.cyw-scope :focus-visible, .cyw-archive :focus-visible, .cyw-loop :focus-visible, .cyw-cbar :focus-visible { outline: 3px solid var(--cyw-amber); outline-offset: 2px; border-radius: 6px; }
.cyw-scope [hidden], .cyw-archive [hidden] { display: none !important; }
.cyw-wrap { max-width: var(--cyw-max); margin: 0 auto; padding: 0 var(--cyw-gutter); }
.cyw-scope .cy-icon, .cyw-archive .cy-icon { flex: none; }
.cyw-scope, .cyw-archive { --cyw-sec: var(--cyw-white); --cyw-box: var(--cyw-cream); }

/* Shared (same as the product page) */
.cyw-run--cream { background: var(--cyw-cream); }
.cyw-run--white { background: var(--cyw-white); }
.cyw-product { --cyw-sec: var(--cyw-white); --cyw-box: var(--cyw-cream); }
.cyw-run--cream { --cyw-sec: var(--cyw-cream); --cyw-box: var(--cyw-white); }
.cyw-run--white { --cyw-sec: var(--cyw-white); --cyw-box: var(--cyw-cream); }
/* Height follows the image ratio (2048×110), at least 28px; aspect-ratio + min-height widened the page on narrow screens. */
.cyw-tear { position: relative; width: 100%; height: clamp(28px, 5.371vw, 110px); background: var(--cyw-tear-base); line-height: 0; pointer-events: none; }
/* The torn shape comes from the image as a mask; its colours come from the section variables. */
.cyw-tear__s { position: absolute; inset: 0; background: var(--cyw-tear-shape); -webkit-mask: url(../../img/shop/tear-white-cream.webp) center bottom / cover no-repeat; mask: url(../../img/shop/tear-white-cream.webp) center bottom / cover no-repeat; }
.cyw-tear--top .cyw-tear__s { -webkit-mask-image: url(../../img/shop/tear-cream-white.webp); mask-image: url(../../img/shop/tear-cream-white.webp); -webkit-mask-position: center top; mask-position: center top; }
/* Wave: the same colour logic, an SVG mask instead of the torn image. Colour fade: from one section colour to the next. */
.cyw-tear--wave { height: clamp(24px, 4vw, 72px); }
.cyw-tear--wave .cyw-tear__s { -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 100' preserveAspectRatio='none'%3E%3Cpath d='M0 58C180 18 360 18 540 50S900 98 1080 66 1320 22 1440 42V100H0Z'/%3E%3C/svg%3E") center / 100% 100% no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 100' preserveAspectRatio='none'%3E%3Cpath d='M0 58C180 18 360 18 540 50S900 98 1080 66 1320 22 1440 42V100H0Z'/%3E%3C/svg%3E") center / 100% 100% no-repeat; }
.cyw-tear--wave.cyw-tear--top .cyw-tear__s { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 100' preserveAspectRatio='none'%3E%3Cpath d='M0 42C180 82 360 82 540 50S900 2 1080 34 1320 78 1440 58V0H0Z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 100' preserveAspectRatio='none'%3E%3Cpath d='M0 42C180 82 360 82 540 50S900 2 1080 34 1320 78 1440 58V0H0Z'/%3E%3C/svg%3E"); }
.cyw-tear--gradient { height: clamp(40px, 6vw, 120px); background: linear-gradient(to bottom, var(--cyw-tear-from), var(--cyw-tear-to)); }
.cyw-tear--gradient .cyw-tear__s { display: none; }
.cyw-run--last { padding-bottom: 40px; }
.cyw-bc { font-size: 14px; color: var(--cyw-muted); padding: 28px 0 16px; }
.cyw-bc ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.cyw-bc li:not(:last-child)::after { content: "/"; margin-left: 6px; color: var(--cyw-soft); }
.cyw-bc a { color: inherit; text-decoration: none; }
.cyw-bc a:hover { color: var(--cyw-amber); text-decoration: underline; }
.cyw-bc [aria-current] { color: var(--cyw-ink-2); font-weight: 500; }
.cyw-cat-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--cyw-leaf); text-decoration: none; }
.cyw-cat-tag:hover { text-decoration: underline; }
.cyw-title { font-weight: 600; font-size: clamp(30px, 3.4vw, 42px); line-height: 1.12; letter-spacing: -.01em; margin: 6px 0 0; }
.cyw-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 54px; padding: 0 26px; border-radius: 999px; border: 0; cursor: pointer; font-weight: 700; font-size: 16px; line-height: 1.2; text-decoration: none; transition: background .15s, transform .1s; font-family: inherit; }
.cyw-btn:active { transform: translateY(1px); }
.cyw-btn--pri { background: var(--cyw-amber); color: var(--cyw-on-pri); }
.cyw-btn--pri:hover { background: var(--cyw-amber-h); color: var(--cyw-on-pri); }
.cyw-btn--pri.is-done { background: var(--cyw-leaf); }
.cyw-btn:disabled { opacity: .55; cursor: not-allowed; }
.cyw-btn--ink { background: var(--cyw-dark); color: var(--cyw-cream); }
.cyw-btn--ink:hover { background: var(--cyw-dark-h); color: var(--cyw-cream); }
.cyw-btn--ghost { background: transparent; border: 1.5px solid var(--cyw-ink); color: var(--cyw-ink); height: 46px; padding: 0 20px; font-size: 15px; }
.cyw-btn--ghost:hover { background: var(--cyw-dark); border-color: var(--cyw-dark); color: var(--cyw-cream); }
.cyw-sec { padding: 64px 0; }
.cyw-sec + .cyw-sec { padding-top: 0; }
.cyw-sec-h { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 26px; }
.cyw-sec-h h2 { font-weight: 600; font-size: clamp(26px, 2.6vw, 34px); line-height: 1.15; margin: 0; letter-spacing: -.01em; }
.cyw-sec-h p { margin: 6px 0 0; color: var(--cyw-muted); }
.cyw-sec-h a { font-weight: 600; white-space: nowrap; color: var(--cyw-amber); }
.cyw-toast { position: fixed; left: 50%; bottom: 96px; transform: translate(-50%, 140%); background: var(--cyw-dark); color: var(--cyw-cream); padding: 12px 18px; border-radius: 12px; font-size: 14.5px; z-index: 1300; transition: transform .3s ease; box-shadow: var(--cyw-shadow); display: flex; gap: 10px; align-items: center; max-width: calc(100% - 32px); visibility: hidden; }
.cyw-toast.on { transform: translate(-50%, 0); visibility: visible; }
.cyw-toast .cy-icon { color: var(--cyw-yellow); }

/* Full-width image, centred; a torn edge in the section colour at the bottom
   (the divider image is used as a mask, so the colour always matches). */
.cyw-rhero { position: relative; margin: 0; height: 70vh; height: 70svh; min-height: 300px; overflow: hidden; background: var(--cyw-yellow); }
.cyw-rhero .cyw-rhero__img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.cyw-rhero__edge { position: absolute; left: 0; right: 0; bottom: -1px; height: clamp(28px, 5.4vw, 110px); background: var(--cyw-white); -webkit-mask: url(../../img/shop/tear-white-cream.webp) center bottom / 100% 100% no-repeat; mask: url(../../img/shop/tear-white-cream.webp) center bottom / 100% 100% no-repeat; }


@media (max-width: 900px) {
	.cyw-bc { padding: 12px 0 10px; font-size: 13px; }
	.cyw-sec { padding: 44px 0; }
}
