@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&display=swap');

:root {
    --primary-salmon: #C35C44; /* Terracotta secondary */
    --primary-salmon-hover: #A64833; /* Deeper terracotta hover */
    --primary-salmon-dark: #863725; /* High contrast variation */
    --bg-navy: #44403E; /* Charcoal secondary/hover */
    --bg-navy-dark: #2D2926; /* Charcoal neutral base */
    --accent-teal: #87CEEB; /* Sky blue primary */
    --accent-teal-dark: #4EA3BA; /* Deeper sky blue hover */
    --bg-light: #F7F5F0; /* Soft warm cream-white base */
    --bg-white: #FFFFFF;
    --gold: #F3E5AB; /* Soft vanilla gold tertiary */
    --text-dark: #2D2926; /* Charcoal text */
    --text-slate: #5C5856; /* Slate gray neutral */
    --font-display: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;

}

/* Page Transition Animations — navbar stays, content crossfades */
main, footer {
    animation: pageFadeIn 0.45s ease-out forwards;
}

@keyframes pageFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

body.page-exit main,
body.page-exit footer {
    animation: pageFadeOut 0.25s ease-in forwards;
}

@keyframes pageFadeOut {
    from { opacity: 1; }
    to   { opacity: 0; }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5%;
}

.container-wide {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 5%;
}

/* =========================================
   Typography & Accents
 ========================================= */
h1, h2, h3, h4 {
    font-family: var(--font-display);
    color: var(--text-dark);
}

h2 {
    font-size: clamp(2rem, 8vw, 3.5rem);
    margin-bottom: 2rem;
    line-height: 1.1;
    word-break: break-word;
}

em {
    font-style: italic;
    font-weight: 500;
}

em.salmon { color: var(--primary-salmon-dark); }
em.teal { color: var(--accent-teal-dark); }

.eyebrow-container {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.center-eyebrow {
    justify-content: center;
}

.gold-line {
    width: 30px;
    height: 2px;
    background-color: var(--gold);
}

.eyebrow {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 2px;
    color: var(--text-slate);
    text-transform: uppercase;
}

.hero-eyebrow {
    color: var(--primary-salmon); /* Makes it pop on the dark background */
}

/* =========================================
   Buttons
========================================= */
.btn-primary {
    display: inline-block;
    background-color: var(--primary-salmon);
    color: white; /* Changed words to white */
    padding: 0.8rem 1.8rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600; /* Bolder weight for better readability */
    transition: all 0.2s ease-in-out;
    border: none;
    cursor: pointer;
    text-align: center;
}

.btn-primary i {
    color: white; /* Make icon white */
}

.btn-primary:hover {
    background-color: var(--primary-salmon-hover);
    color: white; /* Keep text white on hover */
    transform: translateY(-2px);
}

.btn-glass {
    display: inline-block;
    background-color: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 0.8rem 1.8rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-glass:hover {
    background-color: rgba(255, 255, 255, 0.25);
}

.btn-navy {
    display: inline-block;
    background-color: var(--bg-navy-dark); /* Using new charcoal base */
    color: white;
    padding: 0.8rem 1.8rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-navy:hover {
    background-color: var(--bg-navy);
}

/* Blue button override for dark sections */
.section-navy .btn-primary {
    background-color: var(--accent-teal-dark);
    border-color: var(--accent-teal-dark);
}
.section-navy .btn-primary:hover {
    background-color: var(--accent-teal);
    border-color: var(--accent-teal);
}

.btn-outline {
    display: inline-block;
    background-color: transparent;
    border: 1px solid var(--text-dark);
    color: var(--text-dark);
    padding: 0.8rem 1.8rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-outline:hover {
    background-color: var(--bg-navy-dark);
    color: white;
    border-color: var(--bg-navy-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.w-100 { width: 100%; }

.mobile-text { display: none; }

/* =========================================
   Header & Nav
========================================= */
#floating-logo-trigger {
    display: none;
}

.top-bar {
    background-color: var(--primary-salmon); /* Changed to terracotta */
    color: white;
    position: relative;
    z-index: 2000;
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 5%;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 1px;
    position: relative;
    z-index: 10;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 3rem;
    background: rgba(45, 41, 38, 0.25); /* Translucent charcoal base */
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    position: sticky;
    top: 1rem;
    z-index: 1000;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 100px; /* Rounded pill style */
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25), inset 0 1px 1px rgba(255, 255, 255, 0.15);
    width: 90%;
    max-width: 1200px;
    margin: 1rem auto 0 auto; /* Centered, floating navbar */
    transition: all 0.3s ease;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    text-decoration: none; /* Keep link text clean */
}

.logo-img {
    height: 48px;
    width: auto;
    mix-blend-mode: screen; /* Instantly removes the black background from the uploaded image! */
}

.logo-text-group {
    display: flex;
    flex-direction: column;
}

.logo-main {
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 600;
    color: white;
    line-height: 1.1;
}

.logo-sub {
    font-size: 0.65rem;
    letter-spacing: 2px;
    color: var(--primary-salmon);
    font-weight: 800; /* Extra bold */
}

.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: white; /* Clean white hamburger */
    font-size: 1.8rem;
    cursor: pointer;
    padding: 0.2rem 0.5rem;
    transition: color 0.3s ease;
}
.menu-toggle:active {
    color: var(--primary-salmon);
}
.menu-toggle:focus {
    outline: none;
}

nav.nav-links {
    position: relative;
}

nav.nav-links a {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.9);
    margin: 0 1.2rem;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.3s ease;
    position: relative;
}

nav.nav-links a:hover { color: var(--primary-salmon); }

nav.nav-links a.active-link {
    color: var(--bg-white);
}

/* Sliding indicator bar */
.nav-indicator {
    position: absolute;
    bottom: -6px;
    height: 2px;
    background: var(--primary-salmon);
    transition: left 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 2px;
    pointer-events: none;
}

/* =========================================
   Hero Section
========================================= */
.hero {
    position: relative;
    min-height: 90vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 5%;
    margin-top: -150px; /* Pull hero up to touch the bottom of top-bar */
    padding-top: 150px; /* Push content back down so it doesn't hide under the glass nav */
    overflow: hidden; /* Contains the background video */
    /* Single hero background image — replaces the multi-layer parallax */
    background-image: url('assets/images/hero_spring3.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 75px;
    background: linear-gradient(to bottom, transparent, var(--bg-light));
    z-index: 1;
    pointer-events: none;
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}
/* =========================================
   Hero Layer Animations (DISABLED — layers commented out in HTML for performance)
   To re-enable: uncomment the HTML layers and remove display:none below
 ========================================= */
.hero-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: background-image 1s ease-in-out;
    display: none; /* DISABLED — re-enable by removing this line */
}

.hero-sky {
    z-index: 0;
    background-image: url('assets/images/hero_sky_bg.png');
    background-position: center top;
    display: none; /* DISABLED */
}

.hero-clouds {
    z-index: 2;
    overflow: hidden;
    pointer-events: none;
    display: none; /* DISABLED */
}

/* Clouds setup */
.cloud {
    position: absolute;
    background-size: contain;
    background-repeat: no-repeat;
    opacity: 0.8;
    display: none; /* DISABLED */
}

.cloud-1 {
    top: 15%;
    left: -800px;
    width: 600px;
    height: 300px;
    background-image: url('assets/images/hero_spring_clouds.png');
    animation: none; /* DISABLED — was: drift 80s linear infinite -10s */
}

.cloud-2 {
    top: 25%;
    left: -800px;
    width: 450px;
    height: 225px;
    background-image: url('assets/images/hero_spring_clouds.png');
    animation: none; /* DISABLED — was: drift 110s linear infinite -40s */
    opacity: 0.6;
    transform: scale(0.8);
}

.cloud-3 {
    top: 10%;
    left: -800px;
    width: 500px;
    height: 250px;
    background-image: url('assets/images/cloud_3.png');
    animation: none; /* DISABLED — was: drift 95s linear infinite -25s */
    opacity: 0.75;
    transform: scale(0.9);
}

.cloud-4 {
    top: 35%;
    left: -800px;
    width: 400px;
    height: 200px;
    background-image: url('assets/images/cloud_4.png');
    animation: none; /* DISABLED — was: drift 130s linear infinite -75s */
    opacity: 0.5;
    transform: scale(0.7);
}

@keyframes drift {
    0% { left: -800px; }
    100% { left: 110vw; }
}

.hero-foreground {
    z-index: 4;
    background-position: center 85%;
    transform-origin: bottom center;
    pointer-events: none;
    transition: opacity 1.2s ease-in-out;
    display: none; /* DISABLED */
}

/* Background coordinates containers for tracking background cover size */
.hero-bg-size-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    container-type: size;
    pointer-events: none;
    z-index: 5;
}

.hero-bg-coords {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    
    /* Cover size math based on background image aspect ratio 1691/930 = 1.818279 */
    width: max(100cqw, calc(100cqh * 1.818279));
    height: max(100cqh, calc(100cqw / 1.818279));
}

/* Open Sign */
.hero-open-sign {
    position: absolute;
    /* Move these percentages to precisely place it behind a window */
    top: 64%;  
    left: 60.5%; /* Shifted right further on desktop */
    z-index: 5;
    font-family: 'Outfit', sans-serif;
    text-transform: uppercase;
    font-size: 0.56rem; /* Slightly smaller font */
    font-weight: 700;
    padding: 0.15rem 0.35rem;
    border: 1px solid;
    border-radius: 3px;
    pointer-events: none;
    transition: opacity 0.5s ease;
    opacity: 0.6; /* Base opacity so it renders by default */
    /* 3D Morph: 30deg angle, looking up from below */
    transform: perspective(600px) rotateY(-30deg) rotateX(10deg) scale(0.72); /* Slightly smaller scale */
    mix-blend-mode: screen; /* Makes it look like it's behind glass */
}

.hero-open-sign.open {
    opacity: 0.35; /* Duller to match tinted glass */
    color: #ff3366;
    border-color: #ff3366;
    box-shadow: 0 0 2px #ff3366, inset 0 0 1px #ff3366;
    text-shadow: 0 0 2px #ff3366;
    animation: neon-flicker 4s infinite alternate;
}

.hero-open-sign.closed {
    opacity: 0.6;
    color: #111;
    border-color: #333;
    background: rgba(0,0,0,0.4);
    box-shadow: none;
    text-shadow: none;
    animation: none;
}

@keyframes neon-flicker {
    0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% { opacity: 0.99; }
    20%, 24%, 55% { opacity: 0.4; }
}



.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: none; /* Removed the gradient altogether */
    z-index: 1;
}

