/*
Theme Name: Jovital Theme
Author: Agilstore
Author URI: https://agilstore.pt
Description: Um tema One Page para Jovital.
Version: 1.0.0
Text Domain: jovital_theme
*/

/* Reset & Basic Styles */
:root {
    --primary-color: #009382;
    --secondary-color: #2C5F56;
    --secondary-hover: #1a3c36;
    --text-color: #333;
    --heading-color: #222;
    --white: #fff;
    --black: #000;
    --overlay-color: rgba(0, 30, 40, 0.4);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background: var(--white);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Header */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--white);
    padding: 1.25rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.branding-group {
    display: flex;
    align-items: center;
}

.site-title {
    margin: 0;
    line-height: 1;
}

.site-title a {
    text-decoration: none;
    color: var(--black);
    font-weight: 700;
    font-size: 1.8rem;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.container {
    width: 90%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    gap: 2.5rem;
    margin: 0;
    padding: 0;
}

.main-navigation {
    position: relative;
    /* Context for absolute indicator */
}

.main-navigation a {
    text-decoration: none;
    color: var(--secondary-color);
    /* Dark Green */
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s ease;
    padding: 0.5rem 0;
    /* Add padding for easier click/hover */
    display: block;
}

.main-navigation a:hover,
.main-navigation a.active-link {
    color: var(--secondary-hover);
}

/* Sliding Indicator */
.menu-indicator {
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 6px;
    height: 6px;
    background-color: var(--primary-color);
    border-radius: 50%;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    /* Hidden until JS positions it */
    pointer-events: none;
}

/* One Page Sections */
.section {
    min-height: 100vh;
    padding: 100px 20px 40px;
    /* Top padding for header */
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    background: var(--white);
}

.section h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    text-align: center;
    width: 100%;
}

/* Hero Section Specifics */
#home {
    padding-top: 0;
    color: var(--white);
    clip-path: polygon(0 0, 100% 0, 100% 85%, 0 100%);
    margin-bottom: -10vh;
    z-index: 10;
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0%;
    /* Give some room for parallax movement */
    left: 0;
    width: 100%;
    height: 120%;
    /* Taller than container to allow travel */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
    will-change: transform;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--overlay-color);
    /* Dark Green/Blue Tint */
    z-index: 1;
}

#home .container {
    position: relative;
    z-index: 2;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    margin-top: 0;
    /* Reset flex alignment margin */
}

.hero-content {
    width: 100%;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.hero-content h1 {
    font-size: 4.5rem;
    text-transform: uppercase;
    font-weight: 800;
    margin-bottom: 0.5rem;
    letter-spacing: 2px;
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    opacity: 0;
    filter: blur(10px);
}

.hero-content p {
    width: 100%;
    font-size: 1.5rem;
    font-weight: 400;
    margin-top: 0;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    opacity: 0;
    filter: blur(10px);
}

/* Adjust next section to handle the overlap gracefully */
#about-us {
    background: var(--white);
    padding: 100px 0;
    text-align: center;
}

.about-container {
    max-width: 1200px;
    flex-direction: column;
}

.about-text-wrapper {
    max-width: 800px;
    margin: 0 auto 4rem auto;
}

#about-us h2 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-size: 2.5rem;
}

.about-grid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.about-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    /* Spacing between vertical items in columns */
}

.center-image {
    flex: 1.2;
    /* Slightly wider center */
}

.center-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    display: block;
}

.feature-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border: 2px solid #00938220;
    border-radius: 8px;
    padding: 20px;
    transition: all 0.3s ease;
}

.feature-item:hover {
    background-color: #00938210;
    color: var(--white);
    transform: translateY(-4px);
}

.feature-item .iconify {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.feature-item h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--heading-color);
}

@media (max-width: 900px) {
    .about-grid {
        flex-direction: column;
    }

    .center-image {
        order: -1;
        /* Image first on mobile? Or keep middle? Let's keep natural flow or put image after text */
        width: 100%;
        margin-bottom: 2rem;
    }

    .about-col {
        width: 100%;
        gap: 2rem;
    }
}

/* Products Section */
.products-section {
    background: var(--white);
    padding-top: 100px;
    padding-bottom: 100px;
    text-align: center;
}

.products-container {
    flex-direction: column;
    gap: 5rem;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4rem;
    width: 100%;
}

.product-col {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
}

.product-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 4px;
    /* Optional rounded corners */
}

