/* --- 1. SETUP BASE E VARIABILI MODERNE --- */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800;900&display=swap');

:root {
    --bg-body: #f4f4f6;
    --card-bg: #ffffff;
    --text-dark: #111827;
    --text-muted: #6b7280;
    --accent: #4f46e5; /* Indaco moderno */
    --accent-hover: #4338ca;
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 24px;
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--bg-body);
    color: var(--text-dark);
    -webkit-font-smoothing: antialiased;
}

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

/* --- 2. HEADER E NAVIGAZIONE (Stile App) --- */
header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.logo h2 {
    font-weight: 800;
    font-size: 1.5rem;
    letter-spacing: -0.5px;
}

.logo span {
    color: var(--accent);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 25px;
    align-items: center;
}

nav ul li a {
    color: var(--text-dark);
    font-weight: 600;
    font-size: 1rem;
}

nav ul li a:hover {
    color: var(--accent);
}

.cart-icon-container {
    cursor: pointer;
    font-size: 1.2rem;
    background: var(--bg-body);
    padding: 8px 15px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: bold;
    transition: var(--transition);
}

.cart-icon-container:hover {
    background: #e5e7eb;
}

/* --- 3. HERO SECTION (Banner Principale) --- */
.hero {
    height: 70vh;
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin-top: 60px;
}

.hero-content h1 {
    font-size: 4rem;
    font-weight: 800;
    letter-spacing: -2px;
    margin-bottom: 15px;
    color: var(--text-dark);
}

.hero-content p {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 30px;
}

/* --- 4. PRODOTTI E CARD --- */
.section-padding {
    padding: 80px 5%;
}

.section-title {
    text-align: center;
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 40px;
}

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

.prodotto-card {
    background: var(--card-bg);
    padding: 20px;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

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

.img-container {
    font-size: 5rem;
    background: var(--bg-body);
    border-radius: var(--radius-md);
    padding: 30px;
    margin-bottom: 20px;
    transition: var(--transition);
}

.prodotto-card:hover .img-container {
    transform: scale(1.05);
}

.prodotto-card h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.prodotto-card p {
    color: var(--text-muted);
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 20px;
}

/* --- 5. TASTI (Buttons) --- */
.btn {
    display: inline-block;
    padding: 14px 28px;
    border-radius: var(--radius-md);
    background: var(--text-dark);
    color: white;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

.btn-add-cart {
    width: 100%;
    padding: 12px;
    border-radius: var(--radius-sm);
    background: #f3f4f6;
    color: var(--text-dark);
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-add-cart:hover {
    background: var(--accent);
    color: white;
}

/* --- 6. FORM E INPUT (Modalità Facile) --- */
.modal-input {
    width: 100%;
    padding: 14px 16px;
    margin-bottom: 15px;
    border: 2px solid #e5e7eb;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    background: #f9fafb;
    transition: var(--transition);
}

.modal-input:focus {
    outline: none;
    border-color: var(--accent);
    background: white;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

/* --- 7. CARRELLO LATERALE --- */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -100%; /* Meglio di -400px, si nasconde del tutto anche su mobile */
    width: 100%;
    max-width: 400px;
    height: 100vh;
    background: var(--card-bg);
    box-shadow: -10px 0 30px rgba(0,0,0,0.1);
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10000; /* Alzato per superare l'header fisso */
    padding: 30px;
    display: flex;
    flex-direction: column;
}

.cart-sidebar.open {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    font-size: 1.5rem;
    font-weight: 800;
}

.close-cart, .close-modal {
    cursor: pointer;
    font-size: 2rem;
    line-height: 1;
    color: var(--text-muted);
    transition: var(--transition);
}

.close-cart:hover, .close-modal:hover {
    color: var(--text-dark);
    transform: rotate(90deg);
}

.cart-items-list {
    flex-grow: 1;
    overflow-y: auto;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    padding: 15px 0;
    border-bottom: 1px solid #f3f4f6;
    font-weight: 600;
}

.btn-checkout {
    display: block;
    text-align: center;
    background: var(--accent);
    color: white;
    padding: 18px;
    border-radius: var(--radius-md);
    font-weight: 800;
    font-size: 1.1rem;
    margin-top: 20px;
}

.btn-checkout:hover {
    background: var(--accent-hover);
}

/* --- 8. FINESTRE POPUP (Modals) --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(5px);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    z-index: 1000;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-box {
    background: var(--card-bg);
    width: 90%;
    max-width: 450px;
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-hover);
    position: relative;
    transform: translateY(20px);
    transition: var(--transition);
}

.modal-overlay.active .modal-box {
    transform: translateY(0);
}

.modal-box .close-modal {
    position: absolute;
    top: 20px;
    right: 25px;
}

.modal-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 25px;
    text-align: center;
}

.track-result {
    display: none;
    background: #ecfdf5;
    color: #065f46;
    padding: 15px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    text-align: center;
    border: 1px solid #a7f3d0;
}

/* --- 10. PAGINA PRODOTTO SINGOLO --- */
.product-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    margin-top: 40px;
    align-items: center;
}

@media (max-width: 768px) {
    .product-detail-grid { grid-template-columns: 1fr; }
}

.product-image-box {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 100px 50px;
    text-align: center;
    font-size: 8rem;
    box-shadow: var(--shadow-soft);
}

.product-info-box h1 {
    font-size: 2.8rem;
    margin-bottom: 10px;
}

.product-info-box .price {
    font-size: 1.8rem;
    color: var(--accent);
    font-weight: 800;
    margin-bottom: 30px;
}

.size-selector {
    display: flex;
    gap: 12px;
    margin-bottom: 30px;
}

.size-btn {
    width: 50px;
    height: 50px;
    border: 2px solid #e5e7eb;
    border-radius: var(--radius-sm);
    background: transparent;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
}

.size-btn:hover {
    border-color: var(--text-dark);
}

.size-btn.active {
    border-color: var(--text-dark);
    background: var(--text-dark);
    color: white;
}

/* --- 12. AGGIORNAMENTO PER FOTO REALI --- */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.7)), 
                url('https://images.unsplash.com/photo-1523381210434-271e8be1f52b?q=80&w=2070&auto=format&fit=crop') center/cover no-repeat;
}