.hero-content {
    max-width: 900px;
    margin-top: -14rem; /* Moved higher up in the sky */
    position: relative;
    z-index: 3; /* Behind foreground (which is z-index 4) */
    animation: fadeInUp 1s ease-out;
}

.hero h1 {
    font-size: clamp(3.5rem, 6vw, 5rem); /* Fluid typography scales with screen/zoom perfectly */
    font-weight: 500;
    color: white;
    line-height: 0.9;
    margin-bottom: 1.5rem;
    text-shadow: none; /* Removed legibility boost */
}

.hero h1 em { color: var(--primary-salmon); }

.hero-welcome {
    display: block;
    font-size: 0.55em;
    font-weight: 400;
    line-height: 1.1;
    margin-bottom: 0.5rem;
}

.hero p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.85);
    max-width: 600px;
    margin-bottom: 2.5rem;
    font-weight: 300;
}

.hero-actions {
    display: flex;
    gap: 1.5rem;
    position: relative;
    z-index: 5; /* Keep buttons in front of the building so they are always clickable and visible */
}

.hero-stats {
    display: flex;
    gap: 4rem;
    
    /* Liquid Glass styling */
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(16px) saturate(140%);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    padding: 1.5rem 3rem;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2), inset 0 1px 1px rgba(255, 255, 255, 0.15);
}

.stat-item {
    flex: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    border-right: none;
}

.stat-item:last-child { border-right: none; }

.stat-num {
    font-family: var(--font-display);
    font-size: 2rem;
    color: white;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    min-width: 150px;
}

.stat-num.highlight { color: var(--primary-salmon); }

.word-animate {
    display: inline-block;
    width: 240px; /* Fixed width — fits 'Compounding' so card never jitters */
    text-align: left;
    transition: opacity 0.4s ease, transform 0.4s ease;
}
.word-out {
    opacity: 0;
    transform: translateY(-15px);
}
.word-in {
    opacity: 0;
    transform: translateY(15px);
}

.stat-label {
    font-size: 0.8rem;
    letter-spacing: 2px;
    color: rgba(255,255,255,0.6);
    margin-top: 0.5rem;
}

/* =========================================
   Hero Stats Flip Card
 ========================================= */
.hero-stats-flip {
    position: absolute;
    bottom: 5%;
    right: 5%;
    left: auto;
    z-index: 5;
    perspective: 1000px;
    cursor: pointer;
}

.hero-stats-inner {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    -webkit-transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center center;
}

/* When flipped */
.hero-stats-flip.flipped .hero-stats-inner {
    transform: rotateY(180deg);
}