.product-info h3 {
    color: var(--primary-color);
    font-size: 1.8rem;
    font-weight: 700;
    margin: 1rem 0 0.5rem;
}

.product-info p {
    font-size: 1rem;
    color: var(--text-color);
    margin: 0;
}

@media (max-width: 900px) {
    .products-grid {
        grid-template-columns: 1fr;
        gap: 4rem;
    }

    /* On mobile, reset standard order if needed, or keep as is */
    .middle-col {
        flex-direction: column-reverse;
    }
}

/* Contact Section */
.contact-section {
    background: var(--white);
    padding-top: 0px;
    padding-bottom: 100px;
}

.contact-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2rem;
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.contact-wrapper {
    display: flex;
    flex-direction: row;
    justify-content: center;
    width: 100%;
    gap: 4rem;
    align-items: stretch;
}

.contact-map {
    flex: 1;
    min-height: 300px;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.contact-map iframe {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 300px;
}

.contact-info-wrapper {
    flex: 1;
    text-align: left;
    /* Image shows left aligned titles? Or centered section title? */
}

.contact-info-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

.contact-item h3 {
    color: #555;
    /* The image shows greyish titles for sub-items */
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 1rem;
    text-transform: capitalize;
}

.contact-item p,
.contact-item a {
    color: var(--text-color);
    font-size: 1rem;
    line-height: 1.6;
    text-decoration: none;
    margin: 0;
}

.contact-item a:hover {
    color: var(--primary-color);
}

.social-icons {
    display: flex;
    gap: 0.5rem;
}

.social-icons .iconify {
    color: #333;
    /* Dark icons as per image (black/dark grey buttons) */
    transition: color 0.3s;
}

.social-icons a:hover .iconify {
    color: var(--primary-color);
}

@media (max-width: 900px) {
    .contact-container {
        flex-direction: column;
    }

    .contact-map {
        width: 100%;
        min-height: 300px;
    }

    .contact-info-grid {
        grid-template-columns: 1fr;
        /* Stack on small screens */
    }

    .contact-info-wrapper h2 {
        text-align: center;
    }
}

/* Footer Section */
.site-footer {
    background: #f9f9f9;
    padding: 2rem 0;
    text-align: center;
    border-top: 1px solid #eee;
    margin-top: auto;
}

.footer-logos {
    margin-bottom: 2rem;
    padding: 0 20px;
}

.footer-logos img {
    max-width: 100%;
    height: auto;
    display: inline-block;
    max-height: 60px;
    /* Adjust as needed for "discreet" look */
    opacity: 0.8;
    transition: opacity 0.3s;
    filter: brightness(0.5);
}

.footer-logos img:hover {
    opacity: 1;
}

.site-footer p {
    margin: 0.5rem 0;
    font-size: 0.9rem;
    color: #666;
}

.site-credit a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.site-credit a:hover {
    text-decoration: underline;
}

/* Language Toggle */
.language-toggle {
    margin-left: 2rem;
    position: relative;
    display: flex;
    align-items: center;
}

.language-toggle input[type="checkbox"] {
    display: none;
}

.lang-toggle-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 64px;
    height: 32px;
    background-color: #eee;
    border-radius: 16px;
    position: relative;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--secondary-color);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 0 8px;
    user-select: none;
}

.lang-label-in {
    z-index: 1;
    margin-right: auto;
}

.lang-label-pt {
    z-index: 1;
    margin-left: auto;
}

.lang-ball {
    position: absolute;
    top: 4px;
    /* 32 - 24 = 8 / 2 = 4 */
    left: 4px;
    width: 24px;
    height: 24px;
    background-color: var(--primary-color);
    border-radius: 50%;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 0;
}

/* Checked state (PT) */
.language-toggle input:checked+.lang-toggle-label .lang-ball {
    transform: translateX(32px);
    /* 64 - 8 - 24 = 32 */
}

/* Adjust text color when active? Or keep secondary color */
.language-toggle input:checked+.lang-toggle-label .lang-label-pt {
    color: var(--white);
    transition: color 0.3s 0.1s;
}

.language-toggle input:not(:checked)+.lang-toggle-label .lang-label-in {
    color: var(--white);
    transition: color 0.3s 0.1s;
}

@media (max-width: 768px) {
    .container {
        flex-wrap: wrap;
        /* Allow wrapping if menu is large */
    }

    .language-toggle {
        margin-left: auto;
        /* Push to right on mobile if wrapped */
        margin-top: 1rem;
    }
}