:root {
    --primary-color: #1a3628;
    --text-color: #1d3327;
    --bg-white-trans: rgba(255, 255, 255, 0.7);
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
    --border-radius: 20px;
    --transition-smooth: all 0.3s ease;
}

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

body {
    font-family: var(--font-body);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Fixed Backgrounds for Cross-fading */
#bg-layer-1, #bg-layer-2 {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    z-index: -1;
    transition: opacity 1s ease-in-out;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #e5e6e3;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    max-width: 1400px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--primary-color);
    font-family: var(--font-heading);
    cursor: pointer;
}

.logo-f, .logo-s {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1;
}

.logo-text {
    display: flex;
    flex-direction: column;
    margin-left: 10px;
}

.logo-food, .logo-safety {
    font-size: 1.2rem;
    letter-spacing: 2px;
}

.nav-links {
    display: flex;
    gap: 20px;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition-smooth);
    cursor: pointer;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--primary-color);
    text-decoration: underline;
}

.language-selector {
    display: flex;
    gap: 10px;
}

.lang-btn {
    background: none;
    border: none;
    cursor: pointer;
    border-radius: 50%;
    overflow: hidden;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
}

.lang-btn:hover {
    transform: scale(1.1);
}

.lang-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Main Content SPA */
.main-content {
    margin-top: 80px; /* Header height */
    margin-bottom: 60px; /* Footer height */
    min-height: calc(100vh - 140px);
    display: flex;
    justify-content: center;
    align-items: center;
}

.section {
    display: none; /* Hide by default */
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 30px 5%;
    max-width: 1200px;
    width: 100%;
}

.section.active {
    display: flex; /* Show active section */
}

/* Animations */
.animate-item {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 2s ease, transform 2s ease;
}

.animate-item.in-view {
    opacity: 1;
    transform: translateY(0);
}

/* Components */
.rounded-box {
    background-color: var(--bg-white-trans);
    border-radius: var(--border-radius);
    padding: 20px 25px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.rounded-box h3 {
    font-family: var(--font-heading);
    color: var(--primary-color);
    margin-bottom: 8px;
    font-size: 1.1rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.full-box {
    width: 100%;
    max-width: 900px;
}

.full-box p {
    margin-bottom: 15px;
}

/* Director Section */
.director-photo-float {
    /* Styles are handled inline mostly, but we need mobile reset */
}

@media (max-width: 768px) {
    .director-photo-float {
        float: none !important;
        margin: 0 auto 30px auto !important;
        display: block;
    }
    .about-section .rounded-box {
        text-align: center !important;
    }
    .about-section h3 {
        text-align: center;
    }
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition-smooth);
    border: 2px solid transparent;
    cursor: pointer;
    font-family: var(--font-body);
}

.btn-dark {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.btn-dark:hover {
    background-color: transparent;
    color: var(--primary-color);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
    gap: 8px;
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn-light-btn {
    background-color: white;
    color: var(--primary-color);
    border: 1px solid #ccc;
    gap: 8px;
    display: inline-flex;
    align-items: center;
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 500;
}

.btn-light-btn:hover {
    background-color: #f0f0f0;
}

.saiba-mais-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    text-decoration: underline;
    cursor: pointer;
    font-size: 0.9rem;
    margin-top: 10px;
    display: inline-block;
    padding: 0;
    font-family: var(--font-body);
}

/* Home Section */
.home-section {
    text-align: center;
}

.home-section h1 {
    font-family: var(--font-heading);
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.home-section h2 {
    font-weight: 400;
    font-size: 1.5rem;
    margin-bottom: 30px;
}

.home-section > p {
    max-width: 800px;
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.primary-box {
    margin-bottom: 40px;
    max-width: 600px;
    font-weight: 500;
    font-size: 1.1rem;
}

.action-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
}

/* Grid Layouts */
.grid-section {
    width: 100%;
}

.grid-2x2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    width: 100%;
}

.grid-2x3 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    width: 100%;
}

.values-list {
    list-style-position: inside;
    margin-left: 10px;
}

/* Contact Section */
.contact-section {
    width: 100%;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    width: 100%;
    margin-bottom: 30px;
}

.form-group {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.form-group label {
    width: 120px;
    font-weight: 600;
}

.form-group input, .form-group textarea, .form-group select {
    flex: 1;
    background: transparent;
    border: none;
    border-bottom: 1px solid #ccc;
    padding: 8px 0;
    font-family: var(--font-body);
    font-size: 1rem;
    outline: none;
    color: var(--text-color);
}

.ddi-wrapper {
    flex: 0 0 80px;
    margin-right: 15px;
    position: relative;
}

.ddi-wrapper select {
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    position: absolute;
    left: 0;
    top: 0;
    z-index: 2;
    appearance: none;
    -webkit-appearance: none;
}

#ddi-display {
    display: flex;
    align-items: center;
    width: 100%;
    pointer-events: none;
    border-bottom: 1px solid #ccc;
    padding: 8px 0;
    color: var(--text-color);
    font-size: 0.9rem;
    font-family: var(--font-body);
    box-sizing: border-box;
}

.form-group textarea {
    resize: none;
    height: 100%;
    min-height: 150px;
    border: none;
}

.msg-group {
    flex-direction: column;
    align-items: flex-start;
    height: 100%;
}

.msg-group label {
    margin-bottom: 10px;
}

.contact-msg-box {
    display: flex;
    flex-direction: column;
}

.contact-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
}

/* Footer */
.footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #e5e6e3;
    padding: 15px 5%;
    z-index: 1000;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.footer-links a {
    color: var(--text-color);
    text-decoration: none;
}

.footer-links .separator {
    margin: 0 10px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(3px);
    justify-content: center;
    align-items: center;
}

.modal-content {
    max-width: 600px;
    width: 90%;
    position: relative;
    padding: 40px;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--primary-color);
}

/* Responsive */
@media (max-width: 992px) {
    .main-content {
        margin-bottom: 120px;
    }

    .grid-2x2, .grid-2x3, .contact-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: #e5e6e3;
        flex-direction: column;
        padding: 20px;
        text-align: center;
        box-shadow: 0 5px 10px rgba(0,0,0,0.1);
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
}

@media (max-width: 768px) {
    .home-section h1 {
        font-size: 2.5rem;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .contact-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .contact-actions .btn {
        width: 100%;
        margin: 0;
    }
    
    .rounded-box {
        padding: 25px 20px !important;
    }
    
    .form-group {
        flex-direction: column;
        align-items: stretch;
    }
    
    .form-group label {
        margin-bottom: 5px;
    }
}