.hero-stats-front,
.hero-stats-back {
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.hero-stats-front {
    position: relative;
}

.hero-stats-back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: rotateY(180deg);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 0;
    padding: 1rem 1.5rem;
}


/* Quick Refill Form (back face) */
.quick-refill-form {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
}

.quick-input {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 0.55rem 0.75rem;
    color: white;
    font-size: 0.9rem;
    font-family: var(--font-body);
    outline: none;
    transition: background 0.2s ease;
    min-width: 0;
}
.quick-input::placeholder {
    color: rgba(255,255,255,0.4);
}
.quick-input:focus {
    background: rgba(255,255,255,0.18);
}
.quick-name-input {
    flex: 2;
}
.quick-rx-input {
    flex: 1;
}

.quick-submit-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: var(--primary-salmon);
    color: white;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
    flex-shrink: 0;
}
.quick-submit-btn:hover {
    background: var(--primary-salmon-hover);
    transform: scale(1.1);
}

/* Checkmark pop animation inside submit button */
.quick-check-pop {
    animation: successPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes successPop {
    0% { transform: scale(0); opacity: 0; }
    60% { transform: scale(1.4); opacity: 1; }
    100% { transform: scale(1); opacity: 1; }
}

@media (max-width: 1200px) and (min-width: 769px) {
    .hero-stats {
        gap: 2rem;
        padding: 1.2rem 2rem;
    }
    .stat-num {
        font-size: 1.6rem;
        min-width: 110px;
    }
    .word-animate {
        width: 180px;
    }
}

/* =========================================
   Vintage Bottles Marquee
========================================= */
.bottles-marquee-section {
    background-color: var(--bg-navy-dark);
    padding: 0;
    overflow: hidden;
    position: relative;
    border-top: 4px solid var(--text-slate);
    border-bottom: 4px solid var(--text-slate);
}

.bottles-marquee-wrapper {
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    position: relative;
    display: flex;
}

.bottles-marquee-track {
    display: flex;
    width: max-content;
    animation: scroll-bottles 120s linear infinite;
}

.bottles-marquee-track:hover {
    animation-play-state: paused;
}

@keyframes scroll-bottles {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.bottle-img {
    height: clamp(200px, 25vw, 350px);
    width: auto;
    object-fit: cover;
    display: block;
    border-right: 2px solid #111;
}

/* =========================================
   General Sections
========================================= */
.section-light { padding: 8rem 0; background-color: var(--bg-light); }
.section-white { padding: 8rem 0; background-color: var(--bg-white); }
.section-navy { padding: 8rem 0; background-color: var(--bg-navy); color: white; }
.pt-0 { padding-top: 0 !important; }
.pt-safe { padding-top: clamp(100px, 15vh, 140px) !important; }

.section-header.center { text-align: center; }
.header-p { font-size: 1.15rem; color: var(--text-slate); max-width: 1000px; margin: 0 auto 3rem auto; line-height: 1.6; }

/* =========================================
   Services Grid
========================================= */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.service-card {
    background-color: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    padding: 2.2rem;
    border-radius: 12px;
    border: 1px solid rgba(0,0,0,0.05);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease, border-color 0.3s ease; /* Avoid transitioning 'all' to prevent crazy layout jumping on resize */
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.service-card .icon-square {
    flex-shrink: 0;
    margin-bottom: 0;
}

.service-card .card-content {
    display: flex;
    flex-direction: column;
}

.service-card.light-card:hover { 
    transform: translateY(-8px);
    background-color: #ffffff;
    box-shadow: 0 15px 30px -5px rgba(0, 0, 0, 0.1);
}

.service-card.dark-card {
    background-color: var(--bg-navy);
    color: white;
}

.service-card.dark-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px -5px rgba(0, 0, 0, 0.2);
}

.service-card.dark-card h3 { color: white; }
.service-card.dark-card p { color: rgba(255,255,255,0.8); }

.service-card:hover .icon-square {
    background-color: var(--primary-salmon);
    color: white;
    transform: scale(1.05);
}

.teal-bg { background-color: rgba(90, 150, 153, 0.1); color: var(--accent-teal); }
.dark-bg { background-color: rgba(255, 255, 255, 0.1); color: white; }

.service-card h3 { font-size: 1.3rem; margin-bottom: 0.2rem; line-height: 1.3; }
.service-card p { color: var(--text-slate); line-height: 1.8; font-size: 1.1rem; }

/* =========================================
   Specialty Grid
========================================= */
.specialty-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.specialty-card {
    padding: 3rem;
    border-radius: 12px;
    position: relative;
}

.dark-card { background-color: var(--bg-navy); color: white; }
.dark-card h3 { color: white; }
.dark-card p { color: rgba(255,255,255,0.8); }
.dark-card .orange-dot-tag { color: rgba(255,255,255,0.7); }
.dark-card .dot { background-color: var(--primary-salmon); }

.light-card { background-color: var(--bg-white); border: 1px solid rgba(0,0,0,0.05); }

.orange-dot-tag {
    display: inline-flex;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
    align-self: flex-start;
}

.dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--primary-salmon);
    margin-right: 8px;
}

