/* ============================================
   AVVOCATI DEVELOPER - PUBLIC CSS
   Font: Rubik | Primary: #000 | Accent: #FF1818
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Rubik:wght@300;400;500;600;700&display=swap');

:root {
    --avv-primary: #000000;
    --avv-accent: #FF1818;
    --avv-accent-hover: #e00;
    --avv-gold: #FFD700;
    --avv-diamond: #667eea;
    --avv-success: #10b981;
    --avv-warning: #f59e0b;
    --avv-danger: #ef4444;
    --avv-gray-50: #f9fafb;
    --avv-gray-100: #f3f4f6;
    --avv-gray-200: #e5e7eb;
    --avv-gray-300: #d1d5db;
    --avv-gray-400: #9ca3af;
    --avv-gray-500: #6b7280;
    --avv-gray-600: #4b5563;
    --avv-gray-700: #374151;
    --avv-gray-800: #1f2937;
    --avv-gray-900: #111827;
    --avv-radius: 12px;
    --avv-radius-sm: 8px;
    --avv-shadow: 0 4px 20px rgba(0,0,0,0.08);
    --avv-shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
    --avv-transition: all 0.3s ease;
}

* { box-sizing: border-box; }

.avv-form-container, .avv-dashboard, .avv-lista-avvocati, .avv-profilo-page {
    font-family: 'Rubik', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--avv-gray-800);
    line-height: 1.6;
}

/* ============================================
   BUTTONS
   ============================================ */
.avv-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-family: 'Rubik', sans-serif;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    border: none;
    border-radius: var(--avv-radius-sm);
    cursor: pointer;
    transition: var(--avv-transition);
}

.avv-btn-primary {
    background: var(--avv-primary);
    color: #fff;
}
.avv-btn-primary:hover {
    background: var(--avv-gray-800);
    transform: translateY(-2px);
    box-shadow: var(--avv-shadow);
}

.avv-btn-accent {
    background: var(--avv-accent);
    color: #fff;
}
.avv-btn-accent:hover {
    background: var(--avv-accent-hover);
    transform: translateY(-2px);
}

.avv-btn-outline {
    background: transparent;
    border: 2px solid var(--avv-gray-300);
    color: var(--avv-gray-700);
}
.avv-btn-outline:hover {
    border-color: var(--avv-primary);
    color: var(--avv-primary);
}

.avv-btn-whatsapp {
    background: #25D366;
    color: #fff;
}
.avv-btn-whatsapp:hover {
    background: #1da851;
}

.avv-btn-block { width: 100%; }
.avv-btn-sm { padding: 8px 16px; font-size: 13px; }
.avv-btn-lg { padding: 16px 32px; font-size: 16px; }

/* ============================================
   FORMS
   ============================================ */
.avv-form-container {
    max-width: 520px;
    margin: 0 auto;
    padding: 40px;
    background: #fff;
    border-radius: var(--avv-radius);
    box-shadow: var(--avv-shadow-lg);
}

.avv-form-group {
    margin-bottom: 20px;
}

.avv-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--avv-gray-700);
    font-size: 14px;
}

.avv-form-group input,
.avv-form-group select,
.avv-form-group textarea {
    width: 100%;
    padding: 14px 16px;
    font-family: 'Rubik', sans-serif;
    font-size: 15px;
    border: 2px solid var(--avv-gray-200);
    border-radius: var(--avv-radius-sm);
    background: var(--avv-gray-50);
    transition: var(--avv-transition);
}

.avv-form-group input:focus,
.avv-form-group select:focus,
.avv-form-group textarea:focus {
    outline: none;
    border-color: var(--avv-accent);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(255,24,24,0.1);
}

.avv-form-group input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
    accent-color: var(--avv-accent);
}

.avv-form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.avv-form-hint {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    color: var(--avv-gray-500);
}

