/* Google Fonts (Lora 400, Cinzel, Source Sans Pro 900) imported in HTML head for better performance */
/* CRITICAL TEXT ALIGNMENT FIX v3.0 - Last updated: 2024-12-19 */
/* Forces left alignment to prevent justification issues */

/* IMMEDIATE FIX: Override all text alignment globally */
* {
    text-align: left !important;
}

/* Reset specific elements that need different alignment */
.align-center, .text-center, #intro, #intro p, 
.post.featured .major h1, .post.featured .major h2, 
.post.featured .major h2 a, header.major, 
section.special, article.special,
#header, #header .logo, #copyright {
    text-align: center !important;
}

.align-right, .text-right {
    text-align: right !important;
}

/* Font styling - Lora 400 for body text only, headings remain as Cinzel */
body, p, input, select, textarea {
    font-family: "Lora", Georgia, "Times New Roman", serif;
    font-weight: 400;
}

/* Speed up initial page fade-in overlay */
#wrapper.fade-in:before {
    -moz-transition: opacity 0.15s ease-in-out !important;
    -webkit-transition: opacity 0.15s ease-in-out !important;
    -ms-transition: opacity 0.15s ease-in-out !important;
    transition: opacity 0.15s ease-in-out !important;
    -moz-transition-delay: 0s !important;
    -webkit-transition-delay: 0s !important;
    -ms-transition-delay: 0s !important;
    transition-delay: 0s !important;
}

h1, h2, h3, h4, h5, h6,
.post.featured h2 a,
#header .logo,
#footer h3, 
#nav ul.links li a {
    font-family: 'Cinzel', serif;
}

/* For JS-detected uppercase text */
.cinzel-font {
    font-family: 'Cinzel', serif !important;
    font-weight: 500;
}

/* Custom CSS to override the background image */
#wrapper > .bg {
    background-image: url("../../images/overlay.png"), linear-gradient(0deg, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.1)), url("../../images/hero_final.jpeg") !important;
}

/* Control the spacing between logo and content */
#intro img {
    margin-bottom: 0.2rem !important; /* Reduce logo bottom margin from 1em */
}

#intro .actions {
    margin-top: 0.5rem !important;
    margin-bottom: 0rem !important;
}

#main {
    margin-top: 5vh !important; /* Set exact 5vh gap for desktop */
}

/* Reset navigation to original style */
#nav {
    background: transparent !important;
    transition: background-color 0.3s ease-in-out;
}

/* Reset footer to original style */
#footer {
    background: #3B7791 !important; /* Deep Ocean Blue - Primary brand color */
}

/* Custom logo adjustments */
.logo img {
    height: 4.55em;
    vertical-align: middle;
}

/* Remove the banner and fix nav appearance */
#intro {
    /* Reset any overrides and let the original template behavior work */
    background: transparent !important;
}

/* Override body background so it doesn't affect the scroll appearance */
body {
    background-color: transparent !important;
}

/* Make footer labels and text white */
#footer label, 
#footer h3, 
#footer p, 
#footer .icons .label,
#footer a {
    color: #ffffff !important;
}

/* Make the send message button white */
#footer input[type="submit"] {
    background-color: #4E96B6 !important; /* Sky Blue - Approved palette */
    color: #ffffff !important; /* Changed to white for contrast */
    border-color: #4E96B6 !important;
}

#footer input[type="submit"]:hover {
    background-color: #ffffff !important;
    color: #4E96B6 !important;
}

/* Enhanced mobile background image handling */
@media screen and (max-width: 736px) {
    #wrapper > .bg {
        background-size: auto, auto, cover !important;
        background-position: center, center, center 30% !important;
    }
}

@media screen and (max-width: 480px) {
    #wrapper > .bg {
        background-position: center, center, center 25% !important;
    }
}

/* For landscape mobile devices */
@media screen and (max-width: 736px) and (orientation: landscape) {
    #wrapper > .bg {
        background-size: auto, auto, 100% auto !important;
        background-position: center, center, center center !important;
    }
}

/* Reduce intro heights for better UX across all screen sizes */
/* Desktop and larger screens */
@media screen and (min-width: 981px) {
    #intro {
        min-height: 20vh !important; /* Much smaller intro */
        padding: 2rem 4rem 1rem 4rem !important; /* Aggressive override of template's 8rem 4rem 6rem 4rem */
        justify-content: flex-start !important; /* Override template's flex-end */
        align-items: center !important; /* Center horizontally */
    }
    
    #intro + #header {
        margin-top: 0rem !important; /* Override template's -20rem */
    }
    
    /* Force main content to start right after intro */
    #main {
        margin-top: 5vh !important; /* Exact 5vh gap */
    }
}

@media screen and (max-width: 980px) {
    #intro {
        min-height: 19vh !important; /* Compact for tablets */
        padding: 2rem 4rem 1rem 4rem !important; /* Override template padding */
        justify-content: flex-start !important; /* Override template's flex-end */
        align-items: center !important; /* Center horizontally */
    }
    
    #intro + #header {
        margin-top: 0rem !important; /* Override template's negative margin */
    }
    
    #main {
        margin-top: 4.5vh !important; /* Scaled gap */
    }
}

@media screen and (max-width: 736px) {
    #intro {
        min-height: 18vh !important; /* Compact for mobile */
        padding: 2rem 2rem 1rem 2rem !important; /* Override template padding */
        justify-content: flex-start !important; /* Override template's flex-end */
        align-items: center !important; /* Center horizontally */
    }
    
    #intro + #header {
        margin-top: 0rem !important; /* Override template's negative margin */
    }
    
    #main {
        margin-top: 4vh !important; /* Scaled gap for mobile */
    }
}

@media screen and (max-width: 480px) {
    #intro {
        min-height: 17vh !important; /* Very compact for small mobile */
        padding: 2rem 1.5rem 1rem 1.5rem !important; /* Override template padding */
        justify-content: flex-start !important; /* Override template's flex-end */
        align-items: center !important; /* Center horizontally */
    }
    
    #intro + #header {
        margin-top: 0rem !important; /* Override template's negative margin */
    }
    
    #main {
        margin-top: 3.5vh !important; /* Scaled gap for small mobile */
    }
}