.icon-square {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.orange-bg { background-color: rgba(217, 119, 87, 0.15); color: var(--primary-salmon); }
.blue-bg { background-color: rgba(90, 150, 153, 0.15); color: var(--accent-teal); }

.specialty-card h3 { font-size: 2rem; margin-bottom: 1rem; }
.specialty-card p { line-height: 1.8; font-size: 1.1rem; }

/* =========================================
   Our Story
========================================= */
.story-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.story-text p { font-size: 1.1rem; color: var(--text-slate); margin-bottom: 1.5rem; line-height: 1.8; max-width: 70ch; }

.story-image {
    background: url('assets/images/salmon_state.jpg') center/cover no-repeat;
    height: 500px;
    border-radius: 12px;
}

.compounding-image {
    background: url('assets/images/salmon-compounding.webp') center/cover no-repeat;
    height: 600px;
    border-radius: 12px;
}

/* =========================================
   Compounding & Unit Dosing Lists
========================================= */
.large-p { font-size: 1.1rem; color: var(--text-slate); max-width: 700px; margin-bottom: 3rem; line-height: 1.8; }
.white-p { color: rgba(255,255,255,0.8) !important; }

.check-list { list-style: none; display: flex; flex-direction: column; gap: 1rem; margin-bottom: 3rem; }
.check-list li { display: flex; align-items: flex-start; gap: 1rem; font-size: 1.1rem; color: var(--text-dark); }
.check-list i { color: var(--accent-teal); margin-top: 5px; }

.section-navy h2 { color: white; }
.section-navy .eyebrow { color: rgba(255,255,255,0.6); }

.unit-dosing-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
.unit-card { background-color: rgba(255,255,255,0.05); padding: 2.5rem; border-radius: 12px; border: 1px solid rgba(255,255,255,0.1); }
.unit-card h3 { color: white; font-size: 1.8rem; margin-bottom: 1rem; }
.unit-card p { color: rgba(255,255,255,0.7); line-height: 1.8; font-size: 1.1rem; }

/* =========================================
   Refills
========================================= */
.center-content { text-align: center; max-width: 800px; }
.header-p { font-size: 1.1rem; line-height: 1.8; margin-bottom: 2.5rem; color: var(--text-slate); }
.justify-center { justify-content: center; }

/* =========================================
   Reviews
========================================= */
.reviews-header { text-align: center; }
.reviews-marquee-wrapper {
    overflow: hidden;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    position: relative;
    padding: 1rem 0 3rem 0;
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
}
.reviews-marquee-track {
    display: flex;
    width: max-content;
    animation: scroll-marquee 90s linear infinite;
    gap: 2rem;
    padding: 0 1rem;
}
@keyframes scroll-marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-50% - 1rem)); }
}
.reviews-marquee-wrapper {
    -webkit-overflow-scrolling: touch;
}
@media (max-width: 768px) {
    .reviews-marquee-track {
        animation-duration: 45s;
    }
    .reviews-marquee-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .reviews-marquee-track:active {
        animation-play-state: paused;
    }
}
.review-card { background-color: var(--bg-light); padding: 3rem; border-radius: 12px; width: 450px; flex-shrink: 0; white-space: normal; }
.stars { color: var(--primary-salmon); margin-bottom: 1.5rem; font-size: 1.2rem; }
.review-card p { font-size: 1.1rem; font-style: italic; color: var(--text-slate); margin-bottom: 2rem; line-height: 1.8; display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
.review-author { display: flex; align-items: center; gap: 1rem; }
.author-initial { width: 40px; height: 40px; border-radius: 50%; background-color: var(--bg-navy); color: white; display: flex; align-items: center; justify-content: center; font-weight: 600; }
.author-name { font-weight: 600; color: var(--text-dark); }

/* =========================================
   Contact Form
========================================= */
.contact-split { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.contact-info { max-width: 600px; }
.contact-details { margin-top: 2rem; display: flex; flex-direction: column; gap: 1.2rem; }
.contact-item { display: flex; gap: 1rem; align-items: center; }
.contact-item i { color: var(--accent-teal); font-size: 1.2rem; }
.contact-text-row { font-size: 1.1rem; color: rgba(255,255,255,0.8); line-height: 1.8; }
.contact-text-row strong { color: white; margin-right: 0.5rem; font-weight: 600; }

.contact-form-container { 
    background-color: rgba(255, 255, 255, 0.05); 
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 4rem; 
    border-radius: 12px; 
    max-width: 600px; 
    width: 100%; 
    margin-left: auto; 
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.3); 
}
.contact-form { display: flex; flex-direction: column; gap: 1.5rem; }
.contact-form input, .contact-form textarea { 
    width: 100%; 
    padding: 1.2rem; 
    border: 1px solid rgba(255, 255, 255, 0.2); 
    background-color: rgba(0, 0, 0, 0.2);
    color: white;
    border-radius: 8px; 
    font-family: var(--font-body); 
    font-size: 1.05rem; 
    transition: all 0.3s ease;
}
.contact-form input::placeholder, .contact-form textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}
.contact-form input:focus, .contact-form textarea:focus { 
    outline: none; 
    border-color: var(--primary-salmon); 
    background-color: rgba(0, 0, 0, 0.4);
}

/* =========================================
   Refill Form
========================================= */
.refill-form-container {
    max-width: 700px;
    margin: 0 auto;
    background-color: transparent;
    padding: 1rem 0;
}

.patient-block {
    background-color: var(--bg-white);
    border-radius: 16px;
    padding: 2.5rem;
    margin-bottom: 2rem;
    position: relative;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    transition: transform 0.3s ease;
}

.patient-block:hover {
    transform: translateY(-2px);
}

.patient-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    padding-bottom: 1rem;
}

.patient-header h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-dark);
}

.btn-remove-patient {
    background: none;
    border: none;
    color: var(--text-slate);
    font-size: 1.2rem;
    cursor: pointer;
    transition: color 0.2s;
}

.btn-remove-patient:hover {
    color: #ef4444;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label, .rx-container label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-slate);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.refill-form input {
    width: 100%;
    padding: 1rem 1.25rem;
    border: none;
    background-color: #F1F5F9; /* Clean slate background */
    color: var(--text-dark);
    border-radius: 12px;
    font-family: var(--font-body);
    font-size: 1.05rem;
    transition: all 0.2s ease;
}

.refill-form input:hover {
    background-color: #E2E8F0;
}

.refill-form input:focus {
    outline: none;
    background-color: #FFFFFF;
    box-shadow: 0 0 0 2px var(--accent-teal);
}

/* Distinct placeholders so they don't look like real inputs */
.refill-form input::placeholder {
    color: #9CA3AF;
    font-style: italic;
    opacity: 1;
}

/* Validation styles - when form is submitted but invalid */
.refill-form.was-validated input:invalid {
    box-shadow: 0 0 0 2px #ef4444;
    background-color: #fef2f2;
}

.rx-inputs {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
    margin-top: 0.5rem;
}

.btn-text {
    background: none;
    border: none;
    color: var(--accent-teal);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    transition: color 0.2s;
}

.btn-text:hover {
    color: var(--bg-navy);
}

.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(0,0,0,0.05);
}

/* =========================================
   Rx Tab Bar (Pill Toggle)
========================================= */
.rx-tab-bar {
    display: flex;
    position: relative;
    background-color: #E8E4DF;
    border-radius: 100px;
    padding: 4px;
    margin-bottom: 2rem;
    gap: 4px;
}

.rx-tab {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1.5rem;
    border: none;
    background: transparent;
    color: var(--text-slate);
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 100px;
    position: relative;
    z-index: 2;
    transition: color 0.3s ease;
}

