/* ==========================================
   MAVI HOLDING - MODERN BLACK & WHITE THEME
   Inspired by TEMPLUS design
   ========================================== */

/* CSS VARIABLES */
:root {
    --color-black: #000000;
    --color-white: #ffffff;
    --color-gray-100: #f8f9fa;
    --color-gray-200: #e9ecef;
    --color-gray-300: #dee2e6;
    --color-gray-400: #ced4da;
    --color-gray-500: #adb5bd;
    --color-gray-600: #6c757d;
    --color-gray-700: #495057;
    --color-gray-800: #343a40;
    --color-gray-900: #212529;

    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.2s ease;

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

/* RESET & BASE STYLES */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--color-gray-900);
    background-color: var(--color-white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
}

/* BACKGROUND LOGO WATERMARK */
body::before {
    content: '';
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100vw;
    height: 100vh;
    background-image: url('../images/logo_mavi.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.03;
    z-index: -999;
    pointer-events: none;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

/* TYPOGRAPHY */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    color: var(--color-black);
}

h1 { font-size: 3.5rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.25rem; }

/* CONTAINER */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* HEADER */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-gray-200);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.header.scrolled {
    background-color: rgba(255, 255, 255, 0);
    backdrop-filter: blur(20px);
    border-bottom-color: transparent;
    transform: translateY(-100%);
    opacity: 0;
}

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

.logo-wrapper {
    display: flex;
    align-items: center;
}

.logo {
    height: 80px;
    width: auto;
}

.nav {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--color-gray-700);
    position: relative;
    transition: var(--transition-fast);
}

.nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-black);
    transition: var(--transition-smooth);
}

.nav a:hover {
    color: var(--color-black);
}

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

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.menu-toggle span {
    width: 25px;
    height: 2px;
    background-color: var(--color-black);
    transition: var(--transition-fast);
}

/* HERO SECTION */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: linear-gradient(135deg, var(--color-gray-100) 0%, var(--color-white) 100%);
    padding-top: 80px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(0, 0, 0, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(0, 0, 0, 0.02) 0%, transparent 50%);
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 900px;
    padding: 2rem;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.hero-divider {
    width: 100px;
    height: 3px;
    background-color: var(--color-black);
    margin: 0 auto 2rem;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--color-gray-700);
    margin-bottom: 3rem;
    font-weight: 400;
}

.hero-cta {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
}

.scroll-indicator {
    display: none; /* Nasconde completamente l'indicatore di scroll */
}

.scroll-indicator span {
    display: none;
}

.scroll-arrow {
    display: none;
}

@keyframes scroll {
    0%, 100% { transform: translateY(0); opacity: 0; }
    50% { transform: translateY(10px); opacity: 1; }
}

/* BUTTONS */
.btn {
    display: inline-block;
    padding: 1rem 2.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 2px;
    transition: var(--transition-smooth);
    cursor: pointer;
    border: 2px solid transparent;
}

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

.btn-primary:hover {
    background-color: var(--color-gray-900);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: var(--color-white);
    color: var(--color-black);
    border-color: var(--color-black);
}

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

.btn-outline {
    background-color: transparent;
    color: var(--color-black);
    border-color: var(--color-black);
}

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

.btn-large {
    padding: 1.25rem 3rem;
    font-size: 1.1rem;
}

/* SECTIONS */
.section {
    padding: 6rem 0;
    background-color: transparent;
}

.section-light {
    background-color: transparent;
}

.section-dark {
    background-color: var(--color-black);
    color: var(--color-white);
}

.section-dark * {
    color: var(--color-white);
}

.section-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

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

.section-subtitle {
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-gray-600);
    margin-bottom: 0.5rem;
}

.section-subtitle-light {
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-gray-400);
    margin-bottom: 0.5rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-black);
}

.section-title-light {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-white);
}

.section-text {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-gray-700);
}

.section-text-light {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-gray-300);
}

.section-header-center {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 4rem;
}

/* SERVICES */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.service-card {
    padding: 2.5rem;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition-smooth);
}

.service-card:hover {
    background-color: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-5px);
}

.service-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--color-white);
}

.service-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--color-white);
}