.avv-form-message {
    padding: 14px 18px;
    border-radius: var(--avv-radius-sm);
    margin-bottom: 20px;
    font-size: 14px;
    display: none;
}
.avv-form-message.success {
    display: block;
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}
.avv-form-message.error {
    display: block;
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

/* ============================================
   BADGES
   ============================================ */
.avv-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.avv-badge-gratuito { background: var(--avv-gray-200); color: var(--avv-gray-600); }
.avv-badge-gold { background: linear-gradient(135deg, #ffd700, #ffb700); color: #7c5e00; }
.avv-badge-diamond { background: linear-gradient(135deg, #667eea, #764ba2); color: #fff; }
.avv-badge-success { background: #d1fae5; color: #065f46; }

/* ============================================
   TAGS
   ============================================ */
.avv-tag {
    display: inline-block;
    padding: 6px 14px;
    background: var(--avv-gray-100);
    color: var(--avv-gray-700);
    font-size: 13px;
    font-weight: 500;
    border-radius: 20px;
    margin: 4px;
    transition: var(--avv-transition);
}
.avv-tag:hover {
    background: var(--avv-primary);
    color: #fff;
}

/* ============================================
   CARDS
   ============================================ */
.avv-card {
    background: #fff;
    border-radius: var(--avv-radius);
    padding: 24px;
    box-shadow: var(--avv-shadow);
}

.avv-card h3 {
    margin: 0 0 16px;
    font-size: 18px;
    font-weight: 600;
    color: var(--avv-gray-900);
}

/* ============================================
   DASHBOARD / AREA RISERVATA
   ============================================ */
.avv-dashboard {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.avv-dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 30px;
    background: var(--avv-primary);
    color: #fff;
    border-radius: var(--avv-radius);
    margin-bottom: 30px;
}

.avv-dashboard-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

.avv-dashboard-actions {
    display: flex;
    gap: 12px;
}

.avv-dashboard-header .avv-btn {
    background: rgba(255,255,255,0.15);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.3);
}
.avv-dashboard-header .avv-btn:hover {
    background: rgba(255,255,255,0.25);
}

/* PIANI */
.avv-card-piano {
    background: linear-gradient(135deg, var(--avv-gray-50), #fff);
    border: 2px solid var(--avv-gray-200);
    margin-bottom: 30px;
}

.avv-card-piano h3 {
    font-size: 20px;
    margin-bottom: 20px;
}

.avv-piani-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 24px;
}

.avv-piano-box {
    background: #fff;
    border: 2px solid var(--avv-gray-200);
    border-radius: var(--avv-radius);
    padding: 28px 24px;
    text-align: center;
    position: relative;
    transition: var(--avv-transition);
}

.avv-piano-box:hover {
    border-color: var(--avv-accent);
    transform: translateY(-4px);
    box-shadow: var(--avv-shadow-lg);
}

.avv-piano-box.active {
    border-color: var(--avv-accent);
    background: linear-gradient(180deg, #fff5f5 0%, #fff 100%);
}

.avv-piano-box h4 {
    margin: 0 0 12px;
    font-size: 22px;
    font-weight: 700;
    color: var(--avv-gray-900);
}

.avv-piano-prezzo {
    font-size: 36px;
    font-weight: 700;
    color: var(--avv-accent);
    margin-bottom: 8px;
}

.avv-piano-prezzo small {
    display: block;
    font-size: 14px;
    font-weight: 400;
    color: var(--avv-gray-500);
}

.avv-piano-box ul {
    list-style: none;
    padding: 0;
    margin: 20px 0;
    text-align: left;
}

.avv-piano-box ul li {
    padding: 8px 0;
    padding-left: 28px;
    position: relative;
    font-size: 14px;
    color: var(--avv-gray-600);
    border-bottom: 1px solid var(--avv-gray-100);
}

.avv-piano-box ul li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--avv-success);
    font-weight: 700;
}

.avv-piano-featured {
    border-color: var(--avv-accent);
    transform: scale(1.02);
}

.avv-piano-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--avv-accent);
    color: #fff;
    padding: 6px 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: 20px;
}

.avv-piano-current {
    display: inline-block;
    padding: 10px 20px;
    background: var(--avv-gray-100);
    color: var(--avv-gray-500);
    font-size: 13px;
    font-weight: 500;
    border-radius: var(--avv-radius-sm);
}

/* PROFILE FORM */
.avv-profile-section {
    background: #fff;
    border-radius: var(--avv-radius);
    padding: 30px;
    margin-bottom: 24px;
    box-shadow: var(--avv-shadow);
}

.avv-profile-section h3 {
    margin: 0 0 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--avv-gray-100);
    font-size: 18px;
    font-weight: 600;
    color: var(--avv-gray-900);
}

/* CATEGORIE CHECKBOXES */
.avv-categorie-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.avv-categoria-check {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    background: var(--avv-gray-50);
    border: 2px solid var(--avv-gray-200);
    border-radius: var(--avv-radius-sm);
    cursor: pointer;
    transition: var(--avv-transition);
}

.avv-categoria-check:hover {
    border-color: var(--avv-accent);
}

.avv-categoria-check input {
    margin-right: 10px;
    accent-color: var(--avv-accent);
}

.avv-categoria-check.checked {
    background: #fff5f5;
    border-color: var(--avv-accent);
}

/* UPLOAD */
.avv-upload-area {
    border: 2px dashed var(--avv-gray-300);
    border-radius: var(--avv-radius);
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: var(--avv-transition);
}

.avv-upload-area:hover {
    border-color: var(--avv-accent);
    background: var(--avv-gray-50);
}

.avv-upload-preview {
    display: inline-block;
    width: 120px;
    height: 120px;
    border-radius: var(--avv-radius);
    object-fit: cover;
    border: 3px solid var(--avv-gray-200);
}

/* ============================================
   MODAL POPUP
   ============================================ */
.avv-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 20px;
}