.rx-tab i {
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.rx-tab:hover {
    color: var(--text-dark);
}

.rx-tab.active {
    color: var(--bg-white);
}

.rx-tab.active i {
    color: var(--bg-white);
}

/* Sliding indicator pill behind active tab */
.rx-tab-indicator {
    position: absolute;
    top: 4px;
    bottom: 4px;
    left: 4px;
    width: calc(50% - 6px);
    background-color: var(--primary-salmon);
    border-radius: 100px;
    z-index: 1;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(195, 92, 68, 0.3);
}

/* When transfer tab is active, slide indicator right */
.rx-tab-bar[data-active="transfer"] .rx-tab-indicator {
    transform: translateX(calc(100% + 4px));
}

/* =========================================
   Rx Tab Panels
========================================= */
.rx-tab-panels {
    position: relative;
    overflow: hidden;
}

.rx-tab-panel {
    display: none;
    opacity: 0;
    transform: translateY(12px);
}

.rx-tab-panel.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.rx-tab-panel.entering-left {
    animation: slideInLeft 0.35s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
.rx-tab-panel.entering-right {
    animation: slideInRight 0.35s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-20px); }
    to   { opacity: 1; transform: translateX(0); }
}
@keyframes slideInRight {
    from { opacity: 0; transform: translateX(20px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* =========================================
   Transfer Form Specifics
========================================= */

/* 3-column row for City/State/Zip */
.form-row-3col {
    display: grid;
    grid-template-columns: 2fr 1fr 1.2fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

/* Transfer Type Card Toggle */
.transfer-type-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.toggle-option {
    cursor: pointer;
}

.toggle-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.toggle-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem;
    border-radius: 12px;
    background-color: #F1F5F9;
    border: 2px solid transparent;
    transition: all 0.25s ease;
}

.toggle-card i {
    font-size: 1.3rem;
    color: var(--text-slate);
    flex-shrink: 0;
    transition: color 0.25s ease;
}

.toggle-card strong {
    display: block;
    font-size: 0.95rem;
    color: var(--text-dark);
}

.toggle-card span {
    font-size: 0.8rem;
    color: var(--text-slate);
}

/* Active state: teal border + teal icon */
.toggle-option input:checked + .toggle-card {
    border-color: var(--accent-teal);
    background-color: rgba(135, 206, 235, 0.08);
    box-shadow: 0 0 0 1px var(--accent-teal);
}

.toggle-option input:checked + .toggle-card i {
    color: var(--accent-teal-dark);
}

.toggle-card:hover {
    background-color: #E2E8F0;
}

/* Medication list dynamic section */
.medication-list {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(0,0,0,0.05);
}

.medication-list > label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-slate);
    text-transform: uppercase;
    letter-spacing: 1px;
    display: block;
    margin-bottom: 0.75rem;
}

.medication-inputs {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.medication-input-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.medication-input-group input {
    flex: 1;
}

/* Autocomplete search icon wrapper */
.autocomplete-wrapper {
    position: relative;
}

.autocomplete-wrapper input {
    padding-right: 2.5rem;
}

.autocomplete-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-slate);
    font-size: 0.9rem;
    pointer-events: none;
    opacity: 0.5;
}

/* Pharmacy autocomplete dropdown */
.pharmacy-autocomplete-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background-color: var(--bg-white);
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
    border: 1px solid rgba(0,0,0,0.08);
    max-height: 260px;
    overflow-y: auto;
    z-index: 100;
    padding: 0.5rem;
    
    /* Make scrollbar very obvious */
    scrollbar-width: thin;
    scrollbar-color: var(--primary-salmon) #f1f1f1;
}

.pharmacy-autocomplete-dropdown::-webkit-scrollbar {
    width: 8px;
}
.pharmacy-autocomplete-dropdown::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}
.pharmacy-autocomplete-dropdown::-webkit-scrollbar-thumb {
    background: var(--primary-salmon);
    border-radius: 4px;
}

.pharmacy-autocomplete-item {
    padding: 0.85rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.pharmacy-autocomplete-item:hover {
    background-color: rgba(78, 205, 196, 0.08);
}

.pharmacy-autocomplete-item .pharmacy-result-name {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 0.95rem;
}

.pharmacy-autocomplete-item .pharmacy-result-address {
    font-size: 0.8rem;
    color: var(--text-slate);
    margin-top: 0.2rem;
}

.pharmacy-autocomplete-loading {
    padding: 1rem;
    text-align: center;
    color: var(--text-slate);
    font-size: 0.85rem;
}

/* Date input mobile fix */
.refill-form input[type="date"] {
    max-width: 100%;
    min-width: 0;
    -webkit-appearance: none;
    appearance: none;
}

/* =========================================
   Transfer Print Document
========================================= */
.transfer-print-doc {
    display: none;
}

@media print {
    /* Hide everything except the print document */
    body > *:not(.transfer-print-doc) {
        display: none !important;
    }
    .transfer-print-doc {
        display: block !important;
        padding: 0.5in;
        font-family: 'Inter', Arial, sans-serif;
        font-size: 11pt;
        color: #000;
        line-height: 1.5;
    }
    .transfer-print-doc .print-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        border-bottom: 3px solid #C35C44;
        padding-bottom: 1rem;
        margin-bottom: 1.5rem;
    }
    .transfer-print-doc .print-header .print-logo-title {
        font-family: 'Playfair Display', Georgia, serif;
        font-size: 20pt;
        color: #C35C44;
        margin: 0;
    }
    .transfer-print-doc .print-header .print-subtitle {
        font-size: 9pt;
        color: #666;
        text-transform: uppercase;
        letter-spacing: 2px;
        margin-top: 0.25rem;
    }
    .transfer-print-doc .print-date {
        font-size: 10pt;
        color: #333;
        text-align: right;
    }
    .transfer-print-doc .print-section {
        margin-bottom: 1.25rem;
        padding: 1rem;
        border: 1px solid #ddd;
        border-radius: 6px;
    }
    .transfer-print-doc .print-section-title {
        font-weight: 700;
        font-size: 9pt;
        text-transform: uppercase;
        letter-spacing: 1.5px;
        color: #C35C44;
        margin-bottom: 0.75rem;
        padding-bottom: 0.4rem;
        border-bottom: 1px solid #eee;
    }
    .transfer-print-doc .print-row {
        display: flex;
        gap: 2rem;
        margin-bottom: 0.3rem;
    }
    .transfer-print-doc .print-label {
        font-weight: 600;
        min-width: 120px;
        color: #333;
    }
    .transfer-print-doc .print-value {
        color: #000;
    }
    .transfer-print-doc .print-footer {
        margin-top: 2rem;
        padding-top: 1rem;
        border-top: 1px solid #ddd;
        font-size: 8pt;
        color: #999;
        text-align: center;
    }
    .transfer-print-doc .print-meds-list {
        margin: 0.5rem 0 0 1.5rem;
        padding: 0;
    }
    .transfer-print-doc .print-meds-list li {
        margin-bottom: 0.3rem;
    }
}

.hidden {
    display: none !important;
}