/* Better logo sizing for mobile */
@media screen and (max-width: 736px) {
    #intro img {
        max-width: 35% !important; /* Increase from 20% to 35% */
        margin-bottom: 1.5em !important;
    }
    
    #header .logo img {
        height: 3.64em !important; /* Proportionally scaled mobile header logo */
    }
}

@media screen and (max-width: 480px) {
    #intro img {
        max-width: 45% !important;
    }
}

/* Better touch targets for mobile */
@media screen and (max-width: 736px) {
    #intro .button {
        padding: 1rem 2rem !important;
        font-size: 1.1rem !important;
        min-height: 44px; /* iOS recommended touch target */
    }
    
    #nav ul.links li a {
        padding: 1rem !important;
        min-height: 44px;
        display: flex;
        align-items: center;
    }
}

/* Optimize content spacing for mobile */
@media screen and (max-width: 736px) {
    #main > * {
        padding: 1.5rem 2rem 0.1rem 2rem !important; /* Reduce from 2rem */
    }
    
    #main > .posts > * {
        padding: 1.5rem !important; /* Reduce from 2rem */
    }
    
    .post.featured {
        margin-bottom: 2rem !important;
    }
}

@media screen and (max-width: 480px) {
    #main > * {
        padding: 1rem 1.5rem 0.1rem 1.5rem !important;
    }
    
    #main > .posts > * {
        padding: 1rem !important;
    }
}

/* Better typography scaling for mobile readability */
@media screen and (max-width: 736px) {
    #intro h1 {
        font-size: 2.5rem !important; /* Further reduce from 3.25rem */
        line-height: 1.2 !important;
        margin-bottom: 1rem !important;
    }
    
    .post.featured h2 {
        font-size: 2rem !important;
        line-height: 1.3 !important;
    }
    
    .post.featured p {
        font-size: 1.1rem !important;
        line-height: 1.6 !important;
    }
}

/* Mobile - let original template handle header behavior, just fix the intro heights */

/* Make social icons white */
#footer .icons a:before,
#footer .icons.alt a:before {
    color: #ffffff !important;
}

/* Make "Advanced Nano-Hydroxyapatite Toothpaste" black */
.post.featured h2 a {
    color: #000000 !important;
}

/* Change copyright background to brand teal */
#copyright {
    background-color: #3B7791 !important;
    color: #ffffff !important;
}

/* Form input text color */
#footer input[type="text"],
#footer input[type="password"],
#footer input[type="email"],
#footer select,
#footer textarea {
    color: #ffffff !important;
}

#footer input::placeholder,
#footer textarea::placeholder {
    color: rgba(255, 255, 255, 0.7) !important;
}

#footer form label {
    color: #ffffff !important;
}

/* Responsive Typography - Override inline 150% font-size more intelligently */
/* Desktop - keep the 150% scaling */
@media screen and (min-width: 981px) {
    p, .post p, .post .content p {
        font-size: 150% !important;
        line-height: 1.6 !important;
    }
}

/* Tablet - moderate scaling */
@media screen and (max-width: 980px) and (min-width: 737px) {
    p, .post p, .post .content p {
        font-size: 130% !important;
        line-height: 1.5 !important;
    }
}

/* Mobile - prevent text overflow while maintaining readability */
@media screen and (max-width: 736px) {
    p, .post p, .post .content p {
        font-size: 110% !important;
        line-height: 1.5 !important;
    }
    
    /* Featured post needs special handling */
    .post.featured p {
        font-size: 115% !important;
        line-height: 1.6 !important;
        margin-bottom: 1.5rem !important;
    }
    
    /* Ensure headings don't get too large */
    .post.featured h2 {
        font-size: 1.8rem !important;
        line-height: 1.3 !important;
    }
}

/* Small mobile - most conservative scaling */
@media screen and (max-width: 480px) {
    p, .post p, .post .content p {
        font-size: 105% !important;
        line-height: 1.4 !important;
    }
    
    .post.featured p {
        font-size: 108% !important;
        line-height: 1.5 !important;
    }
    
    /* Improve button touch targets */
    .button, .actions .button {
        min-height: 48px !important;
        padding: 0.8rem 1.5rem !important;
        font-size: 0.9rem !important;
    }
    
    /* Enhanced image responsiveness */
    .image.main img,
    .image.fit img,
    .post .image img {
        width: 100% !important;
        height: auto !important;
        border-radius: 0.5rem;
    }
    
    /* Better content spacing */
    .post header.major h1,
    .post header.major h2 {
        margin-bottom: 1.5rem !important;
    }
    
    .post header.major p {
        margin-bottom: 2rem !important;
    }
}

/* Text justification and styling fixes for research pages - CRITICAL: Always left-align text */
.post p, .post .content p, .post ul, .post ol, .box p,
p, body p, main p, article p, section p, 
#main p, #main .post p, #main article p, #main section p {
    text-align: left !important;
    font-style: normal !important; /* Remove any italic styling */
    /* Force cache refresh - updated alignment - Version 2.1 */
}

/* More specific override for justified text */
#main .post p, #main .post .content p, #main .post ul, #main .post ol, #main .box p {
    text-align: left !important;
}

/* Ensure headings and other elements remain properly aligned */
.post h1, .post h2, .post h3, .post h4, .post h5, .post h6 {
    text-align: left !important;
}

