/* --- Global Styles & Professional Color Palette --- */
:root {
    --color-primary: #ff5001;
    --color-dark: #212529;
    --color-black: #000000;
    --color-secondary-text: #6c757d;
    --color-background: #f8f9fa;
    --color-white: #ffffff;
    --font-heading: 'Verdana', sans-serif;
    --font-body: 'Verdana', sans-serif;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

* { box-sizing: border-box; }

body { margin: 0; font-family: var(--font-body); background-color: var(--color-background); color: var(--color-dark); line-height: 1.6; }

/* --- REVISED HEADER WITH SOCIAL ICONS --- */
header {
    background-color: var(--color-white);
    padding: 10px 0; /* Adjusted padding for better vertical alignment */
    border-bottom: 1px solid #dee2e6;
    box-shadow: 0 2px 4px rgba(0,0,0,0.04);
}

/* This is the key for the layout */
header .page-container {
    display: flex;
    justify-content: space-between; /* Pushes logo and icons to opposite ends */
    align-items: center;
}

header .logo img {
    height: 45px; /* Adjust this to control your logo's size */
    width: auto;
    display: block;
}

/* Container for the social media icons in the header */
.header-socials {
    display: flex;
    align-items: center;
    gap: 20px; /* Space between each icon */
}

.header-socials a {
    line-height: 0; /* Removes extra space from link wrappers */
}

.header-socials img {
    height: 28px; /* Adjust this to control icon size */
    width: auto;
    transition: opacity 0.2s ease;
}

.header-socials a:hover img {
    opacity: 0.7; /* Simple and clean hover effect */
}
/* Adds a subtle zoom effect when you hover over the logo */
header .logo:hover img {
    transform: scale(1.05);
}

.page-container { max-width: 1200px; margin: 0 auto; padding: 0 20px; display: flex; align-items: center; gap: 40px; }
.page-container > .content-wrapper, .page-container > .image-wrapper { flex: 1; }

/* --- Feature Section Layout --- */
.feature-section { padding: 80px 0; position: relative; overflow: hidden; }
/* Make the first feature section padding smaller at the top since it no longer has a section above it */
#main-app.feature-section {
    padding-top: 60px;
}
.feature-section.bg-white { background-color: var(--color-white); }
.feature-section.alt-layout .page-container { flex-direction: row-reverse; }

.feature-section::before { content: ''; position: absolute; width: 600px; height: 600px; border-radius: 50%; z-index: 0; opacity: 0.8; background: radial-gradient(circle, rgba(255, 80, 1, 0.1), rgba(255, 80, 1, 0) 70%); pointer-events: none; }
#main-app::before { top: -150px; left: -250px; }
#admin-app::before { bottom: -200px; right: -250px; }

/* --- Content Styling --- */
.content-wrapper { padding-right: 20px; z-index: 1; position: relative; }
.alt-layout .page-container .content-wrapper { padding-left: 20px; padding-right: 0; }
.image-wrapper { z-index: 1; position: relative; }

.section-title { font-family: var(--font-heading); font-size: 1.1rem; font-weight: 600; color: var(--color-primary); margin: 0 0 10px 0; text-transform: uppercase; letter-spacing: 1px; }
.section-subtitle { font-family: var(--font-heading); font-size: 2.5rem; font-weight: 700; font-style: italic; margin: 0 0 20px 0; line-height: 1.2; }

/* --- NEW: Small Inline Language Flags --- */
.language-flags-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px; /* Space between flags and paragraph */
}
.language-flags-container span {
    line-height: 0; /* Helps with vertical alignment */
}
.language-flags-container img {
    height: 24px; /* Small icon size */
    width: auto;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s ease;
}
.language-flags-container span:hover img {
    transform: scale(1.15) translateY(-2px); /* Pop effect on hover */
}


.section-description { font-size: 1.1rem; color: var(--color-secondary-text); margin-bottom: 30px; }
.feature-list { list-style: none; padding: 0; margin: 0 0 40px 0; }
.feature-list li { position: relative; padding-left: 30px; margin-bottom: 15px; font-size: 1rem; transition: transform 0.2s ease-in-out; }
.feature-list li:hover { transform: translateX(5px); }
.feature-list li::before { content: '✔'; position: absolute; left: 0; top: 0; color: var(--color-primary); font-weight: 700; }

/* --- AUTHENTIC APP STORE BUTTONS --- */
.app-buttons-container { display: flex; flex-wrap: wrap; gap: 15px; align-items: center; margin-top: 40px; }