/* =========================================
   Footer
========================================= */
.footer { background-color: var(--bg-navy-dark); padding: 4rem 0; color: rgba(255,255,255,0.6); }
.footer-split { display: flex; justify-content: space-between; align-items: center; }
.footer-left .logo { margin-bottom: 1rem; }
.socials a { color: white; font-size: 1.5rem; margin-left: 1.5rem; transition: color 0.3s; }
.socials a:hover { color: var(--primary-salmon); }

/* =========================================
   Mobile
========================================= */
@media (max-width: 900px) {
    .top-bar { 
        display: none !important; /* Remove terracotta bar on mobile entirely */
    }
    .menu-toggle { display: flex; }
    
    .navbar {
        position: fixed; /* Removes from document flow so sky goes to very top */
        z-index: 2000;
        height: 60px; /* Force exact same height in both states */
        width: 60px;
        padding: 0 13px; /* Centers the 34px image inside the 60px width */
        border-radius: 24px; /* Rounded square to seamlessly expand into rounded rect */
        margin-left: calc(100% - 60px - 5%); /* Anchor to the right */
        margin-right: 5%;
        top: 1rem;
        overflow: hidden;
        cursor: pointer;
        /* The transition animates the width expansion and position from right to left */
        transition: width 0.5s cubic-bezier(0.2, 0.8, 0.2, 1), margin-left 0.5s cubic-bezier(0.2, 0.8, 0.2, 1), padding 0.5s ease, border-radius 0.5s ease;
    }
    body.nav-expanded .navbar {
        width: 92%;
        margin-left: 4%;
        margin-right: 4%;
        padding: 0 1.5rem; /* Standard horizontal padding */
        border-radius: 24px;
        cursor: default;
        overflow: visible; /* Allows the hamburger dropdown to break out of the navbar bounds */
    }
    .navbar .logo-text-group, .navbar .menu-toggle {
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease 0.2s, visibility 0.3s ease 0.2s; /* Fade in after width expands */
        white-space: nowrap; /* Prevent wrapping during animation */
    }
    body.nav-expanded .navbar .logo-text-group, body.nav-expanded .navbar .menu-toggle {
        opacity: 1;
        visibility: visible;
        transition: opacity 0.3s ease, visibility 0.3s ease;
    }
    .logo-img {
        width: 34px; /* Slightly smaller to fit in the 50px pill */
        height: auto; /* Fix squished aspect ratio */
        margin: 0;
        transition: width 0.3s ease;
    }
    body.nav-expanded .logo-img {
        width: 44px; /* Standard size when expanded */
    }
    
    nav.nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: calc(100% + 10px);
        left: 0;
        width: 100%;
        background-color: rgba(45, 41, 38, 0.95); /* Charcoal glass mobile background */
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255, 255, 255, 0.15);
        border-radius: 20px;
        box-shadow: 0 10px 40px rgba(0,0,0,0.3);
        max-height: 0;
        overflow: hidden;
        opacity: 0; /* Hides the border completely when closed */
        pointer-events: none;
        transition: max-height 0.3s ease, opacity 0.3s ease;
    }
    
    nav.nav-links.active {
        max-height: 500px;
        padding: 1rem;
        opacity: 1;
        pointer-events: auto;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }

    nav.nav-links a {
        margin: 0.3rem 0;
        padding: 0.8rem 1.5rem;
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.03);
        border: 1px solid rgba(255, 255, 255, 0.05);
        text-align: center;
        transition: all 0.3s ease;
    }

    nav.nav-links a:hover, nav.nav-links a.active-link {
        background: rgba(195, 92, 68, 0.2); /* Terracotta glass hint */
        border-color: rgba(195, 92, 68, 0.4);
        color: white;
    }
    
    .story-split, .check-list, .unit-dosing-grid, .reviews-grid, .contact-split {
        grid-template-columns: 1fr;
    }
    
    .services-grid {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 1.5rem;
        padding-bottom: 1rem;
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE/Edge */
    }
    
    .services-grid::-webkit-scrollbar {
        display: none; /* Chrome/Safari/Opera */
    }

    /* Disable reveal animations for carousel items so they don't delay-load when swiping */
    .services-grid > * {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
        animation: none !important;
    }
    
    .carousel-indicators {
        display: flex;
        justify-content: center;
        width: 100%;
        gap: 8px;
        margin-top: 0.5rem;
        margin-bottom: 1rem;
    }
    
    .carousel-dot {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background-color: rgba(217, 119, 87, 0.2);
        transition: all 0.3s ease;
    }
    
    .carousel-dot.active {
        background-color: var(--primary-salmon);
        width: 24px;
        border-radius: 4px;
    }
    
    .service-card {
        flex: 0 0 85vw;
        scroll-snap-align: center;
        flex-direction: row; /* Keep icon on the left on mobile */
        padding: 1.5rem; /* Slightly less padding on mobile to give text room */
    }
    
    .contact-form-container { 
        padding: 2rem; 
    }
    .refill-form-container {
        padding: 1.5rem;
    }
    .patient-block {
        padding: 1.5rem;
    }
    .form-row {
        grid-template-columns: 1fr;
    }
    .form-actions {
        flex-direction: column;
        gap: 1rem;
    }
    .form-actions button {
        width: 100%;
        justify-content: center;
    }
    .form-row-3col {
        grid-template-columns: 1fr;
    }
    .transfer-type-toggle {
        grid-template-columns: 1fr;
    }
    .refill-form input[type="date"] {
        font-size: 0.9rem;
        padding: 0.85rem 0.75rem;
    }

    .hero { 
        margin-top: 0; 
        justify-content: flex-start; /* Break out of vertical centering */
        padding-top: 50px; /* Pushed up higher, sitting adjacent to the navbar pill */
        background-position: 60% 80%; /* Shifted right so building sign isn't cut off, image pushed down */
    }
    .hero-bg-coords {
        left: 60%;
        top: 80%;
        transform: translate(-60%, -80%);
    }
    .hero-open-sign {
        font-size: 0.5rem; /* Slightly smaller on mobile */
        padding: 0.12rem 0.3rem;
        transform: perspective(600px) rotateY(-30deg) rotateX(10deg) scale(0.68); /* Slightly smaller on mobile */
    }

    /* Subtle dark gradient wash over the top portion for text readability */
    .hero::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 60%;
        background: linear-gradient(to bottom, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.25) 50%, transparent 100%);
        z-index: 1;
        pointer-events: none;
    }
    .hero-content { 
        margin-top: 0;
        z-index: 3;
    }
    /* White text on mobile to contrast against the dark gradient */
    .hero h1 { color: #fff !important; font-size: clamp(2.5rem, 11vw, 4rem); line-height: 1; }
    .hero p { color: rgba(255,255,255,0.9) !important; }
    .hero-content .eyebrow-container {
        display: none; /* Hide family owned text on mobile */
    }
    .hero-foreground {
        background-size: 250% auto;
        background-position: center bottom;
    }
    
    #compounding .compounding-image {
        order: 2;
        margin-top: 1.5rem;
        width: 100%;
    }
    #compounding .compounding-content {
        order: 1;
    }
    
    .bottles-marquee-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .bottles-marquee-wrapper::-webkit-scrollbar {
        display: none;
    }
    .bottles-marquee-track {
        animation: none !important;
    }
    .bottles-marquee-track:active {
        animation-play-state: paused;
    }
    .hero-stats-flip {
        position: absolute;
        bottom: 1.5rem;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        width: calc(100% - 2rem);
        max-width: 420px;
    }
    .hero-stats { 
        white-space: nowrap;
        gap: 0.5rem;
        padding: 0.8rem 0.6rem;
        width: 100%;
        box-sizing: border-box;
        justify-content: space-evenly;
    }
    .hero-stats-back {
        padding: 0.8rem 1rem;
        box-sizing: border-box;
    }
    .hero-stats .stat-item {
        flex: 1;
        min-width: 0;
        align-items: center;
        text-align: center;
    }
    .hero-stats .stat-num {
        font-size: 1.1rem;
        min-width: 0;
    }
    .hero-stats .stat-label {
        font-size: 0.55rem;
        letter-spacing: 1px;
    }
    .word-animate {
        width: 115px;
        min-width: 115px;
        text-align: center;
    }
    .footer-split { flex-direction: column; text-align: center; gap: 2rem; }
    .socials a { margin: 0 0.75rem; }

    /* Reduce vertical padding on mobile */
    .section-light, .section-white, .section-navy {
        padding: 3rem 0;
    }
    
    .pt-safe {
        padding-top: 2rem !important; /* Tighter gap below the navbar on mobile */
    }
}

