/* ============================================
   Sức Khỏe Tự Nhiên — Global Stylesheet
   ============================================ */

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --primary: #7c3aed;
    --primary-light: #ede9fe;
    --primary-dark: #5b21b6;
    --accent: #d97706;
    --accent-light: #fef3c7;
    --bg: #ffffff;
    --bg-alt: #f8faf6;
    --surface: #ffffff;
    --text: #1f2d24;
    --text-muted: #5b6d62;
    --border: rgba(45, 122, 79, 0.13);
    --danger: #dc2626;

    --font-body: 'Be Vietnam Pro', system-ui, -apple-system, sans-serif;
    --font-display: 'Fraunces', Georgia, serif;

    --radius-sm: 8px;
    --radius: 14px;
    --radius-lg: 20px;
    --radius-full: 999px;

    --shadow-sm: 0 1px 2px rgba(20, 40, 25, 0.04);
    --shadow: 0 4px 14px rgba(30, 85, 54, 0.08);
    --shadow-lg: 0 20px 50px -10px rgba(30, 85, 54, 0.18);

    --transition: 220ms cubic-bezier(0.4, 0, 0.2, 1);
    --container: 1200px;
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--font-body);
    color: var(--text);
    background: var(--bg);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-dark); }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 600; line-height: 1.2; letter-spacing: -0.01em; color: var(--text); }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity 700ms ease, transform 700ms cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.reveal.is-visible { opacity: 1; transform: none; }
.reveal--delay-1 { transition-delay: 80ms; }
.reveal--delay-2 { transition-delay: 160ms; }
.reveal--delay-3 { transition-delay: 240ms; }

