/* ==================================================
   PANTYTEX - Modern Business Website
   ================================================== */

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

:root {
    /* ========== PRIMARY PALETTE ========== */
    --primary-color: #2C497F;
    --secondary-color: #5EB1BF;
    /* ========== ACCENT PALETTE ========== */
    --accent-color: #5BC0BE;
    --accent-light: #8FD9E8;
    --accent-dark: #0B132B;
    
    /* ========== TEXT COLORS ========== */
    --text-light: #ffffff;
    --text-dark: #1C2541;
    --text-medium: #3A506B;
    
    /* ========== BACKGROUND COLORS ========== */
    --section-light-bg: #F0F4F8;
    --section-dark-bg: #1C2541;
    
    /* ========== BORDER & UTILITY ========== */
    --border-subtle: #5BC0BE;
    --footer-bg: #0B132B;
    --hover-overlay: rgba(91, 192, 190, 0.1);
    --overlay-light: rgba(255, 255, 255, 0.05);
    --overlay-dark: rgba(0, 0, 0, 0.2);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    overflow-x: hidden;
    background: var(--primary-color);
}

/* ==================================================
   NAVIGATION BAR
   ================================================== */

.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(44, 73, 127, 0.98); /* new primary color, less purple */
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 5%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-light);
    letter-spacing: 2px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-icon {
    font-size: 2rem;
}

/* Language Switcher */
.language-switcher {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

#languageSelect {
    padding: 0.6rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    border: 1px solid rgba(255, 255, 255, 0.2);
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    border-radius: 4px;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.5rem center;
    background-size: 1.2em 1.2em;
    padding-right: 2.5rem;
}

#languageSelect:hover {
    background-color: rgba(255, 255, 255, 0.15);
    border-color: var(--accent-color);
}

#languageSelect option {
    background: #52528C;
    color: var(--text-light);
}

.lang-btn.active {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

/* Navigation Links */
.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
    align-items: center;
}

.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    z-index: 1001;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-light);
    transition: all 0.3s ease;
}

/* ==================================================
   HERO SECTION
   ================================================== */

.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: linear-gradient(135deg, #52528C 0%, #6B7BA5 100%);
    margin-top: 70px;
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.3;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.6));
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--text-light);
    padding: 4rem 2rem;
    max-width: 900px;
}

.hero-badge {
    display: inline-block;
    padding: 0.8rem 2rem;
    background: rgba(28, 37, 65, 0.2);
    border: 1px solid var(--accent-color);
    color: var(--accent-color);
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 2rem;
    border-radius: 50px;
    animation: fadeInDown 1s ease;
}

.hero-content h1 {
    font-size: 5rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    animation: fadeInUp 1s ease 0.2s backwards;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-subtitle {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    opacity: 0.95;
    animation: fadeInUp 1s ease 0.3s backwards;
    font-weight: 300;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 3rem;
    opacity: 0.85;
    animation: fadeInUp 1s ease 0.4s backwards;
    font-weight: 300;
    line-height: 1.8;
}

.cta-button {
    display: inline-block;
    padding: 1.2rem 3.5rem;
    background: var(--accent-color);
    color: white;
    text-decoration: none;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: all 0.4s ease;
    animation: fadeInUp 1s ease 0.5s backwards;
    border: 2px solid var(--accent-color);
    cursor: pointer;
    font-size: 1rem;
}

.cta-button:hover {
    background: transparent;
    color: var(--accent-color);
    transform: translateY(-3px);
    box-shadow: 0 15px 40px #1C2541;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==================================================
   SECTIONS STYLING
   ================================================== */

section {
    scroll-margin-top: 80px;
}

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

.section-light {
    background: var(--section-light-bg);
    padding: 6rem 5%;
}

.section-dark {
    background: var(--section-dark-bg);
    color: var(--text-light);
    padding: 6rem 5%;
}

.section-title {
    font-size: 3.2rem;
    font-weight: 900;
    text-align: center;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    display: inline-block;
    width: 100%;
}

.section-light .section-title {
    color: var(--primary-color);
}

.section-dark .section-title {
    color: var(--accent-light);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: var(--accent-color);
}

.section-intro {
    text-align: center;
    font-size: 1.2rem;
    color: var(--text-medium);
    max-width: 800px;
    margin: 3rem auto;
    line-height: 1.8;
}

.section-dark .section-intro {
    color: rgba(255, 255, 255, 0.8);
}

/* ==================================================
   AZIENDA SECTION
   ================================================== */

#azienda {
    background: var(--section-light-bg);
    padding: 6rem 5%;
}

.department-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
    margin: 4rem 0;
}

