:root {
    --primary-color: #660033;
    --secondary-color: #000000;
    --text-color: #000000;
    --bg-color: #ffffff;
    --light-gray: #f4f4f4;
    --white: #ffffff;
    --font-primary: 'Outfit', sans-serif;
    --font-secondary: 'Inter', sans-serif;
    --container-width: 1200px;
    --header-height: 80px;
}

/* Fonts */

/* Outfit - Latin */
@font-face {
    font-family: 'Outfit';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/QGYvz_MVcBeNP4NJtEtq.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Outfit - Latin-Ext */
@font-face {
    font-family: 'Outfit';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/QGYvz_MVcBeNP4NJuktqQ4E.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* Outfit - Latin (Bold/600 reused as per original site practice if identical file, 
   but ideally should be different. Since we only have one weight file per subset, 
   we map it to 600 as well or rely on browser synthesis. 
   Original CSS used same file for 400 and 600. We will do the same.) */
@font-face {
    font-family: 'Outfit';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/QGYvz_MVcBeNP4NJtEtq.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Inter - Latin */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/UcC73FwrK3iLTeHuS_nVMrMxCp50SjIa1ZL7.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Inter - Latin-Ext */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/UcC73FwrK3iLTeHuS_nVMrMxCp50SjIa25L7SUc.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

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

html, body {
    height: 100%;
}

body {
    font-family: var(--font-secondary);
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* Layout */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 80px 0;
}

/* Header */
.header {
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.header .container {
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 60px; /* Increased from 40px to 60px as requested */
    width: auto;
}

.nav-menu {
    display: flex;
    gap: 30px;
}

.nav-link {
    font-weight: 500;
    font-size: 16px;
    position: relative;
}

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

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary-color);
}

.hamburger {
    display: none;
    cursor: pointer;
    font-size: 24px;
}

/* Hero Section with Parallax Image */
.hero {
    height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    margin-top: 0;
    /* New Parallax Background */
    background-image: url('../images/photo-1683881069807-779ed411ab51.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Creates the parallax effect */
    background-repeat: no-repeat;
}

.hero p {
    font-size: 1.125rem; /* 18px */
    line-height: 1.6;
    margin-bottom: 24px;
    color: var(--light-gray);
}

/* Removed .hero-video styles */

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Gradient overlay for better text readability and branding */
    background: linear-gradient(135deg, rgba(0,0,0,0.7) 0%, rgba(102, 0, 51, 0.4) 100%);
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: 20px;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
}

/* Button - Clean up old styles */
.btn {
    display: inline-block;
    padding: 12px 30px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid var(--primary-color);
    cursor: pointer;
}

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

/* Services Preview */
.services-preview {
    background: linear-gradient(135deg, var(--primary-color) 0%, #4a0025 100%);
    position: relative;
    z-index: 1;
    color: var(--white);
    padding: 100px 0;
}

.services-preview h2 {
    color: var(--white);
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
    position: relative;
}

.services-preview h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--white);
    margin: 15px auto 0;
    border-radius: 2px;
}

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

.service-card {
    background: rgba(255, 255, 255, 0.95);
    padding: 40px 30px;
    border-radius: 15px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    border-top: none;
    position: relative;
    overflow: hidden;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.service-icon {
    width: 70px;
    height: 70px;
    background: var(--light-gray);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.service-icon svg {
    width: 35px;
    height: 35px;
    stroke: var(--primary-color);
    transition: stroke 0.3s ease;
}

.service-card h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.service-card p {
    color: var(--text-color);
    font-size: 1rem;
    line-height: 1.6;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.service-card:hover .service-icon {
    background: var(--primary-color);
}

.service-card:hover .service-icon svg {
    stroke: var(--white);
}

/* Contact Section Redesign (Scheda Contatti Modernizzata) */
.contact-section {
    position: relative;
    padding: 80px 0 100px;
    background-color: var(--light-gray);
    min-height: calc(100vh - var(--header-height));
    margin-top: var(--header-height);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.contact-bg-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Subtle geometric pattern using primary color */
    background-image: radial-gradient(rgba(102, 0, 51, 0.03) 2px, transparent 2px);
    background-size: 40px 40px;
    z-index: 0;
}

.relative-z {
    position: relative;
    z-index: 1;
}

.contact-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 60px;
}

.contact-header h1 {
    font-family: var(--font-primary);
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 20px;
    line-height: 1.1;
}

.contact-header p {
    font-size: 1.2rem;
    color: #666;
    line-height: 1.6;
}

/* Grid Layout for Contact Cards */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    width: 100%;
}

.contact-card-item {
    background: var(--white);
    padding: 40px 30px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    text-align: center;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
    border: 1px solid rgba(0,0,0,0.02);
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.contact-card-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: var(--primary-color);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.contact-card-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(102, 0, 51, 0.08);
}

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

.icon-box {
    width: 80px;
    height: 80px;
    background: rgba(102, 0, 51, 0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    color: var(--primary-color);
    transition: all 0.3s ease;
}

.contact-card-item:hover .icon-box {
    background: var(--primary-color);
    color: var(--white);
    transform: rotate(5deg) scale(1.1);
}

.card-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-grow: 1;
    width: 100%;
}

.card-content h3 {
    font-family: var(--font-primary);
    font-size: 1.5rem;
    color: var(--secondary-color);
    margin-bottom: 10px;
    font-weight: 700;
}

.card-content p {
    color: #666;
    margin-bottom: 25px;
    font-size: 1rem;
    line-height: 1.5;
}

.contact-text {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 1.15rem;
    padding: 10px 20px;
    background: #fcfcfc;
    border-radius: 30px;
    border: 1px solid #eee;
}

.contact-link-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 30px;
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    font-size: 1rem;
}

.contact-link-action:hover, .contact-link-action:focus {
    background-color: var(--primary-color);
    color: var(--white);
    box-shadow: 0 5px 15px rgba(102, 0, 51, 0.3);
    outline: none;
}

/* Social Icons in Card */
.social-links-row {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: auto;
}

.social-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #f8f8f8;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-color);
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border: 1px solid #eee;
}

