/*
Theme Name: Beta Group Theme
Theme URI: https://www.betagroup.it/
Author: Antigravity AI
Description: Custom highly performant theme for Beta Group.
Version: 1.0
*/
:root {
    /* Color Palette - Dark Premium */
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --accent-primary: #dc2626; /* Rosso Beta Group */
    --accent-secondary: #2563eb; /* Blu Beta Group */
    --accent-glow: rgba(220, 38, 38, 0.4);
    
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    
    /* Glassmorphism */
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    
    /* Variables */
    --container-width: 1200px;
    --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    font-family: 'Outfit', sans-serif;
    overflow-x: hidden;
    width: 100%;
}

body {
    background-color: var(--bg-primary);
    background-image: linear-gradient(rgba(10,10,15,0.7), rgba(10,10,15,0.85)), url('https://images.unsplash.com/photo-1508514177221-188b1cf16e9d?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
    position: relative;
}

/* Background Blobs for depth */
.bg-gradient {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    z-index: -1;
    opacity: 0.5;
}

.bg-blob-1 {
    top: -10%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-primary) 0%, transparent 70%);
}

.bg-blob-2 {
    bottom: 20%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-secondary) 0%, transparent 70%);
}



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

/* Typography */
h1, h2, h3, h4 {
    line-height: 1.2;
    font-weight: 700;
}

h1 {
    font-size: clamp(3rem, 6vw, 5rem);
    margin-bottom: 1.5rem;
    letter-spacing: -1px;
}

h1 span {
    background: linear-gradient(135deg, var(--accent-primary), #f87171);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

h2 {
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    margin-bottom: 1.5rem;
}

p {
    color: var(--text-muted);
    font-size: 1.125rem;
    max-width: 600px;
}

/* Glass & Utilities */
.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

.badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(220, 38, 38, 0.1);
    color: var(--accent-primary);
    border: 1px solid rgba(220, 38, 38, 0.2);
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-smooth);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-primary);
    color: white;
    box-shadow: 0 4px 14px var(--accent-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--accent-glow);
    background: #ef4444; 
}

.btn-secondary {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--glass-border);
}

.btn-secondary:hover {
    background: var(--glass-bg);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Navbar (Option B) */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    border-radius: 0;
    border-left: none;
    border-right: none;
    border-top: none;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.5s ease;
}

.hidden-top {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

.navbar.scrolled {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
    background: rgba(255, 255, 255, 0.05); /* Vetro quasi invisibile invece di nero */
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 90px;
}

.logo-img {
    height: 50px;
    width: auto;
    object-fit: contain;
    transition: var(--transition-smooth);
}

.desktop-nav {
    display: flex;
    gap: 2.5rem;
}

.desktop-nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    transition: var(--transition-smooth);
    position: relative;
    padding: 0.5rem 0;
}

.desktop-nav a:hover {
    color: var(--text-main);
}

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

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

/* Hero Slider Background */
.hero-slider {
    height: 100vh;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.static-hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.slider-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(0,0,0,0.4) 0%, rgba(10,10,15,0.9) 100%);
    z-index: 2;
}