/* Mobile Performance Optimizations */
@media screen and (max-width: 736px) {    
    /* Disable parallax on mobile for better performance */
    .bg {
        background-attachment: scroll !important;
    }
    
    /* Reduce animations for better performance */
    * {
        animation-duration: 0.2s !important;
        transition-duration: 0.2s !important;
    }
    
    /* Enhanced form elements for mobile */
    input[type="text"],
    input[type="password"],
    input[type="email"],
    input[type="tel"],
    select,
    textarea {
        font-size: 16px !important; /* Prevent zoom on iOS */
        min-height: 48px !important;
        padding: 0.8rem 1rem !important;
        border-radius: 0.5rem !important;
    }
    
    /* Better list styling */
    .post ul, .post ol {
        padding-left: 1.5rem !important;
        margin: 1rem 0 !important;
    }
    
    .post li {
        margin-bottom: 0.5rem !important;
        line-height: 1.6 !important;
    }
    
    /* Enhanced card styling for mobile */
    .box, article {
        margin-bottom: 2rem !important;
        padding: 1.5rem !important;
        border-radius: 1rem !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
    }
    
    /* Better navigation link spacing */
    #nav ul.links li a {
        padding: 1rem 1.5rem !important;
        font-size: 1rem !important;
        line-height: 1.4 !important;
    }
}

/* Responsive main content margins for consistent 5vh-scaled gaps */
@media screen and (max-width: 980px) {
    #main {
        margin-top: 4.5vh !important; /* Scaled for tablets */
    }
}

@media screen and (max-width: 736px) {
    #main {
        margin-top: 4vh !important; /* Scaled for mobile */
    }
}

@media screen and (max-width: 480px) {
    #main {
        margin-top: 3.5vh !important; /* Scaled for small mobile */
    }
}

/* Center justify main headings */
.post .major h1, 
.post.featured .major h2,
.post.featured .major h2 a {
    text-align: center !important;
}

/* Join main content with copyright section - remove gap */
#main {
    margin-bottom: 0 !important;
}

#copyright {
    margin-top: 0 !important;
    border-top: none !important;
} 

		/* Ensure Buy Now button is visible and styled correctly */
		.buy-now-desktop .button.primary {
			background: #ffffff !important;
			color: #3B7791 !important;
			border: none !important;
			padding: 0.6rem 1.8rem !important;
			border-radius: 2rem !important;
			display: flex !important;
			align-items: center !important;
			justify-content: center !important;
			text-align: center !important; /* Added center justification */
			line-height: 1.2 !important; /* Adjusted line height for better vertical centering if wrapping occurs */
			font-weight: 800 !important;
			box-shadow: 0 4px 15px rgba(255, 255, 255, 0.5), 0 2px 5px rgba(0,0,0,0.1) !important;
			animation: pulse-white 2s infinite !important;
			-webkit-animation: pulse-white 2s infinite !important;
			will-change: box-shadow; /* Optimize animation performance */
		}

		.buy-now-desktop .button.primary:hover {
			background: #f0f4f8 !important;
			color: #2c5b70 !important;
			transform: translateY(-2px);
			box-shadow: 0 6px 20px rgba(255, 255, 255, 0.7) !important;
		}

/* Animation Definitions */
@keyframes pulse-white {
    0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(255, 255, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

@-webkit-keyframes pulse-white {
    0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(255, 255, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

@keyframes pulse-blue {
    0% { box-shadow: 0 0 0 0 rgba(59, 119, 145, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(59, 119, 145, 0); }
    100% { box-shadow: 0 0 0 0 rgba(59, 119, 145, 0); }
}

@-webkit-keyframes pulse-blue {
    0% { box-shadow: 0 0 0 0 rgba(59, 119, 145, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(59, 119, 145, 0); }
    100% { box-shadow: 0 0 0 0 rgba(59, 119, 145, 0); }
}

/* Material Design Floating Bottom Navigation Bar */
@media screen and (max-width: 980px) {
    /* Override original navPanelToggle positioning */
    #navPanelToggle {
        position: relative !important;
        top: auto !important;
        right: auto !important;
        left: auto !important;
        bottom: auto !important;
        display: flex !important;
        width: auto !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
        text-decoration: none !important;
        text-indent: 0 !important;
        border: none !important;
    }
    
    /* Hide mobile nav bar on desktop */
    .mobile-nav-bar {
        display: block !important;
    }
    
    /* Main floating bar container */
    .mobile-nav-bar {
        position: fixed;
        bottom: 1.5rem;
        bottom: calc(1.5rem + env(safe-area-inset-bottom));
        left: 50%;
        transform: translateX(-50%);
        z-index: 10001;
        animation: slideUp 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    }
    
    /* Inner container for the bar */
    .nav-bar-container {
        display: flex;
        align-items: center;
        gap: 1.8rem;
        padding: 0.9rem 1.8rem;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border-radius: 2rem;
        box-shadow: 
            0 10px 30px rgba(0, 0, 0, 0.15),
            0 6px 10px rgba(0, 0, 0, 0.1),
            0 0 0 1px rgba(0, 0, 0, 0.05);
        transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    }
    
    /* Circular FAB buttons */
    .nav-fab {
        position: relative;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 67px;
        height: 67px;
        min-width: 67px;
        min-height: 67px;
        max-width: 67px;
        max-height: 67px;
        border-radius: 50%;
        background: #ffffff;
        color: #3B7791 !important;
        text-decoration: none !important;
        box-shadow: 
            0 4px 8px rgba(0, 0, 0, 0.1),
            0 2px 4px rgba(0, 0, 0, 0.06);
        transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
        user-select: none;
        overflow: hidden;
    }
    
    /* Primary button (Buy Now) */
    .nav-fab-primary {
        background: linear-gradient(135deg, #3B7791 0%, #4E96B6 100%);
        color: #ffffff !important;
        box-shadow: 
            0 6px 12px rgba(59, 119, 145, 0.3),
            0 3px 6px rgba(59, 119, 145, 0.2);
        animation: pulse-blue 2s infinite !important;
        -webkit-animation: pulse-blue 2s infinite !important;
        will-change: box-shadow; /* Optimize animation performance */
    }
    
    /* Icon styling */
    .fab-icon {
        font-size: 1.8rem;
        line-height: 1;
        display: block;
        margin-bottom: 0.24rem;
        font-style: normal;
        transition: transform 0.3s ease, color 0.3s ease;
        font-weight: bold;
    }
    
    /* Specific styling for ellipses menu icon */
    #navPanelToggle .fab-icon {
        letter-spacing: 0.3rem;
        font-size: 1.44rem;
        line-height: 1;
        margin-bottom: 0;
    }
    
    /* Buy Now text styling */
    #buyNowMobile .fab-icon {
        font-family: "Source Sans Pro", Helvetica, sans-serif !important;
        font-size: 0.84rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        line-height: 0.9;
        text-align: center !important;
        margin-bottom: 0;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        width: 100% !important;
    }
    
    /* Label styling */
    .fab-label {
        font-size: 0.78rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        line-height: 1;
        font-family: "Source Sans Pro", Helvetica, sans-serif;
    }
    
    /* Icon colors for better visibility */
    .nav-fab .fab-icon {
        color: #3B7791;
    }
    
    .nav-fab-primary .fab-icon {
        color: #ffffff;
    }
    
    .nav-fab .fab-label {
        color: #666;
    }
    
    .nav-fab-primary .fab-label {
        color: rgba(255, 255, 255, 0.95);
    }
    
    /* Hover effects */
    .nav-fab:hover {
        transform: translateY(-2px) scale(1.05);
        box-shadow: 
            0 8px 16px rgba(0, 0, 0, 0.15),
            0 4px 8px rgba(0, 0, 0, 0.1);
    }
    
    .nav-fab-primary:hover {
        box-shadow: 
            0 10px 20px rgba(59, 119, 145, 0.4),
            0 6px 10px rgba(59, 119, 145, 0.25);
    }
    
    /* Active/pressed state */
    .nav-fab:active {
        transform: translateY(0) scale(0.98);
        box-shadow: 
            0 2px 4px rgba(0, 0, 0, 0.1),
            0 1px 2px rgba(0, 0, 0, 0.06);
    }
    
    /* Ripple effect on tap */
    .nav-fab::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 0;
        height: 0;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.5);
        transform: translate(-50%, -50%);
        transition: width 0.6s, height 0.6s;
    }
    
    .nav-fab:active::after {
        width: 100px;
        height: 100px;
    }
    
    /* Alt state when scrolled - buttons stay consistent */
    
    /* Panel visible state */
    body.is-navPanel-visible .nav-bar-container {
        transform: scale(0.95);
        opacity: 0.9;
    }
    
    body.is-navPanel-visible #navPanelToggle {
        background: linear-gradient(135deg, #3B7791 0%, #4E96B6 100%);
        color: #ffffff !important;
    }
    
    body.is-navPanel-visible #navPanelToggle .fab-icon,
    body.is-navPanel-visible #navPanelToggle .fab-label {
        color: #ffffff !important;
    }
    
    /* Keep ellipses stable when panel is open */
    body.is-navPanel-visible #navPanelToggle .fab-icon {
        /* No rotation for ellipses */
        letter-spacing: 0.36rem;
        line-height: 1;
        margin-bottom: 0;
    }
    
    /* Hide Font Awesome icon from main.js */
    #navPanelToggle:before {
        content: none !important;
        display: none !important;
    }
    
    /* Slide up animation */
    @keyframes slideUp {
        from {
            opacity: 0;
            transform: translateX(-50%) translateY(100px);
        }
        to {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }
    }
}