.social-btn:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-5px);
    border-color: var(--primary-color);
    box-shadow: 0 5px 15px rgba(102, 0, 51, 0.2);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-up {
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }

/* Responsive Adjustments for Contact */
@media (max-width: 768px) {
    .contact-header h1 {
        font-size: 2.5rem;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .contact-card-item {
        padding: 30px 20px;
    }
}

/* Footer */
.footer {
    background: var(--secondary-color);
    color: var(--white);
    padding: 40px 0;
    text-align: center;
    margin-top: auto;
    border-top: 5px solid var(--primary-color);
}

/* About Section */
.about {
    background-color: var(--white);
    position: relative;
    z-index: 2;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
    margin-bottom: 60px;
}

.about-left h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    line-height: 1.2;
}

.about-description {
    font-size: 1.1rem;
    color: var(--text-color);
    margin-bottom: 30px;
}

.stats-container {
    display: flex;
    gap: 40px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-color);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 5px;
}

.about-image-container {
    width: 100%;
    display: flex;
    justify-content: center;
}

.rounded-image {
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 100%;
    height: 400px;
    object-fit: cover;
    object-position: center;
}

/* Innovative Services Section */
.innovative-services {
    background-color: var(--light-gray);
    padding: 80px 0;
}

.innovative-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

.innovative-col-featured {
    position: relative;
    width: 100%;
}

.innovative-image-wrapper {
    position: relative;
    width: 100%;
    height: 400px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.innovative-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

.innovative-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.6);
    padding: 30px;
    color: var(--white);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.innovative-overlay h2 {
    font-size: 2rem;
    color: var(--white);
    margin-bottom: 10px;
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.innovative-overlay p {
    font-size: 1.1rem;
    line-height: 1.5;
    color: #f0f0f0;
    max-width: 60ch;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.innovative-col-right {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.innovative-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    border: 1px solid rgba(0,0,0,0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.innovative-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 12px rgba(0,0,0,0.1);
}

.innovative-card h3 {
    font-size: 1.25rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.innovative-card p {
    font-size: 0.95rem;
    color: var(--text-color);
    line-height: 1.4;
}

/* Reviews Section */
.reviews-section {
    background-color: #fdf5f8; /* Light distinct background (tint of primary) */
    padding: 80px 0;
}

.reviews-section h2 {
    text-align: center;
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 50px;
}

.reviews-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

.review-card {
    background: var(--white);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    border: 1px solid rgba(102, 0, 51, 0.1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
}

.review-rating {
    color: #ffc107; /* Gold color for stars */
    font-size: 1.5rem;
    margin-bottom: 20px;
    letter-spacing: 5px;
}

.review-text {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--text-color);
    font-style: italic;
    margin-bottom: 30px;
}

.review-author {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-top: auto;
}

.review-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--primary-color);
    flex-shrink: 0;
}

.review-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.review-info {
    display: flex;
    flex-direction: column;
}

.review-name {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary-color);
}

.review-city {
    font-size: 0.9rem;
    color: #666;
}

/* Progetti Page Styles */

/* Intro Section Styling */
.intro-progetti {
    text-align: center;
    padding-bottom: 0; /* Removed padding to eliminate white space */
    background: #ffffff;
}

.intro-progetti h1 {
    font-family: 'Outfit', sans-serif;
    font-size: 3rem; /* Reduced from 3.5rem */
    font-weight: 700; /* Bold */
    color: var(--primary-color);
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
    position: relative;
    display: inline-block;
}

.intro-progetti h1::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--primary-color);
    margin: 15px auto 0;
    border-radius: 2px;
}