.service-desc {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--color-gray-300);
    margin-bottom: 1.5rem;
}

.service-link {
    color: var(--color-white);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    transition: var(--transition-fast);
}

.service-link:hover {
    transform: translateX(5px);
}

/* TEAM */
.team-showcase {
    max-width: 1100px;
    margin: 0 auto;
}

.team-member-featured {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 4rem;
    align-items: start;
}

.team-member-image {
    width: 100%;
    height: 600px;
    overflow: hidden;
    background-color: var(--color-gray-100);
    border-radius: 20px;
    position: relative;
}

.team-member-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 20px;
    pointer-events: none;
    z-index: 1;
}

.team-member-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: none; /* Mantiene i colori originali */
    transition: var(--transition-smooth);
    border-radius: 20px;
}

.team-member-image:hover img {
    transform: scale(1.05);
}

.team-member-content {
    padding: 2rem 0;
}

.team-member-name {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.team-member-role {
    font-size: 1.1rem;
    color: var(--color-gray-600);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.team-member-bio {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--color-gray-700);
    margin-bottom: 2rem;
}

.team-member-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.detail-group h4 {
    font-size: 1rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-black);
}

.detail-list {
    list-style: none;
}

.detail-list li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--color-gray-700);
}

.detail-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--color-black);
    font-weight: 600;
}

/* BENEFITS */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.benefit-card {
    padding: 2rem;
}

.benefit-number {
    font-size: 3rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.2);
    margin-bottom: 1rem;
}

.benefit-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--color-white);
}

.benefit-card p {
    color: var(--color-gray-300);
    line-height: 1.7;
}

/* CONTACT */
.contact-container {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 4rem;
    max-width: 1100px;
    margin: 0 auto;
}

.contact-form {
    background-color: transparent;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 1.5rem;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--color-gray-700);
}

.form-group input,
.form-group textarea {
    padding: 1rem;
    font-size: 1rem;
    font-family: inherit;
    border: 2px solid var(--color-gray-300);
    background-color: var(--color-white);
    transition: var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-black);
}

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

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-item {
    display: flex;
    gap: 1.5rem;
}

.contact-icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-black);
    color: var(--color-white);
}

.contact-item h4 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.contact-item p {
    color: var(--color-gray-700);
    line-height: 1.6;
}

.contact-item a {
    color: var(--color-black);
    font-weight: 600;
    transition: var(--transition-fast);
}

.contact-item a:hover {
    text-decoration: underline;
}

/* FOOTER */
.footer {
    background-color: var(--color-black);
    color: var(--color-white);
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    height: 60px;
    width: auto;
    margin-bottom: 1rem;
    filter: brightness(0) invert(1);
}

.footer-desc {
    color: var(--color-gray-400);
    line-height: 1.6;
}

.footer-col h4 {
    font-size: 1rem;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-white);
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-links a {
    color: var(--color-gray-400);
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: var(--color-white);
}

.footer-links li:not(:has(a)) {
    color: var(--color-gray-500);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--color-gray-500);
    font-size: 0.9rem;
}

.footer-legal {
    display: flex;
    gap: 2rem;
}

.footer-legal a {
    color: var(--color-gray-500);
    transition: var(--transition-fast);
}

.footer-legal a:hover {
    color: var(--color-white);
}

/* BACK TO TOP BUTTON */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background-color: var(--color-black);
    color: var(--color-white);
    border: 2px solid var(--color-black);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 999;
    box-shadow: var(--shadow-lg);
}

.back-to-top:hover {
    background-color: var(--color-white);
    color: var(--color-black);
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top svg {
    width: 24px;
    height: 24px;
}

/* RESPONSIVE */
@media (max-width: 968px) {
    .nav {
        display: none;
    }

    .menu-toggle {
        display: flex;
    }

    .hero-title {
        font-size: 3rem;
    }

    .section-grid,
    .team-member-featured,
    .contact-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .team-member-image {
        height: 400px;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }

    .section {
        padding: 4rem 0;
    }
}

@media (max-width: 640px) {
    html {
        font-size: 14px;
    }

    .container {
        padding: 0 1.5rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-cta {
        flex-direction: column;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .team-member-details {
        grid-template-columns: 1fr;
    }
}