.department-card {
    background: white;
    padding: 3rem 2.5rem;
    border-radius: 0;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Flip-card styles for department photos */
.flip-card {
    perspective: 1200px;
    cursor: pointer;
    padding: 0; /* inner content handles padding */
}
.flip-card .flip-inner {
    position: relative;
    width: 100%;
    min-height: 500px;
    transition: transform 0.7s cubic-bezier(.2,.9,.2,1);
    transform-style: preserve-3d;
}
.flip-card.flipped .flip-inner {
    transform: rotateY(180deg);
}
.flip-front, .flip-back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 2;
    overflow: hidden;
}
.flip-front {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
}
.flip-front .dept-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
/* Certification logo styling */
.flip-front .cert-logo {
    max-width: 120px;
    max-height: 120px;
    object-fit: contain;
    padding: 1rem;
}
.card-front-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.6) 100%);
    color: #fff;
    padding: 1.5rem;
    text-align: left;
}
.card-front-overlay h3 { margin: 0; font-size: 1.5rem; text-transform: uppercase; }
.flip-back {
    background: #fff;
    transform: rotateY(180deg);
    padding: 2rem 1.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-medium);
}
.flip-back .card-icon { font-size: 1.8rem; margin-bottom: 1rem; }
.flip-back h3 { color: var(--primary-color); margin-bottom: .5rem; font-size: 1.2rem; }
.flip-back p { max-width: 100%; text-align: center; font-size: 0.95rem; line-height: 1.5; overflow-y: auto; max-height: calc(100% - 6rem); }

/* Accessibility: allow keyboard users to flip */
.flip-card:focus { outline: 2px dashed var(--accent-color); outline-offset: 6px; }

.department-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-color) 0%, var(--accent-light) 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.department-card:hover {
    transform: translateY(-15px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

.department-card:hover::before {
    transform: scaleX(1);
}

.card-icon {
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

.department-card h3 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.department-card p {
    font-size: 1.05rem;
    color: var(--text-medium);
    line-height: 1.8;
}

/* Stats Container */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 2rem;
    margin-top: 5rem;
    padding-top: 3rem;
    border-top: 2px solid var(--border-subtle);
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 3.5rem;
    font-weight: 900;
    color: var(--accent-color);
    display: block;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1rem;
    color: var(--text-medium);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

/* ==================================================
   SERVICES SECTION
   ================================================== */

#servizi {
    background: var(--section-dark-bg);
    color: var(--text-light);
    padding: 6rem 5%;
}

#servizi .section-intro {
    color: rgba(255, 255, 255, 0.8);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
    margin-top: 4rem;
}

.service-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 2.5rem;
    border: 1px solid rgba(212, 165, 116, 0.2);
    text-align: center;
    transition: all 0.4s ease;
    cursor: pointer;
}

.service-card:hover {
    background: rgba(212, 165, 116, 0.1);
    border-color: var(--accent-color);
    transform: translateY(-10px);
}

.service-icon {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    display: block;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent-color);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.service-card p {
    font-size: 1.05rem;
    line-height: 1.7;
    opacity: 0.9;
}

/* ==================================================
   SUSTAINABILITY SECTION
   ================================================== */

#sostenibilita {
    background: white;
    padding: 6rem 5%;
}

.sustainability-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.sustainability-item {
    padding: 2.5rem;
    background: var(--section-light-bg);
    border-left: 4px solid var(--accent-color);
    transition: all 0.3s ease;
}

.sustainability-item:hover {
    transform: translateX(10px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
}

.sustainability-item h3 {
    font-size: 1.3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-weight: 700;
}

.sustainability-item p {
    font-size: 1rem;
    color: var(--text-medium);
    line-height: 1.7;
}

/* Process Timeline */
.process-timeline {
    background: var(--section-light-bg);
    padding: 4rem;
    margin-top: 4rem;
    border-radius: 0;
}

.process-timeline h3 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 3rem;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.timeline {
    display: flex;
    justify-content: space-around;
    gap: 1rem;
    position: relative;
    padding: 2rem 0;
    overflow-x: auto;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 30px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-color), transparent);
    z-index: -1;
}

