/* ==========================================================================
   Magic Flower — static site stylesheet
   Ported from the live Shopify theme (Dwell + Magic Flower custom sections):
   colors, sizes, spacing and section rhythm match magicflower.com.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap');

:root {
  --purple: #5a2a82;      /* header + footer */
  --plum: #3b2160;        /* hero, trust band, final CTA, headings */
  --plum-deep: #2b1836;   /* ingredient strip */
  --gold: #f2b420;        /* buttons, accents */
  --gold-light: #f7d96a;  /* announcement bar, product buy button */
  --gold-text: #ffd150;   /* footer headings */
  --magenta: #a92f86;     /* kickers, card 2 */
  --cream: #faf5ea;       /* section backgrounds */
  --cream-2: #f2ecde;     /* product image background */
  --card-border: #e8dfcd;
  --text: #4a3f31;
  --ink: rgba(0, 0, 0, 0.71);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 140px; }
body {
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: Poppins, sans-serif;
  font-size: 14px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}
body * { font-family: Poppins, sans-serif; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2 { font-weight: 400; margin: 0; }
h3 { margin: 0; }
p { margin: 0 0 1em; }
button { font: inherit; }

.mf-container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.mf-section { padding: 80px 0; }
.mf-kicker { margin-bottom: 12px; text-transform: uppercase; letter-spacing: 2px; font-size: 13px; color: var(--magenta); }
.mf-section-title { font-size: 42px; line-height: 1.1; margin: 0 0 20px; color: var(--ink); }
.mf-section-description { color: var(--text); line-height: 1.8; max-width: 700px; }

.skip { position: absolute; left: 1rem; top: -4rem; background: var(--plum); color: #fff; padding: .5rem .8rem; border-radius: 6px; z-index: 50; }
.skip:focus { top: .6rem; }

/* ---------- Buttons (theme .mf-btn) ---------- */
.mf-btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 15px 32px; border-radius: 50px; border: 0; cursor: pointer;
  font-size: 14px; font-weight: 400; line-height: 1.4; text-decoration: none;
  transition: transform .15s ease, box-shadow .15s ease, opacity .15s ease;
}
.mf-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 25px rgba(0, 0, 0, .18); }
.mf-btn-primary { background: var(--gold); color: #000; }
.mf-btn-secondary { background: transparent; color: #fff; border: 1px solid #fff; }

/* ---------- Announcement bar ---------- */
.announcement { background: var(--gold-light); color: var(--purple); text-align: center; font-weight: 700; font-size: 14px; padding: 15px 20px; }

/* ---------- Header ---------- */
.site-header { background: var(--purple); color: #fff; position: sticky; top: 0; z-index: 30; box-shadow: 0 2px 8px rgba(0,0,0,.15); }
.site-header .mf-container { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; min-height: 129px; gap: 20px; }
.site-header .brand { display: inline-flex; align-items: center; }
.site-header .brand img { width: 122px; height: auto; }
.menu { display: flex; gap: 32px; justify-content: center; margin: 0; padding: 0; list-style: none; }
.menu a { color: #fff; text-decoration: none; font-size: 14px; font-weight: 500; position: relative; padding: 6px 0; }
.menu a::after { content: ""; position: absolute; left: 50%; bottom: -6px; width: 0; height: 3px; background: linear-gradient(-97deg, #e94e9a, #ffc34a, #e94e9a); border-radius: 10px; transition: .3s; transform: translateX(-50%); }
.menu a:hover::after, .menu a.is-active::after { width: 80%; }
.header-right { display: flex; justify-content: flex-end; }
.header-right a { color: #fff; text-decoration: none; font-size: 14px; font-weight: 500; display: inline-flex; align-items: center; gap: 8px; }
.header-right svg { width: 22px; height: 22px; }
.menu-toggle { display: none; }

/* ---------- Hero (magic-hero-banner) ---------- */
.mf-hero { position: relative; display: flex; align-items: center; background: var(--plum); min-height: 700px; padding: 80px 0; overflow: hidden; }
.mf-hero-overlay { position: absolute; inset: 0; background: #000; opacity: .2; }
.mf-hero-grid { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, 420px); gap: 40px; align-items: center; width: 100%; }
.mf-hero-content { position: relative; z-index: 2; max-width: 1200px; }
.mf-eyebrow { margin-bottom: 20px; text-transform: uppercase; letter-spacing: 2px; font-size: 14px; color: var(--gold); }
.mf-heading { color: #fff; font-size: 68px; line-height: 1.1; margin: 0 0 24px; }
.mf-heading em { color: var(--gold); }
.mf-subheading { color: #fff; font-size: 18px; line-height: 1.7; }
.mf-buttons { display: flex; gap: 16px; margin-top: 35px; flex-wrap: wrap; align-items: center; }
.mf-hero-guarantee { align-self: center; color: #fff; font-size: 16px; line-height: 1.4; }
.mf-hero-ship { margin: 14px 0 0; color: #fff; font-size: 16px; line-height: 1.4; }
.mf-hero-visual { display: flex; align-items: center; justify-content: center; }
.mf-hero-visual__img { display: block; width: 100%; max-width: 420px; height: auto; object-fit: contain; }

/* ---------- Ingredient strip ---------- */
.mf-ingredient-strip { overflow: hidden; padding: 14px 0; white-space: nowrap; position: relative; background: var(--plum-deep); color: #fff; --mf-strip-speed: 30s; }
.mf-strip-track { display: flex; width: max-content; animation: mf-scroll var(--mf-strip-speed) linear infinite; }
.mf-strip-track span { padding: 0 25px; font-size: 14px; text-transform: uppercase; letter-spacing: 2px; flex-shrink: 0; }
.mf-dot { margin-left: 20px; color: var(--gold); }
@keyframes mf-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Shop (product page buy box) ---------- */
.mf-shop { background: #fff; padding: 40px 0 64px; }
.mf-shop-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.mf-shop-media { padding: 0 8px; }
.mf-shop-media figure { margin: 0; background: var(--cream-2); aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.mf-shop-media img { width: 100%; height: 100%; object-fit: contain; }
.mf-shop-details { padding: 0 0 0 8px; max-width: 420px; }
.mf-shop-title { font-size: 56px; line-height: 1.1; color: #000; font-weight: 400; margin: 0 0 16px; }
.mf-shop-desc p { margin: 0 0 12px; line-height: 1.6; color: var(--ink); }
.mf-shop-price { font-size: 24px; font-weight: 500; color: #000; margin: 12px 0 16px; }
.mf-shop-price .tax-note { font-size: 20px; font-weight: 400; }
.size-label { font-size: 14px; margin: 0 0 8px; color: var(--ink); }
.pills { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.pill input { position: absolute; opacity: 0; pointer-events: none; }
.pill label { display: inline-block; padding: 8px 12.8px; border: 1px solid #eae8e6; background: #fff; color: #000; cursor: pointer; line-height: 1.4; }
.pill label:hover { border-color: #000; }
.pill input:checked + label { background: var(--plum); color: #fff; border-color: var(--plum); }
.pill input:focus-visible + label { outline: 3px solid var(--magenta); outline-offset: 2px; }
.buy-forms form { display: none; }
.buy-forms form.f1 { display: block; }
.buybox:has(#size5:checked) .buy-forms .f1, .buybox:has(#size10:checked) .buy-forms .f1 { display: none; }
.buybox:has(#size5:checked) .buy-forms .f5 { display: block; }
.buybox:has(#size10:checked) .buy-forms .f10 { display: block; }
.btn-buy {
  width: 100%; border: 0; cursor: pointer; padding: 16px 24px; border-radius: 0;
  background: var(--gold-light); color: var(--purple); font-size: 18px; font-weight: 600; line-height: 1.2;
  transition: filter .15s ease;
}
.btn-buy:hover { filter: brightness(.95); }
.btn-buy small { display: block; font-size: 12px; font-weight: 400; margin-top: 4px; }
.mf-buybox-refund { margin: 8px 0 0; font-size: 13px; line-height: 1.35; color: var(--plum); }
.mf-buybox-refund a { color: var(--plum); text-decoration: underline; }
.pay-note { margin: 12px 0 0; font-size: 13px; line-height: 1.45; color: var(--text); background: rgba(250, 245, 234, .9); border-left: 3px solid var(--gold); padding: 8px 12px; }
.pay-note a { color: var(--plum); }
.mf-trust-box { margin: 18px 0 22px; padding: 4px 16px; background: rgba(250, 245, 234, .55); border: 1px solid rgba(59, 33, 96, .16); border-radius: 10px; }
.mf-trust-box .mf-trust-item { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; }
.mf-trust-box .mf-trust-item + .mf-trust-item { border-top: 1px solid rgba(59, 33, 96, .12); }
.mf-trust-box .mf-trust-icon { width: 24px; min-width: 24px; height: 24px; color: var(--plum); margin-top: 2px; }
.mf-trust-box .mf-trust-icon svg { width: 24px; height: 24px; }
.mf-trust-box strong { display: block; font-size: 13px; font-weight: 700; color: var(--plum); margin: 0 0 3px; }
.mf-trust-box p { margin: 0; font-size: 12.5px; line-height: 1.45; color: #4a443c; }
.mf-accordion details { border-top: 1px solid #e6e2dc; }
.mf-accordion details:last-child { border-bottom: 1px solid #e6e2dc; }
.mf-accordion summary { list-style: none; cursor: pointer; padding: 16px 0; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; font-weight: 500; color: #000; display: flex; justify-content: space-between; align-items: center; }
.mf-accordion summary::-webkit-details-marker { display: none; }
.mf-accordion summary::after { content: "+"; font-size: 18px; font-weight: 400; }
.mf-accordion details[open] summary::after { content: "–"; }
.mf-accordion .body { padding: 0 0 16px; line-height: 1.6; color: var(--ink); }
.mf-accordion .body p:last-child { margin-bottom: 0; }
.mf-accordion .body a { color: var(--plum); }

/* ---------- Benefits grid ---------- */
.mf-benefits { background: var(--cream); }
.mf-benefits-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; margin-top: 50px; }
.mf-card { background: #fff; border: 1px solid var(--card-border); border-radius: 16px; padding: 0; overflow: hidden; }
.mf-benefits .mf-card h3 { font-size: 24px; font-weight: 700; line-height: 1.1; margin: 0 0 15px; padding: 20px; border-radius: 5px 5px 0 0; color: #fff; background: var(--plum); }
.mf-benefits .mf-card p { line-height: 1.8; margin: 14px 0 20px; padding: 0 20px; color: var(--text); }
.mf-tags { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 20px 20px; }
.mf-tags span { border: 1px solid #e2d7bf; padding: 6px 12px; border-radius: 30px; font-size: 13px; background: var(--plum); color: #fff; }
.mf-benefits-grid .mf-card:nth-child(2) h3, .mf-benefits-grid .mf-card:nth-child(2) .mf-tags span { background: var(--magenta); color: #fff; }
.mf-benefits-grid .mf-card:nth-child(3) h3, .mf-benefits-grid .mf-card:nth-child(3) .mf-tags span { background: var(--gold); color: #000; }

/* ---------- Trust band ---------- */
.mf-trust { padding: 50px 0; background: var(--plum); color: #d8d8d8; }
.mf-trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; text-align: center; }
.mf-trust .mf-trust-item h3 { font-size: 32px; font-weight: 700; margin: 0 0 10px; color: var(--gold); }
.mf-trust .mf-trust-item p { margin: 0; line-height: 1.7; color: #d8d8d8; }

/* ---------- How to use ---------- */
.mf-how { background: var(--cream); }
.mf-how .mf-kicker { text-transform: none; letter-spacing: normal; font-size: 14px; color: var(--ink); margin: 0; }
.mf-steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; margin-top: 50px; }
.mf-step-card { background: #fff; border: 1px solid var(--card-border); border-radius: 16px; padding: 30px; }
.mf-step-number { display: block; margin-bottom: 18px; color: var(--magenta); font-size: 13px; letter-spacing: 2px; font-weight: 600; }
.mf-step-card h3 { margin: 24px 0 12px; font-size: 24px; font-weight: 700; color: var(--plum); }
.mf-step-card p { margin: 0; line-height: 1.8; color: var(--text); }

/* ---------- Final CTA ---------- */
.mf-final { background: var(--plum); text-align: center; }
.mf-final .mf-section-title { max-width: 700px; margin: 0 auto 30px; color: #fff; }
.mf-final .mf-btn { min-width: 240px; }
.mf-final-note { margin: 20px auto 0; font-size: 15px; line-height: 1.7; color: #fff; max-width: 650px; }

/* ---------- FAQ ---------- */
.mf-faq-section { background: var(--cream); padding: 90px 20px; }
.mf-faq-section .page-width { max-width: 950px; margin: auto; }
.mf-faq-kicker { color: var(--magenta); text-transform: uppercase; letter-spacing: .22em; font-size: 12px; text-align: center; margin: 0 0 14px; }
.mf-faq-heading { text-align: center; color: var(--plum); font-size: 42px; line-height: 1.2; font-weight: 400; margin: 0 0 55px; }
.mf-faq-wrapper { display: flex; flex-direction: column; gap: 18px; }
.mf-faq-item { background: #fff; border: 1px solid #eadfcf; border-radius: 18px; overflow: hidden; transition: .35s; }
.mf-faq-item.active { border-color: var(--gold); box-shadow: 0 15px 40px rgba(59, 33, 96, .08); }
.mf-faq-btn { width: 100%; cursor: pointer; background: none; border: none; display: flex; justify-content: space-between; align-items: center; padding: 28px 30px; text-align: left; gap: 16px; }
.mf-faq-btn span:first-child { color: var(--plum); font-size: 22px; font-weight: 600; }
.mf-faq-icon { width: 42px; height: 42px; border-radius: 50%; background: var(--gold); display: flex; align-items: center; justify-content: center; color: var(--plum); font-size: 26px; font-weight: bold; transition: .35s; flex-shrink: 0; }
.mf-faq-item.active .mf-faq-icon { transform: rotate(45deg); }
.mf-faq-content { display: none; }
.mf-faq-item.active .mf-faq-content { display: block; }
.mf-faq-inner { padding: 0 30px 30px; color: #514338; font-size: 16px; line-height: 1.8; max-width: 95%; }
.mf-faq-inner p { margin: 0 0 .6em; }
.mf-faq-inner p:last-child { margin: 0; }
.mf-faq-inner a { color: var(--plum); }
.mf-faq-bottom { text-align: center; margin-top: 45px; color: #6c5f52; font-size: 15px; }
.mf-faq-bottom a { color: var(--plum); }

/* ---------- Footer ---------- */
.site-footer { background: var(--purple); color: #fff; padding: 40px 0 30px; }
.club { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: center; padding-bottom: 40px; border-bottom: 1px solid rgba(255, 255, 255, .25); }
.club h3 { color: var(--gold-text); font-size: 25px; font-weight: 700; letter-spacing: 1.4px; margin: 0 0 8px; }
.club p { margin: 0; font-size: 18px; line-height: 1.5; }
.club form { display: flex; gap: 12px; align-items: flex-end; }
.club input { flex: 1; min-width: 0; background: transparent; border: 0; border-bottom: 1px solid rgba(255, 255, 255, .7); color: #fff; font-size: 18px; padding: 12px 4px; outline: none; }
.club input::placeholder { color: rgba(255, 255, 255, .7); }
.club button { background: var(--gold); color: #111; border: 0; border-radius: 8px; padding: 17px 30px; font-size: 18px; font-weight: 500; letter-spacing: .03em; cursor: pointer; margin-bottom: 3px; }
.footer-grid { display: grid; grid-template-columns: 140px minmax(0, 1fr) minmax(0, 1.2fr); gap: 40px; padding-top: 50px; align-items: start; }
.footer-logo img { width: 122px; height: auto; margin-bottom: 20px; }
.footer-social { display: flex; gap: 20px; }
.footer-social a { color: #fff; }
.footer-social svg { width: 34px; height: 34px; fill: #fff; }
.footer-menu { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.footer-menu a { color: #fff; text-decoration: none; font-size: 18px; }
.footer-menu a:hover { text-decoration: underline; }
.footer-contact h4 { color: var(--gold-text); font-size: 25px; font-weight: 500; margin: 0 0 20px; }
.footer-contact p { font-size: 18px; line-height: 1.5; margin: 0 0 16px; }
.footer-contact a { color: #fff; }
.footer-fine { margin-top: 40px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .15); font-size: 13px; color: rgba(255, 255, 255, .8); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }
.footer-fine a { color: #fff; }

/* ---------- Policies page ---------- */
.mf-page-hero { background: var(--plum); color: #fff; padding: 60px 0; }
.mf-page-hero h1 { font-size: 56px; line-height: 1.1; margin: 0 0 12px; }
.mf-page-hero p { font-size: 18px; line-height: 1.6; max-width: 700px; margin: 0; }
.mf-page-hero a { color: var(--gold); }
.mf-policies { background: var(--cream); padding: 60px 0; }
.policy-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 40px; }
.toc { position: sticky; top: 150px; align-self: start; }
.toc ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.toc a { display: block; padding: 10px 14px; border-radius: 30px; text-decoration: none; color: var(--plum); font-weight: 600; background: #fff; border: 1px solid var(--card-border); }
.toc a:hover { border-color: var(--gold); }
.policy { background: #fff; border: 1px solid #eadfcf; border-radius: 18px; padding: 30px; margin-bottom: 18px; }
.policy h2 { color: var(--plum); font-size: 32px; font-weight: 600; margin: 0 0 16px; }
.policy h3 { color: var(--plum); font-size: 18px; font-weight: 600; margin: 20px 0 8px; }
.policy p, .policy li { font-size: 16px; line-height: 1.8; color: #514338; }
.policy a { color: var(--plum); }
.policy .updated { font-size: 13px; color: #6c5f52; }
.states { list-style: none; padding: 0; margin: 12px 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 6px 16px; }
.states li { display: flex; justify-content: space-between; border-bottom: 1px dashed var(--card-border); padding: 4px 0; font-size: 15px; }
.states b { color: var(--plum); }
.not-shipped { background: #fbeaea; color: #7a1f1f; border-radius: 10px; padding: 10px 14px; font-size: 15px; margin: 0; }

/* ---------- Responsive (mirrors the live theme's breakpoints) ---------- */
@media (max-width: 990px) {
  .mf-benefits-grid, .mf-steps-grid { grid-template-columns: 1fr; }
  .mf-shop-grid { grid-template-columns: 1fr; }
  .mf-shop-details { max-width: none; padding: 30px 20px 0; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .club { grid-template-columns: 1fr; gap: 20px; }
  .policy-layout { grid-template-columns: 1fr; }
  .toc { position: static; }
  .toc ul { display: flex; flex-wrap: wrap; }
}
@media (max-width: 768px) {
  h1, h2, .mf-section-title, .mf-faq-heading, .mf-shop-title, .mf-page-hero h1 { font-size: 26px !important; line-height: 1.2 !important; }
  h3 { font-size: 20px !important; }
  .mf-trust-grid { grid-template-columns: 1fr; gap: 30px; }
  .mf-strip-track span { font-size: 12px; padding: 0 15px; }
  .site-header .mf-container { grid-template-columns: auto 1fr auto; min-height: 90px; }
  .site-header .brand img { width: 80px; }
  .menu { display: none; }
  .menu.open { display: grid; position: absolute; left: 0; right: 0; top: 100%; background: var(--purple); padding: 16px 20px 24px; gap: 14px; }
  .menu-toggle { display: inline-flex; background: none; border: 0; color: #fff; cursor: pointer; padding: 8px; justify-self: end; }
  .menu-toggle svg { width: 26px; height: 26px; }
  .header-right { display: none; }
  .mf-hero { min-height: 0; padding: 10px 0; }
  .mf-hero-grid { grid-template-columns: 1fr; gap: 8px; }
  .mf-hero-content { display: contents; }
  .mf-eyebrow { order: 1; font-size: 11px; letter-spacing: 1px; margin: 0 0 6px; }
  .mf-heading { order: 2; font-size: 22px !important; line-height: 1.15 !important; margin: 0 0 6px; }
  .mf-subheading { order: 3; font-size: 13px; line-height: 1.3; margin: 0; }
  .mf-hero-visual { order: 4; }
  .mf-hero-visual__img { max-width: 280px; margin: 0 auto; }
  .mf-buttons { order: 5; margin-top: 8px; gap: 8px; }
  .mf-hero--visual .mf-btn { padding: 10px 16px; font-size: 15px; }
  .mf-hero-guarantee, .mf-hero-ship { order: 6; font-size: 13px; }
  .mf-hero-ship { margin-top: 6px; }
  .mf-section { padding: 60px 0; }
  .mf-benefits .mf-card h3 { font-size: 20px !important; }
  .mf-shop { padding: 30px 0 40px; }
  .mf-faq-heading { font-size: 30px; }
  .mf-faq-btn { padding: 22px; }
  .mf-faq-btn span:first-child { font-size: 19px; }
  .mf-faq-inner { padding: 0 22px 24px; }
  .mf-faq-icon { width: 36px; height: 36px; font-size: 22px; }
  .club form { flex-direction: column; align-items: stretch; }
  .club h3 { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  .mf-strip-track { animation: none; }
  html { scroll-behavior: auto; }
}
