/* ════════════════════════════════════════════════════════════════════════════
   FINHANCE - MOBILE FIRST CSS
   Design System & Variables
════════════════════════════════════════════════════════════════════════════ */

:root {
    /* Colors */
    --green: #07f968;
    --green-dark: #05c854;
    --navy: #1E2761;
    --navy-light: #2a3575;
    --black: #000000;
    --white: #FFFFFF;
    --cream: #FAFAF8;
    --gray-100: #F5F5F4;
    --gray-200: #E8E8E6;
    --gray-400: #9CA3AF;
    --gray-600: #4B5563;
    --gray-800: #1F2937;
    
    /* Typography */
    --font-heading: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    
    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;
    --space-3xl: 64px;
    --space-4xl: 80px;
    
    /* Layout */
    --container-sm: 640px;
    --container-md: 768px;
    --container-lg: 1024px;
    --container-xl: 1200px;
    
    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 400ms ease;
    --transition-bounce: 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
    
    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -2px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.1);
}

/* ════════════════════════════════════════════════════════════════════════════
   RESET & BASE
════════════════════════════════════════════════════════════════════════════ */

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--black);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

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

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

ul, ol {
    list-style: none;
}

/* ════════════════════════════════════════════════════════════════════════════
   TYPOGRAPHY
════════════════════════════════════════════════════════════════════════════ */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.15;
    color: var(--black);
}

h1 {
    font-size: clamp(28px, 6vw, 52px);
}

h2 {
    font-size: clamp(24px, 5vw, 40px);
}

h3 {
    font-size: clamp(20px, 4vw, 28px);
}

h4 {
    font-size: clamp(16px, 3vw, 20px);
}

p {
    color: var(--gray-600);
    line-height: 1.7;
}

strong {
    color: var(--black);
    font-weight: 600;
}

/* ════════════════════════════════════════════════════════════════════════════
   UTILITY CLASSES
════════════════════════════════════════════════════════════════════════════ */

.container {
    width: 100%;
    max-width: var(--container-xl);
    margin: 0 auto;
    padding: 0 var(--space-md);
}

.highlight {
    background: var(--green);
    padding: 2px 8px;
    display: inline;
    color: var(--black);
}

.dashed-box {
    border: 2px dashed var(--green);
    padding: 4px 12px;
    display: inline-block;
}

.text-green {
    color: var(--green);
}

.text-navy {
    color: var(--navy);
}

.section-padding {
    padding: var(--space-3xl) 0;
}

.bg-white {
    background: var(--white);
}

.bg-cream {
    background: var(--cream);
}

/* ════════════════════════════════════════════════════════════════════════════
   BUTTONS
════════════════════════════════════════════════════════════════════════════ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 14px;
    border-radius: 0;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left var(--transition-slow);
}

.btn:hover::before {
    left: 100%;
}

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

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

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

.btn-secondary:hover {
    background: var(--green);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--navy);
    color: var(--navy);
    font-weight: 600;
}

.btn-outline:hover {
    background: var(--navy);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* ════════════════════════════════════════════════════════════════════════════
   CARDS
════════════════════════════════════════════════════════════════════════════ */

.card {
    background: var(--white);
    padding: var(--space-lg);
    border-left: 4px solid var(--green);
    transition: all var(--transition-base);
    position: relative;
}

.card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--green);
    transition: width var(--transition-slow);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.card:hover::after {
    width: 100%;
}

.card-cream {
    background: var(--cream);
}

.card h4 {
    margin-bottom: var(--space-sm);
}

.card p {
    font-size: 14px;
    line-height: 1.7;
}

/* ════════════════════════════════════════════════════════════════════════════
   HEADER
════════════════════════════════════════════════════════════════════════════ */

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    transition: all var(--transition-base);
}

.header.scrolled {
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(0,0,0,0.08);
    padding-top: 0;
    padding-bottom: 0;
}

.header.scrolled .header-container {
    padding-top: var(--space-sm);
    padding-bottom: var(--space-sm);
}

.header.scrolled .logo {
    height: 32px;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-md);
    max-width: var(--container-xl);
    margin: 0 auto;
    transition: padding var(--transition-base);
}

.logo {
    height: 48px;
    width: auto;
    transition: all var(--transition-base);
}

.logo:hover {
    transform: scale(1.05);
}

.nav {
    display: none;
}

.nav-list {
    display: flex;
    gap: var(--space-xl);
}

.nav-link {
    font-weight: 500;
    font-size: 15px;
    position: relative;
    padding: var(--space-xs) 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--green);
    transition: width var(--transition-base);
}

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