.avv-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.avv-modal {
    background: #fff;
    border-radius: 20px;
    padding: 40px;
    max-width: 480px;
    width: 100%;
    position: relative;
    transform: scale(0.8) translateY(20px);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 25px 80px rgba(0,0,0,0.3);
}

.avv-modal-overlay.active .avv-modal {
    transform: scale(1) translateY(0);
}

.avv-modal-close-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    border: none;
    background: var(--avv-gray-100);
    border-radius: 50%;
    font-size: 24px;
    color: var(--avv-gray-500);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--avv-transition);
    line-height: 1;
}

.avv-modal-close-btn:hover {
    background: var(--avv-accent);
    color: #fff;
}

.avv-modal-icon {
    font-size: 48px;
    text-align: center;
    margin-bottom: 16px;
}

.avv-modal h3 {
    margin: 0 0 8px;
    font-size: 26px;
    font-weight: 700;
    color: var(--avv-gray-900);
    text-align: center;
}

.avv-modal-subtitle {
    text-align: center;
    color: var(--avv-gray-500);
    margin: 0 0 28px;
    font-size: 15px;
}

.avv-modal-subtitle strong {
    color: var(--avv-accent);
    text-transform: capitalize;
}

.avv-ciclo-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 28px;
}

.avv-ciclo-option {
    display: flex;
    align-items: center;
    padding: 20px;
    border: 2px solid var(--avv-gray-200);
    border-radius: var(--avv-radius);
    cursor: pointer;
    transition: var(--avv-transition);
    position: relative;
}

.avv-ciclo-option:hover {
    border-color: var(--avv-gray-300);
    background: var(--avv-gray-50);
}