/* Tablet optimizations for desktop Buy Now button */
@media screen and (max-width: 1200px) and (min-width: 981px) {
    .buy-now-desktop .button.primary {
        padding: 0.5rem 1.5rem !important;
        font-size: 0.8rem;
    }
}

/* Hide desktop buy now on mobile, show mobile nav instead */
@media screen and (max-width: 980px) {
    .buy-now-desktop {
        display: none !important;
    }
}

/* Hide mobile nav bar on desktop */
@media screen and (min-width: 981px) {
    .mobile-nav-bar {
        display: none !important;
    }
}

/* Additional responsive enhancements for Material Design bar */
@media screen and (max-width: 736px) {
    .mobile-nav-bar {
        bottom: 1rem;
        bottom: calc(1rem + env(safe-area-inset-bottom));
    }
    
    .nav-bar-container {
        gap: 1.5rem;
        padding: 0.72rem 1.5rem;
    }
    
    .nav-fab {
        width: 62px;
        height: 62px;
    }
    
    .fab-icon {
        font-size: 1.68rem;
    }
    
    .fab-label {
        font-size: 0.72rem;
    }
}

@media screen and (max-width: 480px) {
    .mobile-nav-bar {
        bottom: 0.75rem;
        bottom: calc(0.75rem + env(safe-area-inset-bottom));
        /* Ensure it doesn't get too close to the edge on very small screens */
        left: 50%;
        transform: translateX(-50%);
        max-width: calc(100vw - 2rem);
    }
    
    .nav-bar-container {
        gap: 1.2rem;
        padding: 0.6rem 1.2rem;
        /* Improve shadow for better visibility */
        box-shadow: 
            0 12px 36px rgba(0, 0, 0, 0.18),
            0 8px 16px rgba(0, 0, 0, 0.12),
            0 0 0 1px rgba(0, 0, 0, 0.08);
    }
    
    .nav-fab {
        width: 58px;
        height: 58px;
        min-width: 58px;
        min-height: 58px;
        /* Enhanced touch feedback */
        position: relative;
        overflow: visible;
    }
    
    /* Larger touch area for better accessibility */
    .nav-fab::before {
        content: '';
        position: absolute;
        top: -8px;
        left: -8px;
        right: -8px;
        bottom: -8px;
        border-radius: 50%;
        background: transparent;
        pointer-events: auto;
    }
    
    .fab-icon {
        font-size: 1.56rem;
    }
    
    .fab-label {
        font-size: 0.66rem;
    }
    
    /* Enhanced Buy Now button for small screens */
    #buyNowMobile .fab-icon {
        font-size: 0.78rem;
        line-height: 0.85;
        font-weight: 800;
    }
}

