/*
Theme Name: Elephant Peptide Labs
Theme URI: https://elephantpeptide.co.za/
Author: Elephant Peptide Labs
Description: Premium, research-led WooCommerce theme built from the supplied Elephant Peptide Labs prototype and brand guidelines.
Version: 1.2.0
Requires at least: 6.4
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: elephant-peptide-labs
*/

:root{
    --black:#0A0A0A;
    --gold:#B8944C;
    --ivory:#FAF9F5;
    --graphite:#565652;
    --soft:#D9D7CF;
    --white:#fff;
    --max:1240px;
}

*{
    box-sizing:border-box;
}

html{
    scroll-behavior:smooth;
}

body{
    margin:0;
    background:var(--ivory);
    color:var(--black);
    font-family:Inter,Arial,sans-serif;
    line-height:1.65;
}

h1,h2,h3,h4{
    font-family:"EB Garamond",Georgia,serif;
    font-weight:400;
    line-height:1.08;
    margin:0 0 18px;
}

h1{
    font-size:clamp(42px,6vw,78px);
}

h2{
    font-size:clamp(30px,4vw,48px);
}

h3{
    font-size:28px;
}

p{
    margin:0 0 18px;
}

.container{
    width:min(92%,var(--max));
    margin:auto;
}

a{
    color:inherit;
    text-decoration:none;
}

.screen-reader-text{
    position:absolute;
    left:-9999px;
}

/* =========================
   QUALITY RIBBON
========================= */

.quality-ribbon{
    background:var(--gold);
    color:#fff;
    text-align:center;
    font-size:11px;
    letter-spacing:.16em;
    font-weight:700;
    padding:8px 15px;
    display:flex;
    justify-content:center;
    gap:22px;
}

/* =========================
   HEADER
========================= */

.site-header{
    background:var(--black);
    color:#fff;
    position:sticky;
    top:0;
    z-index:50;
    border-bottom:1px solid rgba(255,255,255,.12);
}

.header-wrap{
    width:min(94%,var(--max));
    margin:auto;
    min-height:82px;
    display:flex;
    align-items:center;
    gap:30px;
}

.brand{
    display:flex;
    align-items:center;
    gap:12px;
    min-width:250px;
}

.brand img{
    width:43px;
    height:43px;
    object-fit:contain;
}

.brand strong{
    display:block;
    font-size:13px;
    letter-spacing:.12em;
}

.brand small{
    display:block;
    color:#cfcfc9;
    font-size:10px;
    letter-spacing:.08em;
    margin-top:2px;
}

.main-nav{
    display:flex;
    gap:25px;
    align-items:center;
    margin-left:auto;
}

.main-nav a{
    font-size:12px;
    letter-spacing:.08em;
    text-transform:uppercase;
    color:#e8e8e5;
}

.main-nav a:hover,
.main-nav .current-menu-item a{
    color:var(--gold);
}

.header-cta,
.btn{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    background:var(--gold);
    color:#fff;
    padding:12px 20px;
    border:1px solid var(--gold);
    font-size:12px;
    letter-spacing:.08em;
    text-transform:uppercase;
    font-weight:700;
    cursor:pointer;
}

.header-cta{
    white-space:nowrap;
}

.btn:hover{
    filter:brightness(.94);
}

.btn.ghost,
.btn.outline{
    background:transparent;
    color:inherit;
    border-color:currentColor;
}

.menu-toggle{
    display:none;
    margin-left:auto;
    background:none;
    border:0;
    color:#fff;
    font-size:28px;
}

/* =========================
   HERO
========================= */

.hero{
    background:var(--black);
    color:#fff;
    min-height:650px;
    display:flex;
    align-items:center;
    position:relative;
    overflow:hidden;
}

.hero:after{
    content:"";
    position:absolute;
    inset:0;
    background:
        radial-gradient(
            circle at 78% 42%,
            rgba(184,148,76,.13),
            transparent 22%
        ),
        linear-gradient(
            135deg,
            transparent 60%,
            rgba(255,255,255,.025)
        );
    pointer-events:none;
}

.hero-inner{
    display:grid;
    grid-template-columns:1.05fr .95fr;
    gap:50px;
    align-items:center;
    position:relative;
    z-index:1;
    padding:85px 0;
}

.kicker{
    display:inline-block;
    color:var(--gold);
    text-transform:uppercase;
    letter-spacing:.18em;
    font-size:11px;
    font-weight:700;
    margin-bottom:18px;
}