.header-cta {
    display: none;
}

/* Mobile Menu Toggle */
.mobile-toggle {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: var(--space-sm);
}

.mobile-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--black);
    transition: all var(--transition-base);
}

.mobile-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--white);
    padding: var(--space-xl);
    transform: translateX(100%);
    transition: transform var(--transition-base);
    z-index: 999;
}

.mobile-menu.active {
    transform: translateX(0);
}

.mobile-menu-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

.mobile-menu-link {
    font-size: 18px;
    font-weight: 500;
    padding: var(--space-md) 0;
    border-bottom: 1px solid var(--gray-200);
}

.mobile-menu-cta {
    margin-top: var(--space-xl);
}

.mobile-menu-cta .btn {
    width: 100%;
}

/* ════════════════════════════════════════════════════════════════════════════
   HERO
════════════════════════════════════════════════════════════════════════════ */

.hero {
    padding-top: 100px;
    padding-bottom: var(--space-3xl);
    overflow: hidden;
}

.hero-container {
    display: flex;
    flex-direction: column;
    gap: var(--space-2xl);
}

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

.hero h1 {
    margin-bottom: var(--space-lg);
    animation: fadeInUp 0.8s ease forwards;
}

.hero-subtitle {
    font-size: clamp(16px, 3vw, 19px);
    margin-bottom: var(--space-xl);
    animation: fadeInUp 0.8s ease 0.2s forwards;
    opacity: 0;
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    animation: fadeInUp 0.8s ease 0.4s forwards;
    opacity: 0;
}

.hero-visual {
    position: relative;
    animation: fadeInRight 1s ease 0.3s forwards;
    opacity: 0;
}

.hero-image {
    width: 100%;
    border-radius: 0;
    overflow: hidden;
    position: relative;
}

.hero-image img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    mix-blend-mode: normal;
}

.hero-grid {
    position: absolute;
    bottom: -20px;
    left: -20px;
    width: 100px;
    opacity: 0.6;
    animation: float 4s ease-in-out infinite;
}

/* ════════════════════════════════════════════════════════════════════════════
   VISION & FILOSOFIA
════════════════════════════════════════════════════════════════════════════ */

.vision {
    padding: var(--space-3xl) 0;
}

.vision-main {
    display: flex;
    flex-direction: column;
    gap: var(--space-2xl);
    margin-bottom: var(--space-3xl);
}

.vision-image {
    position: relative;
}

.vision-image img {
    width: 100%;
    height: auto;
}

.vision-image .grid-overlay {
    position: absolute;
    bottom: -15px;
    left: -15px;
    width: 80px;
    opacity: 0.5;
    animation: float 5s ease-in-out infinite;
}

.vision-content h2 {
    margin-bottom: var(--space-sm);
}

.vision-content h3 {
    font-size: clamp(16px, 3vw, 22px);
    font-weight: 600;
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-sm);
    border-bottom: 3px solid var(--green);
    display: inline-block;
}

.vision-content p {
    font-size: 15px;
    margin-bottom: var(--space-md);
    line-height: 1.8;
}

/* Filosofia */
.filosofia {
    border-top: 1px solid var(--gray-200);
    padding-top: var(--space-2xl);
}

.filosofia h3 {
    font-size: clamp(20px, 4vw, 28px);
    margin-bottom: var(--space-xl);
    text-align: center;
}

.filosofia-grid {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

/* ════════════════════════════════════════════════════════════════════════════
   CFO MODERNO
════════════════════════════════════════════════════════════════════════════ */

.cfo-section {
    padding: var(--space-3xl) 0;
}

.cfo-images {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
    position: relative;
}

.cfo-images img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    object-position: center;
}

.cfo-grid-overlay {
    position: absolute;
    top: -15px;
    left: -15px;
    width: 100px;
    opacity: 0.5;
    z-index: 1;
}

.cfo-header {
    margin-bottom: var(--space-xl);
}

.cfo-header h2 {
    margin-bottom: var(--space-sm);
}

.cfo-header p {
    font-size: 16px;
}