.timeline-item {
    flex: 1;
    min-width: 150px;
    text-align: center;
    position: relative;
}

.timeline-number {
    width: 60px;
    height: 60px;
    background: var(--accent-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 900;
    margin: 0 auto 1.5rem;
    position: relative;
    z-index: 1;
}

.timeline-item h4 {
    font-size: 1.1rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-weight: 700;
    text-transform: uppercase;
}

.timeline-item p {
    font-size: 0.95rem;
    color: var(--text-medium);
}

/* ==================================================
   CERTIFICATIONS SECTION
   ================================================== */

#certificazioni {
    background: var(--section-dark-bg);
    color: var(--text-light);
    padding: 6rem 5%;
}

.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.cert-item {
    padding: 2.5rem;
    background: rgba(255, 255, 255, 1);
    border: 2px solid rgba(15, 255, 255, 0.3);
    transition: all 0.3s ease;
    text-align: center;
}

.cert-item:hover {
    border-color: var(--primary-color);
    background: rgba(15, 255, 255, 0.1);
    transform: scale(1.05);
}

.cert-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    display: block;
}

.cert-item h4 {
    font-size: 1.4rem;
    color: var(--primary-color);
    margin-bottom: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
}

.cert-item p {
    font-size: 0.95rem;
    line-height: 1.6;
    opacity: 0.9;
}

/* Make certificate cards use the same flip-card pattern as department cards
   - remove inner padding so the flip-inner can control the size
   - add perspective and overflow hidden so the 3D flip looks correct
   - ensure front/back faces cover the full card area
*/
.cert-item.flip-card {
    padding: 0;
    perspective: 1200px;
    cursor: pointer;
    overflow: hidden;
    border: 2px solid rgba(15, 255, 255, 0.15);
    background: transparent;
}
.cert-item.flip-card .flip-inner {
    position: relative;
    width: 100%;
    min-height: 160px; /* ensures a reasonable click area */
    transition: transform 0.7s cubic-bezier(.2,.9,.2,1);
    transform-style: preserve-3d;
}
.cert-item.flip-card.flipped .flip-inner {
    transform: rotateY(180deg);
}
.cert-item.flip-card .flip-front,
.cert-item.flip-card .flip-back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    box-sizing: border-box;
}
.cert-item.flip-card .flip-front {
    background: rgba(255,255,255,0.03);
}
.cert-item.flip-card .flip-back {
    transform: rotateY(180deg);
    background: rgba(255,255,255,1);
    color: var(--text-dark);
    text-align: center;
    padding: 1.25rem;
}
.cert-item .cert-logo {
    max-width: 120px;
    max-height: 120px;
}

/* ==================================================
   CONTACT SECTION
   ================================================== */

#contattaci {
    background: white;
    padding: 6rem 5%;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.contact-card {
    background: var(--section-light-bg);
    padding: 2.5rem;
    border-left: 4px solid var(--accent-color);
    transition: all 0.3s ease;
}

.contact-card:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transform: translateY(-5px);
}

.contact-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--accent-color);
    font-weight: 700;
    text-transform: uppercase;
}

.contact-card p {
    line-height: 1.8;
    color: var(--text-medium);
}

.contact-form {
    margin-top: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: white;
    border: 1px solid var(--border-subtle);
    color: var(--text-dark);
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(15, 255, 255, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

.submit-btn {
    padding: 1rem 2.5rem;
    background: var(--primary-color);
    color: var(--accent-color);
    border: 2px solid var(--primary-color);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.submit-btn:hover {
    background: var(--accent-color);
    color: var(--primary-color);
}

/* ==================================================
   WHISTLEBLOWING POLICY SECTION
   ================================================== */

#whistleblowing-policy {
    background: var(--section-dark-bg);
    color: var(--text-light);
    padding: 6rem 5%;
}

.policy-content {
    max-width: 1000px;
    margin: 3rem auto;
}

.policy-section {
    margin-bottom: 3rem;
}

.policy-section h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
}

.policy-list {
    margin-left: 2rem;
    line-height: 2;
    font-size: 1.05rem;
}

.policy-list li {
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.85);
}

