/* ============================================
   E-COMMERCE PRO - FOGLIO DI STILE PRINCIPALE
   Percorso: css/style.css
   ============================================ */

/* ============================================
   1. VARIABILI E RESET
   ============================================ */
:root {
    --primary-color: #667eea;
    --primary-dark: #764ba2;
    --accent-color: #6366f1;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --bg-light: #f9fafb;
    --white: #ffffff;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* Smooth scroll globale */
html {
    scroll-behavior: smooth;
}

/* ============================================
   2. GRADIENT E BACKGROUND
   ============================================ */
.hero-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

.hero-gradient::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ============================================
   3. TRANSIZIONI GLOBALI
   ============================================ */
a, button, .service-card, .btn-primary {
    transition: all var(--transition-normal);
}

/* ============================================
   4. BOTTONI
   ============================================ */
.btn-primary {
    display: inline-block;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Effetto ripple sui bottoni */
.btn-primary::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-primary:active::after {
    width: 300px;
    height: 300px;
}

/* ============================================
   5. CARD SERVIZI
   ============================================ */
.service-card {
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
    position: relative;
    overflow: hidden;
}

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

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-normal);
}

.service-card:hover::before {
    transform: scaleX(1);
}

/* ============================================
   6. HEADER E NAVIGAZIONE
   ============================================ */
header {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.98);
}

#mobile-menu {
    transition: all var(--transition-normal);
}

#mobile-menu-btn {
    transition: transform var(--transition-fast);
}

#mobile-menu-btn:hover {
    transform: scale(1.1);
}

/* Link attivi nel menu */
nav a.active {
    color: var(--primary-color);
    font-weight: 600;
    position: relative;
}

nav a.active::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* ============================================
   7. ANIMAZIONI
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

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

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

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

.animate-fade-in {
    animation: fadeInUp 0.6s ease-out;
}

.animate-fade-in-down {
    animation: fadeInDown 0.6s ease-out;
}

.animate-fade-in-left {
    animation: fadeInLeft 0.6s ease-out;
}

.animate-fade-in-right {
    animation: fadeInRight 0.6s ease-out;
}

.animate-scale-in {
    animation: scaleIn 0.5s ease-out;
}

.animate-pulse {
    animation: pulse 2s infinite;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* ============================================
   8. ICONE E EFFETTI
   ============================================ */
.icon-hover {
    transition: all var(--transition-normal);
}

.icon-hover:hover {
    transform: scale(1.2) rotate(5deg);
    color: var(--primary-color);
}

/* Effetto hover per le icone dei servizi */
.service-card .fa-store,
.service-card .fa-mobile-alt,
.service-card .fa-bullhorn,
.service-card .fa-globe,
.service-card .fa-link,
.service-card .fa-rocket {
    transition: all var(--transition-normal);
}

.service-card:hover .fa-store,
.service-card:hover .fa-mobile-alt,
.service-card:hover .fa-bullhorn,
.service-card:hover .fa-globe,
.service-card:hover .fa-link,
.service-card:hover .fa-rocket {
    transform: scale(1.15);
}

/* ============================================
   9. IMMAGINI
   ============================================ */
img {
    transition: transform var(--transition-slow);
}

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

/* ============================================
   10. FOOTER
   ============================================ */
footer a {
    transition: color var(--transition-fast), padding-left var(--transition-fast);
}

footer a:hover {
    color: var(--white);
    padding-left: 4px;
}

footer .fab {
    transition: all var(--transition-normal);
}

footer .fab:hover {
    transform: translateY(-3px);
    color: var(--primary-color) !important;
}

/* ============================================
   11. BADGE E TAG
   ============================================ */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-primary {
    background-color: rgba(102, 126, 234, 0.1);
    color: var(--primary-color);
}

.badge-success {
    background-color: rgba(34, 197, 94, 0.1);
    color: #16a34a;
}

/* ============================================
   12. SEZIONI SPECIALI
   ============================================ */
.section-divider {
    height: 4px;
    width: 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin: 0 auto 2rem;
    border-radius: 2px;
}

.price-highlight {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.5rem 1.5rem;
    border-radius: 0.5rem;
    display: inline-block;
    box-shadow: var(--shadow-lg);
}

/* ============================================
   13. SCROLLBAR PERSONALIZZATA
   ============================================ */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 5px;
    transition: background 0.3s;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: #667eea #f1f1f1;
}