.avv-ciclo-option.selected {
    border-color: var(--avv-accent);
    background: linear-gradient(135deg, #fff5f5 0%, #fff 100%);
    box-shadow: 0 4px 15px rgba(255,24,24,0.15);
}

.avv-ciclo-option input[type="radio"] {
    width: 22px;
    height: 22px;
    margin-right: 16px;
    accent-color: var(--avv-accent);
    cursor: pointer;
}

.avv-ciclo-info {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
}

.avv-ciclo-label {
    font-weight: 600;
    color: var(--avv-gray-800);
    font-size: 16px;
}

.avv-ciclo-price {
    font-size: 22px;
    font-weight: 700;
    color: var(--avv-accent);
}

.avv-ciclo-price small {
    font-size: 14px;
    font-weight: 400;
    color: var(--avv-gray-500);
}

.avv-ciclo-badge {
    position: absolute;
    top: -10px;
    right: 16px;
    background: var(--avv-success);
    color: #fff;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
    border-radius: 20px;
    text-transform: uppercase;
}

.avv-modal-actions {
    display: flex;
    gap: 12px;
}

.avv-modal-actions .avv-btn {
    flex: 1;
    padding: 16px 24px;
    font-size: 15px;
    justify-content: center;
}

.avv-modal-actions .avv-btn-accent {
    gap: 8px;
}

.avv-modal-actions .avv-btn-accent svg {
    transition: transform 0.3s ease;
}

.avv-modal-actions .avv-btn-accent:hover svg {
    transform: translateX(4px);
}

/* ============================================
   LISTA AVVOCATI
   ============================================ */
.avv-lista-avvocati {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.avv-filters {
    display: flex;
    gap: 12px;
    margin-bottom: 40px;
    flex-wrap: wrap;
    padding: 24px;
    background: var(--avv-gray-50);
    border-radius: var(--avv-radius);
}

.avv-filters select {
    padding: 12px 20px;
    font-family: 'Rubik', sans-serif;
    font-size: 14px;
    border: 2px solid var(--avv-gray-200);
    border-radius: var(--avv-radius-sm);
    background: #fff;
    min-width: 200px;
    cursor: pointer;
}

.avv-filters select:focus {
    outline: none;
    border-color: var(--avv-accent);
}

.avv-no-results {
    text-align: center;
    padding: 60px 20px;
    background: var(--avv-gray-50);
    border-radius: var(--avv-radius);
}

.avv-no-results p {
    font-size: 18px;
    color: var(--avv-gray-500);
    margin-bottom: 20px;
}

/* SEZIONE PREMIUM */
.avv-section-premium {
    margin-bottom: 50px;
}

.avv-section-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--avv-gray-900);
    margin: 0 0 24px;
    padding-bottom: 16px;
    border-bottom: 3px solid var(--avv-accent);
    display: inline-block;
}

.avv-grid-premium {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

/* CARD PREMIUM - Verticali, 3 per riga */
.avv-card-premium {
    background: #fff;
    border-radius: var(--avv-radius);
    box-shadow: var(--avv-shadow-lg);
    overflow: hidden;
    position: relative;
    border: 2px solid transparent;
    transition: var(--avv-transition);
}

.avv-card-premium:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.15);
}

.avv-card-diamond {
    border-color: var(--avv-diamond);
    background: linear-gradient(135deg, #f8f9ff 0%, #fff 100%);
}

.avv-card-gold {
    border-color: var(--avv-gold);
    background: linear-gradient(135deg, #fffdf5 0%, #fff 100%);
}

.avv-card-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--avv-diamond);
    color: #fff;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 700;
    border-radius: 20px;
    z-index: 2;
}

.avv-card-badge.avv-badge-gold {
    background: linear-gradient(135deg, #ffd700, #ffb700);
    color: #7c5e00;
}

.avv-card-premium-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 28px 20px;
}

.avv-card-premium-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--avv-gray-100);
    flex-shrink: 0;
    margin-bottom: 16px;
}

.avv-card-premium-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avv-card-premium-avatar .avv-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--avv-primary);
    color: #fff;
    font-size: 36px;
    font-weight: 700;
}

.avv-card-premium-content {
    width: 100%;
    margin-bottom: 16px;
}

.avv-card-premium-content h3 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 700;
    color: var(--avv-gray-900);
}

.avv-card-location {
    font-size: 14px;
    color: var(--avv-gray-500);
    margin-bottom: 12px;
}

.avv-card-desc {
    font-size: 14px;
    color: var(--avv-gray-600);
    line-height: 1.6;
    margin-bottom: 14px;
}

.avv-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.avv-card-tags .avv-tag {
    font-size: 11px;
    padding: 4px 10px;
    margin: 0;
}