.cfo-cards {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

/* ════════════════════════════════════════════════════════════════════════════
   SERVIZIO CFO FRACTIONAL
════════════════════════════════════════════════════════════════════════════ */

.servizio {
    padding: var(--space-3xl) 0;
}

.servizio-container {
    display: flex;
    flex-direction: column;
    gap: var(--space-2xl);
}

.servizio-content h2 {
    margin-bottom: var(--space-sm);
}

.servizio-content .subtitle {
    font-size: 16px;
    margin-bottom: var(--space-xl);
}

.servizio-cards {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

.servizio-image {
    position: relative;
    order: -1;
}

.servizio-image img {
    width: 100%;
}

.servizio-image .grid-overlay {
    position: absolute;
    top: -15px;
    right: -15px;
    width: 80px;
    opacity: 0.5;
}

/* ════════════════════════════════════════════════════════════════════════════
   ECOSISTEMA
════════════════════════════════════════════════════════════════════════════ */

.ecosistema {
    padding: var(--space-3xl) 0;
}

.ecosistema h2 {
    margin-bottom: var(--space-xl);
}

.ecosistema-grid {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
    margin-bottom: var(--space-xl);
}

.cgo-hero {
    background: var(--cream);
    border: 2px solid var(--green);
    padding: var(--space-xl);
    position: relative;
    overflow: hidden;
}

.cgo-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--green);
}

.cgo-hero h4 {
    font-size: clamp(18px, 3.5vw, 22px);
    margin-bottom: var(--space-md);
    color: var(--navy);
}

.cgo-hero p {
    font-size: 15px;
    line-height: 1.8;
}

.cgo-badge {
    display: inline-block;
    background: var(--green);
    color: var(--black);
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    margin-bottom: var(--space-md);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ════════════════════════════════════════════════════════════════════════════
   METODOLOGIA
════════════════════════════════════════════════════════════════════════════ */

.metodologia {
    padding: var(--space-3xl) 0;
}

.metodologia > .container > h2 {
    margin-bottom: var(--space-sm);
}

.metodologia > .container > p {
    font-size: 16px;
    margin-bottom: var(--space-xl);
    max-width: 700px;
}

.accordion {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.accordion-item {
    background: var(--white);
    border: 1px solid var(--gray-200);
    transition: all var(--transition-base);
}

.accordion-item.active {
    border-color: var(--green);
    box-shadow: var(--shadow-md);
}

.accordion-header {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-lg);
    cursor: pointer;
    transition: background var(--transition-base);
}

.accordion-header:hover {
    background: var(--gray-100);
}

.accordion-num {
    width: 40px;
    height: 40px;
    min-width: 40px;
    background: var(--green);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 14px;
}

.accordion-title {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 15px;
    flex: 1;
    color: var(--black);
}

/* FIX: freccia accordion +/- unambigua */
.accordion-arrow {
    width: 28px;
    height: 28px;
    min-width: 28px;
    border: 1.5px solid var(--gray-200);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-600);
    font-size: 20px;
    font-weight: 300;
    line-height: 1;
    transition: all var(--transition-base);
}
.accordion-arrow::before {
    content: '+';
    display: block;
    margin-top: -1px;
}
.accordion-item.active .accordion-arrow {
    background: var(--green);
    border-color: var(--green);
    color: var(--black);
    transform: none;
}
.accordion-item.active .accordion-arrow::before {
    content: '\2212';
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-slow);
}

.accordion-item.active .accordion-content {
    max-height: 500px;
}

.accordion-inner {
    padding: 0 var(--space-lg) var(--space-lg);
}

