/* ============================================
   Total News Community - Frontend CSS
   ============================================ */

/* === BARRA SUPERIORE UTENTE === */
.tnc-user-topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 99999;
    background: #1a1a2e;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.tnc-topbar-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.tnc-topbar-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.tnc-topbar-avatar img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.tnc-topbar-avatar-letter {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #3498db;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
}

.tnc-topbar-nickname {
    font-weight: 600;
    font-size: 14px;
}

.tnc-topbar-menu {
    display: flex;
    align-items: center;
    gap: 4px;
}

.tnc-topbar-link {
    color: #ffffff;
    text-decoration: none;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.2s, transform 0.1s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 4px;
}

.tnc-topbar-link:hover {
    background: rgba(255,255,255,0.15);
    color: #ffffff;
    transform: translateY(-1px);
}

/* Colori distinti per ogni voce del menù */
.tnc-topbar-link-profilo:hover { background: rgba(52,152,219,0.3); }
.tnc-topbar-link-commenti:hover { background: rgba(155,89,182,0.3); }
.tnc-topbar-link-messaggi:hover { background: rgba(46,204,113,0.3); }
.tnc-topbar-link-annunci:hover { background: rgba(241,196,15,0.3); }
.tnc-topbar-link-invitati:hover { background: rgba(230,126,34,0.3); }
.tnc-topbar-link-documenti:hover { background: rgba(26,188,156,0.3); }
.tnc-topbar-link-esci { color: #e74c3c !important; }
.tnc-topbar-link-esci:hover { background: rgba(231,76,60,0.3); }

.tnc-topbar-separator {
    width: 1px;
    height: 20px;
    background: rgba(255,255,255,0.3);
    margin: 0 6px;
}

.tnc-topbar-toggle {
    display: none;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 26px;
    cursor: pointer;
    padding: 4px 8px;
}

.tnc-badge {
    background: #e74c3c;
    color: #ffffff;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 4px;
    font-weight: 700;
}

/* Body padding quando topbar attiva */
body.tnc-has-topbar {
    padding-top: 50px !important;
}

/* === SEZIONE COMMENTI === */
.tnc-comments-section {
    margin-top: 40px;
    padding-top: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* === BANNER COMMENTI === */
.tnc-banner-comments {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 24px;
}

.tnc-banner-comments img {
    width: 100%;
    height: auto;
    display: block;
}

.tnc-comments-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #1a1a2e;
}

/* === PULSANTI CONDIVISIONE SOCIAL === */
.tnc-share-section {
    margin-bottom: 24px;
    padding: 16px 20px;
    background: #f8f9fa;
    border-radius: 10px;
    border: 1px solid #e9ecef;
}

.tnc-share-title {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
}

.tnc-share-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tnc-share-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
    transition: transform 0.15s, box-shadow 0.15s;
    border: none;
    cursor: pointer;
}

.tnc-share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    color: #ffffff;
}

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

.tnc-share-btn-facebook { background: #1877F2; }
.tnc-share-btn-whatsapp { background: #25D366; }
.tnc-share-btn-twitter { background: #000000; }
.tnc-share-btn-telegram { background: #0088cc; }
.tnc-share-btn-linkedin { background: #0A66C2; }
.tnc-share-btn-email { background: #555555; }

.tnc-share-btn svg {
    width: 18px;
    height: 18px;
    fill: #ffffff;
    flex-shrink: 0;
}

/* === FORM COMMENTO === */
.tnc-comment-form-wrap {
    margin-bottom: 30px;
}

.tnc-comment-form .tnc-form-row {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.tnc-user-avatar img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
}

.tnc-form-input-wrap {
    flex: 1;
    width: 100%;
}

.tnc-comment-form textarea {
    width: 100%;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 16px;
    font-size: 16px;
    resize: vertical;
    min-height: 130px;
    font-family: inherit;
    line-height: 1.5;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.tnc-comment-form textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52,152,219,0.15);
}

.tnc-comment-form textarea::placeholder {
    color: #aaa;
    font-size: 15px;
}

.tnc-form-actions {
    margin-top: 12px;
    text-align: right;
}

.tnc-form-actions .tnc-btn {
    padding: 12px 28px;
    font-size: 15px;
    border-radius: 8px;
}

#tnc-reply-indicator {
    font-size: 12px;
    color: #666;
    margin-top: 6px;
    padding: 4px 8px;
    background: #f0f0f0;
    border-radius: 4px;
}

#tnc-cancel-reply {
    color: #e74c3c;
    margin-left: 8px;
    text-decoration: none;
}

/* === LISTA COMMENTI === */
.tnc-comments-list {
    margin-top: 20px;
}

.tnc-comment {
    padding: 16px;
    margin-bottom: 16px;
    background: #f9f9f9;
    border-radius: 8px;
    border-left: 3px solid #3498db;
}

.tnc-comment-highlighted {
    background: #fff8e1;
    border-left-color: #f39c12;
}

.tnc-comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.tnc-comment-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}

.tnc-comment-avatar.small img {
    width: 28px;
    height: 28px;
}

.tnc-avatar-placeholder {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #3498db;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
}

.tnc-avatar-placeholder.small {
    width: 28px;
    height: 28px;
    font-size: 12px;
}

.tnc-comment-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.tnc-comment-author {
    font-size: 14px;
    color: #1a1a2e;
}

.tnc-comment-date {
    font-size: 12px;
    color: #888;
}

.tnc-badge-highlighted {
    background: #f39c12;
    color: #ffffff;
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 600;
}

.tnc-comment-body {
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    margin-left: 46px;
}

.tnc-comment-actions {
    margin-left: 46px;
    margin-top: 8px;
}

.tnc-reply-btn {
    font-size: 12px;
    color: #3498db;
    text-decoration: none;
    font-weight: 600;
}

.tnc-reply-btn:hover {
    text-decoration: underline;
}

/* Risposte */
.tnc-replies {
    margin-left: 46px;
    margin-top: 12px;
    padding-left: 16px;
    border-left: 2px solid #ddd;
}

.tnc-reply {
    padding: 10px;
    margin-bottom: 8px;
    background: #ffffff;
    border-left: 2px solid #95a5a6;
}

/* === REAZIONI EMOJI === */
.tnc-reactions-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 10px 0 8px 46px;
    padding: 6px 0;
}

.tnc-reaction-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border: 1px solid #e0e0e0;
    border-radius: 20px;
    background: #f8f9fa;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    line-height: 1;
}

.tnc-reaction-btn:hover:not(.disabled) {
    background: #e3f2fd;
    border-color: #90caf9;
    transform: scale(1.1);
}

.tnc-reaction-btn.active {
    background: #e3f2fd;
    border-color: #1565C0;
    box-shadow: 0 0 0 1px #1565C0;
}

.tnc-reaction-btn.disabled {
    cursor: default;
    opacity: 0.7;
}

.tnc-reaction-emoji {
    font-size: 18px;
    line-height: 1;
}

.tnc-reaction-count {
    font-size: 12px;
    font-weight: 700;
    color: #555;
    min-width: 8px;
}

.tnc-reaction-btn.active .tnc-reaction-count {
    color: #1565C0;
}

@media (max-width: 768px) {
    .tnc-reactions-bar {
        margin-left: 0;
        gap: 4px;
    }
    .tnc-reaction-btn {
        padding: 3px 8px;
    }
    .tnc-reaction-emoji {
        font-size: 16px;
    }
}

/* === LOGIN NOTICE === */
.tnc-login-notice {
    background: linear-gradient(135deg, #f0f7ff 0%, #e3f2fd 100%);
    padding: 24px 28px;
    border-radius: 12px;
    margin-bottom: 24px;
    text-align: center;
    border: 2px solid #bbdefb;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.tnc-login-notice p {
    font-size: 16px;
    color: #333;
    margin-bottom: 16px;
}

.tnc-login-notice .tnc-notice-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 12px;
}

.tnc-login-notice a.tnc-btn-login,
.tnc-login-notice a.tnc-btn-register {
    display: inline-block;
    padding: 14px 32px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
    transition: all 0.25s ease;
    color: #ffffff !important;
}