/* Ultra-small screens (< 375px width) */
@media screen and (max-width: 374px) {
    .mobile-nav-bar {
        bottom: 0.5rem;
        bottom: calc(0.5rem + env(safe-area-inset-bottom));
    }
    
    .nav-bar-container {
        gap: 0.9rem;
        padding: 0.48rem 0.96rem;
    }
    
    .nav-fab {
        width: 53px;
        height: 53px;
        min-width: 53px;
        min-height: 53px;
    }
    
    .fab-icon {
        font-size: 1.44rem;
    }
    
    #buyNowMobile .fab-icon {
        font-size: 0.72rem;
        line-height: 0.8;
    }
    
    .fab-label {
        font-size: 0.6rem;
    }
    
    /* Ultra-compact content spacing */
    #main > * {
        padding: 1rem !important;
    }
    
    .post header.major h1 {
        font-size: 2rem !important;
        line-height: 1.1 !important;
    }
    
    .post header.major h2 {
        font-size: 1.6rem !important;
    }
}

/* Landscape orientation optimizations */
@media screen and (max-height: 500px) and (orientation: landscape) {
    /* Compact vertical spacing in landscape mode */
    #intro {
        min-height: 15vh !important;
        padding: 1rem 2rem 0.5rem 2rem !important;
    }
    
    #main {
        margin-top: 2vh !important;
    }
    
    .mobile-nav-bar {
        bottom: 0.25rem;
        bottom: calc(0.25rem + env(safe-area-inset-bottom));
    }
    
    .nav-bar-container {
        padding: 0.36rem 0.96rem;
    }
    
    /* Reduce header heights in landscape */
    .post header.major h1 {
        font-size: 1.8rem !important;
        margin-bottom: 1rem !important;
    }
    
    .post header.major p {
        margin-bottom: 1.5rem !important;
        font-size: 1rem !important;
    }
}

/* Focus states for accessibility */
.buy-now-desktop .button.primary:focus,
.nav-fab:focus {
    outline: 3px solid #3B7791;
    outline-offset: 2px;
}

/* Modal responsive improvements */
@media screen and (max-width: 736px) {
    #comingSoonModal > div {
        margin: 10% auto !important;
        width: 95% !important;
        padding: 1.5rem !important;
    }
    
    #comingSoonModal h2 {
        font-size: 1.5rem !important;
    }
    
    #comingSoonModal input {
        font-size: 16px !important; /* Prevent zoom on iOS */
    }
}

@media screen and (max-width: 480px) {
    #comingSoonModal > div {
        margin: 5% auto !important;
        padding: 1.25rem !important;
    }
    
    #comingSoonModal h2 {
        font-size: 1.3rem !important;
    }
}

/* Improved keyboard navigation */
.nav-fab:focus-visible {
    outline: 3px solid #3B7791;
    outline-offset: 3px;
    box-shadow: 0 0 0 6px rgba(59, 119, 145, 0.2);
}

