/*
Theme Name: لیمو دارچین
Template: wpf
Description: Brand layer for limoo-darchin. Colors, font, header and footer are Customizer options (set at install from site.json); extra CSS below, section patterns in patterns/. No PHP logic here — that goes in the wpf-site-limoo-darchin plugin.
Version: 1.0.0
Text Domain: wpf-limoo-darchin
*/

/* Palette (Customizer): primary #8a4a22 cinnamon (links, text accents), accent #e6b422 lemon gold
   (buttons with dark text, badges), ink #1f1712, surface #fbf6ec cream, footer #16110c warm black.
   Local tokens for the dark hero and banners only: */
:root { --ld-night: #16110c; --ld-night-2: #231a12; --ld-cream: #f6ead0; --ld-gold: #e6b422; --ld-gold-2: #c9961a; --ld-cin: #b0612f; }

/* ---------- hero: mother's wpf-slider, dark like the logo, gold line art ---------- */
.ld-hero { background: radial-gradient(120% 140% at 85% 10%, var(--ld-night-2) 0%, var(--ld-night) 60%); color: var(--ld-cream); }
.ld-hero .wpf-slides { border-radius: 0; }
.ld-slide { display: grid !important; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); align-items: center; gap: 2rem; padding: 2.6rem 3.4rem 3.2rem; min-height: 420px; }
.ld-slide__kicker { display: inline-block; margin: 0 0 .9rem !important; padding: .25rem .8rem; border-radius: 99px; border: 1px solid rgba(230, 180, 34, .45); color: var(--ld-gold); font-size: .85rem; font-weight: 700; letter-spacing: .2px; }
.ld-slide h1, .ld-slide h2 { color: #fff8e8; font-size: clamp(1.7rem, 3.6vw, 2.6rem); line-height: 1.35; font-weight: 800; margin: 0 0 .9rem; text-wrap: balance; }
.ld-slide__txt p:not(.ld-slide__kicker) { color: rgba(246, 234, 208, .78); max-width: 42ch; margin: 0 0 1.6rem; line-height: 1.9; }
.ld-slide .wp-block-button__link { background: var(--ld-gold); color: var(--ld-night); font-weight: 800; padding: .8rem 1.6rem; border-radius: 99px; box-shadow: 0 10px 30px rgba(230, 180, 34, .25); }
.ld-slide .wp-block-button__link:hover { background: #f2c83f; }
.ld-hero .wpf-dots { bottom: 1.1rem; }
.ld-hero .wpf-dots button { background: rgba(246, 234, 208, .3); }
.ld-hero .wpf-dots button.is-on { background: var(--ld-gold); }
.ld-hero .wpf-arrow { background: transparent; border-color: rgba(246, 234, 208, .25); color: var(--ld-cream); box-shadow: none; }
.ld-hero .wpf-arrow:hover { border-color: var(--ld-gold); color: var(--ld-gold); }
@media (max-width: 760px) {
	.ld-slide { grid-template-columns: 1fr; gap: .2rem; padding: 1.4rem 0 3rem; min-height: 0; }
	.ld-art { order: -1; max-width: 280px; margin-inline: auto; width: 100%; }
}

/* line art: cream strokes, gold and cinnamon fills */
.ld-art svg { display: block; width: 100%; height: auto; overflow: visible; }
.ld-art .ln { fill: none; stroke: var(--ld-cream); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.ld-art .gl { fill: none; stroke: var(--ld-gold); stroke-width: 2.5; stroke-linecap: round; opacity: .9; }
.ld-art .g { fill: var(--ld-gold); }
.ld-art .c { fill: var(--ld-cin); }
.ld-art .halo { fill: rgba(230, 180, 34, .07); stroke: rgba(230, 180, 34, .18); stroke-width: 1.5; stroke-dasharray: 2 8; }
.ld-art .sh { fill: #000; opacity: .35; }
@media (prefers-reduced-motion: no-preference) {
	.ld-steam, .ld-float, .ld-twinkle, .ld-tilt, .ld-dust { transform-box: fill-box; transform-origin: center; }
	.ld-steam { animation: ld-steam 2.8s ease-in-out infinite; }
	.ld-float { animation: ld-float 5.5s ease-in-out infinite; }
	.ld-twinkle { animation: ld-twinkle 2.6s ease-in-out infinite; }
	.ld-tilt { transform-origin: 0 100%; animation: ld-tilt 3.2s ease-in-out infinite; }
	.ld-dust { animation: ld-steam 3.4s ease-in-out infinite; }
	.d1 { animation-delay: -.9s; } .d2 { animation-delay: -1.8s; }
}
@keyframes ld-steam { 0%, 100% { opacity: .2; transform: translateY(6px); } 50% { opacity: .95; transform: translateY(-6px); } }
@keyframes ld-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
@keyframes ld-twinkle { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }
@keyframes ld-tilt { 0%, 100% { transform: rotate(0); } 50% { transform: rotate(-4deg); } }

/* ---------- section titles: small gold rule under the heading ---------- */
.wpf-section__head h2 { position: relative; padding-bottom: .5rem; }
.wpf-section__head h2::after { content: ""; position: absolute; inset-inline-start: 0; bottom: 0; width: 2.4rem; height: 3px; border-radius: 3px; background: var(--ld-gold); }

/* ---------- category icons: round cream tiles ---------- */
.ld-cats .wpf-ci { width: 52px; height: 52px; }

/* ---------- two banners ---------- */
.ld-banners { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.ld-banner { position: relative; overflow: hidden; border-radius: 18px; padding: 2rem 2.2rem; min-height: 190px; display: flex; flex-direction: column; justify-content: center; }
.ld-banner h3 { font-size: clamp(1.15rem, 2vw, 1.45rem); font-weight: 800; margin: 0 0 .9rem; max-width: 22ch; }
.ld-banner p { margin: 0; }
.ld-banner a { font-weight: 700; text-decoration: none; }
.ld-banner__kicker { font-size: .85rem; font-weight: 700; margin-bottom: .5rem !important; }
.ld-banner::after { content: ""; position: absolute; inset-inline-end: -40px; bottom: -60px; width: 220px; height: 220px; border-radius: 50%; border: 2px dashed currentColor; opacity: .18; }
.ld-banner--dark { background: var(--ld-night); color: var(--ld-cream); }
.ld-banner--dark .ld-banner__kicker, .ld-banner--dark a { color: var(--ld-gold); }
.ld-banner--dark h3 { color: #fff8e8; }
.ld-banner--gold { background: linear-gradient(135deg, #f3cf55, var(--ld-gold) 55%, var(--ld-gold-2)); color: var(--ld-night); }
.ld-banner--gold .ld-banner__kicker, .ld-banner--gold a { color: #5a2e12; }
@media (max-width: 760px) { .ld-banners { grid-template-columns: 1fr; } .ld-banner { padding: 1.6rem; min-height: 150px; } }

/* ---------- why us: cream cards with a gold top line ---------- */
.ld-why .wpf-feats > * { background: var(--wpf-surface); border: 1px solid var(--wpf-line); border-top: 3px solid var(--ld-gold); border-radius: 14px; padding: 1.4rem 1.5rem; }

/* ---------- product cards: price in cinnamon, sale badge gold on black ---------- */
.woocommerce span.onsale, .wpf-badge--sale { background: var(--ld-night) !important; color: var(--ld-gold) !important; }

/* ---------- footer logo on the dark footer ---------- */
.wpf-footer .custom-logo, .wpf-footer .wpf-logo__img { filter: none; }

/* ---------- header logo: a bit larger than the mother's 3rem ---------- */
.wpf-logo__img { max-height: 3.6rem; }
@media (max-width: 760px) { .wpf-logo__img { max-height: 2.6rem; } }

/* ---------- palette v2 «Warm Spice» (owner 1405/08/22; higher contrast) ----------
   card #FFF9EE · title / text / new price #4A2311 · old price #9C7C6E · buttons #D98200 · icon and media ground #FAF0D9
   ink, accent (buttons) and surface come from the Customizer (site.json brand); the rest is here. */
:root { --ld-card: #FFF9EE; --ld-text: #4A2311; --ld-old: #9C7C6E; --ld-btn: #D98200; --ld-btn-h: #ec9a1a; --ld-soft: #FAF0D9; }

/* product cards like the reference: warm card, soft media ground, dark title and price, full-width mustard button */
ul.products li.wpf-card { background: var(--ld-card); border-color: #f0e2c4; border-radius: 16px; box-shadow: 0 6px 18px rgba(74, 35, 17, .06); transition: transform .15s, box-shadow .15s, border-color .15s; }
ul.products li.wpf-card:hover { border-color: var(--ld-btn); transform: translateY(-2px); box-shadow: 0 12px 26px rgba(74, 35, 17, .1); }
.wpf-card__media { background: var(--ld-soft); border-radius: 12px; }
.wpf-card__t, .wpf-card__t a { color: var(--ld-text); font-weight: 800; }
.wpf-card__t { text-align: center; }
.wpf-card__cat { text-align: center; }
.wpf-card .price { justify-content: center; color: var(--ld-text); font-size: 1.02rem; padding-top: .45rem; border-top: 1px solid #eedfc2; }
.price del, .price del .amount { color: var(--ld-old); }
.price ins, .price ins .amount { color: var(--ld-text); font-weight: 800; }
.wpf-card .button { background: var(--ld-btn); border-color: var(--ld-btn); color: var(--ld-text) !important; border-radius: 10px; font-weight: 800; box-shadow: 0 4px 0 #b86d00; }
.wpf-card .button:hover { background: var(--ld-btn-h); border-color: var(--ld-btn-h); color: var(--ld-text) !important; }
.wpf-pcard { background: var(--ld-card); }
/* text on #D98200: dark brown #4A2311 (4.6:1); white would be 2.9:1; hover is a lighter mustard with the same dark text */
.ld-slide .wp-block-button__link { background: var(--ld-btn); color: var(--ld-text); }
.ld-slide .wp-block-button__link:hover { background: var(--ld-btn-h); color: var(--ld-text); }

/* ---------- quick-browse tiles under the slider (owner 1405/08/22): picture + title, each opens its category ---------- */
.ld-quick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.ld-quick > * { margin: 0 !important; } /* the block layout adds a top margin to every child but the first */
.ld-quick__it { position: relative; background: var(--ld-card); border: 1px solid #f0e2c4; border-radius: 18px; padding: .6rem .6rem 1rem; text-align: center; transition: transform .15s, box-shadow .15s, border-color .15s; }
.ld-quick__it:hover { transform: translateY(-3px); border-color: var(--ld-btn); box-shadow: 0 14px 28px rgba(74, 35, 17, .12); }
.ld-quick__img { margin: 0 0 .7rem !important; }
.ld-quick__img img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 13px; }
.ld-quick__t { margin: 0 0 .2rem !important; font-size: 1.1rem; font-weight: 800; }
.ld-quick__t a { color: var(--ld-text); }
.ld-quick__t a::after { content: ""; position: absolute; inset: 0; } /* the whole card is clickable */
.ld-quick__s { margin: 0 !important; font-size: .82rem; color: #7a6a5c; }
@media (max-width: 900px) { .ld-quick { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; } .ld-quick__t { font-size: 1rem; } }

/* ---------- two pictures per product (client 1405/09/07): jar and pouch swap gently on the card ----------
   The product's main image and its first gallery image (the mother prints it as .wpf-card__img2, lazy-loaded).
   Opacity only, so nothing is re-laid out; off when the visitor asks for less motion; hover still shows image 2. */
@media (prefers-reduced-motion: no-preference) {
	.wpf-card__img2 { animation: ld-swap 9s ease-in-out infinite; }
	ul.products li:nth-child(3n+2) .wpf-card__img2 { animation-delay: -3s; }
	ul.products li:nth-child(3n) .wpf-card__img2 { animation-delay: -6s; }
	.wpf-card:hover .wpf-card__img2 { animation-play-state: paused; opacity: 1; }
}
@keyframes ld-swap { 0%, 38% { opacity: 0; } 50%, 88% { opacity: 1; } 100% { opacity: 0; } }
