:root {
    --enjoy-orange: #f37021;
    --enjoy-orange-dark: #d8570f;
    --enjoy-orange-light: #fff2ea;
    --enjoy-yellow: #ffb703;
    --enjoy-navy: #1a2a3a;
    --enjoy-navy-light: #2c4257;
    --enjoy-blue: #0284c7;
    --enjoy-gray-bg: #f8fafc;
    --enjoy-card-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.03);
    --enjoy-card-hover: 0 20px 30px -10px rgba(243, 112, 33, 0.15), 0 10px 15px -5px rgba(0, 0, 0, 0.04);
}

body {
    background-color: var(--enjoy-gray-bg);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #334155;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Navbar */
.navbar-enjoy {
    background-color: #ffffff;
    border-bottom: 2px solid var(--enjoy-orange);
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.brand-logo-img {
    height: 48px;
    object-fit: contain;
    transition: transform 0.2s ease;
}

.brand-logo-img:hover {
    transform: scale(1.03);
}

/* Hero & Homepage Minimalista */
.homepage-fullscreen {
    position: relative;
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
    margin: 0;
    padding: 2.5rem 1.25rem 5.5rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8fafc;
    overflow-x: hidden;
}

@@media (min-width: 992px) {
    .homepage-fullscreen {
        height: 100vh;
        padding: 2rem 1.5rem;
    }
}

.homepage-fullscreen::before {
    content: "";
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/enjoy-logo-transparent.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center center;
    opacity: 0.24;
    pointer-events: none;
    z-index: 0;
}

.homepage-card {
    background: rgba(255, 255, 255, 0.90);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.07), 0 5px 15px rgba(0, 0, 0, 0.03);
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2.75rem 1.75rem;
    position: relative;
    overflow: hidden;
}

.homepage-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: transparent;
    transition: background 0.3s ease;
}

.homepage-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--enjoy-card-hover);
    color: inherit;
}