.intro-progetti p {
    font-size: 1.3rem;
    color: #555;
    max-width: 800px;
    margin: 0 auto;
    font-weight: 300;
}

/* Portfolio Section Title Styling */
.portfolio-section h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 3rem; /* Min 32px requirement met */
    font-weight: 800; /* Extra-bold */
    color: var(--primary-color);
    text-align: center;
    margin-top: 40px;
    margin-bottom: 20px;
    text-transform: capitalize;
    letter-spacing: -0.5px;
}

.section-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: #555;
    margin-bottom: 60px;
    font-style: italic;
    position: relative;
    padding-bottom: 20px;
}

.section-subtitle::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 2px;
    background-color: #ddd;
}

/* Services 2-Column Section */
.services-details {
    background-color: #FFFFFF;
    padding-bottom: 20px;
    padding-top: 10px; /* Minimal top padding */
}

.portfolio-section {
    background-color: #F8F9FA;
    padding-top: 20px;
}

.progetti-services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    align-items: center;
}

.progetti-text-col h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.progetti-text-col p {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: var(--text-color);
}

.custom-list {
    list-style: none;
    padding: 0;
}

.custom-list li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 15px;
    font-size: 1.05rem;
}

.custom-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.progetti-image-col {
    position: relative;
}

.progetti-image-wrapper {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
    height: 400px;
}

.progetti-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.progetti-image-wrapper:hover img {
    transform: scale(1.05);
}

.progetti-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
}

.progetti-overlay h3 {
    color: white;
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.progetti-overlay p {
    font-size: 1rem;
    color: rgba(255,255,255,0.9);
}

/* Portfolio Grid */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.portfolio-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    height: 300px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-hover {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(102, 0, 51, 0.85); /* Primary color opacity */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    color: white;
    text-align: center;
    padding: 20px;
}

.portfolio-item:hover .portfolio-hover {
    opacity: 1;
}

.portfolio-hover h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.portfolio-hover p {
    font-size: 1rem;
    transform: translateY(20px);
    transition: transform 0.3s ease 0.1s;
}

.portfolio-item:hover .portfolio-hover h3,
.portfolio-item:hover .portfolio-hover p {
    transform: translateY(0);
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    z-index: 2000;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.9);
    animation: fadeIn 0.3s;
}

.lightbox-content {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 900px;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 5px;
    animation: zoomIn 0.3s;
}

#caption {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 700px;
    text-align: center;
    color: #ccc;
    padding: 10px 0;
    height: 150px;
    font-size: 1.2rem;
}

.close-lightbox {
    position: absolute;
    top: 30px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

.close-lightbox:hover,
.close-lightbox:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}

@keyframes zoomIn {
    from {transform:scale(0)} 
    to {transform:scale(1)}
}