.avv-card-premium-action {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.avv-card-premium-action .avv-btn {
    text-align: center;
    justify-content: center;
}

/* SEZIONE GRATUITI */
.avv-section-free {
    margin-top: 30px;
}

.avv-section-title-small {
    font-size: 18px;
    font-weight: 600;
    color: var(--avv-gray-600);
    margin: 0 0 20px;
}

.avv-grid-free {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

/* CARD FREE - Compatte e piccole */
.avv-card-free {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: var(--avv-gray-50);
    border: 1px solid var(--avv-gray-200);
    border-radius: var(--avv-radius-sm);
    text-decoration: none;
    color: inherit;
    transition: var(--avv-transition);
}

.avv-card-free:hover {
    background: #fff;
    border-color: var(--avv-gray-300);
    box-shadow: var(--avv-shadow);
}

.avv-card-free-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--avv-gray-300);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.avv-card-free-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avv-card-free-avatar span {
    font-size: 20px;
    font-weight: 700;
    color: var(--avv-gray-600);
}

.avv-card-free-info {
    flex: 1;
    min-width: 0;
}

.avv-card-free-info h4 {
    margin: 0 0 4px;
    font-size: 15px;
    font-weight: 600;
    color: var(--avv-gray-800);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.avv-card-free-info p {
    margin: 0;
    font-size: 13px;
    color: var(--avv-gray-500);
}

.avv-card-free-cat {
    display: inline-block;
    margin-top: 6px;
    font-size: 11px;
    color: var(--avv-gray-500);
    background: var(--avv-gray-200);
    padding: 2px 8px;
    border-radius: 10px;
}

.avv-card-free-arrow {
    font-size: 20px;
    color: var(--avv-gray-400);
    transition: var(--avv-transition);
}

.avv-card-free:hover .avv-card-free-arrow {
    color: var(--avv-accent);
    transform: translateX(4px);
}

/* ============================================
   PROFILO PUBBLICO PAGE
   ============================================ */
.avv-profilo-page {
    max-width: 1200px;
    margin: 0 auto;
}

/* HERO */
.avv-profilo-hero {
    background: var(--avv-primary);
    padding: 50px 40px;
    border-radius: 0 0 var(--avv-radius) var(--avv-radius);
    margin-bottom: 40px;
}

.avv-profilo-hero-content {
    display: flex;
    align-items: center;
    gap: 30px;
}

.avv-profilo-avatar {
    width: 140px;
    height: 140px;
    min-width: 140px;
    min-height: 140px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid rgba(255,255,255,0.2);
    flex-shrink: 0;
}

.avv-profilo-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avv-profilo-avatar .avv-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--avv-accent);
    color: #fff;
    font-size: 56px;
    font-weight: 700;
    border-radius: 50%;
}

.avv-profilo-hero-info {
    color: #fff;
}

.avv-featured-badge {
    display: inline-block;
    background: var(--avv-accent);
    color: #fff;
    padding: 6px 16px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 20px;
    margin-bottom: 12px;
}

.avv-profilo-hero-info h1 {
    margin: 0 0 12px;
    font-size: 36px;
    font-weight: 700;
    color: #fff;
}

.avv-profilo-location {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    color: rgba(255,255,255,0.8);
    margin-bottom: 16px;
}

.avv-profilo-location svg {
    opacity: 0.8;
}

.avv-profilo-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.avv-profilo-tags .avv-tag {
    background: rgba(255,255,255,0.15);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.2);
}

.avv-profilo-diamond .avv-profilo-hero {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
}

/* BODY */
.avv-profilo-body {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 40px;
    padding: 0 20px;
}

.avv-profilo-main {
    min-width: 0;
}

.avv-section {
    background: #fff;
    border-radius: var(--avv-radius);
    padding: 30px;
    margin-bottom: 24px;
    box-shadow: var(--avv-shadow);
}

.avv-section h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 20px;
    font-size: 20px;
    font-weight: 600;
    color: var(--avv-gray-900);
}

.avv-section-icon {
    font-size: 24px;
}

