/*
Theme Name: CSML Integrated Solutions
Theme URI: https://www.csmlsolutions.it
Author: Cosimo Lippi
Author URI: https://www.csmlsolutions.it
Description: Tema personalizzato per CSML Integrated Solutions. Design scuro con colori brand #2C3E50, #00B4D8, #FFD700.
Version: 1.0.0
License: Private
Text Domain: csml
*/

/* ===== VARIABILI GLOBALI ===== */
:root {
    --primary: #2C3E50;
    --accent: #FFD700;
    --secondary: #00B4D8;
    --light: #FFFFFF;
    --gray: #95a5a6;
    --gray-light: #EEF0F2;
    --dark: #1A1A1A;
    --whatsapp: #25D366;
    --font-head: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --font-body: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --container: 1200px;
    --radius: 4px;
    --transition: 0.3s ease;
}

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

body {
    font-family: var(--font-body);
    background: var(--primary);
    color: var(--light);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ===== CONTAINER ===== */
.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 40px;
    width: 100%;
}

@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }
}

/* ===== HEADER ===== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: var(--primary);
    z-index: 1000;
    display: flex;
    align-items: center;
    transition: box-shadow var(--transition), transform 0.35s ease;
}

.site-header.scrolled {
    box-shadow: 0 2px 20px rgba(0,0,0,0.08);
}

.site-header.hidden {
    transform: translateY(-100%);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 16px;
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 40px;
}

@media (max-width: 768px) {
    .header-inner {
        padding: 0 20px;
    }
}

.header-logo {
    display: block;
}

.header-logo img {
    height: 45px;
    width: 45px;
    border-radius: 50%;
    object-fit: cover;
}

.header-brand {
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 17px;
    color: var(--light);
    letter-spacing: 0.3px;
}

@media (max-width: 768px) {
    .header-brand {
        font-size: 15px;
    }
}

/* ===== TOP NAVIGATION ===== */
.top-nav {
    position: absolute;
    top: 40px;
    left: 60px;
    z-index: 100;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.top-nav a {
    color: var(--gray);
    text-decoration: none;
    margin-right: 20px;
    transition: color var(--transition);
    padding-bottom: 3px;
    border-bottom: 2px solid transparent;
}

.top-nav a:hover {
    color: var(--secondary);
}

.top-nav a.active {
    color: var(--light);
    border-bottom: 2px solid var(--accent);
}

.lang-separator {
    margin-right: 20px;
    color: #555;
    font-weight: 300;
}

/* ===== FOOTER ===== */
.site-footer {
    background: var(--primary);
    padding: 60px 60px 40px;
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.1);
    margin-top: auto;
}

.footer-info {
    font-size: 12px;
    color: var(--gray);
    line-height: 1.6;
    max-width: 500px;
    margin: 0 auto;
}

.footer-info a {
    color: var(--secondary);
    text-decoration: none;
    transition: color var(--transition);
}

.footer-info a:hover {
    color: var(--accent);
}

.footer-logo {
    text-align: center;
    margin-bottom: 48px;
}

.footer-logo img {
    width: 180px;
    filter: brightness(0) invert(1);
    opacity: 0.9;
}

/* ===== POLICY LINKS ===== */
.iubenda-links {
    margin-top: 15px;
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.iubenda-links a.iubenda-embed {
    background-color: transparent !important;
    color: var(--secondary) !important;
    border: 1px solid var(--secondary) !important;
    padding: 5px 12px !important;
    font-size: 10px !important;
    text-transform: uppercase !important;
    text-decoration: none !important;
    display: inline-block !important;
    border-radius: 2px !important;
    font-weight: 700;
    letter-spacing: 1px;
    transition: all var(--transition);
}

.iubenda-links a.iubenda-embed:hover {
    background-color: var(--secondary) !important;
    color: var(--primary) !important;
}

/* ===== SOCIAL ICONS (per footer) ===== */
.footer-social {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 20px;
}

.footer-social-icon {
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light);
    transition: all 0.2s;
    text-decoration: none;
}

.footer-social-icon:hover {
    background: var(--accent);
    color: var(--primary);
    transform: scale(1.1);
}

.footer-social-icon svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
    stroke: currentColor;
}

/* ===== BOTTONI ===== */
.btn {
    display: inline-block;
    padding: 14px 28px;
    text-decoration: none;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 2px;
    font-weight: 700;
    border-radius: var(--radius);
    transition: all var(--transition);
    border: 2px solid var(--accent);
    color: var(--accent);
    background: transparent;
    cursor: pointer;
    min-width: 200px;
    text-align: center;
}

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

.btn-primary {
    border: 2px solid var(--accent);
    color: var(--accent);
}

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

.btn-secondary {
    border: 2px solid var(--secondary);
    color: var(--secondary);
}

.btn-secondary:hover {
    background: var(--secondary);
    color: var(--primary);
}

.btn-whatsapp {
    border: 2px solid var(--whatsapp);
    color: var(--whatsapp);
}

.btn-whatsapp:hover {
    background: var(--whatsapp);
    color: var(--primary);
}

.btn-group {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .btn-group {
        flex-direction: column;
        width: 100%;
    }
    
    .btn {
        width: 100%;
    }
}

/* ===== UTILITY CLASSES ===== */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mt-4 { margin-top: 40px; }
.mb-4 { margin-bottom: 40px; }

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* ===== RESPONSIVE GENERALE ===== */
@media (max-width: 900px) {
    .top-nav {
        top: 20px;
        left: 0;
        width: 100%;
        text-align: center;
    }
    
    .top-nav a {
        margin: 0 10px;
    }
}