.tnc-login-notice a.tnc-btn-login:hover,
.tnc-login-notice a.tnc-btn-register:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
    color: #ffffff !important;
}

.tnc-login-notice a {
    color: #1565C0;
    font-weight: 600;
}

.tnc-no-comments {
    color: #888;
    font-style: italic;
    text-align: center;
    padding: 20px;
}

/* === MODAL === */
.tnc-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.6);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.tnc-modal-content {
    background: #ffffff;
    border-radius: 12px;
    padding: 30px;
    max-width: 450px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.tnc-modal-large {
    max-width: 600px;
}

.tnc-modal-close {
    position: absolute;
    top: 12px;
    right: 16px;
    font-size: 28px;
    cursor: pointer;
    color: #666;
    line-height: 1;
}

.tnc-modal-close:hover {
    color: #000;
}

/* === FORM GENERICI === */
.tnc-form {
    width: 100%;
}

.tnc-form-group {
    margin-bottom: 16px;
}

.tnc-form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.tnc-form-group input[type="text"],
.tnc-form-group input[type="email"],
.tnc-form-group input[type="password"],
.tnc-form-group input[type="tel"],
.tnc-form-group input[type="number"],
.tnc-form-group select,
.tnc-form-group textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.2s;
    background-color: #ffffff !important;
    color: #333333 !important;
    line-height: 1.4;
    min-height: 44px;
    box-sizing: border-box;
}

.tnc-form-group select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 8L1 3h10z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 12px center !important;
    background-size: 12px !important;
    padding-right: 34px !important;
    height: auto !important;
    min-height: 48px !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tnc-form-group select option {
    background-color: #ffffff !important;
    color: #333333 !important;
    padding: 10px 12px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
}

.tnc-form-group input:focus,
.tnc-form-group select:focus,
.tnc-form-group textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52,152,219,0.2);
}

.tnc-form-row-2col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.tnc-privacy-check {
    padding: 12px;
    background: #f9f9f9;
    border-radius: 6px;
}

.tnc-privacy-check label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: normal;
    cursor: pointer;
}

.tnc-antispam-math label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.tnc-antispam-math input {
    width: 100px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
}

/* === BOTTONI === */
.tnc-btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.25s ease;
    font-family: inherit;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

.tnc-btn:active {
    transform: scale(0.96);
}

.tnc-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
}