.lead{
    font-size:18px;
    color:#d7d7d2;
    max-width:700px;
}

.actions{
    display:flex;
    gap:12px;
    flex-wrap:wrap;
    margin-top:28px;
}

/* =========================
   HERO VIDEO
   (replaces the old constellation/molecule graphic, then a static
   3-photo grid, with a branded looping video reel — per Eleanor's
   updated direction: "more alive", grabs attention)
========================= */

.hero-video-frame{
    min-height:390px;
    border:1px solid rgba(184,148,76,.35);
    overflow:hidden;
    position:relative;
    background:#0A0A0A;
}

.hero-video-frame video{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
}

/* =========================
   EDUCATIONAL / RESEARCH VIDEO
========================= */

.epl-video-grid{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:50px;
    align-items:center;
}

.epl-video-frame{
    background:var(--black);
    color:#fff;
    min-height:320px;
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    gap:16px;
    border:1px solid rgba(184,148,76,.4);
    position:relative;
}

.epl-video-frame video{
    width:100%;
    height:100%;
    object-fit:cover;
}

/* Per-product research videos are rendered as vertical 9:16 "reels" (to
   match the credibility-building social-reel style Eleanor asked for) —
   framed narrow and tall rather than stretched to fill the wide copy/video
   grid column, so they don't distort. Scoped to the product page's own
   video section only — the homepage "Verification Process" video (also
   using .epl-video-frame) keeps its original wide framing. */
.epl-product-video .epl-video-frame{
    aspect-ratio:9/16;
    max-width:340px;
    min-height:0;
    margin:0 auto;
}

/* =========================
   SECTIONS
========================= */

.section{
    padding:86px 0;
}

.section.ivory{
    background:#fff;
}

.section-head{
    display:flex;
    justify-content:space-between;
    gap:40px;
    align-items:end;
    margin-bottom:38px;
}

.section-head>div{
    max-width:650px;
}

.section-head>p{
    max-width:480px;
    color:var(--graphite);
}

/* =========================
   PROOF BAR
========================= */

.proofbar{
    background:#151515;
    color:#fff;
    border-top:1px solid #222;
    border-bottom:1px solid #222;
}

.proofgrid{
    display:grid;
    grid-template-columns:repeat(4,1fr);
}

.proof{
    padding:25px 20px;
    border-right:1px solid #333;
}

.proof:last-child{
    border:0;
}

.proof strong{
    display:block;
    font-size:12px;
    text-transform:uppercase;
    letter-spacing:.1em;
}

.proof span{
    display:block;
    color:#aaa;
    font-size:12px;
    margin-top:6px;
}

/* =========================
   CATEGORY / PRODUCT GRIDS
========================= */

.category-grid,
.product-grid{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:18px;
}

.category-card{
    background:var(--ivory);
    border:1px solid #e2dfd6;
    padding:28px;
    min-height:200px;
    transition:.2s;
}

.category-card:hover{
    transform:translateY(-3px);
    border-color:var(--gold);
}

.category-card span,
.product-category{
    font-size:10px;
    letter-spacing:.12em;
    text-transform:uppercase;
    color:var(--graphite);
    font-weight:700;
}

.product-card{
    background:#fff;
    border:1px solid #e2dfd6;
    display:flex;
    flex-direction:column;
    min-width:0;
}