/* =========================================
   Scroll Animations
========================================= */
.reveal-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal-fade {
    opacity: 0;
    transition: opacity 1s ease-out;
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.8s ease-out, transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.delay-100 { transition-delay: 100ms; }
.delay-200 { transition-delay: 200ms; }
.delay-300 { transition-delay: 300ms; }
.delay-400 { transition-delay: 400ms; }
.delay-500 { transition-delay: 500ms; }
.delay-600 { transition-delay: 600ms; }

/* Device Visibility Helpers */
.mobile-only { display: none !important; }
@media (max-width: 768px) {
    main {
        display: flex;
        flex-direction: column;
    }
    #home { order: 1; }
    #services { order: 2; }
    #our-story { order: 3; }
    #museum-container { order: 4; }
    #compounding { order: 5; }
    #unit-dosing { order: 6; }
    #reviews { order: 7; }
    #refills { order: 8; }
    #contact { order: 9; }

    .mobile-only { display: inline-flex !important; }
    .desktop-only { display: none !important; }
    
    .desktop-text { display: none; }
    .mobile-text { display: inline; }
    
    .hero .hero-actions {
        position: absolute;
        bottom: 9rem; /* Sit well above the stats card */
        left: 0;
        width: 100%;
        padding: 0 5%;
        flex-direction: row;
        justify-content: center;
        gap: 8rem;
        z-index: 10;
    }
    .hero .hero-actions a.hero-round-btn {
        flex: none;
        width: 64px;
        height: 64px;
        border-radius: 50%;
        padding: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        font-size: 1.4rem;
        position: relative;
        box-shadow: 0 4px 16px rgba(0,0,0,0.25);
    }
    .hero-btn-label {
        position: absolute;
        bottom: -1.4rem;
        left: 50%;
        transform: translateX(-50%);
        font-size: 0.65rem;
        font-weight: 600;
        letter-spacing: 1px;
        text-transform: uppercase;
        color: white;
        white-space: nowrap;
        text-shadow: 0 1px 4px rgba(0,0,0,0.5);
    }
}

/* =========================================
   Adaptive Gallery (Compounding Page)
========================================= */
.adaptive-gallery {
    display: flex;
    height: 65vh;
    min-height: 400px;
    gap: 1rem;
    width: 100%;
}

.adaptive-item {
    flex: 1;
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    transition: flex 0.6s cubic-bezier(0.25, 1, 0.5, 1), height 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    cursor: pointer;
}

.adaptive-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.adaptive-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.adaptive-overlay h3 {
    color: white;
    font-size: 1.5rem;
    margin: 0;
    margin-bottom: 0.25rem;
}

.adaptive-overlay p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    margin: 0;
    line-height: 1.4;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.adaptive-item.active .adaptive-overlay {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s ease 0.4s, transform 0.4s ease 0.4s;
}

.adaptive-item.active .adaptive-overlay p {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s ease 0.5s, transform 0.4s ease 0.5s;
}

.adaptive-item.active {
    flex: 2;
}

.adaptive-item.active img {
    transform: scale(1.05);
}

/* Desktop-only vertical titles and smooth transitions */
@media (min-width: 901px) {
    .adaptive-overlay {
        height: 100%;
        opacity: 1;
        transform: none;
        background: transparent;
        transition: background 0.6s ease;
        padding: 0;
    }

    /* Subtle background overlay when collapsed */
    .adaptive-item:not(.active) .adaptive-overlay,
    .adaptive-item:not(.active):hover .adaptive-overlay {
        background: transparent;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    /* Dark gradient at the bottom when active */
    .adaptive-item.active .adaptive-overlay {
        background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.4) 20%, transparent 35%);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .adaptive-overlay h3 {
        position: absolute;
        margin: 0;
        white-space: nowrap;
        text-shadow: none;
        transition: transform 1.3s cubic-bezier(0.25, 1, 0.5, 1) 0.15s;
        color: var(--bg-light);
        font-family: 'Bebas Neue', sans-serif;
        font-size: 4.5rem;
        font-weight: 400;
        -webkit-text-stroke: 1.5px var(--bg-light);
        letter-spacing: 1.5px;
        text-transform: uppercase;
    }

    /* Collapsed (vertical reading) title at bottom-left */
    .adaptive-item:not(.active) .adaptive-overlay h3 {
        bottom: 2rem;
        left: calc(1em + 0.5rem);
        top: auto;
        transform: rotate(-90deg);
        transform-origin: left bottom;
        opacity: 1;
    }

    /* Expanded (hidden) title at bottom-left */
    .adaptive-item.active .adaptive-overlay h3 {
        bottom: 2rem;
        left: calc(1em + 0.5rem);
        top: auto;
        transform: rotate(-90deg) translateY(-150%);
        transform-origin: left bottom;
        opacity: 1;
        pointer-events: none;
        transition: transform 2.2s cubic-bezier(0.25, 1, 0.5, 1) 0s;
    }

    .adaptive-overlay p {
        position: absolute;
        bottom: 2rem;
        left: 2rem;
        right: 2rem;
        margin: 0;
        opacity: 0;
        transform: translateY(15px);
        transition: opacity 0.15s ease 0s, transform 0.15s ease 0s;
        text-shadow: 0 1px 3px rgba(0,0,0,0.5);
    }

    .adaptive-item.active .adaptive-overlay p {
        opacity: 1;
        transform: translateY(0);
        transition: opacity 0.35s ease 0.55s, transform 0.35s ease 0.55s;
    }
}



@media (max-width: 900px) {
    .adaptive-gallery {
        flex-direction: column;
        height: auto;
    }
    .adaptive-item {
        flex: none;
        height: 18vh !important;
        opacity: 0.6;
        transition: opacity 0.4s ease, transform 0.4s ease, height 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    }
    .adaptive-item.active {
        flex: none;
        height: 45vh !important; /* Expands accordion vertically on mobile */
        opacity: 1;
        transform: scale(1.02);
    }
}

/* =========================================
   Skeleton Loading System
========================================= */
.service-card,
.unit-card,
.story-image,
.compounding-image,
.adaptive-item {
    position: relative;
    overflow: hidden;
}

.skeleton-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--bg-white);
    z-index: 10;
    display: flex;
    padding: 2.2rem;
    gap: 1rem;
    align-items: flex-start;
    border-radius: inherit;
    transition: opacity 0.4s ease, visibility 0.4s ease;
    pointer-events: none; /* Do not intercept pointer events during transition */
}