.hero-content h1 { color: #ffffff; }
.hero-content p { color: #e5e7eb; }

.img-container {
    padding: 0;
    background: transparent;
    aspect-ratio: 4/5;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

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

.prodotto-card:hover .img-container { transform: none; }
.prodotto-card:hover .img-container img { transform: scale(1.1); }

.product-image-box { padding: 0; overflow: hidden; aspect-ratio: 4/5; display: flex; }
.product-image-box img { width: 100%; height: 100%; object-fit: cover; }

/* --- 13. OTTIMIZZAZIONE PARALLAX --- */
.hero-content { will-change: transform, opacity; }

/* --- 14. PAGINA CHECKOUT (PAGAMENTO) --- */
.checkout-wrapper {
    max-width: 1200px;
    margin: 100px auto 50px;
    padding: 0 5%;
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 40px;
    align-items: start;
}

@media (max-width: 850px) {
    .checkout-wrapper { display: flex; flex-direction: column-reverse; }
}

.checkout-step {
    background: var(--card-bg);
    padding: 35px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    margin-bottom: 30px;
}

.checkout-step h3 {
    font-size: 1.4rem;
    font-weight: 800;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.input-row { display: flex; gap: 15px; }
.input-row .modal-input { flex: 1; }

.payment-methods { display: flex; gap: 15px; margin-bottom: 25px; }

.pay-method {
    flex: 1;
    border: 2px solid #e5e7eb;
    border-radius: var(--radius-md);
    padding: 20px 10px;
    text-align: center;
    cursor: pointer;
    font-weight: 600;
    color: var(--text-muted);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
}

.pay-method span { font-size: 1.8rem; }
.pay-method:hover { border-color: var(--text-dark); color: var(--text-dark); }
.pay-method.active { border-color: var(--accent); background: rgba(79, 70, 229, 0.05); color: var(--accent); }

.order-summary-box {
    background: #f9fafb;
    padding: 35px;
    border-radius: var(--radius-lg);
    border: 1px solid #e5e7eb;
    position: sticky;
    top: 100px;
}

.summary-item { display: flex; justify-content: space-between; margin-bottom: 15px; font-weight: 600; color: var(--text-dark); }
.summary-item.sub { color: var(--text-muted); font-weight: 400; font-size: 0.95rem; }
.summary-total { display: flex; justify-content: space-between; margin-top: 25px; padding-top: 20px; border-top: 2px dashed #d1d5db; font-size: 1.6rem; font-weight: 800; color: var(--text-dark); }

.success-icon { font-size: 4rem; color: #10b981; margin-bottom: 15px; animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; }
@keyframes popIn { 0% { transform: scale(0); } 100% { transform: scale(1); } }

/* --- 15. AGGIORNAMENTO LOGHI PAGAMENTO REALISTICI --- */
.pay-method img.logo-pay {
    height: 30px;
    width: auto;
    object-fit: contain;
    margin-bottom: 10px;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: var(--transition);
}

.pay-method:hover img.logo-pay, .pay-method.active img.logo-pay { filter: grayscale(0%); opacity: 1; }
.card-logos-container { display: flex; gap: 8px; margin-bottom: 10px; align-items: center; justify-content: center; }
.card-logos-container img.logo-pay { height: 20px; margin-bottom: 0; }

/* --- 16. MENU CENTRATO E TASTI CHECKOUT NERI --- */
header { display: flex; align-items: center; }
header nav { position: absolute; left: 50%; transform: translateX(-50%); }

@media (max-width: 850px) {
    header { flex-direction: column; gap: 15px; }
    header nav { position: static; transform: none; }
}

.pay-method {
    background-color: #050505;
    color: #ffffff;
    border: 2px solid #ffffff;
    border-radius: 12px;
    padding: 20px 10px;
}

.pay-method:hover, .pay-method.active { background-color: #121212; border-color: #ffffff; color: #ffffff; }
.pay-method img.logo-pay { filter: brightness(0) invert(1); opacity: 0.5; }
.pay-method:hover img.logo-pay, .pay-method.active img.logo-pay { filter: brightness(0) invert(1); opacity: 1; }

/* --- 20. STILE ESCLUSIVO APPLE PAY --- */
.apple-pay-btn { background-color: #000000 !important; color: #ffffff !important; border-color: #000000 !important; }
.apple-pay-btn img.logo-pay { filter: brightness(0) invert(1) !important; }
.apple-pay-btn:hover, .apple-pay-btn.active { background-color: #1c1c1e !important; }

/* --- 21. MINI CARRELLO A COMPARSA (HOVER) CON PONTE --- */
.cart-icon-container {
    position: relative; /* FONDAMENTALE per ancorare il mini-carrello */
}

.mini-cart {
    /* Sostituiamo display:none per permettere un'animazione fluida */
    visibility: hidden; 
    opacity: 0;
    position: absolute;
    top: calc(100% + 15px); /* Spazio sotto l'header per farlo respirare */
    right: 0; 
    width: 290px;
    background-color: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15); 
    padding: 15px;
    z-index: 10000;
    cursor: default; 
    transform: translateY(10px); /* Partenza per l'animazione */
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 1. IL "PONTE" INVISIBILE */
.mini-cart::after {
    content: '';
    position: absolute;
    bottom: 100%; /* Si attacca sopra al mini-carrello */
    left: 0;
    width: 100%;
    height: 30px; /* Copre il buco vuoto tra icona e carrello */
    background: transparent;
}

/* 2. Il triangolino decorativo (freccia) */
.mini-cart::before {
    content: ''; 
    position: absolute; 
    top: -6px; 
    right: 25px; 
    width: 12px; 
    height: 12px;
    background: #ffffff; 
    border-left: 1px solid #e5e7eb; 
    border-top: 1px solid #e5e7eb;
    transform: rotate(45deg); 
    z-index: 1;
}

/* 3. L'effetto hover che mostra tutto */
.cart-icon-container:hover .mini-cart { 
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
}

#mini-cart-items { 
    max-height: 240px; 
    overflow-y: auto; 
    margin-bottom: 12px; 
}

.mini-item {
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    margin-bottom: 12px;
    font-size: 0.9rem; 
    color: #000000; 
    font-weight: 500; 
    border-bottom: 1px solid #f3f4f6; 
    padding-bottom: 8px;
}

.mini-item-name { 
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    max-width: 55%; 
}

.mini-cart-footer { padding-top: 5px; }

/* --- 23. LAYOUT HEADER (Sinistra, Centro, Destra) --- */
.main-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 15px 30px; background-color: #ffffff; border-bottom: 1px solid #e5e7eb;
}

.center-nav ul { display: flex; gap: 20px; list-style: none; margin: 0; padding: 0; }
.header-right { display: flex; align-items: center; gap: 25px; }

.icon-btn {
    background: none; border: none; font-size: 1rem; font-weight: 600;
    cursor: pointer; font-family: inherit; color: #000;
}

/* --- 24. REVISIONE COMPLETA LOGIN GRAFICA (STILE PREMIUM) --- */
.login-container {
    position: relative;
}

.login-box {
    display: none;
    position: absolute;
    top: calc(100% + 15px);
    right: 0;
    width: 280px;
    background-color: var(--card-bg);
    border: 1px solid #e5e7eb;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-hover);
    padding: 25px;
    z-index: 10001;
}

.login-box.show {
    display: block !important;
}

.login-box h4 {
    font-size: 1.1rem;
    font-weight: 800;
    margin-bottom: 15px;
    text-align: center;
    color: var(--text-dark);
    font-family: 'Inter', sans-serif;
}

.login-input {
    width: 100%;
    padding: 12px 14px;
    margin-bottom: 12px;
    border: 2px solid #e5e7eb;
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    background: #f9fafb;
    font-family: inherit;
    transition: var(--transition);
    box-sizing: border-box;
}

.login-input:focus {
    outline: none;
    border-color: var(--accent);
    background: white;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

.login-submit {
    width: 100%;
    padding: 12px;
    background: var(--text-dark);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 700;
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition);
}

.login-submit:hover {
    background: #374151;
}

.login-links {
    margin-top: 15px;
    font-size: 0.85rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.login-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 600;
}

.login-links a:hover {
    color: var(--text-dark);
    text-decoration: underline;
}

/* --- STILE PER LA 'X' DI RIMOZIONE NEL CARRELLO --- */
.cart-item-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn-remove-item {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.4rem;
    cursor: pointer;
    line-height: 1;
    transition: var(--transition);
    padding: 0 5px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-remove-item:hover {
    color: #ef4444; /* Diventa rossa al passaggio del mouse */
    transform: scale(1.2);
}

/* --- 25. SEZIONE I PIU DESIDERATI (DESIGN PREMIUM) --- */
.bestseller-section { padding: 80px 20px; background-color: #f9fafb; text-align: center; }
.bestseller-header h2 { font-size: 2.2rem; font-weight: 700; margin-bottom: 10px; color: #111827; letter-spacing: -0.5px; }
.bestseller-header p { color: #6b7280; margin-bottom: 50px; font-size: 1.1rem; }
.bestseller-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; max-width: 1100px; margin: 0 auto; }

.bestseller-card {
    background: #ffffff; border-radius: 12px; overflow: hidden; border: 1px solid #e5e7eb;
    position: relative; text-align: left; transition: transform 0.4s ease, box-shadow 0.4s ease;
}
.bestseller-card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(0,0,0,0.08); }

.badge {
    position: absolute; top: 15px; left: 15px; background: #ef4444; color: #ffffff;
    padding: 6px 14px; font-size: 0.8rem; font-weight: 700; border-radius: 20px; z-index: 2;
    box-shadow: 0 4px 6px rgba(239, 68, 68, 0.3);
}

.img-container { width: 100%; height: 350px; overflow: hidden; background-color: #f3f4f6; }
.img-container img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.bestseller-card:hover .img-container img { transform: scale(1.08); }

.card-info { padding: 24px; }
.card-info h3 { font-size: 1.25rem; font-weight: 600; margin-bottom: 8px; color: #111827; }
.card-info .price { font-size: 1.15rem; font-weight: 700; color: #000000; margin-bottom: 20px; }

.btn-add {
    width: 100%; padding: 14px; background: #000000; color: #ffffff; border: none;
    border-radius: 8px; font-size: 0.95rem; font-weight: 600; cursor: pointer; transition: background 0.3s ease;
}
.btn-add:hover { background: #374151; }

/* --- 26. SFONDO VIDEO (Sezione Principale) --- */
.hero-section {
    position: relative; width: 100%; height: 75vh; min-height: 500px;
    display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.hero-video { position: absolute; top: 50%; left: 50%; min-width: 100%; min-height: 100%; width: auto; height: auto; transform: translate(-50%, -50%); object-fit: cover; z-index: 1; }
.hero-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.5); z-index: 2; }
.hero-content { position: relative; z-index: 3; color: #ffffff; text-align: center; padding: 0 20px; }

/* --- 27. ANIMAZIONI ALLO SCORRIMENTO --- */
.scroll-hidden { opacity: 0; transform: translateY(40px); transition: opacity 0.8s ease-out, transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94); will-change: opacity, transform; }
.scroll-hidden.da-sinistra { transform: translateX(-50px); }
.scroll-hidden.da-destra { transform: translateX(50px); }
.scroll-show { opacity: 1; transform: translateY(0) translateX(0); }

/* --- 28. IMPOSTAZIONI COMPLEMENTARI ED ELEMENTI INTEGRATI --- */
.main-header { display: flex; justify-content: space-between; align-items: center; padding: 20px 40px; background: #ffffff; border-bottom: 1px solid #e5e7eb; position: sticky; top: 0; z-index: 1000; }
.logo h2 a { text-decoration: none; color: #000; font-weight: 800; font-size: 1.6rem; letter-spacing: -1px; }
.logo h2 span { color: #ef4444; }
.center-nav ul { display: flex; list-style: none; gap: 30px; }
.center-nav a { text-decoration: none; color: #4b5563; font-weight: 500; transition: color 0.2s; }
.center-nav a:hover { color: #000; }
.header-right { display: flex; align-items: center; gap: 25px; }

/* ==========================================================================
   29. PEZZO CORRETTO: CHI SIAMO E FOOTER PREMIUM (Isolati e d'impatto)
   ========================================================================== */
.about-section { 
    padding: 100px 40px; 
    text-align: center; 
    background: #111827; /* Sfondo scuro profondo */
    color: #ffffff;
    border-top: 4px solid #ef4444; /* Linea di contrasto rossa */
    border-bottom: 4px solid #111827;
}
.about-section h2 { 
    font-size: 2.8rem; 
    font-weight: 900; 
    text-transform: uppercase;
    letter-spacing: -1px;
    margin-bottom: 25px;
    color: #ffffff;
}
.about-section p { 
    max-width: 800px; 
    margin: 0 auto; 
    color: #d1d5db; /* Testo chiaro leggibile */
    line-height: 1.8; 
    font-size: 1.25rem; 
    font-weight: 500; 
}

/* Footer coordinato in grigio/bianco pulito */
footer { 
    text-align: center; 
    padding: 60px 40px !important; 
    background: #ffffff !important; 
    color: #111827 !important; 
    border-top: 2px solid #e5e7eb !important;
}
footer h3 { 
    font-size: 2rem; 
    font-weight: 800; 
    letter-spacing: -1px;
    margin-bottom: 15px; 
    text-transform: uppercase;
}
footer p { 
    font-weight: 600; 
    color: #6b7280; 
    margin-bottom: 20px;
    font-size: 0.95rem;
}
#contatti {
    font-size: 1rem;
    font-weight: 700;
    color: #111827;
    background: #f3f4f6;
    display: inline-block;
    padding: 12px 25px;
    border-radius: 30px;
    border: 2px solid #111827;
}

/* ==========================================================================
   📱 OTTIMIZZAZIONE SMARTPHONE E TABLET (Media Queries)
   ========================================================================== */
@media (max-width: 768px) {
    /* 1. Riorganizza l'Header e il Menu */
    header {
        flex-direction: column;
        padding: 15px 10px;
        gap: 15px;
        position: relative; /* Evita che copra il contenuto scrollando */
    }
    
    .center-nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
    }
    
    .header-right {
        width: 100%;
        justify-content: center;
        gap: 20px;
    }

    /* 2. Ridimensiona la Hero Section (Testi giganti) */
    .hero {
        margin-top: 0;
        height: auto;
        padding: 60px 20px;
    }

    .hero-content h1 {
        font-size: 2.5rem; /* Più piccolo per il telefono */
        letter-spacing: -1px;
    }

    .hero-content p {
        font-size: 1rem;
    }

    /* 3. Riduce gli spazi vuoti laterali e verticali */
    .section-padding {
        padding: 50px 20px;
    }

    .about-section {
        padding: 60px 20px;
    }

    .about-section h2 {
        font-size: 2rem;
    }

    /* 4. Pagina Prodotto: Immagine sopra, testo sotto */
    .product-detail-grid {
        grid-template-columns: 1fr !important;
        gap: 20px;
    }

    /* 5. FIX PER IL POPUP LOGIN SU TELEFONO */
    .login-container {
        position: relative; 
    }

    .login-box {
        position: absolute;
        top: 100% !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) translateY(10px) !important;
        width: 290px !important;
        max-width: 88vw !important; 
        box-sizing: border-box;
        z-index: 99999 !important; 
    }

    .login-input {
        width: 100% !important;
        font-size: 16px !important; 
    }
}