.avv-lead {
    font-size: 17px;
    color: var(--avv-gray-700);
    line-height: 1.8;
    margin: 0 0 16px;
}

.avv-bio {
    color: var(--avv-gray-600);
    line-height: 1.8;
}

.avv-bio p { margin: 0 0 16px; }

/* COMPETENZE */
.avv-competenze-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
}

.avv-competenza-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    background: var(--avv-gray-50);
    border: 1px solid var(--avv-gray-200);
    border-radius: var(--avv-radius-sm);
    font-size: 14px;
    font-weight: 500;
    color: var(--avv-gray-700);
    transition: var(--avv-transition);
}

.avv-competenza-card:hover {
    border-color: var(--avv-accent);
    background: #fff;
}

/* GALLERY */
.avv-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}

.avv-gallery-item {
    height: 200px;
    border-radius: var(--avv-radius);
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.avv-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--avv-transition);
}

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

.avv-gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0);
    transition: var(--avv-transition);
}

.avv-gallery-item:hover::after {
    background: rgba(0,0,0,0.1);
}

/* GALLERY UPLOAD (Backend) */
.avv-gallery-upload {
    margin-top: 12px;
}

.avv-gallery-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.avv-gallery-items .avv-gallery-item {
    position: relative;
    height: 120px;
    border-radius: var(--avv-radius-sm);
    overflow: visible;
    border: 2px solid var(--avv-gray-200);
}

.avv-gallery-items .avv-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--avv-radius-sm);
}

.avv-remove-gallery-item {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 24px;
    height: 24px;
    background: var(--avv-accent);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.avv-remove-gallery-item:hover {
    background: #cc0000;
    transform: scale(1.1);
}

/* LIGHTBOX */
.avv-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.95);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.avv-lightbox.active {
    opacity: 1;
    visibility: visible;
}

.avv-lightbox-content {
    max-width: 90vw;
    max-height: 90vh;
    position: relative;
}

.avv-lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: var(--avv-radius);
}

.avv-lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 28px;
    cursor: pointer;
    transition: var(--avv-transition);
    z-index: 100000;
}

.avv-lightbox-close:hover {
    background: rgba(255,255,255,0.2);
}

.avv-lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    transition: var(--avv-transition);
}

.avv-lightbox-nav:hover {
    background: rgba(255,255,255,0.2);
}

.avv-lightbox-prev {
    left: 20px;
}

.avv-lightbox-next {
    right: 20px;
}

.avv-lightbox-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.7);
    font-size: 14px;
}

/* MAP */
.avv-map {
    height: 350px;
    border-radius: var(--avv-radius);
    overflow: hidden;
    border: 2px solid var(--avv-gray-200);
}

.avv-map-address {
    margin-top: 16px;
    padding: 14px 18px;
    background: var(--avv-gray-50);
    border-radius: var(--avv-radius-sm);
    font-size: 14px;
    color: var(--avv-gray-600);
}

/* SIDEBAR */
.avv-profilo-sidebar {
    position: sticky;
    top: 20px;
    height: fit-content;
}

.avv-sidebar-card {
    background: #fff;
    border-radius: var(--avv-radius);
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: var(--avv-shadow);
}

.avv-sidebar-card h3 {
    margin: 0 0 20px;
    font-size: 18px;
    font-weight: 600;
    color: var(--avv-gray-900);
}

.avv-contact-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.avv-contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--avv-gray-50);
    border-radius: var(--avv-radius-sm);
    color: var(--avv-gray-700);
    text-decoration: none;
    font-size: 14px;
    transition: var(--avv-transition);
}

.avv-contact-item:hover {
    background: var(--avv-gray-100);
    color: var(--avv-primary);
}

.avv-contact-item.avv-whatsapp {
    background: #25D366;
    color: #fff;
}
.avv-contact-item.avv-whatsapp:hover {
    background: #1da851;
    color: #fff;
}

.avv-social-links {
    display: flex;
    gap: 10px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--avv-gray-200);
}