/* Responsive Grid for Innovative Services & Reviews & Progetti */
@media (min-width: 768px) {
    .innovative-grid {
        grid-template-columns: 2fr 1fr; /* 66% Image/Text - 33% Cards */
        align-items: stretch;
        gap: 30px;
    }
    
    .innovative-image-wrapper {
        height: 100%;
        min-height: 400px;
    }

    /* Reviews Grid Desktop */
    .reviews-grid {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }

    /* Progetti Services Grid Desktop */
    .progetti-services-grid {
        grid-template-columns: 1fr 1fr;
    }
}
@media (max-width: 768px) {
    .hamburger {
        display: block;
        z-index: 1001;
        position: absolute; /* Ensures absolute positioning */
        right: 20px; /* Aligns to far right */
        top: 50%;
        transform: translateY(-50%);
    }

    .nav-menu {
        position: fixed;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100vh;
        background: white;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: 0.3s ease;
        z-index: 999;
    }

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

    .hero {
        background-attachment: scroll; /* Disable parallax on mobile for performance */
        background-position: center;
    }

    .hero h1 {
        font-size: 2.5rem;
    }
    
    /* About Section Responsive */
    .about-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .about-left h2 {
        font-size: 2rem;
    }
    
    .stats-container {
        gap: 20px;
        flex-wrap: wrap;
    }
    
    .stat-value {
        font-size: 2.5rem;
    }

    .lightbox-content {
        width: 95%;
    }

    /* Progetti Titles Responsive */
    .intro-progetti h1 {
        font-size: 2.2rem;
    }
    
    .portfolio-section h2 {
        font-size: 2.2rem;
    }

    .section-subtitle {
        font-size: 1rem;
        margin-bottom: 40px;
    }

    /* Progetti Spacing Responsive */
    .services-details {
        padding-bottom: 5%;
    }

    .portfolio-section {
        padding-top: 5%;
    }

    /* Insights Section Responsive */
    .insights-grid {
        grid-template-columns: 1fr;
    }
}

/* Insights/News Section Styles */
.insights-section {
    background-color: #1a1a1a;
    color: #ffffff;
    padding: 80px 0;
}

.insights-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.insight-card {
    background-color: transparent;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.insight-content {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.insight-content h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 15px;
    color: #ffffff;
}

.insight-content p {
    font-size: 1rem;
    line-height: 1.6;
    color: #cccccc;
    margin-bottom: 20px;
    flex-grow: 1;
}

.insight-meta {
    font-size: 0.9rem;
    color: #999999;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
}

.insight-meta .separator {
    font-weight: bold;
}

/* Services Page Styles */

/* Services Hero */
.services-hero {
    position: relative;
    height: 60vh;
    min-height: 400px;
    display: flex;
    align-items: center;
    background-image: url('../images/photo-1683881069807-779ed411ab51.jpg'); /* Reusing existing image */
    background-size: cover;
    background-position: center;
    margin-top: 0;
}

.services-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Alternative 1: Neutral Gradient */
    /* background: linear-gradient(to right, rgba(0,0,0,0.8), rgba(0,0,0,0.4)); */
    
    /* Alternative 2: Image Overlay (Semi-transparent) */
    /* background: rgba(0, 0, 0, 0.5); */

    /* Alternative 3 (Selected): Brand Color Gradient */
    background: linear-gradient(135deg, rgba(102, 0, 51, 0.85) 0%, rgba(0, 0, 0, 0.6) 100%);
    z-index: 1;
}

.services-hero-content {
    position: relative;
    z-index: 2;
    color: white;
}

.services-hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    /* Removed black background box */
    background-color: transparent;
    display: block;
    padding: 0;
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.services-hero-content p {
    font-size: 1.2rem;
    /* Removed black background box */
    background-color: transparent;
    display: block;
    padding: 0;
    max-width: 800px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

/* Services List */
.services-list-section {
    background-color: #f9f9f9;
}

.services-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.service-item {
    display: flex;
    flex-direction: column; /* Changed to vertical card */
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%; /* Uniform height */
}

.service-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.service-icon-wrapper {
    background-color: var(--primary-color);
    width: 100%; /* Full width */
    height: 100px; /* Fixed height for icon area */
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.service-icon-wrapper svg {
    width: 48px; /* Uniform 48x48px */
    height: 48px;
    stroke: white;
    stroke-width: 1.5;
}

.service-details-content {
    padding: 30px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.service-details-content h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    line-height: 1.3;
}

.service-details-content p {
    font-size: 1rem;
    color: #555;
    margin-bottom: 20px;
    line-height: 1.6;
    flex-grow: 1; /* Pushes button down */
}

.service-cta {
    display: inline-block;
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.1rem;
    position: relative;
    padding-bottom: 2px;
    align-self: flex-start;
}

.service-cta::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.service-cta:hover::after {
    width: 100%;
}

/* Responsive Services Page */
@media (max-width: 768px) {
    .services-hero-content h1 {
        font-size: 2.5rem;
    }
    
    .services-hero-content p {
        font-size: 1rem;
    }

    .service-item {
        flex-direction: column;
    }

    .service-icon-wrapper {
        width: 100%;
        height: 100px;
    }

    .service-details-content {
        padding: 20px;
    }

    .service-details-content h3 {
        font-size: 1.5rem;
    }
}