/* ============================================
   14. RESPONSIVE TYPOGRAPHY
   ============================================ */
@media (max-width: 768px) {
    h1 {
        font-size: 2.25rem !important;
        line-height: 1.2;
    }

    h2 {
        font-size: 1.75rem !important;
        line-height: 1.3;
    }

    h3 {
        font-size: 1.375rem !important;
    }

    p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.875rem !important;
    }

    h2 {
        font-size: 1.5rem !important;
    }
}

/* ============================================
   15. ACCESSIBILITÀ
   ============================================ */
a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Skip link per screen reader */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px;
    z-index: 100;
    transition: top var(--transition-fast);
}

.skip-link:focus {
    top: 0;
}

/* Riduci animazioni per chi preferisce movimento ridotto */
@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;
    }
}

/* ============================================
   16. EFFETTI HOVER GENERALI
   ============================================ */
.shadow-hover {
    transition: box-shadow var(--transition-normal), transform var(--transition-normal);
}

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

/* Link con underline animato */
.link-underline {
    position: relative;
    display: inline-block;
}

.link-underline::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: width var(--transition-normal);
}

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

/* ============================================
   17. UTILITÀ
   ============================================ */
.text-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-pattern {
    background-image: radial-gradient(circle at 1px 1px, rgba(102, 126, 234, 0.15) 1px, transparent 0);
    background-size: 20px 20px;
}

/* Glassmorphism effect */
.glass {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* ============================================
   18. STILI PER PAGINE INTERNE
   ============================================ */

/* Breadcrumb */
.breadcrumb {
    padding: 1rem 0;
    font-size: 0.875rem;
}

.breadcrumb a {
    color: var(--text-light);
}

.breadcrumb a:hover {
    color: var(--primary-color);
}

.breadcrumb .separator {
    margin: 0 0.5rem;
    color: var(--text-light);
}

/* Page header */
.page-header {
    padding: 4rem 0;
    text-align: center;
}

/* Content section */
.content-section {
    padding: 4rem 0;
}

.content-section h2 {
    margin-bottom: 1.5rem;
}

.content-section p {
    margin-bottom: 1rem;
    line-height: 1.7;
}

/* List styles */
.check-list li {
    padding-left: 2rem;
    position: relative;
    margin-bottom: 0.75rem;
}

.check-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #16a34a;
    font-weight: bold;
    font-size: 1.25rem;
}

/* Price table */
.price-card {
    transition: all var(--transition-normal);
    border: 2px solid transparent;
}

.price-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.price-card.featured {
    border-color: var(--primary-color);
    position: relative;
    transform: scale(1.05);
}

/* Review card */
.review-card {
    transition: all var(--transition-normal);
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

/* Contact form */
.form-input {
    transition: all var(--transition-fast);
    border: 2px solid #e5e7eb;
}

.form-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

/* ============================================
   19. PRINT STYLES
   ============================================ */
@media print {
    header, footer, .btn-primary, .hero-gradient {
        display: none;
    }

    body {
        background: white;
        color: black;
    }

    a {
        color: black;
        text-decoration: underline;
    }
}

/* ============================================
   20. DARK MODE (opzionale, se vuoi abilitarlo)
   ============================================ */
@media (prefers-color-scheme: dark) {
    /* Puoi abilitare il dark mode decommentando queste righe */
    /*
    body {
        background-color: #1a1a1a;
        color: #e5e7eb;
    }
    
    header {
        background: rgba(26, 26, 26, 0.98);
    }
    
    .service-card, .bg-white {
        background-color: #2d2d2d !important;
        color: #e5e7eb;
    }
    */
}