.product-visual{
    height:250px;
    background:linear-gradient(180deg,#fff,#f6f5f0);
    display:flex;
    align-items:center;
    justify-content:center;
    border-bottom:1px solid #e8e6df;
}

.vial{
    width:105px;
    height:160px;
    border:1px solid #c7c5bd;
    border-radius:16px 16px 20px 20px;
    background:linear-gradient(90deg,#e6e6e2,#fff 38%,#ddd);
    position:relative;
    box-shadow:0 16px 24px rgba(0,0,0,.12);
}

.vial:before{
    content:"";
    position:absolute;
    left:12px;
    right:12px;
    top:-25px;
    height:28px;
    background:#b8b8b2;
    border-radius:5px 5px 2px 2px;
}

.vial:after{
    content:"RESEARCH USE ONLY";
    position:absolute;
    left:8px;
    right:8px;
    bottom:32px;
    font-size:7px;
    letter-spacing:.12em;
    text-align:center;
}

.vial-label{
    position:absolute;
    left:9px;
    right:9px;
    top:42px;
    background:#fff;
    padding:11px 5px;
    text-align:center;
    border-top:1px solid var(--gold);
    border-bottom:1px solid var(--gold);
}

.vial-label b{
    font-family:Georgia,serif;
    font-size:13px;
    display:block;
}

.vial-label small{
    font-size:7px;
    color:var(--graphite);
}

.product-card-copy{
    padding:20px;
}

.product-card h3{
    font-size:25px;
    margin:8px 0;
}

.strength-line{
    font-size:12px;
    color:var(--graphite);
    min-height:42px;
}

.card-bottom{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    margin-top:12px;
}

.card-bottom strong{
    font-size:15px;
}

.card-bottom a{
    font-size:11px;
    text-transform:uppercase;
    letter-spacing:.08em;
    color:var(--graphite);
}

/* =========================
   PAGE HERO
========================= */

.page-hero{
    background:var(--black);
    color:#fff;
    padding:70px 0;
}

.page-hero p{
    color:#ccc;
    max-width:760px;
    font-size:17px;
}

/* =========================
   CATALOGUE TOOLS
========================= */

.catalog-tools{
    padding:25px 0;
    background:#fff;
    border-bottom:1px solid #ddd;
}

.tool-grid{
    display:grid;
    grid-template-columns:2fr 1fr auto;
    gap:12px;
    align-items:center;
}

.search-field,
.filter-select,
input,
textarea,
select{
    width:100%;
    padding:14px 15px;
    border:1px solid #d5d2ca;
    background:#fff;
    font:inherit;
}

.catalog-meta{
    font-size:12px;
    color:var(--graphite);
}

/* =========================
   FOOTER
========================= */

.site-footer{
    background:var(--black);
    color:#fff;
}

.footer-inner{
    width:min(92%,var(--max));
    margin:auto;
    display:grid;
    grid-template-columns:2fr 1fr 1fr;
    gap:50px;
    padding:60px 0;
}

.footer-inner h3{
    font-family:Inter,Arial,sans-serif;
    font-size:12px;
    text-transform:uppercase;
    letter-spacing:.12em;
    color:var(--gold);
}

.footer-inner a,
.footer-inner span{
    display:block;
    color:#bbb;
    font-size:12px;
    margin:7px 0;
}

.gold-line{
    color:var(--gold);
    font-size:12px;
    letter-spacing:.08em;
}

.legal-strip{
    background:#111;
    color:#ccc;
    padding:18px;
    text-align:center;
    font-size:11px;
}

.legal-strip strong{
    color:#fff;
}

/* =========================
   GENERAL CONTENT
========================= */

.entry-content,
.woocommerce{
    width:min(92%,var(--max));
    margin:55px auto;
}

.entry-content h2{
    margin-top:45px;
}

.notice{
    padding:18px;
    border:1px solid #ddd;
    background:#fff;
    margin:18px 0;
}

.notice.gold{
    border-color:var(--gold);
    background:#fbf8f1;
}

/* =========================
   WOOCOMMERCE CATALOGUE
========================= */

.woocommerce ul.products{
    display:grid !important;
    grid-template-columns:repeat(4,1fr);
    gap:18px;
    list-style:none;
    padding:0;
}

.woocommerce ul.products li.product{
    width:auto !important;
    margin:0 !important;
    background:#fff;
    border:1px solid #e2dfd6;
    padding:0 0 18px;
    float:none;
}

.woocommerce ul.products li.product .button{
    display:none;
}

/* Consistent product-photo matting: the catalogue's source photography
   comes from a few different original shoots/crops (mixed aspect ratios,
   backgrounds and lighting), which looked jarring side-by-side in the
   grid. Every thumbnail now sits in a fixed-ratio, ivory-matted frame
   with object-fit:cover, so the grid reads as one consistent system even
   where the underlying photo doesn't perfectly match its neighbours. */
.woocommerce ul.products li.product a img{
    margin:0 !important;
    aspect-ratio:1/1;
    width:100%;
    height:auto;
    object-fit:cover;
    background:var(--ivory);
    display:block;
}

.woocommerce ul.products li.product .price{
    padding:0 20px;
    color:var(--black);
    font-weight:700;
}

.woocommerce ul.products li.product .woocommerce-loop-product__title{
    padding:0 20px;
    font-family:Georgia,serif;
    font-size:25px;
}

.woocommerce span.onsale{
    background:var(--gold);
    padding:5px 9px;
}

/* =========================
   WOOCOMMERCE PRODUCT
========================= */

.woocommerce .quantity .qty{
    padding:10px;
}

.woocommerce button.button,
.woocommerce a.button{
    background:var(--gold);
    color:#fff;
    border-radius:0;
    padding:12px 20px;
}

.woocommerce div.product{
    background:#fff;
    padding:35px;
}

.woocommerce div.product .product_title{
    font-size:48px;
}

.woocommerce div.product .price{
    color:var(--black);
    font-weight:700;
}

.woocommerce-message{
    border-top-color:var(--gold);
}

/* =========================
   RESEARCH / RECOMMENDER
========================= */

.epl-research-note{
    border-left:3px solid var(--gold);
    padding:15px 18px;
    background:#fff;
    margin:25px 0;
    font-size:13px;
}

.reco-card{
    background:#fff;
    border:1px solid #ddd;
    padding:25px;
}

.reco-step{
    display:none;
}

.reco-step.active{
    display:block;
}

.choice-grid{
    display:grid;
    grid-template-columns:repeat(2,1fr);
    gap:12px;
}

.choice{
    padding:20px;
    background:#fff;
    border:1px solid #ddd;
    text-align:left;
    cursor:pointer;
}

.choice.selected{
    border-color:var(--gold);
    box-shadow:0 0 0 2px rgba(184,148,76,.12);
}

.choice strong{
    display:block;
}

.choice span{
    display:block;
    color:var(--graphite);
    font-size:12px;
    margin-top:5px;
}

/* =========================
   FAQ
========================= */

.faq-item{
    border-top:1px solid #d8d5cd;
    padding:18px 0;
}

.faq-q{
    font-weight:700;
    cursor:pointer;
}

.faq-a{
    display:none;
    padding-top:10px;
    color:var(--graphite);
}

.faq-item.open .faq-a{
    display:block;
}

/* =========================
   ACCESS
========================= */

.access-state{
    padding:25px;
    background:#fff;
    border:1px solid #ddd;
}

.access-state.approved{
    border-color:var(--gold);
}

/* =========================
   TABLET
========================= */

@media(max-width:950px){

    .main-nav{
        display:none;
    }

    .menu-toggle{
        display:block;
    }

    .header-wrap{
        gap:10px;
    }

    .header-cta{
        margin-left:auto;
    }

    .hero-inner{
        grid-template-columns:1fr;
    }

    .hero-video-frame{
        min-height:280px;
    }

    .epl-video-grid{
        grid-template-columns:1fr;
    }

    .category-grid,
    .product-grid,
    .woocommerce ul.products{
        grid-template-columns:repeat(2,1fr);
    }

    .proofgrid{
        grid-template-columns:repeat(2,1fr);
    }

    .proof:nth-child(2){
        border-right:0;
    }

    .section-head{
        display:block;
    }

    .section-head>p{
        margin-top:15px;
    }

    .tool-grid{
        grid-template-columns:1fr;
    }

    .footer-inner{
        grid-template-columns:1fr 1fr;
    }
}

/* =========================
   MOBILE
========================= */

@media(max-width:600px){

    .brand{
        min-width:0;
    }

    .brand span{
        display:none;
    }

    .header-cta{
        font-size:10px;
        padding:10px 12px;
    }

    .hero{
        min-height:580px;
    }

    .section{
        padding:58px 0;
    }

    .category-grid,
    .product-grid,
    .woocommerce ul.products,
    .choice-grid,
    .proofgrid{
        grid-template-columns:1fr;
    }

    .proof{
        border-right:0;
        border-bottom:1px solid #333;
    }

    .footer-inner{
        grid-template-columns:1fr;
    }

    .woocommerce div.product{
        padding:20px;
    }

    .woocommerce div.product .product_title{
        font-size:38px;
    }
}
/* =========================================================
   EPL — SINGLE PRODUCT FULL-WIDTH SHELL FIX
   ========================================================= */

body.single-product main {
    width: 100% !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

body.single-product main .woocommerce {
    width: 100% !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

body.single-product main .product {
    width: min(92%, 1240px) !important;
    max-width: 1240px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box !important;
}
/* FIX: WooCommerce class is applied to BODY on shop/product pages */
body.woocommerce,
body.woocommerce-page {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}