/*
Theme Name: Kalesthia Aesthetics
Author: Custom
Description: A bespoke pharmacy-led aesthetics theme.
Version: 1.7
*/

:root {
    --color-bg: #F5F3ED; 
    --color-text: #4F5B45; 
    --color-text-light: #7A8571;
    --color-accent: #8F9E83; 
    --color-white: #FFFFFF;
    
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Lato', sans-serif;
    
    --spacing-container: 1200px;
    --spacing-narrow: 740px; 
    --spacing-section: 80px 20px;
}

/* Reset & Basics */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-body);
    font-size: 17px; 
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 400;
    margin-bottom: 1rem;
    line-height: 1.25;
    color: var(--color-text);
}

h1 { font-size: 3rem; }
h2 { font-size: 2.4rem; }
h3 { font-size: 1.6rem; }

a { color: var(--color-text); text-decoration: none; transition: 0.3s; }
a:hover { opacity: 0.7; }

img { max-width: 100%; height: auto; display: block; }

/* Container */
.container {
    max-width: var(--spacing-container);
    margin: 0 auto;
    padding: 0 20px;
}

.container-narrow {
    max-width: var(--spacing-narrow);
    margin: 0 auto;
    padding: 0 20px;
}

/* --- FIXED HEADER LOGIC --- */
.site-header {
    /* Chrome Scroll Anchor Fix */
    overflow-anchor: none;
    
    padding: 25px 0;
    background-color: var(--color-bg);
    border-bottom: 1px solid rgba(79, 91, 69, 0.1);
    
    /* MUST be fixed to work with the JS spacer */
    position: fixed; 
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    
    /* ANIMATION: Smoothly transition height/padding */
    transition: all 0.4s ease; 
}

/* Fix for WordPress Admin Bar overlap */
body.admin-bar .site-header {
    top: 32px;
}
@media screen and (max-width: 782px) {
    body.admin-bar .site-header { top: 46px; }
}

/* SCROLLED STATE */
.site-header.scrolled {
    padding: 10px 0; /* Shrinks the padding */
    
    /* 90% Opacity Background */
    /* RGB values for #F5F3ED are 245, 243, 237 */
    background-color: rgba(245, 243, 237, 0.9); 
    
    /* Blur effect for glass look */
    backdrop-filter: blur(5px);
    
    /* Optional: Keep the shadow for depth */
    box-shadow: 0 4px 20px rgba(0,0,0,0.05); 
}

.header-inner {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
}

/* 1. Nav (Left) */
.main-navigation ul {
    list-style: none;
    display: flex;
    gap: 30px;
    margin: 0;
    padding: 0;
}
.main-navigation a {
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    font-weight: 700;
}

/* 2. Logo (Center) */
.logo {
    text-align: center;
}

/* Standard Logo Size */
.logo img {
    height: 180px; 
    width: auto;
    margin: 0 auto;
    transition: all 0.4s ease;
}

/* Shrunken Logo Size */
.site-header.scrolled .logo img {
    height: 70px; /* Shrinks logo on scroll */
}

/* 3. WhatsApp (Right) */
.header-right {
    text-align: right;
    display: flex;
    justify-content: flex-end;
}
.whatsapp-link {
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--color-text);
    padding-bottom: 2px;
    display: inline-flex;
    align-items: center;
    gap: 8px; 
}
.whatsapp-link:hover {
    border-bottom-color: transparent;
}

/* Blocks: Common */
.section-block { padding: var(--spacing-section); }

/* Hero Block */
.hero-block {
    text-align: center;
    padding: 120px 20px;
    background-size: cover;
    background-position: center;
    position: relative;
}
.hero-content { max-width: 800px; margin: 0 auto; position: relative; z-index: 2; }
.hero-block h1 { font-size: 3.8rem; margin-bottom: 25px; }
.hero-subtitle {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 0.85rem;
    margin-bottom: 20px;
    display: block;
    font-weight: 700;
}
.btn {
    display: inline-block;
    padding: 18px 40px;
    background-color: var(--color-text);
    color: var(--color-white);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.8rem;
    margin-top: 25px;
    border: 1px solid var(--color-text);
}
.btn:hover { background: transparent; color: var(--color-text); }

/* Split Content */
.split-content { display: flex; align-items: center; gap: 80px; }
.split-content.image-right { flex-direction: row-reverse; }
.split-image, .split-text { flex: 1; }
.split-image img { width: 100%; border-radius: 2px; }

/* Feature Grid */
.grid-block-header { text-align: center; margin-bottom: 60px; max-width: 700px; margin-left: auto; margin-right: auto; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 50px; }
.feature-item {
    text-align: center;
    padding: 40px;
    border: 1px solid rgba(79, 91, 69, 0.1);
    background: rgba(255,255,255,0.4);
    transition: 0.3s;
}
.feature-item:hover { background: #fff; box-shadow: 0 10px 30px rgba(0,0,0,0.03); }
.feature-item h3 { font-size: 1.3rem; margin-bottom: 15px; }

/* Blog Single Post Styling */
.single-post-article { padding: 60px 0; }
.entry-header { text-align: center; margin-bottom: 40px; }
.entry-meta {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--color-text-light);
    margin-bottom: 15px;
}
.entry-thumbnail { margin-bottom: 50px; }
.entry-thumbnail img { width: 100%; }

.entry-content p { margin-bottom: 25px; }
.entry-content h2 { margin-top: 50px; margin-bottom: 20px; font-size: 2rem; }
.entry-content h3 { margin-top: 40px; font-size: 1.5rem; }
.entry-content ul, .entry-content ol { margin-bottom: 25px; padding-left: 20px; }
.entry-content li { margin-bottom: 10px; }

.post-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 80px;
    padding-top: 40px;
    border-top: 1px solid rgba(79, 91, 69, 0.1);
}

/* Footer & Footer Menu */
.site-footer {
    background-color: #ECEAE4;
    padding: 80px 0 30px;
    text-align: center;
    margin-top: 80px;
}
.footer-logo { max-width: 180px; margin: 0 auto 40px; }

.footer-menu {
    margin-top: 40px;
    border-top: 1px solid rgba(79, 91, 69, 0.1);
    padding-top: 20px;
}
.footer-menu ul {
    list-style: none !important; 
    padding: 0;
    margin: 0;
    text-align: center;
    display: block; 
}
.footer-menu li {
    display: inline-block; 
    margin: 0;
}
.footer-menu li:not(:last-child)::after {
    content: "|";
    display: inline-block;
    margin: 0 12px; 
    color: var(--color-text-light);
    opacity: 0.5;
    font-weight: 300;
}
.footer-menu a {
    font-size: 0.8rem;
    color: var(--color-text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
}
.footer-menu a:hover {
    color: var(--color-text);
    text-decoration: underline;
}

/* Website Design Credit */
.site-credit {
    margin-top: 25px;
    font-size: 0.75rem;
    color: var(--color-text-light);
    letter-spacing: 0.5px;
    opacity: 0.8;
}
.site-credit a {
    color: var(--color-text-light);
    font-weight: 700;
    text-decoration: none;
}
.site-credit a:hover {
    color: var(--color-text);
    text-decoration: underline;
}

/* Mobile Responsive */
@media (max-width: 900px) {
    .header-inner {
        display: flex;
        flex-direction: column;
        gap: 20px;
    }
    .logo img { height: 90px; }
    .hero-block h1 { font-size: 2.5rem; }
    .split-content { flex-direction: column !important; gap: 40px; }
    
    .footer-menu ul {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }
    .footer-menu li:not(:last-child)::after {
        content: ""; 
        margin: 0;
    }
}