.policy-list li::marker {
    color: var(--primary-color);
    font-weight: 700;
}

.link {
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

.link:hover {
    text-decoration: underline;
    color: var(--text-dark);
}

/* ==================================================
   FOOTER
   ================================================== */

.footer {
    background: rgba(44, 73, 127, 0.98); /* match header background */
    color: var(--text-light);
    padding: 4rem 5% 2rem;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-section h4 {
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.footer-section ul {
    list-style: none;
}

.footer-section li {
    margin-bottom: 0.8rem;
}

.footer-section a {
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.footer-section a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

.social-links {
    display: flex;
    gap: 1.5rem;
}

.social-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 255, 255, 0.1);
    border: 1px solid rgba(15, 255, 255, 0.3);
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
    border-radius: 50%;
}

.social-icon:hover {
    background: var(--accent-color);
    color: var(--primary-color);
    border-color: var(--accent-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
}

.footer-bottom p {
    font-size: 0.95rem;
    opacity: 0.7;
    line-height: 1.6;
}

.made-in-italy {
    color: var(--primary-color);
    font-weight: 700;
    margin-top: 0.5rem;
}

/* ==================================================
   RESPONSIVE DESIGN
   ================================================== */

@media (max-width: 1024px) {
    .language-switcher {
        order: 3;
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: rgba(26, 26, 26, 0.99);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2rem;
        transition: left 0.3s ease;
        z-index: 999;
    }

    .nav-links.active {
        left: 0;
    }

    .menu-toggle {
        display: flex;
    }

    .hero {
        margin-top: 70px;
    }

    .hero-content {
        padding: 2rem;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.3rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .section-title {
        font-size: 2rem;
        margin-bottom: 1rem;
    }

    .department-grid,
    .services-grid,
    .sustainability-grid,
    .cert-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .timeline {
        flex-direction: column;
    }

    .timeline::before {
        top: auto;
        left: 29px;
        width: 2px;
        height: 100%;
        background: linear-gradient(180deg, var(--accent-color), transparent);
    }

    .timeline-item {
        padding-left: 3rem;
        text-align: left;
    }

    .timeline-number {
        position: absolute;
        left: 0;
        margin: 0;
    }

    .process-timeline {
        padding: 2rem;
    }

    .process-timeline h3 {
        font-size: 1.5rem;
    }

    .section-light,
    .section-dark,
    #azienda,
    #contattaci {
        padding: 4rem 4%;
    }

    .stats-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    .stat-number {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .navbar {
        padding: 1rem 3%;
    }

    .nav-container {
        gap: 1rem;
    }

    .logo {
        font-size: 1.3rem;
    }

    .language-switcher {
        gap: 0.3rem;
    }

    .lang-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.8rem;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-description {
        font-size: 0.95rem;
        margin-bottom: 2rem;
    }

    .cta-button {
        padding: 1rem 2rem;
        font-size: 0.9rem;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .section-intro {
        font-size: 1rem;
    }

    .department-card,
    .service-card,
    .sustainability-item,
    .contact-card {
        padding: 2rem 1.5rem;
    }

    .section-light,
    .section-dark,
    #azienda,
    #contattaci,
    #servizi,
    #sostenibilita,
    #certificazioni,
    #whistleblowing-policy {
        padding: 3rem 4%;
    }

    .footer-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .stats-container {
        grid-template-columns: 1fr;
    }

    .stat-number {
        font-size: 2rem;
    }
}

@media (min-width: 1920px) {
    .hero-content h1 {
        font-size: 6rem;
    }

    .hero-subtitle {
        font-size: 2rem;
    }

    .section-title {
        font-size: 4rem;
    }
}

/* ==================================================
   UTILITY CLASSES
   ================================================== */

.text-center {
    text-align: center;
}

.mt-1 {
    margin-top: 1rem;
}

.mt-2 {
    margin-top: 2rem;
}

.mb-1 {
    margin-bottom: 1rem;
}

.mb-2 {
    margin-bottom: 2rem;
}

/* Loading & Animations */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

@keyframes slideIn {
    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);
    }
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--accent-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}
