/**
 * Your Love Letters — Readability & Design Refresh 1.0
 * --------------------------------------------------------------------------
 * DESIGN PRINCIPLE: Keep the original soft, romantic atmosphere, but make
 * all meaningful reading text dark enough on its background. Decorative rose
 * is for icons/illustrations, not body text.
 *
 * Main palette (all intended for light backgrounds):
 * background #FFFDF9, paper #FFFFFF, rose tint #F8E8EB,
 * headings #553343, body #372F34, muted #62515B,
 * rose text #944460, gold text #815B32, border #E8D6D9.
 *
 * This stylesheet changes presentation only, not HTML, JS, WooCommerce
 * checkout behaviour, customer data or PHP template execution.
 */

/* 1. Consistent design tokens in the four YLL components. */
.yll-home,
.yll-order,
.yll-ma-shell {
  --yll-cream: #FAF7F3;
  --yll-ivory: #FFFDF9;
  --yll-rose: #944460;
  --yll-pink: #F8E8EB;
  --yll-blush: #F8E8EB;
  --yll-burgundy: #553343;
  --yll-wine: #553343;
  --yll-gold: #815B32;
  --yll-ink: #372F34;
  --yll-muted: #62515B;
  --yll-line: #E8D6D9;
  --yll-stroke: #E8D6D9;
}
.yllp {
  --yllp-cream: #FAF7F3;
  --yllp-ivory: #FFFDF9;
  --yllp-rose: #944460;
  --yllp-blush: #F8E8EB;
  --yllp-berry: #553343;
  --yllp-gold: #815B32;
  --yllp-ink: #372F34;
  --yllp-muted: #62515B;
}

