@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Outfit:wght@300;400;500;600;700;800&display=swap');

/* ==========================================================================
   CSS VARIABLES & DESIGN TOKENS
   ========================================================================== */
:root {
    /* Color Palette */
    --color-primary: #002f6c;       /* Deep Navy Blue from logo */
    --color-primary-dark: #001f4d;  /* Darker Navy */
    --color-accent: #f59e0b;        /* Warm Gold/Amber from logo fill */
    --color-accent-dark: #d97706;   /* Darker Gold */
    --color-vintage-red: #be123c;   /* Classic Red highlighting Giacomo's Fiat 690 */
    --color-text-dark: #1e293b;     /* Slate 800 */
    --color-text-light: #64748b;    /* Slate 500 */
    --color-bg-light: #f8fafc;      /* Slate 50 */
    --color-card-bg: #ffffff;
    --color-dark-bg: #0b1329;       /* Deep Navy Slate for Hero & Footer */
    
    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    
    /* Shadows & Border Radius */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    
    /* Animation Transitions */
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   BASE RESET
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

/* ==========================================================================
   TYPOGRAPHY
   ========================================================================== */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--color-primary-dark);
    line-height: 1.2;
}

p {
    font-size: 1.05rem;
    font-weight: 400;
    color: var(--color-text-light);
}

/* ==========================================================================
   LAYOUT STRUCTURE
   ========================================================================== */
section {
    padding: 100px 0;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

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

.section-tag {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--color-vintage-red);
    margin-bottom: 12px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 16px;
    position: relative;
    padding-bottom: 12px;
}

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

/* ==========================================================================
   HERO / HEADER SECTION
   ========================================================================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-image: linear-gradient(to bottom, rgba(11, 19, 41, 0.7) 0%, rgba(11, 19, 41, 0.85) 100%), url('images/Top.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: #ffffff;
    padding: 120px 0 80px 0;
    text-align: center;
}

.hero-logo-container {
    background: rgba(255, 255, 255, 0.95);
    padding: 24px 36px;
    border-radius: var(--radius-md);
    display: inline-block;
    margin-bottom: 40px;
    box-shadow: var(--shadow-xl);
    backdrop-filter: blur(8px);
    animation: fadeInDown 1s ease-out;
}

.hero-logo {
    max-height: 120px;
    width: auto;
    display: block;
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
    animation: fadeInUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.hero-subtitle {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--color-accent);
    margin-bottom: 20px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 24px;
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-desc {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ==========================================================================
   HISTORY SECTION ("CHI SIAMO")
   ========================================================================== */
.history {
    background-color: var(--color-card-bg);
}

.history-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 60px;
    align-items: center;
}

.history-text {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.history-text h3 {
    font-size: 1.75rem;
    color: var(--color-primary-dark);
    margin-bottom: 5px;
}

.history-text p {
    text-align: justify;
    font-size: 1.05rem;
}

.history-highlight {
    border-left: 4px solid var(--color-vintage-red);
    padding-left: 20px;
    margin: 10px 0;
    font-style: italic;
    color: var(--color-text-dark);
}

.history-images {
    position: relative;
}

.history-frame {
    background: #ffffff;
    padding: 16px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xl);
    transform: rotate(-2deg);
    transition: var(--transition-smooth);
}

.history-frame:hover {
    transform: rotate(0deg) scale(1.02);
}

.history-image {
    width: 100%;
    height: auto;
    border-radius: calc(var(--radius-md) - 8px);
    display: block;
}

.history-caption {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    text-align: center;
    margin-top: 12px;
    font-weight: 500;
    color: var(--color-text-light);
}

/* ==========================================================================
   SERVICES & MISSION SECTION
   ========================================================================== */
.services {
    background-color: var(--color-bg-light);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 60px;
}

.service-card {
    background: var(--color-card-bg);
    padding: 40px 30px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: var(--transition-smooth);
    border-top: 4px solid var(--color-primary);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-top-color: var(--color-accent);
}

.service-icon {
    font-size: 2.5rem;
    margin-bottom: 24px;
    display: inline-block;
}

.service-title {
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.service-desc {
    font-size: 0.975rem;
    color: var(--color-text-light);
}

.fleet-banner {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    position: relative;
    height: 400px;
}

.fleet-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.fleet-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 47, 108, 0.9) 0%, rgba(0, 47, 108, 0) 100%);
    padding: 40px;
    color: #ffffff;
}

.fleet-overlay h3 {
    color: #ffffff;
    font-size: 1.75rem;
    margin-bottom: 10px;
}

.fleet-overlay p {
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    font-size: 1rem;
}

/* ==========================================================================
   VINTAGE & DETAIL GALLERY
   ========================================================================== */
.gallery {
    background-color: var(--color-card-bg);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.gallery-card {
    background: var(--color-bg-light);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition-smooth);
}

.gallery-card:hover {
    transform: scale(1.03);
    box-shadow: var(--shadow-xl);
}

.gallery-img-container {
    height: 240px;
    overflow: hidden;
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: var(--transition-smooth);
}

.gallery-card:hover .gallery-img {
    transform: scale(1.08);
}

.gallery-info {
    padding: 20px;
    background: var(--color-card-bg);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.gallery-info h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-primary-dark);
}

.gallery-info p {
    font-size: 0.875rem;
    color: var(--color-text-light);
    margin-top: 4px;
}

/* ==========================================================================
   FOOTER SECTION
   ========================================================================== */
.footer {
    background-color: var(--color-dark-bg);
    color: #ffffff;
    padding: 80px 0 40px 0;
    border-top: 5px solid var(--color-accent);
}

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

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.footer-logo-container {
    background: #ffffff;
    padding: 16px 24px;
    border-radius: var(--radius-sm);
    display: inline-block;
    align-self: flex-start;
}

.footer-logo {
    max-height: 70px;
    width: auto;
    display: block;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
}

.footer-contacts {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.contact-block {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.contact-label {
    font-family: var(--font-heading);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--color-accent);
    font-weight: 600;
}

.contact-value {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
}

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

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* ==========================================================================
   RESPONSIVE MEDIA QUERIES
   ========================================================================== */
@media (max-width: 992px) {
    .history-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .history-images {
        max-width: 600px;
        margin: 0 auto;
        width: 100%;
    }
    
    .services-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

@media (max-width: 768px) {
    section {
        padding: 60px 0;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-desc {
        font-size: 1.1rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-contacts {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}