/* HEADER */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,0.9); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid var(--border); }
.site-header__inner { max-width: var(--container); margin: 0 auto; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 16px; position: relative; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand__logo { height: 38px; width: 38px; border-radius: 50%; object-fit: cover; box-shadow: 0 2px 6px rgba(0,0,0,0.08); }
.brand__name { font-family: var(--font-display); font-size: 1.3rem; font-weight: 700; color: var(--text); }
.nav { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; }
.nav__link { padding: 8px 14px; color: var(--text-muted); font-size: 0.93rem; font-weight: 500; border-radius: var(--radius-sm); transition: color var(--transition), background var(--transition); }
.nav__link:hover { color: var(--primary); background: var(--primary-light); }
.nav-toggle { display: none; background: none; border: none; padding: 8px; color: var(--text); font-size: 24px; }
.header-actions { display: flex; align-items: center; gap: 12px; }
.cart-btn { position: relative; padding: 10px 14px; background: var(--primary-light); color: var(--primary-dark); border: none; border-radius: var(--radius-sm); font-weight: 600; display: inline-flex; align-items: center; gap: 8px; transition: all var(--transition); cursor: pointer; }
.cart-btn:hover { background: var(--primary); color: #fff; }
.cart-btn__badge { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 6px; background: var(--accent); color: #fff; font-size: 0.78rem; font-weight: 700; border-radius: 11px; }
.cart-btn__badge[data-count="0"] { display: none; }

/* BUTTONS */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 22px; font-weight: 600; font-size: 0.95rem; border-radius: var(--radius-full); border: none; cursor: pointer; transition: all var(--transition); text-align: center; text-decoration: none; }
.btn--primary { background: var(--primary); color: #fff; box-shadow: 0 4px 14px rgba(45, 122, 79, 0.25); }
.btn--primary:hover { background: var(--primary-dark); color: #fff; transform: translateY(-1px); box-shadow: 0 8px 24px rgba(45, 122, 79, 0.35); }
.btn--accent { background: var(--accent); color: #fff; box-shadow: 0 4px 14px rgba(231, 111, 36, 0.28); }
.btn--accent:hover { background: #c25a16; color: #fff; }
.btn--ghost { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn--ghost:hover { background: var(--primary); color: #fff; }
.btn--lg { padding: 16px 36px; font-size: 1.02rem; }
.btn--block { width: 100%; }

@media (max-width: 880px) {
    .nav-toggle { display: inline-flex; }
    .nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; background: var(--surface); padding: 8px; box-shadow: var(--shadow); border-bottom: 1px solid var(--border); }
    .nav.is-open { display: flex; }
    .nav__link { padding: 12px 16px; width: 100%; }
}

/* HERO */
.hero { position: relative; padding: clamp(60px, 9vh, 100px) 0; overflow: hidden; background: linear-gradient(135deg, var(--primary-light) 0%, var(--accent-light) 100%); }
.hero__grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.1fr 1fr; gap: 60px; align-items: center; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.hero__eyebrow { display: inline-block; padding: 6px 14px; background: var(--primary-dark); color: #fff; border-radius: var(--radius-full); font-size: 0.78rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 20px; }
.hero__title { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 700; margin-bottom: 18px; }
.hero__title em { font-style: italic; color: var(--accent); font-weight: 600; }
.hero__lead { font-size: clamp(1.05rem, 1.6vw, 1.18rem); color: var(--text-muted); margin-bottom: 28px; max-width: 520px; }
.hero__cta-row { display: flex; gap: 14px; flex-wrap: wrap; }
.hero__badges { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.hero__badge { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; background: rgba(255,255,255,0.7); backdrop-filter: blur(10px); border-radius: var(--radius-full); border: 1px solid rgba(45,122,79,0.15); font-size: 0.85rem; color: var(--text); font-weight: 500; }
.hero__image img { width: 100%; max-width: 540px; margin-left: auto; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }

@media (max-width: 880px) {
    .hero__grid { grid-template-columns: 1fr; gap: 40px; text-align: center; }
    .hero__lead { margin-left: auto; margin-right: auto; }
    .hero__cta-row, .hero__badges { justify-content: center; }
    .hero__image img { margin: 0 auto; }
}

/* TRUST */
.trust { padding: 40px 0; background: var(--bg-alt); border-bottom: 1px solid var(--border); }
.trust__grid { max-width: var(--container); margin: 0 auto; padding: 0 24px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.trust__item { display: flex; align-items: center; gap: 12px; }
.trust__icon { font-size: 28px; flex-shrink: 0; }
.trust__title { font-weight: 600; font-size: 0.95rem; color: var(--text); }
.trust__desc { font-size: 0.82rem; color: var(--text-muted); margin-top: 2px; }
@media (max-width: 800px) { .trust__grid { grid-template-columns: 1fr 1fr; gap: 16px; } }
@media (max-width: 480px) { .trust__grid { grid-template-columns: 1fr; } }

/* SECTION HEAD */
.section-head { text-align: center; max-width: 640px; margin: 0 auto 48px; }
.section-head__eyebrow { font-size: 0.85rem; font-weight: 600; color: var(--primary); letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 10px; }
.section-head__title { font-size: clamp(1.8rem, 3.5vw, 2.4rem); margin-bottom: 12px; }
.section-head__desc { color: var(--text-muted); font-size: 1.05rem; }

/* PRODUCTS */
.products { padding: clamp(64px, 8vh, 100px) 0; background: var(--bg); }
.products__category { font-family: var(--font-display); font-size: 1.5rem; margin: 32px 0 24px; color: var(--text); }
.products__category:first-of-type { margin-top: 0; }
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 22px; }
.product-card { background: var(--surface); border-radius: var(--radius); border: 1px solid var(--border); overflow: hidden; transition: transform var(--transition), box-shadow var(--transition); display: flex; flex-direction: column; }
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.product-card__image { display: block; aspect-ratio: 1; overflow: hidden; background: var(--bg-alt); }
.product-card__image img { width: 100%; height: 100%; object-fit: contain; padding: 16px; transition: transform var(--transition); }
.product-card:hover .product-card__image img { transform: scale(1.04); }
.product-card__body { padding: 16px 18px 18px; display: flex; flex-direction: column; flex: 1; gap: 8px; }
.product-card__title { font-family: var(--font-body); font-size: 0.96rem; font-weight: 600; color: var(--text); line-height: 1.4; }
.product-card__title a { color: inherit; }
.product-card__title a:hover { color: var(--primary); }
.product-card__price { font-size: 1.1rem; font-weight: 700; color: var(--primary-dark); font-family: var(--font-display); }
.product-card__btn { margin-top: 6px; padding: 11px 16px; background: var(--primary); color: #fff; border: none; border-radius: var(--radius-sm); font-weight: 600; font-size: 0.92rem; cursor: pointer; transition: all var(--transition); }
.product-card__btn:hover { background: var(--primary-dark); transform: translateY(-1px); }
.product-card__btn.is-added { background: var(--accent); }

/* PRODUCT PAGE */
.product-page { padding: clamp(36px, 5vh, 64px) 0; }
.product-page__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; max-width: var(--container); margin: 0 auto; padding: 0 24px; align-items: start; }
.product-page__gallery { background: var(--bg-alt); border-radius: var(--radius); padding: 40px; aspect-ratio: 1; display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow); }
.product-page__gallery img { max-width: 100%; max-height: 100%; object-fit: contain; }
.product-page__title { font-size: clamp(1.8rem, 3.5vw, 2.4rem); margin-bottom: 16px; }
.product-page__price { font-family: var(--font-display); font-size: 2rem; font-weight: 700; color: var(--primary-dark); margin-bottom: 24px; }
.product-page__desc { color: var(--text-muted); line-height: 1.85; margin-bottom: 32px; white-space: pre-line; }
.product-page__buttons { display: flex; gap: 14px; flex-wrap: wrap; }
.breadcrumbs { padding-top: 24px; max-width: var(--container); margin: 0 auto; padding-left: 24px; padding-right: 24px; font-size: 0.88rem; color: var(--text-muted); }
.breadcrumbs a { color: var(--text-muted); }
.breadcrumbs a:hover { color: var(--primary); }
@media (max-width: 880px) {
    .product-page__grid { grid-template-columns: 1fr; gap: 32px; }
    .product-page__gallery { padding: 28px; }
}

/* CART DRAWER */
.cart-drawer { position: fixed; top: 0; right: 0; bottom: 0; width: 420px; max-width: 100%; background: var(--surface); box-shadow: -10px 0 40px rgba(0,0,0,0.12); z-index: 9999; transform: translateX(100%); transition: transform var(--transition); display: flex; flex-direction: column; }
.cart-drawer.is-open { transform: translateX(0); }
.cart-drawer__overlay { position: fixed; inset: 0; background: rgba(20, 30, 25, 0.4); backdrop-filter: blur(4px); z-index: 9998; display: none; }
.cart-drawer__overlay.is-open { display: block; }
.cart-drawer__head { padding: 20px 24px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border); }
.cart-drawer__title { font-size: 1.25rem; }
.cart-drawer__close { background: none; border: none; font-size: 28px; color: var(--text-muted); }
.cart-drawer__close:hover { color: var(--text); }
.cart-drawer__items { flex: 1; overflow-y: auto; padding: 16px 24px; }
.cart-drawer__empty { padding: 40px 24px; text-align: center; color: var(--text-muted); }
.cart-item { display: grid; grid-template-columns: 70px 1fr auto; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--border); align-items: center; }
.cart-item__img { width: 70px; height: 70px; object-fit: contain; background: var(--bg-alt); border-radius: var(--radius-sm); }
.cart-item__name { font-size: 0.92rem; font-weight: 600; color: var(--text); margin-bottom: 4px; line-height: 1.4; }
.cart-item__price { font-size: 0.9rem; color: var(--primary-dark); font-weight: 600; }
.cart-item__qty { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
.cart-item__qty button { width: 26px; height: 26px; background: var(--bg-alt); border: 1px solid var(--border); border-radius: 6px; color: var(--text); font-weight: 600; line-height: 1; }
.cart-item__qty button:hover { background: var(--primary-light); }
.cart-item__qty span { min-width: 24px; text-align: center; font-weight: 600; font-size: 0.9rem; }
.cart-item__remove { background: none; border: none; color: var(--danger); font-size: 18px; padding: 4px 8px; cursor: pointer; }
.cart-drawer__foot { padding: 20px 24px; border-top: 1px solid var(--border); }
.cart-drawer__total { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; font-size: 1.1rem; font-weight: 700; }
.cart-drawer__total span:last-child { color: var(--primary-dark); font-family: var(--font-display); font-size: 1.3rem; }

/* MODAL */
.modal { position: fixed; inset: 0; background: rgba(20, 30, 25, 0.55); backdrop-filter: blur(6px); z-index: 9998; display: none; align-items: center; justify-content: center; padding: 16px; }
.modal.is-visible { display: flex; }
.modal__box { background: var(--surface); border-radius: var(--radius-lg); padding: 36px 32px; max-width: 460px; width: 100%; position: relative; box-shadow: 0 24px 60px rgba(0,0,0,0.25); }
.modal__title { font-size: 1.35rem; margin-bottom: 22px; }
.modal__close { position: absolute; top: 16px; right: 18px; background: none; border: none; font-size: 24px; color: var(--text-muted); line-height: 1; }
.modal__field { margin-bottom: 14px; }
.modal__field label { display: block; font-size: 0.83rem; font-weight: 500; color: var(--text); margin-bottom: 6px; }
.modal__field input { width: 100%; padding: 11px 14px; font: inherit; font-size: 0.95rem; border: 1.5px solid var(--border); border-radius: var(--radius-sm); background: var(--bg); color: var(--text); outline: none; transition: border-color var(--transition); }
.modal__field input:focus { border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-light); }
.modal__submit { width: 100%; padding: 13px; background: var(--primary); color: #fff; border: none; border-radius: var(--radius-sm); font-weight: 600; margin-top: 8px; transition: background var(--transition); }
.modal__submit:hover { background: var(--primary-dark); }

/* STATIC PAGES */
.page-hero { padding: clamp(50px, 7vh, 80px) 0 clamp(30px, 4vh, 50px); background: linear-gradient(135deg, var(--bg-alt), var(--bg)); text-align: center; }
.page-hero__title { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 12px; }
.page-hero__meta { color: var(--text-muted); font-size: 0.92rem; }
.legal { padding: 48px 0 80px; }
.legal__inner { max-width: 820px; margin: 0 auto; padding: 48px clamp(20px, 5vw, 56px); background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.legal__inner h2 { font-size: 1.4rem; margin: 32px 0 14px; }
.legal__inner h2:first-of-type { margin-top: 0; }
.legal__inner p { color: var(--text-muted); margin-bottom: 14px; line-height: 1.8; font-size: 0.97rem; }
.legal__inner ul { padding-left: 24px; margin-bottom: 14px; color: var(--text-muted); line-height: 1.8; }

/* CONTACT */
.contact { padding: clamp(60px, 8vh, 100px) 0; background: var(--bg); }
.contact__grid { max-width: 1080px; margin: 0 auto; padding: 0 24px; display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: start; }
.contact__title { font-size: clamp(1.8rem, 3vw, 2.4rem); margin-bottom: 12px; }
.contact__lead { color: var(--text-muted); font-size: 1.05rem; margin-bottom: 36px; }
.contact__list { display: flex; flex-direction: column; gap: 22px; }
.contact__item { display: flex; gap: 14px; align-items: flex-start; }
.contact__icon { width: 44px; height: 44px; background: var(--primary-light); color: var(--primary-dark); border-radius: var(--radius-sm); display: inline-flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.contact__label { font-weight: 600; color: var(--text); margin-bottom: 2px; font-size: 0.95rem; }
.contact__value { color: var(--text-muted); font-size: 0.92rem; }

.form-card { background: var(--surface); border-radius: var(--radius-lg); padding: 36px 32px; border: 1px solid var(--border); box-shadow: var(--shadow); }
.form-card__title { font-size: 1.3rem; margin-bottom: 22px; }
.form { display: flex; flex-direction: column; gap: 12px; }
.form__input { width: 100%; padding: 12px 14px; font: inherit; font-size: 0.95rem; background: var(--bg); border: 1.5px solid var(--border); border-radius: var(--radius-sm); outline: none; transition: border-color var(--transition); }
.form__input:focus { border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-light); }
.form__submit { padding: 13px 22px; background: var(--primary); color: #fff; border: none; border-radius: var(--radius-sm); font-weight: 600; cursor: pointer; transition: background var(--transition); }
.form__submit:hover { background: var(--primary-dark); }
.form__note { font-size: 0.78rem; color: var(--text-muted); text-align: center; margin-top: 6px; line-height: 1.55; }
@media (max-width: 880px) { .contact__grid { grid-template-columns: 1fr; gap: 36px; } }

/* THANKS */
.thanks { min-height: 70vh; display: flex; align-items: center; justify-content: center; padding: 80px 24px; text-align: center; background: linear-gradient(135deg, var(--primary-light), var(--accent-light)); }
.thanks__box { max-width: 560px; }
.thanks__icon { width: 96px; height: 96px; margin: 0 auto 28px; background: linear-gradient(135deg, var(--primary), var(--accent)); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 48px; box-shadow: 0 12px 36px rgba(45, 122, 79, 0.25); }
.thanks__title { font-size: clamp(1.8rem, 3.5vw, 2.4rem); margin-bottom: 14px; }
.thanks__text { color: var(--text-muted); font-size: 1.05rem; line-height: 1.7; margin-bottom: 28px; }

/* FOOTER */
.site-footer { background: var(--text); color: rgba(255,255,255,0.85); padding: 60px 0 0; }
.site-footer a { color: rgba(255,255,255,0.7); }
.site-footer a:hover { color: var(--accent); }
.site-footer__inner { max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.site-footer__top { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 32px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.1); }
.site-footer__brand-name { font-family: var(--font-display); font-size: 1.4rem; font-weight: 700; color: #fff; margin-bottom: 12px; }
.site-footer__desc { font-size: 0.92rem; line-height: 1.7; max-width: 340px; color: rgba(255,255,255,0.7); }
.site-footer__heading { font-size: 0.85rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: #fff; margin-bottom: 16px; }
.site-footer__list { list-style: none; padding: 0; margin: 0; }
.site-footer__list li { margin-bottom: 8px; }
.site-footer__list a { font-size: 0.92rem; }
.site-footer__contact { font-size: 0.92rem; line-height: 1.85; color: rgba(255,255,255,0.7); }
.site-footer__bottom { padding: 24px 0; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.site-footer__copy { font-size: 0.85rem; color: rgba(255,255,255,0.6); }
.site-footer__legal { display: flex; gap: 20px; }
.site-footer__legal a { font-size: 0.85rem; }
@media (max-width: 768px) {
    .site-footer__top { grid-template-columns: 1fr 1fr; gap: 28px; }
    .site-footer__bottom { justify-content: center; text-align: center; }
}
@media (max-width: 480px) { .site-footer__top { grid-template-columns: 1fr; } }

/* COOKIE */
.cookie { position: fixed; bottom: 16px; left: 16px; right: 16px; max-width: 720px; margin: 0 auto; background: var(--text); color: #fff; padding: 18px 22px; border-radius: var(--radius); display: none; align-items: center; gap: 18px; box-shadow: 0 20px 50px rgba(0,0,0,0.25); z-index: 9997; font-size: 0.88rem; line-height: 1.55; }
.cookie.is-visible { display: flex; }
.cookie a { color: #fff; text-decoration: underline; }
.cookie__btn { background: var(--accent); color: #fff; border: none; padding: 10px 22px; border-radius: var(--radius-full); font-weight: 600; flex-shrink: 0; cursor: pointer; }
.cookie__btn:hover { background: #c25a16; }
@media (max-width: 600px) { .cookie { flex-direction: column; text-align: center; } }