/* Style for text-based buttons (like Apple) */
.app-store-button { display: flex; align-items: center; gap: 12px; padding: 8px 20px; border-radius: 8px; text-decoration: none; background-color: var(--color-black); color: var(--color-white); transition: transform 0.2s ease, box-shadow 0.2s ease; border: none; }
.app-store-button:hover { transform: translateY(-3px); box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2); }

.app-store-button .app-logo { height: 28px; width: auto; }
.app-store-button .button-text { display: flex; flex-direction: column; line-height: 1.2; text-align: left; }
.app-store-button .small-text { font-size: 0.7rem; font-weight: 400; opacity: 0.9; text-transform: uppercase; letter-spacing: 0.5px; }
.app-store-button .large-text { font-size: 1.05rem; font-weight: 600; }

/* Styles for image-only buttons (like Google Play) */
.app-store-button.image-only { background-color: transparent; padding: 0; box-shadow: none; }
.app-store-button.image-only img { height: 44px; width: auto; display: block; border-radius: 8px; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.app-store-button.image-only:hover { transform: none; box-shadow: none; }
.app-store-button.image-only:hover img { transform: translateY(-3px); box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2); }

/* --- Phone Mockup & Carousel Styling --- */
.image-wrapper { display: flex; justify-content: center; align-items: center; }
.phone-mockup { position: relative; width: 100%; max-width: 300px; aspect-ratio: 1098 / 2040; background-color: var(--color-dark); border-radius: 30px; box-shadow: var(--shadow); padding: 10px; border: 1px solid #e9ecef; overflow: hidden; }
.phone-mockup::before { content: ''; position: absolute; top: 10px; left: 50%; transform: translateX(-50%); width: 40%; height: 15px; background-color: var(--color-dark); border-radius: 0 0 10px 10px; z-index: 3; }
.carousel-inner { position: relative; width: 100%; height: 100%; border-radius: 20px; overflow: hidden; }
.carousel-inner img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* =========== THE FIX FOR A NICE FIT =========== */
    object-fit: cover; /* Fills the frame, cropping if necessary. */
    object-position: center top; /* Aligns image to the top, so cropping happens at the bottom. */
    /* ============================================== */
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
}
.carousel-inner img.active { opacity: 1; z-index: 1; }

/* --- FOOTER (HEADER-MATCHING DESIGN) --- */
footer {
    background-color: var(--color-white); /* Match header background */
    color: var(--color-dark); /* Black/dark text */
    padding: 25px 0; /* Keeps it lean */
    margin-top: 80px;
    font-size: 0.9rem;
    border-top: 1px solid #dee2e6; /* Mirrors header's bottom border */
    box-shadow: 0 -2px 4px rgba(0, 0, 0, 0.04); /* Inverse shadow to mirror header */
}

/* This controls the left/right layout */
footer .page-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; 
    gap: 15px;
}

.footer-left p,
.footer-right p {
    margin: 0;
}

.footer-left {
    text-align: left;
}
.footer-right {
    text-align: right;
}

/* Default link styles in the footer (Privacy, Terms) */
footer a {
    color: var(--color-dark); /* Dark text by default */
    text-decoration: none;
    transition: color 0.2s ease;
}
footer a:hover {
    color: var(--color-primary); /* Brand orange on hover */
}

/* Specific styling for the 'Biovell' link */
.biovell-link {
    font-weight: 600;
}
/* Override to make Biovell link navy blue on hover */
.biovell-link:hover,
.biovell-link:focus,
.biovell-link:active {
    color: #007bff; /* Navy blue */
}


/* Responsive stacking for small screens */
@media (max-width: 768px) {
    footer .page-container {
        flex-direction: column;
        gap: 10px;
    }
    .footer-left,
    .footer-right {
        text-align: center;
    }
}


/* --- Scroll Animation Styles --- */
.hidden { opacity: 0; transform: translateY(50px); transition: opacity 0.8s ease-out, transform 0.8s ease-out; }
.visible { opacity: 1; transform: translateY(0); }

/* --- Responsive Design --- */
@media (max-width: 992px) {
    .page-container, .feature-section.alt-layout .page-container { flex-direction: column; text-align: center; }
    .feature-section { padding: 60px 0; }
    #main-app.feature-section { padding-top: 40px; }
    header .page-container { flex-direction: row; justify-content: center; }
    
    .image-wrapper { 
        margin-top: 40px; 
        margin-bottom: 0; 
        order: -1; 
        width: 100%; /* Ensures the wrapper has a width in the mobile column layout */
    }
    
    /* Center the small flags on mobile */
    .language-flags-container {
        justify-content: center;
    }

    .content-wrapper, .alt-layout .page-container .content-wrapper { padding: 0; }
    .feature-list { display: inline-block; text-align: left; }
    .app-buttons-container { justify-content: center; }
    .section-subtitle { font-size: 2rem; }
}