.avv-social-btn {
    flex: 1;
    padding: 10px;
    text-align: center;
    background: var(--avv-gray-100);
    color: var(--avv-gray-700);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    border-radius: var(--avv-radius-sm);
    transition: var(--avv-transition);
}

.avv-social-btn:hover {
    background: var(--avv-primary);
    color: #fff;
}

.avv-orari {
    font-size: 14px;
    color: var(--avv-gray-600);
    line-height: 1.8;
}

.avv-address {
    font-style: normal;
    font-size: 14px;
    color: var(--avv-gray-600);
    line-height: 1.8;
}

/* ============================================
   PAGINATION
   ============================================ */
.avv-pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 40px;
}

.avv-pagination .page-numbers {
    padding: 10px 16px;
    background: #fff;
    border: 2px solid var(--avv-gray-200);
    border-radius: var(--avv-radius-sm);
    color: var(--avv-gray-700);
    text-decoration: none;
    font-weight: 500;
    transition: var(--avv-transition);
}

.avv-pagination .page-numbers:hover,
.avv-pagination .page-numbers.current {
    background: var(--avv-primary);
    border-color: var(--avv-primary);
    color: #fff;
}

/* ============================================
   SHORTCODE CITTÀ / PROVINCE / CONTATORI
   ============================================ */
.avv-lista-citta,
.avv-lista-province {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.avv-lista-citta li,
.avv-lista-province li {
    margin: 0;
}

.avv-lista-citta a,
.avv-lista-province a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--avv-gray-50);
    border: 1px solid var(--avv-gray-200);
    border-radius: 25px;
    color: var(--avv-gray-700);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--avv-transition);
}

.avv-lista-citta a:hover,
.avv-lista-province a:hover {
    background: var(--avv-primary);
    border-color: var(--avv-primary);
    color: #fff;
}

.avv-citta-prov,
.avv-prov-sigla {
    font-weight: 400;
    opacity: 0.7;
}

.avv-citta-count,
.avv-prov-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 6px;
    background: var(--avv-accent);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    border-radius: 12px;
}

.avv-lista-citta a:hover .avv-citta-count,
.avv-lista-province a:hover .avv-prov-count {
    background: #fff;
    color: var(--avv-primary);
}

/* Variante lista verticale */
.avv-lista-citta.verticale,
.avv-lista-province.verticale {
    flex-direction: column;
    gap: 6px;
}

.avv-lista-citta.verticale a,
.avv-lista-province.verticale a {
    justify-content: space-between;
    width: 100%;
    border-radius: var(--avv-radius-sm);
}

/* Variante compatta */
.avv-lista-citta.compatta a,
.avv-lista-province.compatta a {
    padding: 4px 12px;
    font-size: 13px;
}

.avv-lista-citta.compatta .avv-citta-count,
.avv-lista-province.compatta .avv-prov-count {
    min-width: 20px;
    height: 20px;
    font-size: 11px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
    .avv-profilo-body {
        grid-template-columns: 1fr;
    }
    
    .avv-profilo-sidebar {
        position: static;
    }
    
    .avv-piani-grid {
        grid-template-columns: 1fr;
    }
    
    .avv-grid-premium {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .avv-form-container {
        padding: 24px;
        margin: 16px;
    }
    
    .avv-form-row {
        grid-template-columns: 1fr;
    }
    
    .avv-dashboard-header {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .avv-profilo-hero {
        padding: 30px 20px;
    }
    
    .avv-profilo-hero-content {
        flex-direction: column;
        text-align: center;
    }
    
    .avv-profilo-hero-info h1 {
        font-size: 28px;
    }
    
    .avv-profilo-tags {
        justify-content: center;
    }
    
    .avv-section {
        padding: 20px;
    }
    
    .avv-filters {
        flex-direction: column;
    }
    
    .avv-filters select {
        width: 100%;
        min-width: auto;
    }
    
    .avv-grid-free {
        grid-template-columns: 1fr;
    }
    
    .avv-grid-premium {
        grid-template-columns: 1fr;
    }
    
    .avv-card-badge {
        position: static;
        display: inline-block;
        margin-bottom: 12px;
    }
}