/* Ensure buttons don't overlap with content on very small screens */
@media screen and (max-height: 600px) {
    .mobile-nav-bar {
        bottom: 0.5rem;
        bottom: calc(0.5rem + env(safe-area-inset-bottom));
    }
    
    .nav-bar-container {
        padding: 0.48rem 0.96rem;
    }
    
    .nav-fab {
        width: 53px;
        height: 53px;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .buy-now-desktop .button.primary,
    .nav-fab {
        border: 3px solid currentColor !important;
    }
    
    .nav-bar-container {
        border: 2px solid #000 !important;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .buy-now-desktop .button.primary,
    .nav-fab,
    .nav-bar-container {
        transition: none !important;
        animation: none !important;
    }
    
    .buy-now-desktop .button.primary:hover,
    .nav-fab:hover {
        transform: none !important;
    }
    
    .nav-fab::after {
        display: none !important;
    }
}

/* Monotone inline icons to replace emojis */
.icon-inline {
    display: inline-block;
    width: 1.1em;
    text-align: center;
    margin-right: 0.4em;
    color: #3B7791; /* brand blue color for white backgrounds */
}

/* Keep icons white on blue navigation buttons */
.benefit-nav-btn .icon-inline {
    width: 1.05em;
    margin-right: 0.5em;
    color: #ffffff !important; /* white on blue background */
}

.how-it-works-card summary .icon-inline {
    width: 1em;
    margin-right: 0.5rem;
}

/* How it Works Page */
.how-it-works-container {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
	margin-top: 1rem; /* Add space for top shadows */
}

/* Hide carousel navigation on desktop */
.carousel-navigation,
.scroll-indicator {
	display: none;
}

/* Benefits Navigation Buttons */
.benefits-nav {
	margin: 2rem 0;
	padding: 1.5rem;
	background: rgba(255, 255, 255, 0.95);
	border-radius: 12px;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.benefits-nav-container {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	justify-content: center;
	align-items: center;
}

.benefit-nav-btn {
	display: inline-flex;
	align-items: center;
	padding: 0.75rem 1.25rem;
	background: linear-gradient(135deg, #3B7791 0%, #4E96B6 100%);
	color: #ffffff !important;
	text-decoration: none !important;
	border-radius: 25px;
	font-size: 0.9rem;
	font-weight: 600;
	font-family: "Source Sans Pro", Helvetica, sans-serif;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	transition: all 0.3s ease;
	box-shadow: 0 3px 8px rgba(59, 119, 145, 0.3);
	white-space: nowrap;
}

.benefit-nav-btn:hover {
	background: linear-gradient(135deg, #4E96B6 0%, #7DB3CA 100%);
	transform: translateY(-2px);
	box-shadow: 0 5px 15px rgba(59, 119, 145, 0.4);
	color: #ffffff !important;
}

.benefit-nav-btn:active {
	transform: translateY(0);
}

/* Add smooth scrolling with offset for fixed headers */
html {
	scroll-behavior: smooth;
	scroll-padding-top: 120px; /* Account for fixed header */
}

/* Respect user motion preferences */
@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
}

/* Adjust scroll offset to account for fixed headers if any */
.how-it-works-card {
	scroll-margin-top: 2rem;
}

/* Mobile responsive for benefits navigation */
@media screen and (max-width: 736px) {
	.benefits-nav {
		margin: 1.5rem 0;
		padding: 1rem;
	}
	
	.benefits-nav-container {
		gap: 0.5rem;
	}
	
	.benefit-nav-btn {
		padding: 0.6rem 1rem;
		font-size: 0.8rem;
		flex: 1 1 calc(50% - 0.25rem);
		min-width: calc(50% - 0.25rem);
		justify-content: center;
		text-align: center;
	}
}

@media screen and (max-width: 480px) {
	.benefit-nav-btn {
		flex: 1 1 100%;
		min-width: 100%;
	}
}
.how-it-works-card {
	background: #ffffff;
	border-radius: 8px;
	box-shadow: 
		0 -1px 3px rgba(0,0,0,0.05),
		0 5px 15px rgba(0,0,0,0.2);
	transition: box-shadow 0.3s ease-in-out;
}
.how-it-works-card:hover {
	box-shadow: 
		0 -1px 3px rgba(0,0,0,0.05),
		0 8px 25px rgba(0,0,0,0.25);
}
.how-it-works-card summary {
	padding: 1.5rem;
	font-size: 1.5rem;
	font-weight: 700;
	font-family: 'Cinzel', serif;
	cursor: pointer;
	list-style: none; /* Remove default marker */
	text-align: center !important; /* Centre justify card titles */
}
.how-it-works-card summary::-webkit-details-marker {
	display: none; /* Hide Safari marker */
}
.how-it-works-card .card-content {
	padding: 1rem 1.5rem 1.5rem;
}
.how-it-works-card[open] summary {
	border-bottom: 3px double #4E96B6;
	margin-bottom: 0.5rem;
}

@media screen and (max-width: 736px) {
	.how-it-works-container {
		flex-direction: row;
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		-webkit-overflow-scrolling: touch; /* for smooth scrolling on iOS */
		padding: 1rem 2rem 3rem 2rem; /* Add horizontal padding to show card edges */
		position: relative;
		scroll-behavior: smooth;
		/* Improve snap behavior */
		overscroll-behavior-x: contain;
	}
	.how-it-works-card {
		flex: 0 0 95%; /* Larger cards to show less of adjacent cards */
		scroll-snap-align: center; /* Center alignment for better locking */
		scroll-snap-stop: always; /* Force stop at each card */
		margin-right: 0.5rem; /* Reduced gap between cards */
		/* Enhanced shadows to show adjacent cards */
		box-shadow: 
			0 -1px 3px rgba(0,0,0,0.05),
			0 8px 25px rgba(0,0,0,0.15),
			-2px 0 10px rgba(0,0,0,0.08),
			2px 0 10px rgba(0,0,0,0.08) !important;
		transition: box-shadow 0.3s ease, transform 0.2s ease;
	}
	
	.how-it-works-card:last-child {
		margin-right: 0;
	}
	
	/* Show carousel navigation elements on mobile */
	.carousel-navigation,
	.scroll-indicator {
		display: block;
	}
	
	/* Carousel Navigation with Universal Symbols */
	.carousel-navigation {
		display: flex;
		justify-content: center;
		align-items: center;
		gap: 0.5rem;
		margin-top: 1.5rem;
		position: sticky;
		bottom: 0;
		background: rgba(255, 255, 255, 0.95);
		backdrop-filter: blur(15px);
		-webkit-backdrop-filter: blur(15px);
		padding: 0.6rem 0;
		border-radius: 1rem 1rem 0 0;
		box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
	}

	/* Top pagination dots: Material-style, minimal chrome */
	.carousel-navigation--top {
		position: relative;
		bottom: auto;
		background: transparent;
		backdrop-filter: none;
		-webkit-backdrop-filter: none;
		padding: 0;
		border-radius: 0;
		box-shadow: none;
		margin-top: 0.5rem;
		margin-bottom: 0.75rem;
	}
	
	/* Functional arrow buttons */
	.nav-arrow {
		display: inline-flex;
		justify-content: center;
		align-items: center;
		width: 32px;
		height: 32px;
		border-radius: 50%;
		background: transparent;
		border: none !important;
		cursor: pointer;
		font-size: 1.2rem;
		color: #3B7791;
		opacity: 0.6;
		font-weight: bold;
		transition: all 0.25s ease;
		touch-action: manipulation;
		outline: none !important;
		-webkit-tap-highlight-color: transparent;
		box-shadow: none !important;
	}
	
	.nav-arrow:hover {
		opacity: 1;
		background: rgba(78, 150, 182, 0.2);
		box-shadow: 0 0 20px rgba(78, 150, 182, 0.6);
	}
	
	.nav-arrow:active {
		background: rgba(78, 150, 182, 0.3);
		box-shadow: 0 0 25px rgba(78, 150, 182, 0.8);
	}
	
	.nav-arrow:focus,
	.nav-arrow:focus-visible {
		outline: none !important;
		border: none !important;
		box-shadow: none !important;
	}

	/* All carousel navigation now shows arrows - removed selective hiding */
	
	/* CRITICAL FIX: Hide card carousel arrows on mobile */
	@media screen and (max-width: 736px) {
		.carousel-navigation .nav-arrow,
		.nav-arrow--prev,
		.nav-arrow--next,
		button.nav-arrow {
			display: none !important;
			visibility: hidden !important;
			opacity: 0 !important;
			pointer-events: none !important;
		}
		
		/* Make dots more prominent for easier tapping */
		.nav-dot {
			width: 40px !important;
			height: 40px !important;
		}
		
		.nav-dot::after {
			width: 14px !important;
			height: 14px !important;
		}
	}
	
	/* Dots container */
	.carousel-navigation {
		position: relative;
	}
	
	.nav-dot {
		display: inline-flex;
		justify-content: center;
		align-items: center;
		width: 32px; /* large tap target */
		height: 32px; /* large tap target */
		border-radius: 50%;
		background: transparent !important;
		cursor: pointer;
		transition: filter 0.25s ease;
		touch-action: manipulation;
		border: none !important;
		outline: none !important;
		position: relative;
		padding: 0;
		-webkit-tap-highlight-color: transparent;
		box-shadow: none !important;
	}

	/* Visual dot inside the button */
	.nav-dot::after {
		content: '';
		display: block;
		width: 10px;
		height: 10px;
		border-radius: 50%;
		background: rgba(78, 150, 182, 0.6);
		box-shadow: 0 0 12px rgba(78, 150, 182, 0.7), 0 0 4px rgba(78, 150, 182, 0.4);
		transition: box-shadow 0.25s ease, background-color 0.25s ease, transform 0.25s ease;
	}
	
	.nav-dot.active::after {
		background: #4E96B6;
		box-shadow: 
			0 0 20px rgba(78, 150, 182, 1), 
			0 0 12px rgba(78, 150, 182, 0.8),
			0 0 6px rgba(78, 150, 182, 0.6);
		transform: scale(1.2);
	}
	
	.nav-dot:hover::after {
		background: #4E96B6;
		box-shadow: 0 0 16px rgba(78, 150, 182, 0.85), 0 0 6px rgba(78, 150, 182, 0.5);
		transform: scale(1.1);
	}
	
	.nav-dot:focus,
	.nav-dot:active,
	.nav-dot:focus-visible {
		outline: none !important;
		border: none !important;
		box-shadow: none !important;
	}
	
	/* Enhanced scroll indicator with universal swipe symbol */
	.scroll-indicator {
		position: absolute;
		top: 50%;
		right: 1rem;
		transform: translateY(-50%);
		background: rgba(59, 119, 145, 0.9);
		color: white;
		padding: 0.6rem 0.8rem;
		border-radius: 25px;
		font-size: 0.9rem;
		opacity: 0.8;
		animation: slideHint 2.5s infinite;
		pointer-events: none;
		font-weight: bold;
		box-shadow: 0 2px 10px rgba(0,0,0,0.2);
	}
	
	/* Improved animation for swipe hint */
	@keyframes slideHint {
		0%, 80% { opacity: 0.8; transform: translateY(-50%); }
		90% { opacity: 1; transform: translateY(-50%) translateX(-5px); }
		100% { opacity: 0.8; transform: translateY(-50%); }
	}
	
	@keyframes pulse {
		0%, 100% { opacity: 0.7; }
		50% { opacity: 1; }
	}
	
	/* Hide scroll indicator after first interaction */
	.how-it-works-container.scrolled .scroll-indicator {
		opacity: 0;
		transition: opacity 0.5s ease;
	}
}

/* Research Professionals Button - Responsive Styling */
.research-professionals-btn {
	font-size: 1.1em !important;
	padding: 0.85rem 2rem !important;
	white-space: normal !important; /* Allow text wrapping */
	line-height: 1.3 !important;
	text-align: center !important;
	display: inline-block !important;
	max-width: 100% !important;
	word-wrap: break-word !important;
}

/* Mobile responsive styles for research professionals button */
@media screen and (max-width: 736px) {
	.research-professionals-btn {
		font-size: 0.9em !important;
		padding: 0.7rem 1.5rem !important;
		line-height: 1.4 !important;
		max-width: 90vw !important;
		/* Allow text to wrap to two lines if needed */
		white-space: normal !important;
		word-break: break-word !important;
		hyphens: auto !important;
	}
}

@media screen and (max-width: 480px) {
	.research-professionals-btn {
		font-size: 0.8em !important;
		padding: 0.6rem 1.2rem !important;
		line-height: 1.5 !important;
		max-width: 85vw !important;
		/* Ensure it fits even on very small screens */
		word-wrap: break-word !important;
	}
}

@media screen and (max-width: 374px) {
	.research-professionals-btn {
		font-size: 0.75em !important;
		padding: 0.5rem 1rem !important;
		line-height: 1.6 !important;
		max-width: 80vw !important;
	}
}

/* Product Hero - New shots block displayed right after page headlines */
.product-hero {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin: 1.5rem 0 2rem 0;
}

.product-hero__image {
    width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
}

@media screen and (max-width: 980px) {
    .product-hero {
        grid-template-columns: 1fr 1fr;
        gap: 0.9rem;
        margin: 1.25rem 0 1.75rem 0;
    }
}

@media screen and (max-width: 736px) {
    .product-hero {
        grid-template-columns: 1fr;
        gap: 0.85rem;
        margin: 1rem 0 1.5rem 0;
    }
    .product-hero__image {
        border-radius: 0.6rem;
        box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
    }
}
/* Hero Image Carousel - Desktop & Mobile */
.hero-carousel-container {
    position: relative;
    width: 100%;
    margin: 1.5rem 0 3rem 0; /* Increased bottom margin for dots */
    overflow: hidden; 
}

.hero-carousel {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    gap: 0; /* Remove gap for standard seamless carousel */
    padding-bottom: 0; 
    scrollbar-width: none; 
}

.hero-carousel::-webkit-scrollbar {
    display: none; 
}

.hero-slide {
    flex: 0 0 100%;
    scroll-snap-align: center;
    scroll-snap-stop: always;
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.hero-slide img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* Navigation for Hero Carousel */
.hero-carousel-nav {
    display: flex;
    justify-content: center;
    gap: 0.8rem;
    margin-top: 1rem;
    position: relative;
    bottom: auto;
}

.hero-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: transparent;
    border: 2px solid #3B7791;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
    opacity: 0.5;
}

.hero-dot:hover {
    opacity: 0.8;
    background: rgba(59, 119, 145, 0.3);
}

.hero-dot.active {
    background: #3B7791;
    opacity: 1;
    transform: scale(1.15);
}

/* Standard "Off the Shelf" Carousel Arrows - Clean White Circles with Higher Transparency */
.hero-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    color: #333;
    font-size: 1.3rem;
    z-index: 100;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.hero-arrow:hover {
    background: rgba(255, 255, 255, 0.7);
    transform: translateY(-50%) scale(1.08);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.hero-arrow:active {
    transform: translateY(-50%) scale(0.95);
}

.hero-arrow.prev { left: 16px; }
.hero-arrow.next { right: 16px; }

/* Mobile adjustments - HIDE ARROWS COMPLETELY */
@media screen and (max-width: 736px) {
    .hero-carousel-container {
        margin-bottom: 3.5rem; /* More space for touch */
    }
    
    /* CRITICAL FIX: Hide hero carousel arrows on mobile with maximum specificity */
    .hero-carousel-container .hero-arrow,
    .hero-arrow.prev,
    .hero-arrow.next,
    button.hero-arrow,
    .hero-carousel-container button.hero-arrow.prev,
    .hero-carousel-container button.hero-arrow.next {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        pointer-events: none !important;
        position: absolute !important;
        left: -9999px !important;
    }
    
    .hero-slide {
        border-radius: 8px;
    }
    
    header.major h1 {
        font-size: 2.5rem !important;
    }
}

/* Enhanced Benefits Hero Section */
.benefits-hero-section {
    max-width: 800px;
    margin: 2rem auto;
    text-align: center;
}

.benefits-header h2 {
    font-family: 'Cinzel', serif;
    font-size: 2em;
    color: #212931;
    margin-bottom: 2rem;
    position: relative;
    display: inline-block;
}

.benefits-header h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: #4E96B6;
    margin: 0.5rem auto 0;
}

.benefits-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.benefit-item {
    display: flex;
    align-items: center;
    background: #f8f9fa;
    padding: 1rem 1.5rem;
    border-radius: 50px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid rgba(78, 150, 182, 0.1);
}

.benefit-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.1);
    background: white;
    border-color: #4E96B6;
}

.benefit-icon {
    font-size: 1.2rem;
    color: #4E96B6;
    margin-right: 0.8rem;
    display: flex;
    align-items: center;
}

.benefit-text {
    font-family: "Lora", serif;
    font-size: 1.1rem;
    color: #333;
    line-height: 1.2;
}

.benefit-text strong {
    color: #212931;
    font-weight: 700;
}

/* Science Highlight Section */
.science-highlight {
    background: linear-gradient(135deg, #f1f6f9 0%, #e6eef1 100%);
    padding: 1.5rem;
    border-radius: 12px;
    border-left: 5px solid #3B7791;
    margin-top: 1rem;
    text-align: center;
}

.science-highlight h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.3rem;
    color: #3B7791;
    margin-bottom: 0.8rem;
    letter-spacing: 0.05em;
    text-align: center !important; /* Centre justify Advanced Science title */
}

.ingredients-list {
    font-family: "Source Sans Pro", sans-serif;
    font-size: 1.1rem;
    color: #555;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.8rem;
    align-items: center;
}

.separator {
    color: #4E96B6;
    font-weight: 300;
}

/* Mobile Adjustments */
@media screen and (max-width: 736px) {
    .benefits-grid {
        flex-direction: column;
        align-items: stretch; /* Full width items */
        gap: 0.8rem;
        padding: 0 1rem;
    }
    
    .benefit-item {
        justify-content: flex-start;
        padding: 0.8rem 1.2rem;
    }

    .science-highlight {
        margin: 1rem;
    }
    
    .ingredients-list {
        font-size: 0.9rem;
        flex-direction: column;
        gap: 0.4rem;
    }
    
    .ingredients-list .separator {
        display: none; /* Hide dots on mobile vertical stack */
    }
}

/* Make benefit items clickable buttons */
a.benefit-item {
    text-decoration: none;
    cursor: pointer;
    width: auto;
    display: inline-flex; /* Maintain inline-flex behavior */
    color: inherit; /* Inherit color unless overridden */
}

/* Ensure text color inside anchor remains correct */
a.benefit-item .benefit-text {
    color: #333;
    transition: color 0.2s ease;
}

a.benefit-item:hover .benefit-text {
    color: #4E96B6;
}

/* Ensure icon color transition on hover */
a.benefit-item:hover .benefit-icon {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

/* Center justify the specific header */
.benefits-header {
    text-align: center;
}

/* Force center alignment for the benefits header */
.benefits-header, .benefits-header h2 {
    text-align: center !important;
}

/* Ensure title is responsive and not too large */
@media screen and (max-width: 736px) {
    .major h1 {
        font-size: 2rem !important;
        line-height: 1.3 !important;
    }
}

/* Make the title truly punchy and vertically stacked with responsive sizing */
header.major h1 {
    /* Use CSS clamp for truly fluid, responsive sizing */
    font-size: clamp(1.6rem, 4vw + 1rem, 3.5rem) !important;
    line-height: 1.15 !important;
    letter-spacing: clamp(0.05em, 0.5vw, 0.1em) !important;
    font-weight: 700 !important;
    text-align: center !important;
    display: block !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    hyphens: auto !important;
}

/* Ensure br tags work in headings */
header.major h1 br,
.benefits-header h2 br {
    display: block !important;
    content: "" !important;
}

/* Fallback responsive title sizing for browsers without clamp support */
@supports not (font-size: clamp(1rem, 1vw, 2rem)) {
    @media screen and (max-width: 736px) {
        header.major h1 {
            font-size: 2.2rem !important;
            line-height: 1.2 !important;
            letter-spacing: 0.08em !important;
            padding: 0 0.5rem !important;
            max-width: 100% !important;
        }
    }

    @media screen and (max-width: 480px) {
        header.major h1 {
            font-size: 1.9rem !important;
            line-height: 1.2 !important;
            letter-spacing: 0.06em !important;
            padding: 0 0.25rem !important;
        }
    }

    @media screen and (max-width: 374px) {
        header.major h1 {
            font-size: 1.6rem !important;
            letter-spacing: 0.05em !important;
        }
    }
}

/* Fix carousel cropping by ensuring container has room */
.hero-carousel-container {
    padding-bottom: 3rem !important; /* Space for dots */
    overflow: visible !important;
}