/* Central Dynamic Logo Navigation */
.central-nav-wrapper {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.central-nav {
    position: relative;
    display: inline-block; /* Si adatta esattamente all'immagine */
    margin-bottom: 3rem;
}

/* Animazione Rotatoria all'ingresso */
.animate-spin-in {
    animation: spin-and-scale 2.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes spin-and-scale {
    0% {
        transform: scale(0) rotate(-1080deg);
        opacity: 0;
    }
    100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
}

.central-logo {
    display: block;
    width: 700px;
    max-width: 100%;
    height: auto;
    object-fit: contain;
    position: relative;
    z-index: 5;
    filter: drop-shadow(0 0 30px rgba(220, 38, 38, 0.3));
    transition: filter 0.5s ease;
}

.central-nav:hover .central-logo {
    filter: drop-shadow(0 0 50px rgba(220, 38, 38, 0.6));
}

/* Interactive Navigation Spots */
.nav-spot {
    position: absolute;
    width: 115px;
    height: 115px;
    border-radius: 50%;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: var(--transition-smooth);
    background: #1c2ce6; /* Esatto blu dell'immagine */
    border: 2px solid #000; /* Bordo nero del pallino originale */
    cursor: pointer;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.3);
}

.nav-spot:hover {
    background: #2563eb;
    box-shadow: 0 0 25px rgba(37, 99, 235, 1);
    transform: translate(-50%, -50%) scale(1.15) !important;
}

.spot-label {
    font-family: 'Inter', sans-serif;
    color: white;
    font-weight: 700;
    font-size: 0.8rem;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
    transition: var(--transition-smooth);
    pointer-events: none;
    line-height: 1.2;
    width: 100%;
    white-space: normal;
}

.nav-spot:hover .spot-label {
    transform: scale(1.1);
}

/* Posizionamento dei 4 punti esatti sui pallini blu dell'immagine */
.spot-top {
    top: 5%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.spot-bottom {
    top: 93%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.spot-left {
    top: 50%;
    left: 8.5%;
    transform: translate(-50%, -50%);
}

.spot-right {
    top: 40%;
    left: 87.0%;
    transform: translate(-50%, -50%);
}


.central-nav-title {
    text-align: center;
    z-index: 10;
}

.central-nav-title h1 {
    font-size: clamp(2rem, 4vw, 3.5rem);
    margin-bottom: 0.5rem;
}

.central-nav-title p {
    color: var(--accent-secondary);
    font-weight: 500;
    margin: 0 auto;
}

/* Chi Siamo */
.about { padding: 6rem 0; }
.about-box {
    border-radius: 50px;
    padding: 5rem 4rem;
    text-align: left;
}
.about-main-text {
    color: var(--text-main);
    font-size: 1.5rem;
    line-height: 1.8;
    max-width: 100%;
    margin-bottom: 2rem;
    font-weight: 300;
}
.about-sub-text {
    font-size: 1.125rem;
    margin-bottom: 2.5rem;
    color: var(--text-muted);
}
.about-actions { display: flex; gap: 1rem; }

/* Services */
.services { padding: 6rem 0; background: rgba(0,0,0,0.2); }
.section-header {
    text-align: center;
    margin-bottom: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}
.service-card {
    padding: 2.5rem;
    border-radius: 16px;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}
.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(220,38,38,0.05) 0%, transparent 100%);
    opacity: 0;
    transition: var(--transition-smooth);
}
.service-card:hover::before { opacity: 1; }
.service-card:hover {
    transform: translateY(-10px);
    border-color: rgba(220, 38, 38, 0.3);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}
.service-icon {
    width: 64px;
    height: 64px;
    background: rgba(220, 38, 38, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--accent-primary);
}

/* Gallery (Lavori) */
.gallery {
    padding: 6rem 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.gallery-item {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    aspect-ratio: 4/3;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, transparent 100%);
    display: flex;
    align-items: flex-end;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.4s ease;
}

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

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay h4 {
    color: white;
    font-size: 1.25rem;
    transform: translateY(20px);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery-item:hover h4 {
    transform: translateY(0);
}

/* Contact */
.contact { padding: 6rem 0; background: rgba(0,0,0,0.2); }
.contact-box {
    border-radius: 24px;
    padding: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.contact-methods {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    margin-top: 3rem;
}
.contact-method {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
}
.icon-wrap {
    width: 48px;
    height: 48px;
    background: var(--bg-secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
}
.contact-method a {
    color: var(--text-muted);
    text-decoration: none;
    transition: var(--transition-smooth);
}
.contact-method a:hover { color: var(--accent-primary); }

/* Footer */
.footer {
    border-top: 1px solid var(--glass-border);
    padding: 2rem 0;
    margin-top: 4rem;
}
.footer-bottom {
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}
.fade-in-up.visible { opacity: 1; transform: translateY(0); }

/* Responsive */
@media (max-width: 900px) {
    .desktop-nav, .btn-nav { display: none !important; }
    
    .central-nav {
        /* In mobile si adatta al max-width 100% dell'immagine */
    }
    
    .nav-spot {
        width: 75px;
        height: 75px;
    }
    
    .spot-label {
        font-size: 0.55rem;
    }
    
    .about-actions { flex-direction: column; }
    .contact-box, .about-box { padding: 2rem; }
    h1 { font-size: 2.5rem !important; }
}

/* Marchi */
.marchi { padding: 6rem 0; background: rgba(0,0,0,0.4); }
.marchi-grid { display: flex; flex-wrap: wrap; gap: 2rem; justify-content: center; align-items: center; }
.marchio-item { padding: 2rem; background: var(--glass-bg); border-radius: 16px; border: 1px solid var(--glass-border); transition: var(--transition-smooth); display: flex; align-items: center; justify-content: center; filter: grayscale(100%) opacity(0.6); width: 250px; height: 150px; }
.marchio-item:hover { filter: grayscale(0%) opacity(1); transform: translateY(-5px); box-shadow: 0 12px 30px rgba(0,0,0,0.5); border-color: rgba(220, 38, 38, 0.3); }
.marchio-item img { max-width: 100%; max-height: 100%; object-fit: contain; }