/* Dark card skeleton background override */
.service-card.dark-card .skeleton-overlay,
.unit-card .skeleton-overlay {
    background-color: var(--bg-navy);
}

.skeleton-overlay.fade-out {
    opacity: 0;
    visibility: hidden;
}

.skeleton-shimmer {
    position: relative;
    overflow: hidden;
    background-color: #E2E8F0;
    border-radius: 6px;
}

.service-card.dark-card .skeleton-shimmer,
.unit-card .skeleton-shimmer {
    background-color: rgba(255, 255, 255, 0.1);
}

.skeleton-shimmer::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    transform: translateX(-100%);
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 20%,
        rgba(255, 255, 255, 0.5) 60%,
        rgba(255, 255, 255, 0) 100%
    );
    animation: shimmer 1.5s infinite;
}

/* Darker shimmer for dark elements */
.service-card.dark-card .skeleton-shimmer::after,
.unit-card .skeleton-shimmer::after {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.15) 20%,
        rgba(255, 255, 255, 0.25) 60%,
        rgba(255, 255, 255, 0) 100%
    );
}

@keyframes shimmer {
    100% {
        transform: translateX(100%);
    }
}

.skeleton-circle {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    flex-shrink: 0;
}

.skeleton-content-block {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    flex-grow: 1;
}

.skeleton-text {
    height: 14px;
    width: 100%;
}

.skeleton-text.title {
    height: 18px;
    width: 60%;
    margin-bottom: 0.4rem;
}

.skeleton-text.short {
    width: 45%;
}

.skeleton-image-full {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    border-radius: inherit;
    z-index: 10;
    transition: opacity 0.4s ease, visibility 0.4s ease;
    pointer-events: none;
}

.skeleton-image-full.fade-out {
    opacity: 0;
    visibility: hidden;
}

/* Focus styles for keyboard navigation */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--accent-teal-dark);
    outline-offset: 4px;
}

/* Screen Reader & Honeypot visual hiding utility */
.sr-only-honeypot {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

/* =========================================
   Image Comparison Slider
========================================= */
.image-compare-container {
    position: relative;
    overflow: hidden;
    height: 500px;
    border-radius: 12px;
}

.story-image.image-compare-container {
    background: none; 
}

.image-compare-base,
.image-compare-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 12px;
}

.image-compare-overlay {
    width: 100%;
    height: 100%;
    clip-path: polygon(0 0, 80% 0, 80% 100%, 0 100%); /* Initial state */
}

.image-compare-range {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: ew-resize;
    z-index: 20;
    margin: 0;
}

.image-compare-handle {
    position: absolute;
    top: 0;
    left: 80%;
    width: 2px;
    height: 100%;
    background-color: #fff;
    box-shadow: 0 0 10px rgba(0,0,0,0.5);
    z-index: 15;
    pointer-events: none;
    transform: translateX(-50%);
}

.image-compare-arrows {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background-color: var(--teal);
    color: white;
    border: 2px solid white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 0 4px;
    font-size: 0.9rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* =========================================
   Compounding Page Enhancements
========================================= */

/* Specialties Grid */
.specialties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.specialty-card {
    background: var(--bg-white);
    padding: 2.5rem 2rem;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    border: 1px solid rgba(0,0,0,0.03);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.specialty-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.06);
}

.specialty-card h3 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.specialty-card p {
    color: var(--text-slate);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

/* Process Timeline */
.process-timeline {
    display: flex;
    justify-content: space-between;
    gap: 2rem;
    position: relative;
}

.process-timeline::before {
    content: '';
    position: absolute;
    top: 24px;
    left: 0;
    right: 0;
    height: 2px;
    background: rgba(0,0,0,0.05);
    z-index: 1;
}

.timeline-step {
    flex: 1;
    position: relative;
    z-index: 2;
    padding-top: 4rem;
}

.step-number {
    width: 50px;
    height: 50px;
    background: var(--primary-salmon);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    position: absolute;
    top: 0;
    left: 0;
}

.timeline-step h3 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.timeline-step p {
    color: var(--text-slate);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

@media (max-width: 768px) {
    .process-timeline {
        flex-direction: column;
        gap: 3rem;
    }
    .process-timeline::before {
        top: 0;
        bottom: 0;
        left: 24px;
        width: 2px;
        height: auto;
        right: auto;
    }
    .timeline-step {
        padding-top: 0;
        padding-left: 5rem;
    }
    .step-number {
        left: 0;
        top: 0;
    }
}

/* Provider Section */
.btn-outline-light {
    display: inline-block;
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.8);
    color: white;
    padding: 0.8rem 1.8rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-outline-light:hover {
    background-color: white;
    color: var(--bg-navy-dark);
}

/* Responsive CTA display */
@media (max-width: 768px) {
    .desktop-contact {
        display: none !important;
    }
    .mobile-contact {
        display: inline-block !important;
    }
}