/* Pulsante INVIA COMMENTO - Arancione vivace */
.tnc-btn-primary {
    background: linear-gradient(135deg, #FF6B35 0%, #FF8C42 100%);
    color: #ffffff;
    font-size: 16px;
    padding: 14px 32px;
}

.tnc-btn-primary:hover {
    background: linear-gradient(135deg, #E85D2C 0%, #FF7A30 100%);
    color: #ffffff;
}

/* Pulsante LOGIN - Blu intenso */
.tnc-btn-login {
    background: linear-gradient(135deg, #1565C0 0%, #1E88E5 100%);
    color: #ffffff !important;
    font-size: 16px;
    padding: 14px 32px;
}

.tnc-btn-login:hover {
    background: linear-gradient(135deg, #0D47A1 0%, #1565C0 100%);
    color: #ffffff !important;
}

/* Pulsante REGISTRATI - Verde brillante */
.tnc-btn-register {
    background: linear-gradient(135deg, #2E7D32 0%, #43A047 100%);
    color: #ffffff !important;
    font-size: 16px;
    padding: 14px 32px;
}

.tnc-btn-register:hover {
    background: linear-gradient(135deg, #1B5E20 0%, #2E7D32 100%);
    color: #ffffff !important;
}

/* Pulsante AZIONE - Rosso */
.tnc-btn-action {
    background: linear-gradient(135deg, #C62828 0%, #E53935 100%);
    color: #ffffff;
}

.tnc-btn-action:hover {
    background: linear-gradient(135deg, #B71C1C 0%, #C62828 100%);
    color: #ffffff;
}

.tnc-btn-small {
    padding: 6px 14px;
    font-size: 12px;
    text-transform: none;
    letter-spacing: 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* === MESSAGGI === */
.tnc-message {
    margin-top: 12px;
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 13px;
}

.tnc-message-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.tnc-message-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.tnc-form-links {
    margin-top: 12px;
    font-size: 13px;
    text-align: center;
}

.tnc-form-links a {
    color: #3498db;
}

/* === AREA PERSONALE === */
.tnc-user-area {
    max-width: 900px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.tnc-user-area-nav {
    display: flex;
    gap: 4px;
    margin-bottom: 24px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 0;
}

.tnc-user-area-nav a {
    padding: 10px 16px;
    text-decoration: none;
    color: #666;
    font-weight: 600;
    font-size: 14px;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s;
}

.tnc-user-area-nav a:hover,
.tnc-user-area-nav a.active {
    color: #3498db;
    border-bottom-color: #3498db;
}

/* Profilo */
.tnc-profile-card {
    display: flex;
    gap: 24px;
    padding: 24px;
    background: #f9f9f9;
    border-radius: 12px;
}

.tnc-profile-photo img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
}

.tnc-profile-info h3 {
    margin: 0 0 12px 0;
    font-size: 20px;
    color: #1a1a2e;
}

.tnc-profile-info p {
    margin: 4px 0;
    font-size: 14px;
    color: #333;
}

/* Commenti utente */
.tnc-user-comment-item {
    padding: 16px;
    margin-bottom: 12px;
    background: #f9f9f9;
    border-radius: 8px;
    border-left: 3px solid #3498db;
}

.tnc-user-comment-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.tnc-comment-status {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 600;
}

.tnc-status-pending { background: #fff3cd; color: #856404; }
.tnc-status-approved { background: #d4edda; color: #155724; }
.tnc-status-hidden { background: #f8d7da; color: #721c24; }

.tnc-user-comment-replies {
    margin-top: 12px;
    padding: 12px;
    background: #ffffff;
    border-radius: 6px;
}

.tnc-reply-item {
    padding: 6px 0;
    border-bottom: 1px solid #eee;
    font-size: 13px;
}

.tnc-reply-item:last-child {
    border-bottom: none;
}

.tnc-reply-author {
    font-weight: 600;
    color: #3498db;
}

.tnc-reply-date {
    font-size: 11px;
    color: #888;
    margin-left: 8px;
}

/* Messaggi */
.tnc-message-item {
    padding: 16px;
    margin-bottom: 12px;
    background: #f9f9f9;
    border-radius: 8px;
    border-left: 3px solid #3498db;
}

.tnc-message-item.tnc-unread {
    background: #eef6ff;
    border-left-color: #e74c3c;
}

.tnc-message-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.tnc-message-date {
    font-size: 12px;
    color: #888;
}

.tnc-badge-global {
    background: #9b59b6;
    color: #ffffff;
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 10px;
}

.tnc-message-body {
    font-size: 14px;
    line-height: 1.6;
    color: #333;
}

/* Documenti */
.tnc-docs-section {
    margin-bottom: 30px;
}

.tnc-docs-section h4 {
    font-size: 16px;
    margin-bottom: 12px;
    color: #1a1a2e;
}

.tnc-docs-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.tnc-docs-table th,
.tnc-docs-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.tnc-docs-table th {
    background: #f5f5f5;
    font-weight: 600;
    color: #333;
}

.tnc-docs-upload {
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
}

/* === SEZIONE REFERRAL / INVITATI === */
.tnc-referral-box {
    margin-top: 24px;
    padding: 24px;
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f4fd 100%);
    border-radius: 12px;
    border: 1px solid #b8daff;
}

.tnc-referral-box h4 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #1a1a2e;
}

.tnc-referral-box p {
    font-size: 14px;
    color: #333;
    margin: 0 0 12px 0;
}

.tnc-referral-link-wrap {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    flex-wrap: wrap;
    max-width: 100%;
    overflow: hidden;
}

.tnc-referral-link-wrap input {
    flex: 1;
    min-width: 0;
    max-width: 100%;
}

.tnc-referral-link-wrap .tnc-btn {
    white-space: nowrap;
    flex-shrink: 0;
}

.tnc-referral-link-input {
    flex: 1;
    padding: 10px 14px;
    border: 2px solid #3498db;
    border-radius: 8px;
    font-size: 13px;
    background: #ffffff;
    color: #333;
}

.tnc-referral-code-display {
    font-size: 13px;
    color: #555;
    margin-bottom: 16px;
}

.tnc-referral-share {
    margin-top: 12px;
}

.tnc-referral-notice {
    padding: 10px 14px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 8px;
    margin-bottom: 12px;
}

.tnc-referral-notice p {
    margin: 0;
    font-size: 13px;
    color: #155724;
    font-weight: 600;
}

.tnc-success-notice {
    padding: 14px 18px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 8px;
    margin-bottom: 20px;
}

.tnc-success-notice p {
    margin: 0;
    font-size: 14px;
    color: #155724;
}

.tnc-error-notice {
    padding: 14px 18px;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    margin-bottom: 20px;
}

.tnc-error-notice p {
    margin: 0;
    font-size: 14px;
    color: #721c24;
}

.tnc-logged-notice {
    padding: 20px;
    background: #f0f7ff;
    border-radius: 12px;
    text-align: center;
}

.tnc-referral-summary {
    font-size: 14px;
    color: #333;
    margin-bottom: 20px;
    padding: 12px 16px;
    background: #f0f7ff;
    border-radius: 8px;
    border-left: 4px solid #3498db;
}

.tnc-referral-summary code {
    font-size: 12px;
    background: #e9ecef;
    padding: 2px 6px;
    border-radius: 4px;
    word-break: break-all;
}

.tnc-no-referrals {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    font-style: italic;
}

.tnc-referrals-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.tnc-referral-card {
    padding: 20px;
    background: #f9f9f9;
    border-radius: 12px;
    border: 1px solid #e0e0e0;
    transition: box-shadow 0.2s;
}

.tnc-referral-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.tnc-referral-header {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.tnc-referral-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.tnc-referral-avatar .tnc-avatar-placeholder {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #3498db;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-weight: bold;
    font-size: 18px;
}

.tnc-referral-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.tnc-referral-name {
    font-size: 15px;
    color: #1a1a2e;
}

.tnc-referral-nickname {
    font-size: 13px;
    color: #3498db;
}

.tnc-referral-date {
    font-size: 12px;
    color: #888;
}

.tnc-referral-stats {
    display: flex;
    gap: 8px;
}

.tnc-stat-badge {
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 12px;
    background: #e9ecef;
    color: #333;
    font-weight: 600;
}

.tnc-stat-badge.tnc-stat-approved {
    background: #d4edda;
    color: #155724;
}

.tnc-referral-comments {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e0e0e0;
}

.tnc-referral-comments h5 {
    font-size: 13px;
    font-weight: 600;
    color: #555;
    margin: 0 0 10px 0;
}

.tnc-referral-comments-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tnc-referral-comment-item {
    padding: 10px 14px;
    background: #ffffff;
    border-radius: 6px;
    border-left: 3px solid #3498db;
}

.tnc-rc-article {
    font-size: 12px;
    font-weight: 600;
    color: #1a1a2e;
    display: block;
    margin-bottom: 4px;
}

.tnc-rc-status {
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 8px;
    font-weight: 600;
    float: right;
}

.tnc-rc-content {
    font-size: 13px;
    color: #333;
    margin: 4px 0;
    line-height: 1.4;
}

.tnc-rc-date {
    font-size: 11px;
    color: #888;
}

.tnc-badge {
    display: inline-block;
    background: #e74c3c;
    color: #ffffff;
    font-size: 10px;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 4px;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .tnc-topbar-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #1a1a2e !important;
        flex-direction: column;
        padding: 16px 12px;
        box-shadow: 0 8px 20px rgba(0,0,0,0.5);
        gap: 4px;
        z-index: 999999;
    }

    .tnc-topbar-menu.active {
        display: flex !important;
    }

    .tnc-topbar-toggle {
        display: block;
    }

    .tnc-topbar-link {
        padding: 14px 20px;
        font-size: 16px;
        border-radius: 8px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        color: #ffffff !important;
        -webkit-text-fill-color: #ffffff !important;
        text-align: left;
        width: 100%;
    }

    .tnc-topbar-link:visited,
    .tnc-topbar-link:active,
    .tnc-topbar-link:focus {
        color: #ffffff !important;
        -webkit-text-fill-color: #ffffff !important;
    }

    .tnc-topbar-link-esci {
        color: #e74c3c !important;
        -webkit-text-fill-color: #e74c3c !important;
    }

    .tnc-topbar-link:last-child {
        border-bottom: none;
    }

    .tnc-topbar-separator {
        width: 100%;
        height: 1px;
        background: rgba(255,255,255,0.15) !important;
        margin: 8px 0;
    }

    .tnc-form-row-2col {
        grid-template-columns: 1fr;
    }

    .tnc-modal-content {
        padding: 20px;
        margin: 10px;
    }

    .tnc-profile-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .tnc-user-area-nav {
        flex-wrap: wrap;
    }

    .tnc-user-area-nav a {
        padding: 8px 12px;
        font-size: 12px;
    }

    .tnc-comment-body {
        margin-left: 0;
    }

    .tnc-comment-actions {
        margin-left: 0;
    }

    .tnc-replies {
        margin-left: 16px;
    }

    .tnc-docs-table {
        font-size: 11px;
    }

    .tnc-docs-table th,
    .tnc-docs-table td {
        padding: 6px 8px;
    }

    /* Social buttons responsive */
    .tnc-share-buttons {
        gap: 8px;
    }

    .tnc-share-btn {
        padding: 9px 12px;
        font-size: 12px;
    }

    .tnc-share-btn span {
        display: none;
    }

    .tnc-share-btn svg {
        width: 20px;
        height: 20px;
    }

    /* Textarea commento responsive */
    .tnc-comment-form textarea {
        min-height: 120px;
        font-size: 16px;
        padding: 14px;
    }

    .tnc-banner-comments {
        border-radius: 8px;
    }
}

@media (max-width: 480px) {
    .tnc-comment-form .tnc-form-row {
        flex-direction: column;
    }

    .tnc-user-avatar {
        display: none;
    }

    .tnc-topbar-nickname {
        display: none;
    }

    .tnc-share-btn {
        padding: 10px;
        border-radius: 50%;
    }

    .tnc-share-btn svg {
        width: 22px;
        height: 22px;
    }

    .tnc-comment-form textarea {
        min-height: 110px;
        font-size: 16px;
    }
}

/* ============================================
   SEZIONE ANNUNCI
   ============================================ */

.tnc-annunci-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Header annunci */
.tnc-annunci-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.tnc-annunci-header h2 {
    font-size: 28px;
    color: #1a1a2e;
    margin: 0;
}

.tnc-annunci-header-btns {
    display: flex;
    gap: 10px;
}

.tnc-btn-new-annuncio {
    display: inline-block;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: #ffffff !important;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    box-shadow: 0 3px 10px rgba(255, 107, 53, 0.3);
    transition: all 0.3s ease;
}

.tnc-btn-new-annuncio:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 53, 0.4);
    color: #ffffff !important;
}

.tnc-btn-my-annunci {
    display: inline-block;
    background: linear-gradient(135deg, #2196F3, #1976D2);
    color: #ffffff !important;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    box-shadow: 0 3px 10px rgba(33, 150, 243, 0.3);
    transition: all 0.3s ease;
}

.tnc-btn-my-annunci:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(33, 150, 243, 0.4);
    color: #ffffff !important;
}

/* Filtri */
.tnc-annunci-filters {
    background: #f8f9fa;
    padding: 16px;
    border-radius: 10px;
    margin-bottom: 24px;
    border: 1px solid #e0e0e0;
}

.tnc-filter-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.tnc-filter-row select,
.tnc-filter-row input[type="text"] {
    padding: 12px 14px;
    border: 1px solid #ccc;
    background-color: #ffffff !important;
    color: #333333 !important;
    border-radius: 6px;
    font-size: 14px;
    flex: 1;
    min-width: 150px;
    min-height: 48px;
    line-height: 1.4;
    box-sizing: border-box;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.tnc-filter-row select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 8L1 3h10z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 14px center !important;
    background-size: 12px !important;
    padding-right: 36px !important;
}

.tnc-filter-row select option {
    background-color: #ffffff !important;
    color: #333333 !important;
    padding: 10px 12px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
}

.tnc-btn-filter {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    color: #ffffff;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.tnc-btn-filter:hover {
    background: linear-gradient(135deg, #16213e, #0f3460);
}

/* Griglia annunci */
.tnc-annunci-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.tnc-annuncio-card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid #eee;
}

.tnc-annuncio-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

.tnc-ann-card-img {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f0f0f0;
}

.tnc-ann-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
    transition: transform 0.3s ease;
}

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

.tnc-ann-no-img {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 14px;
}

.tnc-ann-card-body {
    padding: 16px;
}

.tnc-ann-card-category {
    display: inline-block;
    background: #e3f2fd;
    color: #1565c0;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 8px;
}

.tnc-ann-card-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0 0 6px 0;
}

.tnc-ann-card-location {
    color: #666;
    font-size: 13px;
    margin: 0 0 8px 0;
}

.tnc-ann-card-desc {
    color: #444;
    font-size: 14px;
    line-height: 1.5;
    margin: 0 0 12px 0;
}

.tnc-ann-card-price {
    font-size: 22px;
    font-weight: 800;
    color: #e65100;
    margin-bottom: 12px;
}

.tnc-ann-no-price {
    font-size: 14px;
    color: #888;
    font-weight: 400;
    font-style: italic;
}

/* Badge VENDUTO sovrapposto alla foto */
.tnc-ann-card-img-wrapper {
    position: relative;
    overflow: hidden;
}

.tnc-venduto-badge {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    pointer-events: none;
}

.tnc-venduto-badge span {
    background: rgba(220, 20, 20, 0.88);
    color: #ffffff !important;
    font-size: 32px;
    font-weight: 900;
    letter-spacing: 4px;
    padding: 14px 30px;
    border: 4px solid #ffffff;
    border-radius: 8px;
    transform: rotate(-15deg);
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    text-transform: uppercase;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.tnc-annuncio-card.tnc-venduto .tnc-ann-card-img img {
    opacity: 0.5;
    filter: grayscale(50%);
}

.tnc-annuncio-card.tnc-venduto .tnc-ann-card-body {
    opacity: 0.7;
}

/* Pulsante Venduto nei miei annunci */
.tnc-btn-venduto-annuncio {
    background: linear-gradient(135deg, #ff6b35, #e64900) !important;
    color: #ffffff !important;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.tnc-btn-venduto-annuncio:hover {
    background: linear-gradient(135deg, #e64900, #cc3d00) !important;
    transform: scale(1.05);
}

.tnc-btn-venduto-annuncio.is-venduto {
    background: linear-gradient(135deg, #4caf50, #388e3c) !important;
}

.tnc-btn-venduto-annuncio.is-venduto:hover {
    background: linear-gradient(135deg, #388e3c, #2e7d32) !important;
}

/* Contatti annuncio */
.tnc-ann-card-contacts {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.tnc-ann-contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.tnc-ann-whatsapp {
    background: #25d366;
    color: #ffffff !important;
}

.tnc-ann-whatsapp:hover {
    background: #1da851;
    color: #ffffff !important;
}

.tnc-ann-email {
    background: #2196F3;
    color: #ffffff !important;
}

.tnc-ann-email:hover {
    background: #1976D2;
    color: #ffffff !important;
}

.tnc-ann-card-contacts-locked {
    background: #fff3e0;
    padding: 10px;
    border-radius: 6px;
    font-size: 13px;
    color: #e65100;
    margin-bottom: 12px;
}

.tnc-ann-card-contacts-locked a {
    color: #e65100;
    font-weight: 700;
}

/* Galleria foto annuncio */
.tnc-ann-card-gallery {
    display: flex;
    gap: 4px;
    padding: 0 16px 12px;
    overflow-x: auto;
}

.tnc-ann-gallery-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    border: 2px solid #eee;
    transition: all 0.2s ease;
}

.tnc-ann-gallery-thumb:hover {
    border-color: #2196F3;
    transform: scale(1.1);
}

/* Condivisione annuncio */
.tnc-ann-card-share {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 10px 16px;
    border-top: 1px solid #f0f0f0;
    background: #fafafa;
}

.tnc-ann-card-share .tnc-share-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 11px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    color: #ffffff !important;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    white-space: nowrap;
}

.tnc-ann-card-share .tnc-share-btn svg {
    flex-shrink: 0;
    fill: #ffffff;
}

.tnc-ann-card-share .tnc-share-btn span {
    line-height: 1;
}

.tnc-share-fb { background: #1877f2; }
.tnc-share-wa { background: #25d366; }
.tnc-share-tw { background: #000000; }
.tnc-share-tg { background: #0088cc; }

.tnc-ann-card-share .tnc-share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 3px 10px rgba(0,0,0,0.25);
    color: #ffffff !important;
}

/* Footer card */
.tnc-ann-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 16px;
    background: #f8f9fa;
    font-size: 12px;
    color: #888;
}

/* Paginazione */
.tnc-annunci-pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 30px;
}

.tnc-annunci-pagination a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f0f0f0;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

.tnc-annunci-pagination a.active,
.tnc-annunci-pagination a:hover {
    background: #1a1a2e;
    color: #ffffff;
}

/* Form inserimento annuncio */
.tnc-annunci-form-container {
    background: #ffffff;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    border: 1px solid #eee;
}

.tnc-annunci-form-container h2 {
    font-size: 24px;
    color: #1a1a2e;
    margin: 0 0 8px 0;
}

.tnc-annunci-subtitle {
    color: #666;
    margin: 0 0 24px 0;
}

.tnc-form-row {
    margin-bottom: 18px;
}

.tnc-form-row-2col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.tnc-form-group label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
    font-size: 14px;
}

.tnc-form-group input[type="text"],
.tnc-form-group input[type="email"],
.tnc-form-group input[type="tel"],
.tnc-form-group select,
.tnc-form-group textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.4;
    min-height: 48px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
    background-color: #ffffff !important;
    color: #333333 !important;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.tnc-form-group select {
    background-color: #ffffff !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 8L1 3h10z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 14px center !important;
    background-size: 12px !important;
    padding-right: 36px !important;
    color: #111111 !important;
    opacity: 1 !important;
    -webkit-text-fill-color: #111111 !important;
    font-size: 14px !important;
    font-weight: 400 !important;
    height: auto !important;
    min-height: 48px !important;
    line-height: 1.4 !important;
}

.tnc-form-group select option {
    background-color: #ffffff !important;
    color: #111111 !important;
    -webkit-text-fill-color: #111111 !important;
    padding: 10px 12px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
}

.tnc-form-group input:focus,
.tnc-form-group select:focus,
.tnc-form-group textarea:focus {
    border-color: #2196F3;
    outline: none;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

.tnc-form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.tnc-form-checkbox-group {
    display: flex;
    align-items: center;
}

.tnc-form-checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 400;
}

.tnc-form-hint {
    color: #888;
    font-size: 12px;
    margin-top: 4px;
    display: block;
}

/* Upload foto */
.tnc-foto-upload-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.tnc-social-preview-grid {
    grid-template-columns: 1fr;
    max-width: 250px;
}

.tnc-foto-upload-item {
    position: relative;
}

.tnc-foto-upload-label {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 140px;
    border: 2px dashed #ccc;
    border-radius: 8px;
    cursor: pointer;
    background: #fafafa;
    transition: all 0.3s ease;
    overflow: hidden;
}

.tnc-foto-upload-label:hover {
    border-color: #2196F3;
    background: #e3f2fd;
}

.tnc-foto-upload-label span {
    color: #888;
    font-size: 14px;
    font-weight: 500;
}

.tnc-foto-upload-label img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tnc-foto-input {
    display: none;
}

/* Pulsante pubblica */
.tnc-btn-submit-annuncio {
    display: block;
    width: 100%;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: #ffffff !important;
    border: none;
    padding: 16px 30px;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 800;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
    transition: all 0.3s ease;
    margin-top: 10px;
}

.tnc-btn-submit-annuncio:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
}

/* I miei annunci */
.tnc-annunci-my-container h2 {
    font-size: 24px;
    color: #1a1a2e;
    margin: 0 0 16px 0;
}

.tnc-my-annunci-list {
    margin-top: 20px;
}

.tnc-my-annuncio-card {
    background: #ffffff;
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 12px;
    border: 1px solid #eee;
    box-shadow: 0 1px 6px rgba(0,0,0,0.05);
}

.tnc-my-annuncio-card.expired {
    opacity: 0.6;
    border-color: #ffcdd2;
}

.tnc-my-annuncio-card.expiring {
    border-color: #fff3e0;
    background: #fffde7;
}

.tnc-my-ann-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.tnc-my-ann-header h3 {
    margin: 0;
    font-size: 18px;
    color: #1a1a2e;
}

.tnc-ann-status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
}

.tnc-ann-status-badge.active {
    background: #c8e6c9;
    color: #2e7d32;
}

.tnc-ann-status-badge.expired {
    background: #ffcdd2;
    color: #c62828;
}

.tnc-my-ann-info {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 13px;
    color: #555;
    margin-bottom: 12px;
}

.tnc-my-ann-actions {
    display: flex;
    gap: 8px;
}

.tnc-btn-renew-annuncio {
    background: linear-gradient(135deg, #4caf50, #388e3c);
    color: #ffffff !important;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.tnc-btn-renew-annuncio:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(76, 175, 80, 0.3);
}

.tnc-btn-delete-annuncio {
    background: linear-gradient(135deg, #e53935, #c62828);
    color: #ffffff !important;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.tnc-btn-delete-annuncio:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(229, 57, 53, 0.3);
}

/* Lightbox */
.tnc-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tnc-lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.85);
}

.tnc-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tnc-lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    border-radius: 8px;
    box-shadow: 0 4px 30px rgba(0,0,0,0.5);
}

.tnc-lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 36px;
    cursor: pointer;
}

.tnc-lightbox-prev,
.tnc-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.2);
    border: none;
    color: #ffffff;
    font-size: 28px;
    padding: 10px 16px;
    cursor: pointer;
    border-radius: 50%;
    transition: background 0.3s ease;
}

.tnc-lightbox-prev:hover,
.tnc-lightbox-next:hover {
    background: rgba(255,255,255,0.4);
}

.tnc-lightbox-prev { left: -60px; }
.tnc-lightbox-next { right: -60px; }

.tnc-no-results {
    text-align: center;
    color: #888;
    font-style: italic;
    padding: 40px 20px;
}

/* Responsive annunci - Tablet */
@media (max-width: 1024px) {
    .tnc-annunci-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .tnc-annunci-form-container {
        padding: 24px;
    }

    .tnc-venduto-badge span {
        font-size: 26px;
        padding: 10px 22px;
    }
}

/* Responsive annunci - Mobile */
@media (max-width: 768px) {
    .tnc-annunci-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    
    .tnc-form-row-2col {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .tnc-foto-upload-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .tnc-filter-row {
        flex-direction: column;
        gap: 8px;
    }

    .tnc-filter-row select,
    .tnc-filter-row input[type="text"] {
        width: 100%;
        min-width: unset;
        min-height: 48px;
        font-size: 14px !important;
        line-height: 1.4;
    }
    
    .tnc-annunci-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .tnc-annunci-header-btns {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 8px;
    }

    .tnc-annunci-header-btns a {
        text-align: center;
    }

    .tnc-annunci-form-container {
        padding: 16px;
        margin: 0 -10px;
    }

    .tnc-annunci-form-container h2 {
        font-size: 20px;
    }

    .tnc-btn-submit-annuncio {
        font-size: 16px;
        padding: 14px 20px;
    }

    .tnc-my-ann-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .tnc-my-ann-actions {
        flex-wrap: wrap;
        gap: 6px;
    }

    .tnc-my-ann-actions button {
        flex: 1;
        min-width: 120px;
        text-align: center;
    }

    .tnc-ann-card-share {
        flex-wrap: wrap;
        justify-content: center;
    }

    .tnc-ann-card-contacts {
        flex-direction: column;
    }

    .tnc-ann-contact-btn {
        width: 100%;
        text-align: center;
    }

    .tnc-venduto-badge span {
        font-size: 22px;
        padding: 8px 18px;
        letter-spacing: 2px;
    }
    
    .tnc-lightbox-prev { left: 10px; }
    .tnc-lightbox-next { right: 10px; }

    .tnc-lightbox-content img {
        max-width: 95vw;
        max-height: 80vh;
    }
}

/* Responsive annunci - Mobile piccolo */
@media (max-width: 480px) {
    .tnc-foto-upload-grid {
        grid-template-columns: 1fr 1fr;
    }

    .tnc-foto-upload-label {
        height: 90px;
    }

    .tnc-ann-card-gallery {
        grid-template-columns: repeat(2, 1fr);
    }

    .tnc-venduto-badge span {
        font-size: 18px;
        padding: 6px 14px;
        letter-spacing: 1px;
    }

    .tnc-annuncio-card {
        border-radius: 8px;
    }

    .tnc-ann-card-body {
        padding: 12px;
    }

    .tnc-my-ann-actions {
        flex-direction: column;
    }

    .tnc-my-ann-actions button {
        width: 100%;
    }
}


/* === SEZIONE BLOG - STILE CORRIERE DI GENOVA === */
.tnc-blog-wrapper {
    max-width: 750px;
    margin: 0 auto;
    padding: 0 15px 40px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #ffffff;
}

/* Login box */
.tnc-blog-login-box {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 24px;
    text-align: center;
}

.tnc-blog-login-box p {
    font-size: 16px;
    color: #333;
    margin: 0 0 12px 0;
}

.tnc-blog-login-btns {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.tnc-blog-btn-login,
.tnc-blog-btn-register {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    text-transform: uppercase;
    color: #ffffff !important;
}

.tnc-blog-btn-login {
    background: #1a1a2e;
}

.tnc-blog-btn-register {
    background: #c0392b;
}

/* TESTATA BLOG - Stile Corriere */
.tnc-blog-testata {
    text-align: center;
    padding: 30px 0 20px;
    border-bottom: 3px solid #1a1a2e;
    margin-bottom: 20px;
}

.tnc-blog-testata-title {
    font-family: "Georgia", "Times New Roman", serif;
    font-size: 36px;
    font-weight: 900;
    color: #1a1a2e;
    margin: 0;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.tnc-blog-testata-sub {
    font-size: 14px;
    color: #666;
    margin: 6px 0 0;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Header buttons */
.tnc-blog-header-btns {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 20px;
}

.tnc-btn-my-blog,
.tnc-btn-new-blog {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 13px;
    text-decoration: none;
    text-transform: uppercase;
    transition: all 0.3s;
}

.tnc-btn-my-blog {
    background: #1a1a2e;
    color: #ffffff !important;
}

.tnc-btn-new-blog {
    background: #c0392b;
    color: #ffffff !important;
}

.tnc-btn-my-blog:hover,
.tnc-btn-new-blog:hover {
    opacity: 0.85;
    transform: translateY(-1px);
}

/* TABS - Più recenti / Popolari */
.tnc-blog-tabs {
    display: flex;
    gap: 0;
    border-bottom: 3px solid #e0e0e0;
    margin-bottom: 24px;
}

.tnc-blog-tab {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 20px;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 700;
    color: #666;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    transition: color 0.3s;
}

.tnc-blog-tab.active {
    color: #1a1a2e;
}

.tnc-blog-tab.active::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    right: 0;
    height: 3px;
    background: #2980b9;
}

.tnc-blog-tab:hover {
    color: #1a1a2e;
}

.tnc-blog-tab svg {
    flex-shrink: 0;
}

/* Tab content */
.tnc-blog-tab-content {
    display: none;
}

.tnc-blog-tab-content.active {
    display: block;
}

/* FILTRI */
.tnc-blog-filters {
    margin-bottom: 24px;
}

.tnc-blog-filter-form .tnc-filter-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

.tnc-blog-filter-form select,
.tnc-blog-filter-form input[type="text"] {
    padding: 12px 14px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    min-width: 150px;
    min-height: 48px;
    line-height: 1.4;
    box-sizing: border-box;
    background-color: #ffffff !important;
    color: #333333 !important;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.tnc-blog-filter-form select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 8L1 3h10z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 14px center !important;
    background-size: 12px !important;
    padding-right: 36px !important;
}

.tnc-blog-filter-form select option {
    background-color: #ffffff !important;
    color: #333333 !important;
    padding: 10px 12px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
}

.tnc-blog-filter-form .tnc-btn-filter {
    padding: 10px 20px;
    background: #1a1a2e;
    color: #ffffff;
    border: none;
    border-radius: 6px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    text-transform: uppercase;
}

.tnc-blog-filter-form .tnc-btn-filter:hover {
    background: #2c2c4a;
}

/* === ARTICOLO CARD - STILE CORRIERE (colonna singola) === */
.tnc-blog-article-card {
    margin-bottom: 36px;
    padding-bottom: 36px;
    border-bottom: 1px solid #e8e8e8;
}

.tnc-blog-article-card:last-child {
    border-bottom: none;
}

.tnc-blog-article-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

/* Immagine articolo con badge overlay */
.tnc-blog-article-img-wrapper {
    position: relative;
    margin-bottom: 16px;
    border-radius: 4px;
    overflow: hidden;
    width: 100%;
    height: 220px;
}

.tnc-blog-article-img {
    width: 100% !important;
    height: 220px !important;
    object-fit: cover !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    transition: transform 0.3s;
}

.tnc-blog-article-link:hover .tnc-blog-article-img {
    transform: scale(1.02);
}

/* Badge categorie overlay sull'immagine */
.tnc-blog-article-badges,
.tnc-blog-hero-badges {
    position: absolute;
    bottom: 12px;
    left: 12px;
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.tnc-blog-badge-cat {
    display: inline-block;
    background: #2980b9;
    color: #ffffff;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tnc-blog-badge-luogo {
    display: inline-block;
    background: #27ae60;
    color: #ffffff;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Titolo articolo */
.tnc-blog-article-title {
    font-family: "Georgia", "Times New Roman", serif;
    font-size: 26px;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0 0 10px 0;
    line-height: 1.25;
}

.tnc-blog-article-link:hover .tnc-blog-article-title {
    color: #2980b9;
}

/* Meta autore + data */
.tnc-blog-article-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.tnc-blog-article-author {
    font-size: 15px;
    font-weight: 700;
    color: #1a1a2e;
}

.tnc-blog-article-date {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
    color: #666;
}

.tnc-blog-article-date svg {
    flex-shrink: 0;
}

/* Anteprima testo */
.tnc-blog-article-excerpt {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    margin: 0 0 16px 0;
}

/* Pulsante Leggi articolo */
.tnc-blog-read-btn {
    display: inline-block;
    padding: 10px 24px;
    border: 2px solid #1a1a2e;
    border-radius: 4px;
    color: #1a1a2e !important;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
}

.tnc-blog-read-btn:hover {
    background: #1a1a2e;
    color: #ffffff !important;
}

/* === TAB POPOLARI - Layout orizzontale con thumb === */
.tnc-blog-popular-row {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid #eee;
}

.tnc-blog-popular-row:last-child {
    border-bottom: none;
}

.tnc-blog-popular-row-img-link {
    position: relative;
    flex-shrink: 0;
    width: 180px;
    height: 120px;
    border-radius: 4px;
    overflow: hidden;
}

.tnc-blog-popular-row-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.tnc-blog-popular-row-num {
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    background: #2980b9;
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
}

.tnc-blog-popular-row-content {
    flex: 1;
    min-width: 0;
}

.tnc-blog-popular-row-title {
    display: block;
    font-family: "Georgia", "Times New Roman", serif;
    font-size: 18px;
    font-weight: 700;
    color: #1a1a2e;
    text-decoration: none;
    line-height: 1.3;
    margin-bottom: 8px;
}

.tnc-blog-popular-row-title:hover {
    color: #2980b9;
}

.tnc-blog-popular-row-meta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.tnc-blog-popular-row-date {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: #666;
}

/* === SEZIONE ARTICOLI IN PRIMO PIANO (fondo pagina) === */
.tnc-blog-popular-section {
    margin-top: 40px;
    padding: 24px 0;
    border-top: 3px solid #1a1a2e;
}

.tnc-blog-popular-section h3 {
    margin: 0 0 20px 0;
    font-size: 18px;
    font-weight: 800;
    color: #1a1a2e;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.tnc-blog-popular-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.tnc-blog-popular-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px solid #eee;
}

.tnc-blog-popular-item:last-child {
    border-bottom: none;
}

.tnc-blog-popular-thumb {
    width: 100px;
    height: 70px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
}

.tnc-blog-popular-content {
    flex: 1;
    min-width: 0;
}

.tnc-blog-popular-title {
    display: block;
    font-family: "Georgia", "Times New Roman", serif;
    font-size: 16px;
    font-weight: 700;
    color: #1a1a2e;
    text-decoration: none;
    line-height: 1.3;
    margin-bottom: 6px;
}

.tnc-blog-popular-title:hover {
    color: #2980b9;
}

.tnc-blog-popular-meta {
    display: flex;
    gap: 12px;
    align-items: center;
}

.tnc-blog-popular-date {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #888;
}

.tnc-blog-popular-views {
    font-size: 12px;
    color: #888;
}

/* Paginazione Blog */
.tnc-blog-pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.tnc-blog-pagination a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    border-radius: 4px;
    background: #f0f0f0;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s;
}

.tnc-blog-pagination a.active,
.tnc-blog-pagination a:hover {
    background: #1a1a2e;
    color: #ffffff;
}

/* === ARTICOLO SINGOLO === */
.tnc-blog-single {
    max-width: 750px;
    margin: 0 auto;
}

/* Hero immagine con badge */
.tnc-blog-single-hero {
    position: relative;
    margin-bottom: 20px;
    border-radius: 4px;
    overflow: hidden;
}

.tnc-blog-hero-img {
    width: 100% !important;
    height: auto;
    min-height: 200px;
    max-height: 450px;
    object-fit: cover !important;
    display: block !important;
    cursor: pointer;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Titolo singolo */
.tnc-blog-single-title {
    font-family: "Georgia", "Times New Roman", serif;
    font-size: 32px;
    font-weight: 800;
    color: #1a1a2e;
    margin: 0 0 14px 0;
    line-height: 1.2;
}

/* Meta line singolo */
.tnc-blog-single-meta-line {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #eee;
}

.tnc-blog-single-author {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 700;
    color: #1a1a2e;
}

.tnc-blog-author-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
}

.tnc-blog-single-date {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
    color: #666;
}

.tnc-blog-single-views {
    font-size: 13px;
    color: #888;
}

/* Contenuto articolo */
.tnc-blog-single-content {
    font-size: 17px;
    line-height: 1.8;
    color: #333;
    margin-bottom: 30px;
}

.tnc-blog-single-content p {
    margin-bottom: 16px;
}

/* Galleria thumbnail nella card articolo (lista) */
.tnc-blog-card-gallery {
    display: flex;
    gap: 4px;
    padding: 12px 0 0;
    overflow-x: auto;
}

.tnc-blog-card-gallery-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    border: 2px solid #eee;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.tnc-blog-card-gallery-thumb:hover {
    border-color: #2980b9;
    transform: scale(1.1);
}

/* Galleria */
.tnc-blog-single-gallery {
    margin-bottom: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.tnc-blog-single-gallery h3 {
    margin: 0 0 16px 0;
    font-size: 16px;
    font-weight: 700;
    color: #333;
    text-transform: uppercase;
}

.tnc-blog-gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.tnc-blog-gallery-thumb {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 2px solid #eee;
}

.tnc-blog-gallery-thumb:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 16px rgba(0,0,0,0.2);
    border-color: #c0392b;
}

/* Lightbox per immagini */
.tnc-lightbox-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    z-index: 999999;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.tnc-lightbox-overlay.active {
    display: flex;
}

.tnc-lightbox-overlay img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}

.tnc-lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1000000;
    line-height: 1;
}

/* Condivisione singolo */
.tnc-blog-single-share {
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.tnc-blog-single-share h3 {
    margin: 0 0 12px 0;
    font-size: 15px;
    font-weight: 700;
    color: #333;
    text-transform: uppercase;
}

.tnc-blog-share-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.tnc-share-btn-blog {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 16px;
    border-radius: 22px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    color: #ffffff !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    white-space: nowrap;
}

.tnc-share-btn-blog svg {
    flex-shrink: 0;
    fill: #ffffff;
}

.tnc-share-btn-blog:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    color: #ffffff !important;
}

.tnc-share-btn-facebook { background: #1877f2; }
.tnc-share-btn-whatsapp { background: #25d366; }
.tnc-share-btn-twitter { background: #000000; }
.tnc-share-btn-telegram { background: #0088cc; }
.tnc-share-btn-linkedin { background: #0a66c2; }
.tnc-share-btn-email { background: #6c757d; }

/* Pulsante torna indietro */
.tnc-blog-single-back {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.tnc-btn-back-blog {
    display: inline-block;
    padding: 10px 20px;
    background: #f0f0f0;
    color: #333 !important;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: background 0.3s;
}

.tnc-btn-back-blog:hover {
    background: #e0e0e0;
}

/* Form inserimento blog */
.tnc-blog-form-container {
    max-width: 750px;
    margin: 0 auto;
}

.tnc-blog-form-container h2 {
    font-family: "Georgia", "Times New Roman", serif;
    font-size: 24px;
    color: #1a1a2e;
    margin-bottom: 8px;
}

.tnc-blog-subtitle {
    color: #666;
    margin-bottom: 24px;
    font-size: 14px;
}

.tnc-btn-submit-blog {
    display: block;
    width: 100%;
    padding: 16px;
    background: #c0392b;
    color: #ffffff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s;
}

.tnc-btn-submit-blog:hover {
    background: #a93226;
    transform: translateY(-1px);
}

/* I Miei Articoli */
.tnc-blog-my-container h2 {
    font-family: "Georgia", "Times New Roman", serif;
    font-size: 24px;
    color: #1a1a2e;
    margin-bottom: 16px;
}

.tnc-my-blog-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 20px;
}

.tnc-my-blog-card {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 16px 20px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.tnc-my-blog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 8px;
}

.tnc-my-blog-header h3 {
    margin: 0;
    font-size: 17px;
    color: #1a1a2e;
    font-family: "Georgia", "Times New Roman", serif;
}

.tnc-blog-status-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.tnc-blog-status-badge.approved {
    background: #d4edda;
    color: #155724;
}

.tnc-blog-status-badge.pending {
    background: #fff3cd;
    color: #856404;
}

.tnc-blog-status-badge.hidden {
    background: #f8d7da;
    color: #721c24;
}

.tnc-my-blog-info {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 13px;
    color: #555;
    margin-bottom: 12px;
}

.tnc-my-blog-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.tnc-btn-view-blog {
    display: inline-block;
    padding: 8px 16px;
    background: #1a1a2e;
    color: #ffffff !important;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
}

.tnc-btn-delete-blog {
    padding: 8px 16px;
    background: #c0392b;
    color: #ffffff;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
}

.tnc-btn-delete-blog:hover {
    background: #a93226;
}

/* Admin Blog - row pending */
.tnc-row-pending td {
    background: #fff8e1 !important;
}

/* === RESPONSIVE BLOG === */
@media (max-width: 768px) {
    .tnc-blog-testata-title {
        font-size: 26px;
    }
    
    .tnc-blog-article-title {
        font-size: 22px;
    }
    
    .tnc-blog-single-title {
        font-size: 24px;
    }
    
    .tnc-blog-article-meta {
        flex-direction: column;
        gap: 4px;
    }
    
    .tnc-blog-single-meta-line {
        flex-direction: column;
        gap: 8px;
    }
    
    .tnc-blog-share-buttons {
        flex-direction: column;
    }
    
    .tnc-share-btn-blog {
        justify-content: center;
    }
    
    .tnc-blog-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tnc-blog-popular-row-img-link {
        width: 140px;
        height: 95px;
    }
    
    .tnc-blog-filter-form .tnc-filter-row {
        flex-direction: column;
    }
    
    .tnc-blog-filter-form select,
    .tnc-blog-filter-form input[type="text"] {
        width: 100%;
        min-width: auto;
        min-height: 48px;
        font-size: 14px !important;
        line-height: 1.4;
    }
    
    .tnc-blog-tabs {
        justify-content: center;
    }
    
    .tnc-blog-tab {
        padding: 10px 14px;
        font-size: 12px;
    }
    
    /* Form blog: campi uno per riga su mobile */
    .tnc-blog-form-container .tnc-form-row-2col {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }
}

@media (max-width: 480px) {
    .tnc-blog-testata-title {
        font-size: 22px;
        letter-spacing: 1px;
    }
    
    .tnc-blog-article-img {
        height: 180px !important;
    }
    
    .tnc-blog-article-img-wrapper {
        height: 180px;
    }
    
    .tnc-blog-hero-img {
        max-height: 280px;
    }
    
    .tnc-blog-popular-row {
        flex-direction: column;
    }
    
    .tnc-blog-popular-row-img-link {
        width: 100%;
        height: 180px;
    }
    
    .tnc-blog-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .tnc-blog-gallery-thumb {
        height: 80px;
    }
    
    .tnc-blog-popular-thumb {
        width: 80px;
        height: 55px;
    }
    
    .tnc-blog-card-gallery-thumb {
        width: 50px;
        height: 50px;
    }
}

/* ============================================================
 * FIX v2.8.6 — Foto upload: layout verticale (1 colonna)
 * I 4 campi foto devono essere uno sopra l'altro, non in griglia 2x2
 * ============================================================ */
.tnc-foto-upload-grid {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
    max-width: 100%;
}
.tnc-foto-upload-label {
    height: 120px;
}
@media (min-width: 768px) {
    .tnc-foto-upload-label {
        height: 150px;
    }
}

/* ============================================================
 * SISTEMA LEADER / COMITATO (v2.9.0)
 * ============================================================ */

/* Barra progressione */
.tnc-leader-progress {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
}
.tnc-progress-bar-wrap {
    margin: 16px 0;
}
.tnc-progress-bar {
    height: 12px;
    background: #e0e0e0;
    border-radius: 6px;
    overflow: hidden;
}
.tnc-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4CAF50, #2196F3, #9C27B0);
    border-radius: 6px;
    transition: width 0.5s ease;
}
.tnc-progress-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 12px;
    color: #888;
}
.tnc-progress-labels span.unlocked {
    color: #4CAF50;
    font-weight: 600;
}
.tnc-progress-status {
    margin-top: 12px;
    font-size: 14px;
    color: #555;
}

/* Messaggistica */
.tnc-leader-messaging {
    margin-bottom: 30px;
}
.tnc-mass-message-box,
.tnc-single-message-box {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 18px;
    margin-bottom: 18px;
}
.tnc-mass-message-box h4,
.tnc-single-message-box h4 {
    margin: 0 0 12px 0;
    font-size: 16px;
}
.tnc-leader-messaging textarea {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px;
    font-size: 14px;
    resize: vertical;
}
.tnc-leader-messaging select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    margin-bottom: 10px;
}

/* Messaggi lista */
.tnc-messages-list {
    max-height: 400px;
    overflow-y: auto;
}
.tnc-msg-item {
    padding: 12px 16px;
    border-left: 3px solid #ddd;
    margin-bottom: 10px;
    background: #fafafa;
    border-radius: 0 8px 8px 0;
}
.tnc-msg-item.tnc-msg-sent {
    border-left-color: #2196F3;
}
.tnc-msg-item.tnc-msg-received {
    border-left-color: #4CAF50;
}
.tnc-msg-item.tnc-msg-unread {
    background: #e8f5e9;
    border-left-color: #388E3C;
}
.tnc-msg-item.tnc-msg-mass {
    border-left-color: #FF9800;
}
.tnc-msg-header {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 6px;
    font-size: 12px;
    color: #666;
}
.tnc-msg-badge {
    background: #FF9800;
    color: #fff;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
}
.tnc-msg-content {
    margin: 0;
    font-size: 14px;
    color: #333;
}

/* Comitato */
.tnc-leader-comitato {
    margin-bottom: 30px;
}
.tnc-comitato-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    margin-bottom: 20px;
}
.tnc-comitato-img {
    margin-bottom: 12px;
}
.tnc-comitato-img img {
    max-width: 200px;
    max-height: 150px;
    border-radius: 10px;
    object-fit: cover;
}
.tnc-comitato-name {
    font-size: 20px;
    margin: 8px 0;
}
.tnc-comitato-meta {
    font-size: 13px;
    color: #888;
}
.tnc-comitato-edit {
    margin-top: 16px;
    text-align: left;
}
.tnc-comitato-edit summary {
    cursor: pointer;
    color: #2196F3;
    font-weight: 500;
}

/* Tabella membri */
.tnc-members-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}
.tnc-members-table th {
    background: #f5f5f5;
    padding: 10px 12px;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid #ddd;
}
.tnc-members-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}
.tnc-member-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}
.tnc-member-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}
.tnc-avatar-mini {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #2196F3;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
}
.tnc-badge-leader {
    background: #9C27B0;
    color: #fff;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
}
.tnc-badge-active {
    background: #4CAF50;
    color: #fff;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
}
.tnc-badge-pending {
    background: #FF9800;
    color: #fff;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
}

/* Sotto-comitati */
.tnc-sotto-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
    margin-top: 12px;
}
.tnc-sotto-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 16px;
    text-align: center;
}
.tnc-sotto-img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 8px;
}
.tnc-sotto-card h5 {
    margin: 4px 0;
    font-size: 15px;
}
.tnc-sotto-meta {
    font-size: 12px;
    color: #888;
}