/* 2. Text, headings and paragraph legibility. */
.yll-home,
.yllp,
.yll-order,
.yll-ma-shell { color: #372F34; }

.yll-home h1,.yll-home h2,.yll-home h3,.yll-home h4,
.yllp h1,.yllp h2,.yllp h3,.yllp h4,
.yll-order h1,.yll-order h2,.yll-order h3,
.yll-ma-shell h1,.yll-ma-shell h2,.yll-ma-shell h3 {
  color: #553343;
}
.yll-home h1 em,.yll-home h2 em,.yll-home .yll-showcase-text h2 em,
.yllp h1 em,.yllp h2 em,.yllp h3 em,
.yll-order .yll-heading h1 em,
.yll-ma-shell .yll-ma-welcome h1 em {
  color: #944460;
}

/* Scoped paragraphs: exclude the dark hero finale/CTA panels. */
.yll-home :is(.yll-hero-intro,.yll-center-heading p,.yll-showcase-text p,.yll-interactive-copy p,.yll-faq-grid>div:first-child>p,.yll-faqs details>p,.yll-benefit p,.yll-step p,.yll-tier-intro,.yll-tier li,.yll-price-disclaimer),
.yllp :is(.yllp-section-head p,.yllp-hero-content>p,.yllp-demo-card>p,.yllp-faq-list details>div,.yllp-tier-sub,.yllp-tier li,.yllp-small-center,.yllp-contact-aside>p,.yllp-about-copy p),
.yll-order :is(.yll-heading p,.yll-optional,.yll-muted,.yll-desc,.yll-summary-row),
.yll-ma-shell :is(.yll-ma-welcome p,.yll-ma-link-card small,.yll-ma-metric>span:last-child,.yll-ma-section-title p,.yll-ma-delivered-info p,.yll-ma-empty p,.yll-ma-smallprint) {
  color: #62515B;
}

.yll-home :is(.yll-hero-intro,.yll-center-heading p,.yll-showcase-text p,.yll-interactive-copy p),
.yllp :is(.yllp-section-head p,.yllp-hero-content>p,.yllp-contact-aside>p),
.yll-order .yll-heading p,
.yll-ma-shell .yll-ma-welcome p { line-height: 1.8; }

/* Uppercase labels should remain visibly readable, even when small. */
.yll-home :is(.yll-eyebrow,.yll-scroll-prompt,.yll-preview-kicker,.yll-scrapbook-top,.yll-secret-top),
.yllp :is(.yllp-kicker,.yllp-demo-top span:first-child,.yllp-hero-letter>span),
.yll-order :is(.yll-kicker,.yll-step),
.yll-ma-shell :is(.yll-ma-eyebrow,.yll-ma-metric-kicker,.yll-ma-delivered-info>span) {
  color: #815B32;
}
.yll-home :is(.yll-tier-name,.yll-tier-from small,.yll-tier-amount),
.yllp :is(.yllp-tier-price,.yllp-tier h3),
.yll-order :is(.yll-package-top,.yll-price),
.yll-ma-shell :is(.yll-ma-metric strong,.yll-ma-link-card strong) { color: #553343; }

/* Prevent tiny functional text on package comparison cards. */
.yll-home .yll-tier li,
.yllp .yllp-tier li,
.yll-order .yll-desc { font-size: max(.875rem, 14px); line-height: 1.65; }
.yll-home .yll-tier-intro,
.yllp .yllp-tier-sub { font-size: max(.875rem, 14px); }
.yll-home .yll-tier-button,.yllp .yllp-tier .yllp-btn { font-size: max(.875rem, 14px); }
.yll-home .yll-hero-points,.yll-home .yll-tier-name { color: #654C57; }
.yll-home .yll-tier-from small { color:#62515B; }

/* 3. Let the cream/rose palette frame the content rather than the text. */
.yll-home :is(.yll-benefit,.yll-tier,.yll-secret-card),
.yllp :is(.yllp-tier,.yllp-demo-card,.yllp-faq-list details,.yllp-form-panel),
.yll-order :is(.yll-panel,.yll-summary-card,.yll-package-inner),
.yll-ma-shell :is(.yll-ma-metric,.yll-ma-link-card,.yll-ma-woocommerce,.yll-ma-auth) {
  border-color: #E8D6D9;
  box-shadow: 0 12px 35px rgba(78,42,58,.065);
}
.yll-home .yll-benefit,
.yllp .yllp-demo-card { background: #FFFDFC; }
.yllp .yllp-tier-featured,
.yll-home .yll-tier-featured,
.yll-order .yll-package.yll-selected .yll-package-inner {
  background: #FFF4F6;
  border-color: #944460;
}
.yll-home .yll-tier-featured,
.yllp .yllp-tier-featured { box-shadow: 0 18px 38px rgba(85,51,67,.11); }
.yll-home .yll-faq-section { background:#FAF5F1; }
.yllp .yllp-cream { background: #FAF5F1; }
.yll-order .yll-summary-card { background:linear-gradient(160deg,#FFFDFC,#FFF6F6); }
.yll-ma-shell .yll-ma-welcome { background:radial-gradient(ellipse at 89% 9%,#F8E8EB,transparent 45%),linear-gradient(120deg,#FFFDF9,#FBF2F2); }

/* 4. Accessible buttons / interactive links. */
.yll-home .yll-btn-primary,
.yll-home .yll-tier-featured .yll-tier-button,
.yllp .yllp-btn-primary,
.yll-order .yll-submit,
.yll-ma-shell :is(.yll-ma-button,.woocommerce button.button,.woocommerce a.button,.woocommerce input.button) {
  background: #553343 !important;
  color: #FFFFFF !important;
  border-color: #553343 !important;
  box-shadow: 0 10px 24px rgba(85,51,67,.13);
}
.yll-home .yll-btn-primary:hover,
.yll-home .yll-tier-featured .yll-tier-button:hover,
.yllp .yllp-btn-primary:hover,
.yll-order .yll-submit:hover,
.yll-ma-shell :is(.yll-ma-button,.woocommerce button.button,.woocommerce a.button,.woocommerce input.button):hover {
  background: #74415A !important;
  border-color: #74415A !important;
}
.yll-home :is(.yll-btn-quiet,.yll-tier-button),
.yllp :is(.yllp-btn-quiet,.yllp-btn-text),
.yll-ma-shell .yll-ma-copy {
  color: #553343 !important;
  border-color: #B997A3;
}
.yll-home :is(.yll-btn-quiet,.yll-tier-button):hover,
.yllp .yllp-btn-quiet:hover,
.yll-ma-shell .yll-ma-copy:hover { background: #F8E8EB !important; }
.yll-home .yll-text-link,
.yllp .yllp-consent a,
.yll-order a,
.yll-ma-shell .woocommerce-MyAccount-content a:not(.button):not(.yll-ma-button) {
  color: #873A59 !important;
  text-underline-offset: 3px;
}
.yll-home :is(a,button,summary):focus-visible,
.yllp :is(a,button,summary,input,textarea,select):focus-visible,
.yll-order :is(a,button,input,textarea,select):focus-visible,
.yll-ma-shell :is(a,button,input,textarea,select):focus-visible {
  outline: 3px solid #944460 !important;
  outline-offset: 3px;
}

/* 5. Inputs, help copy, form panels, labels. */
.yll-order .yll-field,
.yllp .yllp-form-panel label,
.yll-ma-shell label {
  color: #553343;
}
.yll-order :is(input[type="text"],input[type="email"],select,textarea,input[type="date"]),
.yllp :is(input[type="text"],input[type="email"],input[type="tel"],textarea,select),
.yll-ma-shell .woocommerce :is(input.input-text,textarea,select) {
  background: #FFFFFF !important;
  color: #372F34 !important;
  border: 1.5px solid #AE959F !important;
  box-shadow: none !important;
}
.yll-order :is(input,textarea)::placeholder,
.yllp :is(input,textarea)::placeholder,
.yll-ma-shell .woocommerce :is(input,textarea)::placeholder { color: #76636B !important; opacity: 1; }
.yll-order :is(input[type="text"],input[type="email"],select,textarea,input[type="date"]):focus,
.yllp :is(input[type="text"],input[type="email"],input[type="tel"],textarea,select):focus,
.yll-ma-shell .woocommerce :is(input.input-text,textarea,select):focus {
  border-color: #873A59 !important;
  outline: 2px solid #873A59 !important;
  outline-offset: 1px;
}
.yll-order .yll-upload { background: #FFFDFC; border-color: #B997A3; }
.yll-order .yll-consent { color: #54464E; }
.yllp .yllp-consent { color: #54464E; }
.yllp .yllp-faq-list summary,.yll-home .yll-faqs summary { color:#553343; }
.yllp .yllp-faq-list details>div,.yll-home .yll-faqs details>p { color: #62515B; }

/* 6. Tables and product comparison. */
.yllp .yllp-comparison thead th {
  background: #F3E3E8;
  color: #553343;
}
.yllp .yllp-comparison tbody tr:nth-child(even) { background: #FFF8F8; }
.yllp .yllp-comparison :is(td,th) { border-bottom-color: #E8D6D9; }
.yllp .yllp-comparison tbody :is(td,th) { color: #4A3A43; }
.yllp .yllp-table-wrap { border-color: #E8D6D9; }

/* 7. WooCommerce cart, checkout, notices and customer details, scoped to Woo pages. */
body.woocommerce-cart .woocommerce,
body.woocommerce-checkout .woocommerce,
body.woocommerce-account .woocommerce:not(.yll-ma-shell .woocommerce) {
  color: #372F34;
}
body.woocommerce-cart .woocommerce :is(.button,button.button,a.button),
body.woocommerce-checkout .woocommerce :is(.button,button.button,a.button),
body.woocommerce-account .woocommerce :is(.button,button.button,a.button) {
  background:#553343;
  border-color:#553343;
  color:#FFFFFF;
}
body.woocommerce-cart .woocommerce :is(.button,button.button,a.button):hover,
body.woocommerce-checkout .woocommerce :is(.button,button.button,a.button):hover,
body.woocommerce-account .woocommerce :is(.button,button.button,a.button):hover {
  background:#74415A;
  border-color:#74415A;
  color:#FFFFFF;
}
body.woocommerce-cart .woocommerce :is(input.input-text,select,textarea),
body.woocommerce-checkout .woocommerce :is(input.input-text,select,textarea) {
  background:#FFFFFF;
  color:#372F34;
  border:1px solid #AE959F;
  border-radius:8px;
}
body.woocommerce-cart .woocommerce :is(.woocommerce-info,.woocommerce-message),
body.woocommerce-checkout .woocommerce :is(.woocommerce-info,.woocommerce-message) {
  background: #FFF5F6;
  color: #553343;
  border-top-color: #944460;
}
body.woocommerce-checkout :is(.wc-block-components-button,.wc-block-checkout__actions_row .wc-block-components-button),
body.woocommerce-cart :is(.wc-block-components-button,.wc-block-cart__submit-button) {
  background:#553343;
  color:#FFFFFF;
  border:1px solid #553343;
  border-radius:10px;
}
body.woocommerce-cart .wc-block-components-notice-banner,
body.woocommerce-checkout .wc-block-components-notice-banner {
  color: #553343;
}
body.woocommerce-cart :is(.wc-block-components-text-input,.wc-block-components-combobox),
body.woocommerce-checkout :is(.wc-block-components-text-input,.wc-block-components-combobox) {
  color:#372F34;
}

/* 8. Preserve white type on genuinely dark sections. */
.yll-home .yll-final-section,
.yllp .yllp-last { background-color: #553343; color: #FFFFFF; }
.yll-home .yll-final-section :is(h1,h2,h3,p),
.yllp .yllp-last :is(h1,h2,h3,p) { color:#FFFFFF; }
.yll-home .yll-final-section .yll-btn-light,
.yllp .yllp-last .yllp-btn-light {
  color:#553343!important;
  background:#FFFFFF!important;
}
.yllp .yllp-last .yllp-kicker { color:#FCE9D9; }

/* 9. Readable mobile typography, without disturbing page layouts. */
@media (max-width: 767px) {
  .yll-home .yll-tier li,
  .yllp .yllp-tier li,
  .yll-order .yll-desc { font-size: 14px; }
  .yll-home .yll-center-heading p,
  .yllp .yllp-section-head p,
  .yll-order .yll-heading p { font-size: 15.5px; }
  .yllp .yllp-comparison { font-size: 14px; }
  .yll-order .yll-panel,
  .yllp .yllp-form-panel { border-radius: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .yll-home :is(a,button),.yllp :is(a,button),.yll-order :is(a,button),
  .yll-ma-shell :is(a,button) { transition-duration: .01ms !important; }
}

/* 10. Readability fixes for secondary ribbons and small UI copy. */
.yll-home .yll-love-ribbon { background:#EFD6DC; color:#553343; border-color:#E4BAC4; }
.yll-home .yll-love-ribbon span { color:#553343; font-weight:650; }
.yll-home .yll-hero-points { color:#62515B; font-size:13px; }
.yllp .yllp-demo-top span:first-child { color:#654C57; }
.yllp .yllp-explore>span { color:#553343; }
.yll-ma-shell .yll-ma-footer { color:#62515B; }
.yllp .yllp-contact-tip { color:#553343; }