.accordion-cards {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.acc-card {
    background: var(--cream);
    padding: var(--space-lg);
    border-left: 3px solid var(--green);
}

.acc-card h5 {
    font-size: 14px;
    font-family: var(--font-heading);
    font-weight: 700;
    margin-bottom: var(--space-sm);
    color: var(--black);
}

.acc-card p {
    font-size: 13px;
    line-height: 1.6;
}

/* ════════════════════════════════════════════════════════════════════════════
   TRASFORMAZIONE
════════════════════════════════════════════════════════════════════════════ */

.trasformazione {
    padding: var(--space-3xl) 0;
}

.trasformazione-container {
    display: flex;
    flex-direction: column;
    gap: var(--space-2xl);
}

.trasformazione-image img {
    width: 100%;
}

.trasformazione-content h2 {
    margin-bottom: var(--space-sm);
}

.trasformazione-content .subtitle {
    font-size: 16px;
    margin-bottom: var(--space-xl);
}

.prima-dopo {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
}

.prima-box, .dopo-box {
    padding: var(--space-lg);
    transition: transform var(--transition-base);
}

.prima-box:hover, .dopo-box:hover {
    transform: translateX(8px);
}

.prima-box {
    background: #FEF2F2;
    border-left: 4px solid #EF4444;
}

.dopo-box {
    background: #F0FDF4;
    border-left: 4px solid var(--green);
}

.prima-box h4, .dopo-box h4 {
    font-size: 15px;
    margin-bottom: var(--space-sm);
}

.prima-box p, .dopo-box p {
    font-size: 14px;
    line-height: 1.6;
}

.trasformazione-note {
    font-size: 15px;
    line-height: 1.7;
}

/* ════════════════════════════════════════════════════════════════════════════
   VALORE
════════════════════════════════════════════════════════════════════════════ */

.valore {
    padding: var(--space-3xl) 0;
    text-align: center;
}

.valore h2 {
    margin-bottom: var(--space-sm);
}

.valore > .container > p {
    font-size: 16px;
    margin-bottom: var(--space-xl);
}

.valore-cards {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
    max-width: 900px;
    margin: 0 auto;
}

.valore-card {
    text-align: left;
}

.valore-card h4 {
    font-size: clamp(18px, 3vw, 22px);
    margin-bottom: var(--space-sm);
}

.valore-card p {
    font-size: 15px;
}

.valore-note {
    margin-top: var(--space-lg);
    font-size: 13px;
    color: var(--gray-400);
    font-style: italic;
}

/* ════════════════════════════════════════════════════════════════════════════
   TEAM
════════════════════════════════════════════════════════════════════════════ */

.team {
    padding: var(--space-3xl) 0;
    position: relative;
    overflow: hidden;
}

.team-grid-bg {
    position: absolute;
    top: 30px;
    left: 20px;
    width: 120px;
    opacity: 0.4;
    pointer-events: none;
}

.team h2 {
    text-align: center;
    margin-bottom: var(--space-2xl);
}

.team-cards {
    display: flex;
    flex-direction: column;
    gap: var(--space-2xl);
}

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

.team-photo-wrapper {
    position: relative;
    width: 160px;
    margin: 0 auto var(--space-xs);
    overflow: hidden;
}

.team-photo {
    width: 160px;
    height: 200px;
    object-fit: cover;
    object-position: top;
    filter: grayscale(100%);
    transition: filter var(--transition-base);
}

.team-card:hover .team-photo {
    filter: grayscale(0%);
}

.team-photo-line {
    width: 160px;
    height: 4px;
    background: var(--green);
    margin: 0 auto var(--space-md);
}

.team-card h4 {
    font-size: 18px;
    margin-bottom: 4px;
}

.team-role {
    font-size: 11px;
    font-weight: 700;
    color: var(--green);
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: var(--space-sm);
}

.team-bio {
    font-size: 13px;
    line-height: 1.6;
    margin-bottom: var(--space-sm);
    max-width: 280px;
    margin-left: auto;
    margin-right: auto;
}

.team-link {
    font-size: 13px;
    color: var(--navy);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color var(--transition-base);
}

.team-link:hover {
    color: var(--green);
}

.team-logo {
    margin-top: var(--space-2xl);
    text-align: center;
}

.team-logo img {
    height: 50px;
    margin: 0 auto;
}

/* ════════════════════════════════════════════════════════════════════════════
   CLIENTI
════════════════════════════════════════════════════════════════════════════ */

.clienti {
    padding: var(--space-3xl) 0;
}

.clienti h2 {
    margin-bottom: var(--space-sm);
}

.clienti .subtitle {
    margin-top: var(--space-xs);
    margin-bottom: var(--space-2xl);
    max-width: 700px;
}

.clienti-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-md);
}

.cliente-box {
    background: var(--white);
    border: 1px solid var(--gray-200);
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 12px;
    color: var(--gray-600);
    transition: all var(--transition-base);
    text-align: center;
    padding: var(--space-sm);
}