/* Comitato di appartenenza */
.tnc-my-comitato-membership {
    margin-bottom: 24px;
}
.tnc-comitato-membership {
    border-left: 4px solid #4CAF50;
}

/* Responsive */
@media (max-width: 768px) {
    .tnc-members-table {
        font-size: 12px;
    }
    .tnc-members-table th,
    .tnc-members-table td {
        padding: 8px 6px;
    }
    .tnc-sotto-grid {
        grid-template-columns: 1fr;
    }
    .tnc-progress-labels {
        font-size: 10px;
    }
}
.tnc-no-data {
    color: #888;
    font-style: italic;
    padding: 12px 0;
}

/* ============================================================
 * ANNUNCIO SINGOLO (v2.9.2)
 * ============================================================ */
.tnc-annuncio-single {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px 0;
}
.tnc-ann-single-hero {
    margin-bottom: 20px;
}
.tnc-ann-single-title {
    font-size: 24px;
    margin: 0 0 12px 0;
    color: #222;
}
.tnc-ann-single-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
    font-size: 13px;
}
.tnc-ann-single-category {
    background: #e3f2fd;
    color: #1565c0;
    padding: 4px 12px;
    border-radius: 16px;
    font-weight: 500;
}
.tnc-ann-single-location {
    background: #f1f8e9;
    color: #33691e;
    padding: 4px 12px;
    border-radius: 16px;
}
.tnc-ann-single-date {
    color: #888;
}
.tnc-ann-single-price {
    font-size: 28px;
    font-weight: 700;
    color: #2e7d32;
    margin-bottom: 16px;
}
.tnc-ann-single-venduto-badge {
    display: inline-block;
    background: #d32f2f;
    color: #fff;
    padding: 6px 18px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 16px;
}
.tnc-ann-single-desc {
    font-size: 15px;
    line-height: 1.7;
    color: #333;
    margin-bottom: 24px;
    padding: 16px;
    background: #fafafa;
    border-radius: 10px;
    border: 1px solid #eee;
}
.tnc-ann-single-gallery {
    margin-bottom: 24px;
}
.tnc-ann-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
    margin-top: 10px;
}
.tnc-ann-single-contacts {
    margin-bottom: 24px;
    padding: 16px;
    background: #e8f5e9;
    border-radius: 10px;
}
.tnc-ann-single-contacts h3 {
    margin: 0 0 12px 0;
    font-size: 16px;
}
.tnc-ann-single-share {
    margin-bottom: 24px;
    padding: 16px;
    background: #f5f5f5;
    border-radius: 10px;
}
.tnc-ann-single-share h3 {
    margin: 0 0 12px 0;
    font-size: 16px;
}
.tnc-ann-share-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.tnc-ann-single-back {
    margin-top: 20px;
}
.tnc-btn-back-annunci {
    display: inline-block;
    padding: 10px 20px;
    background: #f5f5f5;
    border-radius: 8px;
    color: #333;
    text-decoration: none;
    font-weight: 500;
    transition: background .2s;
}
.tnc-btn-back-annunci:hover {
    background: #e0e0e0;
}
/* Link "VEDI ANNUNCIO" nella card lista */
.tnc-ann-card-view-link {
    padding: 8px 12px;
    text-align: center;
}
.tnc-btn-view-annuncio {
    display: inline-block;
    padding: 8px 18px;
    background: #1565c0;
    color: #fff;
    border-radius: 20px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: background .2s, transform .2s;
}
.tnc-btn-view-annuncio:hover {
    background: #0d47a1;
    transform: translateY(-1px);
}
@media (max-width: 768px) {
    .tnc-annuncio-single {
        padding: 12px;
    }
    .tnc-ann-single-title {
        font-size: 20px;
    }
    .tnc-ann-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* === COMMENTI BLOG === */
.tnc-blog-comments-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #e9ecef;
}
.tnc-blog-comments-title {
    font-size: 20px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 20px;
}
.tnc-blog-comments-count {
    font-weight: 400;
    color: #6c757d;
    font-size: 16px;
}
.tnc-blog-comment-form {
    margin-bottom: 30px;
}
.tnc-blog-comment-form textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    min-height: 80px;
    transition: border-color 0.3s;
}
.tnc-blog-comment-form textarea:focus {
    outline: none;
    border-color: #3498db;
}
.tnc-btn-comment-submit {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 24px;
    background: linear-gradient(135deg, #2980b9, #3498db);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}
.tnc-btn-comment-submit:hover {
    background: linear-gradient(135deg, #1a5276, #2980b9);
    transform: translateY(-1px);
}
.tnc-btn-comment-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}
.tnc-blog-comment-login-msg {
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: center;
    color: #6c757d;
    margin-bottom: 24px;
}
.tnc-blog-comment-login-msg a {
    color: #2980b9;
    font-weight: 600;
    text-decoration: none;
}
.tnc-blog-comment {
    padding: 16px 0;
    border-bottom: 1px solid #f0f0f0;
}
.tnc-blog-comment:last-child {
    border-bottom: none;
}
.tnc-blog-comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}
.tnc-blog-comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}
.tnc-blog-comment-avatar-placeholder {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}
.tnc-blog-comment-author {
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
}
.tnc-blog-comment-date {
    font-size: 12px;
    color: #999;
}
.tnc-blog-comment-text {
    font-size: 14px;
    line-height: 1.6;
    color: #444;
    padding-left: 46px;
}
.tnc-blog-no-comments {
    text-align: center;
    color: #999;
    font-style: italic;
    padding: 20px 0;
}