.homepage-card.card-filosofia:hover::before {
    background: linear-gradient(90deg, #3b82f6, #06b6d4);
}

.homepage-card.card-iscriviti:hover::before {
    background: linear-gradient(90deg, #f37021, #ffb703);
}

.homepage-card.card-area:hover::before {
    background: linear-gradient(90deg, #10b981, #059669);
}

.card-icon-wrapper {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.75rem;
    margin-bottom: 1.5rem;
    transition: transform 0.3s ease;
}

.homepage-card:hover .card-icon-wrapper {
    transform: scale(1.1) rotate(4deg);
}

.icon-filosofia {
    background: #e0f2fe;
    color: #0284c7;
}

.icon-iscriviti {
    background: var(--enjoy-orange-light);
    color: var(--enjoy-orange);
}

.icon-area {
    background: #ecfdf5;
    color: #059669;
}

/* Pulsanti Enjoy */
.btn-enjoy {
    background: linear-gradient(135deg, #f37021 0%, #ff833b 100%);
    color: #ffffff;
    font-weight: 600;
    border: none;
    border-radius: 0.5rem;
    padding: 0.65rem 1.4rem;
    transition: all 0.2s ease;
}

.btn-enjoy:hover {
    background: linear-gradient(135deg, #d8570f 0%, #f37021 100%);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(243, 112, 33, 0.4);
    transform: translateY(-1px);
}

.btn-enjoy-outline {
    background: transparent;
    color: var(--enjoy-orange);
    border: 2px solid var(--enjoy-orange);
    font-weight: 600;
    border-radius: 0.5rem;
    padding: 0.55rem 1.3rem;
}

.btn-enjoy-outline:hover {
    background: var(--enjoy-orange);
    color: #ffffff;
}

/* Pulsanti Azioni Operazioni (Stile Canino) */
.btn-action {
    width: 34px;
    height: 34px;
    min-width: 34px;
    min-height: 34px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50% !important;
    font-size: 0.95rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

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

.btn-action i {
    line-height: 1;
}

/* Logotipo Hero Homepage (Stile Ufficiale en-joy!) */
.enjoy-hero-brand {
    user-select: none;
    display: inline-flex;
    flex-direction: column;
    align-items: stretch;
    transition: transform 0.3s ease;
}

.enjoy-hero-brand:hover {
    transform: scale(1.02);
}

.enjoy-logo-title {
    font-family: 'Fredoka', 'Quicksand', 'Nunito', system-ui, sans-serif;
    font-size: clamp(3.4rem, 8vw, 5.5rem);
    font-weight: 700;
    line-height: 0.95;
    letter-spacing: -0.01em;
    margin-bottom: 0.25rem;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.enjoy-logo-title .logo-en {
    color: #1B437E; /* Blu notte istituzionale Enjoy */
    font-weight: 700;
}

.enjoy-logo-title .logo-dash {
    color: #1B437E;
    margin: 0 0.02em;
}

.enjoy-logo-title .logo-j {
    color: #98C52D; /* Verde lime brillante Hocus&Lotus */
}

.enjoy-logo-title .logo-o {
    color: #00A4B7; /* Ciano / Turchese vivace */
}

.enjoy-logo-title .logo-y {
    color: #963384; /* Magenta / Viola intenso */
}

.enjoy-logo-title .logo-excl {
    color: #EA5C46; /* Corallo / Arancio energico */
    margin-left: 0.02em;
}

.enjoy-logo-sub {
    font-family: 'Fredoka', 'Quicksand', 'Nunito', system-ui, sans-serif;
    font-size: clamp(1.15rem, 2.5vw, 1.6rem);
    font-weight: 600;
    color: #00A4B7;
    letter-spacing: 0.01em;
    line-height: 1;
    padding: 0 0.25rem;
}

.enjoy-logo-sub .logo-sub-left {
    text-align: left;
}

.enjoy-logo-sub .logo-sub-right {
    text-align: right;
}

/* Galleria Fotografica Dinamica */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.25rem;
}

@@media (max-width: 576px) {
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

.gallery-card {
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: var(--enjoy-card-shadow);
    aspect-ratio: 4 / 3;
    background: #e2e8f0;
}

.gallery-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

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

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

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

/* AI Floating Widget Styles */
.bg-gradient-ai {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #ec4899 100%);
}

.btn-ai-float {
    color: white;
    font-size: 0.95rem;
}

.btn-ai-close-pill {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-ai-close-pill:hover {
    background: rgba(255, 255, 255, 0.4);
}

.ai-msg-bubble {
    border-radius: 1rem;
    padding: 0.85rem 1.15rem;
    max-width: 88%;
    font-size: 0.92rem;
    line-height: 1.5;
}

.ai-msg-user {
    background: linear-gradient(135deg, #f37021 0%, #ff833b 100%);
    color: white;
    align-self: flex-end;
    margin-left: auto;
    border-bottom-right-radius: 0.25rem;
}

.ai-msg-assistant {
    background: #ffffff;
    color: #1e293b;
    border: 1px solid rgba(0,0,0,0.08);
    align-self: flex-start;
    margin-right: auto;
    border-bottom-left-radius: 0.25rem;
}

/* Chat Drawer */
.chat-drawer-bubble-me {
    background: #e0f2fe;
    color: #0369a1;
    border-radius: 0.9rem;
    border-bottom-right-radius: 0.2rem;
    padding: 0.6rem 0.9rem;
    max-width: 82%;
    margin-left: auto;
}

.chat-drawer-bubble-other {
    background: #ffffff;
    color: #334155;
    border-radius: 0.9rem;
    border-bottom-left-radius: 0.2rem;
    padding: 0.6rem 0.9rem;
    max-width: 82%;
    margin-right: auto;
    border: 1px solid #e2e8f0;
}

/* Tasti Funzione Eleganti (Icone con Tooltip - Stile Canino / Enjoy) */
.btn-action-lg {
    width: 38px;
    height: 38px;
    min-width: 38px;
    min-height: 38px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.05rem;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    position: relative;
}

.btn-action-lg:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 5px 12px rgba(0, 0, 0, 0.15);
}

.btn-action-lg:active {
    transform: translateY(0) scale(0.98);
}

/* Indicatore Utenti Connessi (Pulse Live) */
.pulse-dot {
    width: 9px;
    height: 9px;
    background-color: #22c55e;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    animation: pulse-green 1.8s infinite;
}

@@keyframes pulse-green {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 8px rgba(34, 197, 94, 0);
    }
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}

.connected-user-avatar {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    color: #ffffff;
}

/* Badge Avatar Utente con Iniziali Header & Profilo */
.user-avatar-circle {
    width: 28px;
    height: 28px;
    min-width: 28px;
    min-height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0d6efd 0%, #0099ff 100%);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.76rem;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    text-transform: uppercase;
    box-shadow: 0 1px 3px rgba(13, 110, 253, 0.25);
    user-select: none;
}

.user-avatar-circle-lg {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    font-size: 0.9rem;
}

/* ========================================================
   Floating PWA & Multi-OS App Dock (Basso a Destra)
   ======================================================== */
.pwa-os-dock-container {
    position: fixed;
    bottom: 16px;
    right: 16px;
    z-index: 1040;
    pointer-events: auto;
}

.pwa-os-dock {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 9999px;
    padding: 5px 8px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.12), 0 1px 3px rgba(0, 0, 0, 0.06);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.pwa-os-dock:hover {
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.18);
    transform: translateY(-2px);
    background: #ffffff;
}

.pwa-os-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 50%;
    border: 1px solid transparent;
    background: transparent;
    color: #495057;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 0;
}

.pwa-os-btn:hover {
    background: #f1f3f5;
    transform: scale(1.15);
}

.pwa-os-btn.btn-android:hover { color: #3ddc84; background: rgba(61, 220, 132, 0.15); }
.pwa-os-btn.btn-apple:hover { color: #000000; background: rgba(0, 0, 0, 0.1); }
.pwa-os-btn.btn-windows:hover { color: #0078d4; background: rgba(0, 120, 212, 0.15); }
.pwa-os-btn.btn-linux:hover { color: #e95420; background: rgba(233, 84, 32, 0.15); }
.pwa-os-btn.btn-desktop:hover { color: #0d6efd; background: rgba(13, 110, 253, 0.15); }

.pwa-os-divider {
    width: 1px;
    height: 20px;
    background-color: rgba(0, 0, 0, 0.12);
    margin: 0 2px;
}

/* Adattamento smartphone per il Dock OS */
@@media (max-width: 576px) {
    .pwa-os-dock-container {
        bottom: 12px;
        right: 12px;
    }
    .pwa-os-dock {
        padding: 4px 6px;
        gap: 4px;
    }
    .pwa-os-btn {
        width: 30px;
        height: 30px;
        min-width: 30px;
        font-size: 0.88rem;
    }
}

/* ========================================================
   Ottimizzazione Modulo Iscrizione per Smartphone (100% Mobile)
   ======================================================== */
.form-control-mobile {
    min-height: 48px;
    font-size: 16px !important; /* Previene auto-zoom su Safari iOS */
    border-radius: 12px;
    border: 1.5px solid #ced4da;
    padding: 10px 14px;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control-mobile:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.15);
}

.form-check-card {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px;
    border-radius: 12px;
    border: 1.5px solid #e2e8f0;
    background: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 10px;
    user-select: none;
}

.form-check-card:hover {
    border-color: #cbd5e1;
    background: #f8fafc;
}

.form-check-card:has(.form-check-input:checked) {
    background: #f0f7ff;
    border-color: #0d6efd;
}

.form-check-card .form-check-input {
    width: 22px;
    height: 22px;
    min-width: 22px;
    margin-top: 2px;
    cursor: pointer;
    border-radius: 6px;
}

.form-step-pill {
    padding: 8px 16px;
    border-radius: 9999px;
    font-size: 0.82rem;
    font-weight: 700;
    text-decoration: none;
    color: #495057;
    background: #f1f3f5;
    border: 1px solid #dee2e6;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.form-step-pill:hover,
.form-step-pill.active {
    background: #0d6efd;
    color: #ffffff;
    border-color: #0d6efd;
}

.mobile-step-nav-wrapper {
    position: sticky;
    top: 60px;
    z-index: 1020;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 10px 0;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

@@media (max-width: 768px) {
    .card-iscrizione-wrapper {
        padding: 1.25rem !important;
        border-radius: 1rem !important;
    }
    .header-card-iscrizione {
        padding: 1.5rem 1rem !important;
    }
    .btn-submit-iscrizione {
        width: 100% !important;
        padding-top: 1rem !important;
        padding-bottom: 1rem !important;
        font-size: 1.15rem !important;
    }
}

/* ========================================================
   Smart Datatable & Mobile Tables & WhatsApp Integration
   ======================================================== */
.enjoy-sort-header:hover {
    background-color: rgba(13, 110, 253, 0.05);
}

.enjoy-sort-header:active {
    background-color: rgba(13, 110, 253, 0.12);
}

.btn-whatsapp {
    background-color: #25d366;
    color: #ffffff !important;
    border: none;
    transition: all 0.2s ease;
}

.btn-whatsapp:hover {
    background-color: #128c7e;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.35);
}

@@media (max-width: 768px) {
    .enjoy-table-toolbar {
        padding: 0.6rem !important;
    }
    .enjoy-table-toolbar .enjoy-table-search {
        font-size: 0.85rem;
    }
    .table-responsive {
        border-radius: 0.75rem;
        -webkit-overflow-scrolling: touch;
    }
    .table-responsive table {
        min-width: 600px;
        font-size: 0.86rem;
    }
    .table-responsive table th,
    .table-responsive table td {
        padding: 0.6rem 0.65rem;
        white-space: normal;
    }
}