.cliente-box:hover {
    border-color: var(--green);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

/* ════════════════════════════════════════════════════════════════════════════
   CTA FINALE
════════════════════════════════════════════════════════════════════════════ */

.cta-section {
    padding: var(--space-3xl) 0;
}

.cta-container {
    display: flex;
    flex-direction: column;
    gap: var(--space-2xl);
}

.cta-content h2 {
    margin-bottom: var(--space-lg);
}

.cta-content p {
    font-size: 16px;
    margin-bottom: var(--space-xl);
}

.cta-form {
    background: var(--cream);
    padding: var(--space-xl);
    border: 1px solid var(--gray-200);
}

.cta-form h4 {
    margin-bottom: var(--space-lg);
}

.form-placeholder {
    background: var(--white);
    border: 2px dashed var(--gray-200);
    padding: var(--space-2xl) var(--space-lg);
    text-align: center;
    color: var(--gray-400);
    font-size: 14px;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ════════════════════════════════════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════════════════════════════════════ */

.footer {
    background: var(--cream);
    padding: var(--space-3xl) 0 var(--space-lg);
    border-top: 1px solid var(--gray-200);
}

.footer-grid {
    display: flex;
    flex-direction: column;
    gap: var(--space-2xl);
}

.footer-brand {
    max-width: 280px;
}

.footer-brand img:not(.footer-logo-large) {
    height: 40px;
    margin-bottom: var(--space-md);
}

.footer-brand p {
    font-size: 13px;
    line-height: 1.6;
}

.footer-col h5 {
    font-family: var(--font-heading);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: var(--space-md);
    color: var(--black);
}

.footer-col ul li {
    margin-bottom: var(--space-sm);
}

.footer-col a {
    font-size: 13px;
    color: var(--gray-600);
    transition: color var(--transition-base);
}

.footer-col a:hover {
    color: var(--green);
}

.footer-bottom {
    margin-top: var(--space-2xl);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--gray-200);
    text-align: center;
}

.footer-bottom p {
    font-size: 12px;
    color: var(--gray-400);
    margin-bottom: var(--space-xs);
}

.footer-links {
    font-size: 12px;
}

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

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

/* Footer logo large */
.footer-logo-large {
    width: 200px;
    height: 200px;
    object-fit: contain;
    margin-bottom: var(--space-lg);
}

@media (min-width: 768px) {
    .footer-logo-large {
        width: 250px;
        height: 250px;
    }
}

/* Footer social */
.footer-social {
    display: flex;
    gap: var(--space-sm);
    margin-top: var(--space-lg);
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: transparent;
    border: 1.5px solid var(--navy);
    border-radius: 4px;
    color: var(--navy);
    transition: all var(--transition-base);
}

.social-link:hover {
    background: transparent;
    border-color: var(--green);
    color: var(--green);
    transform: translateY(-2px);
}

.social-link svg {
    width: 20px;
    height: 20px;
}

/* Subtitle class */
.subtitle {
    font-size: 18px;
    color: var(--gray-600);
    margin-bottom: var(--space-lg);
}

h2 + .subtitle {
    margin-top: calc(var(--space-sm) * -1);
}

/* Team header centered */
.team-header {
    text-align: center;
    margin-bottom: var(--space-2xl);
}

.team-header .subtitle {
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Chi Siamo section */
.chi-siamo {
    padding: var(--space-3xl) 0;
}

.chi-siamo-main {
    display: flex;
    flex-direction: column;
    gap: var(--space-xl);
    margin-bottom: var(--space-2xl);
}

.chi-siamo-image {
    position: relative;
}

.chi-siamo-image img:first-child {
    border-radius: 8px;
    max-height: 400px;
    object-fit: contain;
}

/* Override specifico per la foto milky way */
.chi-siamo-image img.chi-siamo-photo,
.chi-siamo-image .chi-siamo-photo {
    width: 100%;
    height: 380px;
    max-height: none;
    object-fit: cover;
    object-position: center;
    border-radius: 4px;
}

@media (min-width: 768px) {
    .chi-siamo-image img.chi-siamo-photo,
    .chi-siamo-image .chi-siamo-photo {
        height: 460px;
    }
}

.chi-siamo-content h2 {
    margin-bottom: var(--space-sm);
}

.valori-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
}

@media (min-width: 768px) {
    .chi-siamo-main {
        flex-direction: row;
        align-items: center;
    }
    
    .chi-siamo-image {
        flex: 1;
    }
    
    .chi-siamo-content {
        flex: 1.2;
    }
    
    .valori-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Servizio Main section */
.servizio-main {
    padding: var(--space-3xl) 0;
}

.servizio-header {
    text-align: center;
    margin-bottom: var(--space-2xl);
}

.servizio-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    margin-bottom: var(--space-2xl);
}

.servizio-col {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

.servizio-images {
    display: flex;
    justify-content: center;
    gap: var(--space-lg);
    flex-wrap: wrap;
}

.servizio-images img {
    max-height: 200px;
    object-fit: contain;
}

@media (min-width: 768px) {
    .servizio-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .servizio-images img {
        max-height: 250px;
    }
}

/* CTA container 2 columns */
.cta-container {
    display: flex;
    flex-direction: column;
    gap: var(--space-xl);
}

.cta-content h2 {
    margin-bottom: var(--space-md);
}

.cta-calendar {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

@media (min-width: 768px) {
    .cta-container {
        flex-direction: row;
        align-items: flex-start;
        gap: var(--space-2xl);
    }
    .cta-content {
        flex: 0 0 28%;
    }
    .cta-calendar {
        flex: 1;
    }
}

/* Team LinkedIn links */
.team-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    color: var(--navy);
    font-size: 14px;
    font-weight: 500;
    margin-top: var(--space-md);
    padding: var(--space-sm) var(--space-md);
    border: 1px solid var(--navy);
    border-radius: 4px;
    transition: all var(--transition-base);
}

.team-link:hover {
    background: var(--navy);
    color: var(--white);
}

.team-link svg {
    flex-shrink: 0;
}

/* CTA two columns layout */
.cta-two-cols {
    display: flex;
    flex-direction: column;
    gap: var(--space-xl);
}

@media (min-width: 768px) {
    .cta-two-cols {
        flex-direction: row;
        align-items: flex-start;
        gap: var(--space-2xl);
    }
    
    .cta-two-cols .cta-content {
        flex: 1;
    }
    
    .cta-two-cols .cta-calendar {
        flex: 1.2;
    }
}

.cta-calendar {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.cta-calendar iframe {
    display: block;
    width: 100%;
    min-height: 500px;
}

/* ════════════════════════════════════════════════════════════════════════════
   ANIMATIONS
════════════════════════════════════════════════════════════════════════════ */

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

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

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* Scroll animations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    /* FIX: transizione esplicita per evitare che 'transition: all' interferisca con filter/grayscale */
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.animate-on-scroll.visible {
    opacity: 1 !important;
    transform: translateY(0);
}

.animate-on-scroll.delay-1 {
    transition-delay: 0.1s;
}

.animate-on-scroll.delay-2 {
    transition-delay: 0.2s;
}

.animate-on-scroll.delay-3 {
    transition-delay: 0.3s;
}

/* ════════════════════════════════════════════════════════════════════════════
   TABLET BREAKPOINT (768px+)
════════════════════════════════════════════════════════════════════════════ */

@media (min-width: 768px) {
    .container {
        padding: 0 var(--space-xl);
    }
    
    .section-padding {
        padding: var(--space-4xl) 0;
    }
    
    /* Header */
    .nav {
        display: block;
    }
    
    .mobile-toggle {
        display: none;
    }
    
    .header-cta {
        display: block;
    }
    
    /* Hero */
    .hero {
        padding-top: 140px;
        padding-bottom: var(--space-4xl);
    }
    
    .hero-buttons {
        flex-direction: row;
        justify-content: center;
    }
    
    .hero-grid {
        width: 150px;
        bottom: -30px;
        left: -30px;
    }
    
    /* Vision */
    .vision {
        padding: var(--space-4xl) 0;
    }
    
    .filosofia-grid {
        flex-direction: row;
        gap: var(--space-lg);
    }
    
    .filosofia-grid .card {
        flex: 1;
    }
    
    /* CFO */
    .cfo-images {
        grid-template-columns: 2fr 1fr 1fr;
    }
    
    .cfo-images img {
        height: 220px;
    }
    
    .cfo-cards {
        flex-direction: row;
        gap: var(--space-lg);
    }
    
    .cfo-cards .card {
        flex: 1;
    }
    
    /* Servizio */
    .servizio-image {
        order: 0;
    }
    
    /* Ecosistema */
    .ecosistema-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Metodologia */
    .accordion-cards {
        flex-direction: row;
    }
    
    .acc-card {
        flex: 1;
    }
    
    /* Trasformazione */
    .prima-dopo {
        flex-direction: row;
    }
    
    .prima-box, .dopo-box {
        flex: 1;
    }
    
    /* Valore */
    .valore-cards {
        flex-direction: row;
    }
    
    .valore-card {
        flex: 1;
    }
    
    /* Team */
    .team-cards {
        flex-direction: row;
        justify-content: center;
        gap: var(--space-xl);
    }
    
    /* Clienti */
    .clienti-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    /* CTA */
    .cta-container {
        flex-direction: row;
        align-items: flex-start;
        gap: var(--space-2xl);
    }
    .cta-content {
        flex: 0 0 28%;
    }
    .cta-form {
        flex: 1;
    }
    
    /* Footer */
    .footer-grid {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .footer-brand {
        flex: 1 1 100%;
        margin-bottom: var(--space-lg);
    }
    
    .footer-col {
        flex: 1;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   DESKTOP BREAKPOINT (1024px+)
════════════════════════════════════════════════════════════════════════════ */

@media (min-width: 1024px) {
    /* Hero */
    .hero-container {
        flex-direction: row;
        align-items: center;
        gap: var(--space-3xl);
    }
    
    .hero-content {
        flex: 1.1;
        text-align: left;
    }
    
    .hero-visual {
        flex: 0.9;
    }
    
    .hero-buttons {
        justify-content: flex-start;
    }
    
    /* Vision */
    .vision-main {
        flex-direction: row;
        align-items: flex-start;
    }
    
    .vision-image {
        flex: 1;
    }
    
    .vision-content {
        flex: 1.2;
    }
    
    .vision-image .grid-overlay {
        width: 120px;
        bottom: -20px;
        left: -20px;
    }
    
    /* Servizio */
    .servizio-container {
        flex-direction: row;
        align-items: flex-start;
    }
    
    .servizio-content {
        flex: 1.2;
    }
    
    .servizio-image {
        flex: 0.8;
    }
    
    /* Trasformazione */
    .trasformazione-container {
        flex-direction: row;
        align-items: center;
    }
    
    .trasformazione-image {
        flex: 0.8;
    }
    
    .trasformazione-content {
        flex: 1.2;
    }
    
    /* Clienti */
    .clienti-grid {
        grid-template-columns: repeat(5, 1fr);
    }
    
    /* Footer */
    .footer-brand {
        flex: 1.5 1 0;
        margin-bottom: 0;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   LARGE DESKTOP BREAKPOINT (1280px+)
════════════════════════════════════════════════════════════════════════════ */

@media (min-width: 1280px) {
    .container {
        padding: 0 var(--space-2xl);
    }
    
    .hero {
        padding-top: 160px;
    }
    
    .cfo-images img {
        height: 280px;
    }
    
    .cfo-grid-overlay {
        width: 180px;
        top: -30px;
        left: -30px;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   REDUCED MOTION
════════════════════════════════════════════════════════════════════════════ */

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}



/* ════════════════════════════════════════════════════════════════════════════
   SERVIZIO VISUAL — immagine cosmica a piena larghezza
════════════════════════════════════════════════════════════════════════════ */

.servizio-visual {
    width: 100%;
    background: var(--black);
    overflow: hidden;
    margin-bottom: var(--space-2xl);
    display: flex;
    align-items: center;
    justify-content: center;
}

.servizio-visual img {
    width: 100%;
    height: 340px;
    object-fit: cover;
    object-position: center;
    opacity: 0.85;
}

@media (min-width: 768px) {
    .servizio-visual img {
        height: 440px;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   FIX SPACING — titolo sezione + sottotitolo
════════════════════════════════════════════════════════════════════════════ */

.servizio-header h2,
.ecosistema h2,
.metodologia > .container > h2,
.trasformazione h2,
.valore h2,
.team-header h2,
.clienti h2,
.cta-content h2 {
    margin-bottom: var(--space-sm);
}

.servizio-header .subtitle,
.ecosistema .subtitle,
.metodologia > .container > .subtitle,
.trasformazione .subtitle,
.valore > .container > p.subtitle,
.team-header .subtitle,
.cta-content p {
    margin-top: var(--space-xs);
    margin-bottom: var(--space-2xl);
}

/* Fix chi-siamo h2 spacing */
.chi-siamo-content h2 {
    margin-bottom: var(--space-md);
    line-height: 1.2;
}

/* ════════════════════════════════════════════════════════════════════════════
   TEAM BIO — testo più lungo, leggibile
════════════════════════════════════════════════════════════════════════════ */

.team-bio {
    font-size: 13px;
    line-height: 1.7;
    margin-bottom: var(--space-md);
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
    color: var(--gray-600);
}

@media (min-width: 768px) {
    .team-cards {
        align-items: flex-start;
    }
    .team-bio {
        max-width: 280px;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   BLEND SCREEN — rimuove sfondo nero da immagini cosmiche
════════════════════════════════════════════════════════════════════════════ */

.blend-screen {
    mix-blend-mode: screen;
}

/* Assicura che i contenitori non taglino il blending */
.chi-siamo-image,
.servizio-images {
    isolation: isolate;
}

/* ════════════════════════════════════════════════════════════════════════════
   HERO CONSTELLATION SVG
════════════════════════════════════════════════════════════════════════════ */

.hero-constellation {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 180px;
    height: 180px;
    pointer-events: none;
    opacity: 0.6;
    animation: float 6s ease-in-out infinite;
}

@media (min-width: 1024px) {
    .hero-constellation {
        width: 240px;
        height: 240px;
        bottom: -30px;
        right: -30px;
        opacity: 0.8;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   FIX: cgo-badge verde primario coerente
════════════════════════════════════════════════════════════════════════════ */

.cgo-badge {
    display: inline-block;
    background: var(--green);
    color: var(--black);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    margin-bottom: var(--space-md);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}



/* ════════════════════════════════════════════════════════════════════════════
   TRASFORMAZIONE + VALORE ACCORPATE
════════════════════════════════════════════════════════════════════════════ */

.trasformazione-valore {
    padding: var(--space-3xl) 0;
}

.tv-grid {
    display: flex;
    flex-direction: column;
    gap: var(--space-3xl);
}

@media (min-width: 1024px) {
    .tv-grid {
        flex-direction: row;
        align-items: flex-start;
        gap: 0;
    }
}

.tv-col {
    flex: 1;
}

@media (min-width: 1024px) {
    .tv-col-left {
        padding-right: var(--space-3xl);
    }
    .tv-col-right {
        padding-left: var(--space-3xl);
    }
}

/* Separatore verticale — visibile solo su desktop */
.tv-divider {
    display: none;
}

@media (min-width: 1024px) {
    .tv-divider {
        display: block;
        width: 1px;
        background: var(--gray-200);
        align-self: stretch;
        flex-shrink: 0;
    }
}

/* Titoli e sottotitoli uniformi in entrambe le colonne */
.tv-col h2 {
    font-size: clamp(22px, 3.5vw, 32px);
    margin-bottom: var(--space-sm);
    line-height: 1.2;
}

.tv-sub {
    font-size: 15px;
    color: var(--gray-600);
    margin-bottom: var(--space-xl);
    line-height: 1.6;
}

.valore-stack {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}


/* ════════════════════════════════════════════════════════════════════════════
   COSMIC DIVIDER — immagine full-screen tra sezioni
════════════════════════════════════════════════════════════════════════════ */

.cosmic-divider {
    position: relative;
    width: 100%;
    height: 300px;
    overflow: hidden;
    background: var(--black);
}

.cosmic-divider img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 30%;
    opacity: 0.7;
    transform: scale(1.05);
    transition: transform 8s ease;
}

.cosmic-divider:hover img {
    transform: scale(1.0);
}

.cosmic-divider-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(250,250,248,0.6) 0%,
        rgba(0,0,0,0) 30%,
        rgba(0,0,0,0) 70%,
        rgba(255,255,255,0.6) 100%
    );
    pointer-events: none;
}

@media (min-width: 768px) {
    .cosmic-divider {
        height: 400px;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   CTA MINI LINKS (contatti Chiara/Mattia)
════════════════════════════════════════════════════════════════════════════ */

.cta-mini-link {
    font-size: 12px;
    color: var(--navy);
    font-weight: 500;
    margin-top: 2px;
    transition: color var(--transition-base);
    display: block;
}

.cta-mini-link:hover {
    color: var(--green);
}

/* ════════════════════════════════════════════════════════════════════════════
   SEZIONE CONTATTI: mini profili Chiara e Mattia
════════════════════════════════════════════════════════════════════════════ */

.cta-contacts {
    margin-top: var(--space-xl);
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.cta-contact-item {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.cta-contact-photo {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    object-position: top;
    filter: grayscale(100%);
    flex-shrink: 0;
}

.cta-contact-item div {
    display: flex;
    flex-direction: column;
}

.cta-contact-item strong {
    font-size: 14px;
    font-weight: 600;
    color: var(--black);
}

.cta-contact-item span {
    font-size: 12px;
    color: var(--gray-600);
}

.cta-contact-links {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    margin-top: var(--space-sm);
    padding-top: var(--space-sm);
    border-top: 1px solid var(--gray-200);
}

.cta-contact-links a {
    font-size: 14px;
    font-weight: 500;
    color: var(--navy);
    transition: color var(--transition-base);
}

.cta-contact-links a:hover {
    color: var(--green);
}

/* ════════════════════════════════════════════════════════════════════════════
   CHI SIAMO PHOTO — milky way full photo, no blend-screen needed
════════════════════════════════════════════════════════════════════════════ */

.chi-siamo-photo {
    width: 100%;
    height: 380px;
    object-fit: cover;
    object-position: center;
    border-radius: 4px;
}

@media (min-width: 768px) {
    .chi-siamo-photo {
        height: 460px;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   PRINT STYLES
════════════════════════════════════════════════════════════════════════════ */

@media print {
    .header, .mobile-menu, .cta-section, .footer {
        display: none;
    }
    
    body {
        font-size: 12pt;
    }
    
    .section-padding {
        padding: 20pt 0;
    }
}
