/* CSS Reset */
*, *::before, *::after {
    box-sizing: border-box;
}

* {
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
}

body {
    line-height: 1.5;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    color: #333;
    background-color: #f5f7fa;

}

img, picture, video, canvas, svg {
    display: block;
    max-width: 100%;
}

input, button, textarea, select {
    font: inherit;
}

/* Utility Classes */
.container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 15px;
}

.text-left {
    text-align: left;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.d-block { 
    display: block;
}

.d-flex {
    display: flex;
}

.justify-content-between {
    justify-content: space-between;
}

.align-items-center {
    align-items: center;
}

.mb-3 {
    margin-bottom: 1rem;
}

.mt-3 {
    margin-top: 1rem;
}

.mr-2 {
    margin-right: 0.75rem;
}

.mr-3 {
    margin-right: 1rem;
}

.p-3 {
    padding: 1rem;
}

.nowrap {
    white-space: nowrap;
}

.max-h-200 {
    max-height: 200px;
}
.max-h-300 {
    max-height: 300px;
}
.max-h-400 {
    max-height: 400px;
}
.max-h-500 {
    max-height: 500px;
}
.max-h-600 {
    max-height: 600px;
}

.btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    margin: 0.25rem;
    font-size: 1rem;
    font-weight: 400;
    text-align: center;
    text-decoration: none;
    vertical-align: middle;
    cursor: pointer;
    border: 1px solid transparent;
    border-radius: 0.375rem;
    transition: all 0.15s ease-in-out;
}

.btn.disabled.disabled-appearance {
    pointer-events: all;
    background-color: #fff;
    border-color: #fff;
}

.btn-primary {
    color: #fff;
    background-color: #0e6fc6;
    border-color: #0e6fc6;
}

.btn-primary:hover {
    background-color: #006cc1;
    border-color: #004085;
}

.btn-secondary {
    color: #fff;
    background-color: #6c757d;
    border-color: #6c757d;
}

.btn-secondary:hover {
    background-color: #545b62;
    border-color: #4e555b;
}

.btn-success {
    color: #fff;
    background-color: #28a745;
    border-color: #28a745;
}

.btn-danger {
    color: #fff;
    background-color: #dc3545;
    border-color: #dc3545;
}

.alert {
    padding: 0.75rem 1.25rem;
    margin-bottom: 1rem;
    border: 1px solid transparent;
    border-radius: 0.375rem;
}

.alert-success {
    color: #155724;
    background-color: #d4edda;
    border-color: #c3e6cb;
}

.alert-danger {
    color: #721c24;
    background-color: #f8d7da;
    border-color: #f5c6cb;
}

.alert-warning {
    color: #856404;
    background-color: #fff3cd;
    border-color: #ffeaa7;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #555;
}

.form-control {
    display: block;
    width: 100%;
    /*padding: 0.5rem 0.75rem;*/
    padding: 10px;
    line-height: 1.5;
    color: #495057;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus {
    color: #495057;
    background-color: #fff;
    border-color: #80bdff;
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.table {
    width: 100%;
    margin-bottom: 1rem;
    color: #212529;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 0.75rem;
    vertical-align: top;
    border-top: 1px solid #dee2e6;
}

.table thead th {
    vertical-align: bottom;
    border-bottom: 2px solid #dee2e6;
    background-color: #f8f9fa;
    font-weight: 600;
    cursor: pointer;
}

.table thead th i { margin-right: 5px; }

.table.th-cursor-default thead th {
    cursor: default;
}

.table tbody tr:nth-child(even) {
    background-color: #f8f9fa;
}

.table tbody tr:hover {
    background-color: #e9ecef;
}

.table tbody tr.clickable:hover {
    cursor: pointer;
}

.card {
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    margin-bottom: 1.5rem;
}

.card-header {
    padding: 0.75rem 1.25rem;
    margin-bottom: 0;
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    border-radius: 0.375rem 0.375rem 0 0;
    font-weight: 600;
}

.card-body {
    padding: 1.25rem;
}

/* Layout */
.main-layout {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.header {
    background-color: #186bb5;
    border-bottom: 1px solid #dee2e6;
    padding: 10px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    color: #ffffff;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    height: 40px;
    width: auto;
}

.page-title {
    margin-left: 1rem;
    color: #ffffff;
    font-size: 18px;
    font-weight: 500;
}

.admin-as-client {
    color: #ffffff;
    margin-right: 1rem;
    font-size: 0.875rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-menu li {
    margin-left: 20px;
}

.nav-menu a {
    text-decoration: none;
    color: #ffffff;
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 4px;
    transition: all 0.15s ease-in-out;
}

.nav-menu a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.nav-menu a.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}

.main-content {
    /*flex: 1;
    padding: 2rem 0;
    */
    padding: 20px 0;
}

.footer {
    border-top: 1px solid #eee;
    padding: 20px 0;
    text-align: center;
    color: #6c757d;
    font-size: 12px;
}

/* PDF Viewer */
.pdf-viewer {
    width: 100%;
    height: 600px;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
}

/* Search and Filters */
.search-form {
    background-color: #fff;
    padding: 1.5rem;
    border-radius: 0.375rem;
    margin-bottom: 1.5rem;
    border: 1px solid #dee2e6;
}

.filters {
    display: flex;
    gap: 1rem;
    align-items: end;
    flex-wrap: wrap;
}

/* Area Amministratore */
.reserved-area .header {
    background-color: #186bb5;
    color: #ffffff;
}

.reserved-area .nav-menu a {
    color: #ffffff;
}

.reserved-area .nav-menu a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.reserved-area .nav-menu a.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}



/* Area Cliente */
.customer-area .header {
    background-color: #86bc25;
    color: #ffffff;
}

.customer-area .nav-menu a {
    color: #ffffff;
}

.customer-area .nav-menu a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.customer-area .nav-menu a.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}

/* Login Form */
.login-container {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
    margin: 100px auto;
}

.login-logo-ct {
    text-align: center;
    margin-bottom: 35px;
    background-color: #0e6fc6;
    padding-top:7px;
    padding-bottom:10px;
}
.login-logo-ct > img {
    max-width: 250px;
    max-height: 60px;
    margin: 0 auto;
}

.login-title {
    text-align: center;
    margin-bottom: 2rem;
    color: #2c3e50;
    font-size: 1.5rem;
    font-weight: 600;
}


.login-container .form-group input {
    font-family: Tahoma, Geneva, Verdana, sans-serif;
    height: 39px;
    color: #333;
}

.login-container .btn {
    width: 100%;
    font-family: Tahoma, Geneva, Verdana, sans-serif;
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
    border: none;
    margin: 0;
    line-height: 1.2;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 0;
    margin: 2rem 0;
}

.pagination li {
    margin: 0 0.25rem;
}

.pagination a,
.pagination span {
    display: block;
    padding: 0.5rem 0.75rem;
    text-decoration: none;
    color: #0e6fc6;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
}

.pagination a:hover {
    background-color: #e9ecef;
}

.pagination .active span {
    background-color: #0e6fc6;
    color: #fff;
    border-color: #0e6fc6;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav-menu li {
        margin: 0.25rem;
    }
    
    .filters {
        flex-direction: column;
    }
    
    .table-responsive {
        overflow-x: auto;
    }
    
    .login-card {
        margin: 1rem;
        padding: 1.5rem;
    }
}

@media (max-width: 576px) {
    .pdf-viewer {
        height: 400px;
    }
    
    .btn {
        width: 100%;
        margin: 0.25rem 0;
    }
    
    /* Layout select e bottone in colonna */
    .d-flex.gap-2.mb-3.align-items-start {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .period-select-compact {
        max-width: none;
        width: 100%;
    }
    
    .btn-add-period {
        width: 100%;
        justify-content: center;
    }
    
    .selected-period-item {
        flex-direction: row;
        justify-content: space-between;
        width: 100%;
        max-width: none;
    }
    
    .selected-period-item .period-label {
        white-space: normal;
        overflow: visible;
        text-overflow: unset;
        flex: 1;
        margin-right: 0.5rem;
    }
    
    /* Bottoni X mantengono dimensioni costanti */
    .selected-period-item .remove-period-btn {
        min-width: 20px;
        width: 20px;
        height: 20px;
        flex-shrink: 0;
        padding: 0;
    }
}

/* Dashboard specifici */
.dashboard .table th {
    background-color: #f8f9fa;
    font-weight: 600;
    border-bottom: 2px solid #dee2e6;
}

.dashboard .badge {
    font-size: 0.875rem;
    padding: 0.375rem 0.75rem;
    border-radius: 0.375rem;
}

.dashboard .badge.bg-primary {
    background-color: #0e6fc6 !important;
    color: #fff;
}

.dashboard .table-responsive {
    border-radius: 0.375rem;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.dashboard .fw-medium {
    font-weight: 500;
}

.dashboard .alert-info {
    background-color: #d1ecf1;
    border-color: #bee5eb;
    color: #0c5460;
}

.dashboard .btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    border-radius: 0.25rem;
}

.dashboard .py-5 {
    padding-top: 3rem;
    padding-bottom: 3rem;
}

.dashboard .mt-2 {
    margin-top: 0.5rem;
}

/* ========================================
   GENERATIONS STYLES
======================================== */

/* Generazioni - Status badges */
.status-badge {
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    white-space: nowrap;
}

.status-nuovo {
    background-color: #e3f2fd;
    color: #1976d2;
}

.status-ripristinato {
    background-color: #c3d2dd;
    color: #3996f2;
}

.status-import {
    background-color: #f5f8fa;
    color: #2986e2;
}

.status-elaborazione {
    background-color: #fff3e0;
    color: #f57c00;
}

.status-completato {
    background-color: #e8f5e8;
    color: #2e7d32;
}

.status-interrotto {
    background-color: #fce4ec;
    color: #c2185b;
}

.status-errore {
    background-color: #ffebee;
    color: #d32f2f;
}

.status-no_dati {
    background-color: #e0e0e0;
    color: #d32f2f;
}

.table tr.invalid-row > *,
.table.table-striped > tbody > tr.invalid-row > * {
    background-color: #f9dde0;
}
.table.table-striped > tbody > tr.invalid-row:nth-of-type(2n+1) > * {
    background-color: #f8d7da;
}

/* Log Container - Stile macchina da scrivere */
.log-container-wrapper {
    position: relative;
}

.log-container {
    background-color: #0c0c0c;
    border: 2px solid #333;
    border-radius: 0.5rem;
    padding: 1rem;
    font-family: 'Courier New', Consolas, Monaco, monospace;
    min-height: 250px;
    max-height: 400px;
    overflow-y: auto;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Loading spinner per log */
.log-loading-spinner {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: rgba(0, 0, 0, 0.8);
    color: #00ff00;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    z-index: 10;
    border: 1px solid #333;
}

.log-loading-spinner i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Timestamp ultimo aggiornamento */
.log-last-update {
    text-align: right;
    margin-top: 0.5rem;
    font-size: 0.75rem;
}

.log-content {
    color: #00ff00;
    line-height: 1.4;
    font-size: 0.875rem;
}

.log-entry {
    margin-bottom: 0.25rem;
    display: flex;
    align-items: flex-start;
    word-wrap: break-word;
}

.log-timestamp {
    color: #00ccff;
    font-weight: bold;
    white-space: nowrap;
    margin-right: 0.5rem;
    min-width: 150px;
}

.log-separator {
    color: #666;
    margin-right: 0.5rem;
}
.log-entry[data-type="error"] .log-separator {
    color: #ff0000;
}

.log-message {
    color: #00ff00;
    flex: 1;
    word-wrap: break-word;
}

.log-entry[data-type="error"][data-style="highlight"] .log-message {
    color: #ff0000;
    background-color: #fff;
}


/* Nuovi log - animazione */
.log-entry.new-log {
    animation: newLogGlow 2s ease-in-out;
}

@keyframes newLogGlow {
    0% {
        background-color: rgba(0, 255, 0, 0.2);
        box-shadow: 0 0 10px rgba(0, 255, 0, 0.3);
    }
    50% {
        background-color: rgba(0, 255, 0, 0.1);
        box-shadow: 0 0 5px rgba(0, 255, 0, 0.2);
    }
    100% {
        background-color: transparent;
        box-shadow: none;
    }
}

/* Generation summary */
.generation-summary p {
    margin-bottom: 0.5rem;
}

.generation-status {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    padding: 1rem;
}



/* Stop generation progress spinner */
.stop-progress-spinner {
    font-size: 2.5rem;
    color: #0e6fc6;
    display: inline-block;
}

.stop-progress-spinner .stop-spinner-icon,
.stop-progress-spinner i {
    animation: spin 1s linear infinite;
    display: inline-block;
    transform-origin: center;
}

/* Manual sending progress spinner */
.manual-sending-progress-spinner {
    font-size: 2.5rem;
    color: #0e6fc6;
    display: inline-block;
}

.manual-sending-progress-spinner .manual-sending-spinner-icon {
    animation: spin 1s linear infinite;
    display: inline-block;
    transform-origin: center;
}

/* Modal backdrop per progress modal non dismissibile */
.modal[data-bs-backdrop="static"] .modal-backdrop {
    background-color: rgba(0, 0, 0, 0.6);
}

/* Tab content spacing */
.tab-content .tab-pane {
    padding-top: 1rem;
}

/* Bootstrap Nav Tabs Customization */
.nav-tabs {
    border-bottom: 1px solid #dee2e6;
}

.nav-tabs .nav-item {
    margin-bottom: -1px;
}

.nav-tabs .nav-link {
    border: 1px solid transparent;
    border-top-left-radius: 0.375rem;
    border-top-right-radius: 0.375rem;
    background: none;
    color: #495057;
    text-decoration: none;
    padding: 0.5rem 1rem;
}

.nav-tabs .nav-link.btn,
.nav-tabs button.nav-link {
    border: 1px solid transparent;
    border-top-left-radius: 0.375rem;
    border-top-right-radius: 0.375rem;
    background: none;
    color: #495057;
    text-decoration: none;
    padding: 0.5rem 1rem;
    margin: 0;
}

.nav-tabs .nav-link:hover {
    border-color: #e9ecef #e9ecef #dee2e6;
    isolation: isolate;
    color: #0e6fc6;
}

.nav-tabs .nav-link.active {
    color: #495057;
    background-color: #fff;
    border-color: #dee2e6 #dee2e6 #fff;
}

/* Bootstrap Modal Customization */
.modal-backdrop {
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    border: none;
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.modal-header {
    border-bottom: 1px solid #dee2e6;
    padding: 1rem 1.5rem;
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    border-top: 1px solid #dee2e6;
    padding: 1rem 1.5rem;
}
@media (min-width: 992px) and (max-width: 1600px) {
    .modal-xl {
        --bs-modal-width: 90%;
        max-width: 90%;
    }
}
@media (min-width: 1600px) {
    .modal-xl {
        --bs-modal-width: 1500px;
        max-width: 1500px;
    }
}

/* Dropdown menu customization */
.dropdown-menu {
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 0.375rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

.dropdown-item {
    padding: 0.375rem 1rem;
    color: #212529;
    text-decoration: none;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
    color: #16181b;
}

.dropdown-item:focus {
    background-color: #e9ecef;
    color: #16181b;
}

/* Bootstrap Grid and Utilities Override */
.row {
    margin-left: 0;
    margin-right: 0;
}

.col,
.col-1, .col-2, .col-3, .col-4, .col-5, .col-6,
.col-7, .col-8, .col-9, .col-10, .col-11, .col-12,
.col-md, .col-md-1, .col-md-2, .col-md-3, .col-md-4,
.col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9,
.col-md-10, .col-md-11, .col-md-12 {
    padding-left: 15px;
    padding-right: 15px;
}

/* Fix for Bootstrap + custom CSS conflicts */
.btn:not(.btn-close) {
    display: inline-block;
    padding: 0.375rem 0.75rem;
    margin: 0.25rem;
    font-size: 1rem;
    font-weight: 400;
    text-align: center;
    text-decoration: none;
    vertical-align: middle;
    cursor: pointer;
    border: 1px solid transparent;
    border-radius: 0.375rem;
    transition: all 0.15s ease-in-out;
}

/* Responsive per log container */
@media (max-width: 768px) {
    .log-container {
        min-height: 200px;
        max-height: 300px;
    }
    
    .log-entry {
        flex-direction: column;
    }
    
    .log-timestamp {
        min-width: auto;
        margin-right: 0;
        margin-bottom: 0.25rem;
    }
    
    .log-separator {
        display: none;
    }
    
    .log-message {
        padding-left: 0;
    }
    
    /* Loading spinner responsive */
    .log-loading-spinner {
        width: 25px;
        height: 25px;
        font-size: 12px;
        top: 8px;
        right: 8px;
    }
    
    /* Timestamp responsive */
    .log-last-update {
        text-align: center;
        font-size: 0.7rem;
    }
}

/* ========================================
   NEW GENERATION STYLES
======================================== */

/* Form nuova generazione */
.new-generation-form {
    background-color: #fff;
    /*padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    */
}

/* Select multipla periodi */
#periods {
    min-height: 100px;
    background-color: #fff;
}

#periods option {
    padding: 0.5rem;
    border-bottom: 1px solid #f0f0f0;
}

#periods option:hover {
    background-color: #f8f9fa;
}

#periods option:checked {
    background-color: #0e6fc6;
    color: white;
}

/* Area drag & drop per file */
.file-drop-area {
    border: 2px dashed #dee2e6;
    border-radius: 0.5rem;
    padding: 2rem;
    text-align: center;
    background-color: #f8f9fa;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    min-height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.file-drop-area:hover {
    border-color: #0e6fc6;
    background-color: #f0f8ff;
}

.file-drop-area.file-drop-hover {
    border-color: #0e6fc6;
    background-color: #e3f2fd;
    transform: scale(1.02);
}

.file-drop-area.file-selected {
    border-color: #28a745;
    background-color: #f0fff4;
}

.file-drop-content {
    width: 100%;
}

.file-drop-icon {
    font-size: 3rem;
    color: #6c757d;
    margin-bottom: 1rem;
    display: block;
}

.file-drop-area:hover .file-drop-icon,
.file-drop-area.file-drop-hover .file-drop-icon {
    color: #0e6fc6;
}

.file-drop-text {
    font-size: 1.1rem;
    color: #6c757d;
    margin: 0;
}

.file-drop-area:hover .file-drop-text,
.file-drop-area.file-drop-hover .file-drop-text {
    color: #0e6fc6;
}

.file-input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    top: 0;
    left: 0;
}

/* File selezionato */
.file-drop-selected {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.file-selected-icon {
    font-size: 3rem;
    color: #28a745;
}

.file-selected-text {
    font-size: 1.1rem;
    color: #28a745;
    margin: 0;
    font-weight: 500;
}

#file-remove-btn {
    margin-top: 0.5rem;
}

/* File loading */
.file-drop-loading {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    min-height: 180px;
}

.file-loading-icon {
    font-size: 3rem;
    color: #0e6fc6;
    animation: spin 1s linear infinite;
}

.file-loading-text {
    font-size: 1.1rem;
    color: #0e6fc6;
    margin: 0;
    font-weight: 500;
    text-align: center;
}

.file-drop-area.file-loading {
    border-color: #0e6fc6;
    background-color: #f0f8ff;
    pointer-events: none;
}

/* Feedback visivo per validazione */
.form-select.is-valid {
    border-color: #28a745;
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25);
}

.form-select.is-invalid {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

/* Bottoni della form */
.new-generation-form .btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.1rem;
}

/* Responsive per nuova generazione */
@media (max-width: 768px) {
    .new-generation-form {
        padding: 1.5rem;
    }
    
    .file-drop-area {
        padding: 1.5rem;
        min-height: 120px;
    }
    
    .file-drop-icon {
        font-size: 2.5rem;
    }
    
    .file-drop-text {
        font-size: 1rem;
    }
    
    #periods {
        min-height: 120px;
    }
    
    .new-generation-form .btn-lg {
        width: 100%;
        margin-bottom: 0.5rem;
    }
}

/* ========================================
   SISTEMA SELEZIONE PERIODI
======================================== */

/* Select compatta */
.period-select-compact {
    max-width: 300px;
    height: 38px;
    padding: 0.375rem 0.75rem;
}

/* Bottone aggiungi compatto */
.btn-add-period {
    padding: 0.375rem 0.75rem;
    height: 38px;
    min-width: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
}

.btn-add-period:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Container dei periodi selezionati */
.selected-periods-container {
    margin-top: 0.75rem;
}

.selected-periods-list {
    min-height: 50px;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #f8f9fa;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: flex-start;
}

/* Messaggio lista vuota */
#empty-periods-message {
    font-style: italic;
    text-align: center;
    padding: 0.75rem;
    color: #6c757d;
    width: 100%;
    margin: 0;
}

/* Elementi singoli della lista */
.selected-period-item {
    background-color: #fff;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 0.5rem 0.75rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    max-width: 200px;
    flex-shrink: 0;
}

.selected-period-item .period-label {
    font-weight: 500;
    color: #495057;
    font-size: 0.875rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.selected-period-item .remove-period-btn {
    padding: 0.125rem 0.25rem;
    margin: 0;
    line-height: 1;
    border-radius: 3px;
    font-size: 0.75rem;
    min-width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.15s ease;
}

.selected-period-item .remove-period-btn:hover {
    background-color: #dc3545;
    border-color: #dc3545;
    color: #fff;
    transform: scale(1.1);
}

/* Responsive per sistema selezione periodi */
@media (max-width: 768px) {
    .period-select-compact {
        max-width: none;
        flex: 1;
    }
    
    .selected-period-item {
        max-width: none;
        width: 100%;
    }
    
    .selected-periods-list {
        flex-direction: column;
        gap: 0.375rem;
    }
}

@media (max-width: 576px) {
    .selected-period-item {
        flex-direction: row;
        justify-content: space-between;
    }
    
    .selected-period-item .period-label {
        white-space: normal;
        overflow: visible;
        text-overflow: unset;
    }
}

/* ========================================
   PAGE MENU COMPONENT
======================================== */

/* Menu interno alla pagina */
.page-menu {
    margin-bottom: 0;
}

.page-menu-container {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    align-items: center;
}

.page-menu-item {
    padding: 0.25rem 0;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.15s ease-in-out;
    border: none;
    background: none;
    margin: 0;
    position: relative;
}
.page-menu-item.btn { background-color: transparent !important; border: none !important; outline: none !important; }
.page-menu-item.btn-primary {
    color: #0e6fc6;
    font-weight: 600;
}

.page-menu-item.btn-primary::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background-color: #0e6fc6;
    border-radius: 1px;
}

.page-menu-item.btn-outline-primary {
    color: #6c757d;
    background-color: transparent;
}

.page-menu-item.btn-outline-primary:hover:not(.disabled) {
    color: #0e6fc6;
}

.page-menu-item.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    color: #adb5bd;
}

.page-menu-item.disabled[data-bs-toggle="tooltip"] {
    pointer-events: auto;
}

/* Responsive per page menu */
@media (max-width: 768px) {
    .d-flex.justify-content-between.align-items-center {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .page-menu-container {
        gap: 1rem;
    }
    
    .page-menu-item {
        font-size: 0.9rem;
    }
}

/* ========================================
   SENDING SYSTEM STYLES
======================================== */
/* Righe cliccabili nella tabella clienti */
.clickable {
    cursor: pointer;
}

.clickable:hover {
    background-color: rgba(13, 110, 253, 0.1);
}

/* Colonne tabella clienti - larghezze specifiche */
.sending-col-checkbox {
    width: 50px;
}

.sending-col-id {
    width: 50px;
}
/*
.sending-col-vat {
    width: 150px;
}

.sending-col-email {
    width: 200px;
}

.sending-col-last-sending {
    width: 150px;
}

.sending-col-already-programmed {
    width: 200px;
}
*/

.sending-col-customer-name {
    /*white-space: nowrap;*/
}

.sending-col-comment-pod,
.sending-col-comment-pdr,
.sending-col-comment-pe,
.sending-col-comment {
    min-width: 90px;
    text-align: center;
}

#search-input {
    height: 38px;
}

/* ========================================
   CLIENTS LOADING SYSTEM - ABSOLUTE POSITIONING
======================================== */

/* Contenitore principale per l'area clienti */
.clients-area-wrapper {
    position: relative;
    min-height: 300px; /* Altezza minima per evitare saltellamenti */
    margin-bottom: 1rem;
}

/* Loading overlay con posizionamento assoluto */
.clients-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(2px);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-in-out;
    border-radius: 0.375rem;
}

/* Stato loading visibile */
.clients-loading-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* Contenuto del loading centrato */
.clients-loading-content {
    text-align: center;
    padding: 2rem;
    color: #495057;
}

.clients-loading-content .spinner-border {
    width: 2rem;
    height: 2rem;
    margin-bottom: 1rem;
}

.clients-loading-content p {
    margin: 0;
    font-weight: 500;
}

/* Aree di contenuto con transizioni */
.clients-content-area {
    opacity: 1;
    visibility: visible;
    transition: all 0.3s ease-in-out;
    position: relative;
    z-index: 1;
}

/* Stato iniziale nascosto per le aree di contenuto - gestito via JavaScript */
.clients-content-area.hide {
    opacity: 0 !important;
    visibility: hidden !important;
    display: none !important;
}

/* Stato nascosto per le aree di contenuto */
.clients-content-area.hide {
    opacity: 0;
    visibility: hidden;
}

/* Quando il loading è attivo, oscura leggermente il contenuto */
.clients-area-wrapper.loading .clients-content-area {
    opacity: 0.3;
    pointer-events: none;
}

/* Responsive per il sistema di loading */
@media (max-width: 768px) {
    .clients-area-wrapper {
        min-height: 300px;
    }
    
    .clients-loading-content {
        padding: 1.5rem;
    }
    
    .clients-loading-content .spinner-border {
        width: 2.5rem;
        height: 2.5rem;
    }
    
    .clients-loading-content p {
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .clients-area-wrapper {
        min-height: 250px;
    }
    
    .clients-loading-content {
        padding: 1rem;
    }
    
    .clients-loading-content .spinner-border {
        width: 2rem;
        height: 2rem;
    }
    
    .clients-loading-content p {
        font-size: 0.9rem;
    }
}

/* ========================================
   COMMENT STYLES FOR NEW SENDING
======================================== */

/* Colonna commento nella tabella */
.sending-col-comment {
/*
    width: 220px;
    min-width: 200px;
    max-width: 250px;
*/
    width: 122px;
    min-width: 122px;
}

/* Celle commento */
.comment-cell,
.comment-cell-pod,
.comment-cell-pdr,
.comment-cell-pe {
    padding-bottom: 0.25rem !important;
    vertical-align: top;
}

/* Contenitore badge: altezza fissa per garantire allineamento tra colonne */
.comment-badge-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 22px;
    margin-bottom: 0.25rem;
}

.comment-badge-wrapper .badge.bg-light {
    color: #333;
}

/* Azioni sui commenti */
.comment-actions {
    display: flex;
    gap: 0.25rem;
    justify-content: center;
    align-items: center;
}

/* Azioni nascoste (riga non selezionata) */
.comment-actions-wrapper.comment-hidden .btn {
    opacity: 0.3;
    color: #6c757d !important;
}

.comment-actions-wrapper.comment-hidden .comment-actions {
    justify-content: flex-start;
}

.comment-actions .btn {
    padding: 3px 0.4rem;
    font-size: 0.75rem;
    line-height: 1;
    margin: 0;
    min-width: auto;
    border-width: 1px;
}

/* Stili specifici per i bottoni icona */
.comment-actions .btn i {
    font-size: 0.75rem;
}

.comment-modified.comment-actions .btn.add-comment-btn i,
.comment-modified.comment-actions .btn.edit-comment-btn i,
.comment-modified.comment-actions .btn.view-comment-static-btn i {
    color: rgb(var(--bs-danger-rgb));
}
.comment-modified.comment-actions .btn.add-comment-btn i::before,
.comment-modified.comment-actions .btn.edit-comment-btn i::before {
    content: "\f4c9" !important;
}


/* Indicatore commento (non cliccabile) */
.view-comment-indicator {
    cursor: default !important;
    border-color: transparent !important;
}

.view-comment-indicator:hover {
    background-color: inherit !important;
    /*border-color: inherit !important;*/
    color: inherit !important;
}

/* Modal commento */
#commentModal .modal-dialog {
    max-width: 600px;
}

#commentModal .form-control {
    resize: vertical;
    min-height: 100px;
}
.modal { transition: background-color 0.3s linear; }
.modal.modal-dbl { background-color: rgba(0, 0, 0, 0.3); }

.modal-2nd-level .modal-content { box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.5); }

/* Responsive per commenti */
@media (max-width: 768px) {
    
    .comment-actions .btn {
        padding: 0.2rem 0.35rem;
        font-size: 0.75rem;
    }
    
    .comment-actions .btn i {
        font-size: 0.7rem;
    }
}

@media (max-width: 576px) {
    
    .comment-actions {
        gap: 0.15rem;
    }
    
    .comment-actions .btn {
        padding: 0.15rem 0.3rem;
        font-size: 0.7rem;
    }
    
    .comment-actions .btn i {
        font-size: 0.65rem;
    }
    
    #commentModal .modal-dialog {
        margin: 0.5rem;
        max-width: none;
    }
}

/* ========================================
   HISTORIC PAGE STYLES
======================================== */

/* PDF Viewer Container */
.pdf-viewer-container {
    position: relative;
    min-height: 600px;
    background-color: #f8f9fa;
    border-radius: 0.375rem;
    overflow: hidden;
}

/* PDF Loading State */
.pdf-loading {
    padding: 3rem 1rem;
    min-height: 600px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.pdf-loading .spinner-border {
    width: 3rem;
    height: 3rem;
    margin-bottom: 1rem;
}

/* PDF Iframe */
#pdf-viewer,
.historic-pdf-viewer {
    width: 100%;
    min-height: 600px;
    height: 70vh;
    border: 1px solid #ddd;
    border-radius: 0.375rem;
    background-color: #fff;
    display: none;
}

/* No PDF Selected State */
.no-pdf-selected {
    padding: 3rem 1rem;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.no-pdf-selected .py-5 {
    text-align: center;
    max-width: 400px;
}

.no-pdf-selected i.display-1 {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}

/* PDF Error State */
.pdf-error {
    padding: 3rem 1rem;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdf-error .py-5 {
    text-align: center;
    max-width: 400px;
}

.pdf-error i.display-1 {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}



/* Client Select Filtering */
#client-select option[style*="display: none"] {
    display: none !important;
}

/* Responsive adjustments for Historic page */
@media (max-width: 768px) {
    .pdf-viewer-container {
        min-height: 500px;
    }
    
    #pdf-viewer {
        min-height: 500px;
        height: 60vh;
    }
    
    .pdf-loading,
    .no-pdf-selected,
    .pdf-error {
        min-height: 500px;
        padding: 2rem 1rem;
    }
    
    .no-pdf-selected i.display-1,
    .pdf-error i.display-1 {
        font-size: 3rem;
        margin-bottom: 1rem;
    }
    

}

@media (max-width: 576px) {
    .pdf-viewer-container {
        min-height: 400px;
    }
    
    #pdf-viewer {
        min-height: 400px;
        height: 50vh;
    }
    
    .pdf-loading,
    .no-pdf-selected,
    .pdf-error {
        min-height: 400px;
        padding: 1.5rem 1rem;
    }
    

}

/* ========================================
   ANAGRAFICA PAGE STYLES
======================================== */

/* Tabella clienti - righe cliccabili */
.anagrafica .table tbody tr {
    cursor: pointer;
    transition: background-color 0.15s ease-in-out;
}

.anagrafica .table tbody tr:hover {
    background-color: #e9ecef;
}

/* Form control plaintext per campi readonly */

.anagrafica .form-control-plaintext {
    /*padding-top: calc(0.375rem + 1px);*/
    padding-top: 0;
    padding-bottom: calc(0.375rem + 1px);
    margin-bottom: 0;
    /*font-size: inherit;*/
    font-size: 1rem;
    line-height: 1.1;
    color: #212529;
    background-color: transparent;
    border: solid transparent;
    border-width: 1px 0;
    word-wrap: break-word;
}

/* Immagini logo cliente */
.anagrafica .img-thumbnail {
    max-width: 100px;
    height: auto;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    padding: 0.25rem;
    background-color: #fff;
}

/* Button group azioni dettaglio */
.anagrafica .btn-group-vertical .btn {
    margin-bottom: 0.5rem;
}

.anagrafica .btn-group-vertical .btn:last-child {
    margin-bottom: 0;
}

/* Feedback copia link */
.anagrafica .copy-success {
    color: #28a745 !important;
}

/* Responsive per anagrafica */
@media (max-width: 768px) {
    .anagrafica .table-responsive {
        border: none;
    }
    
    .anagrafica .btn-group-vertical {
        width: 100%;
    }
    
    .anagrafica .btn-group-vertical .btn {
        width: 100%;
        text-align: left;
    }
    
    .anagrafica .img-thumbnail {
        max-width: 80px;
    }
}

.mailto-link { text-decoration: none; color: inherit; }
.mailto-link:hover { text-decoration: underline; color: inherit; }

/* === STILI AGGIUNTIVI AREA CLIENTE === */

/* Container principale area cliente report */
.customer-area .customer-report-container {
    /*max-width: 1200px;*/
    margin: 0 auto;
    padding: 0 20px;
}

.customer-area .report-filters {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 20px;
    padding: 0;
    background: transparent;
}

.customer-area .filter-group {
    flex: 1;
    margin-right: 30px;
    min-width: 0; /* Per permettere al flex item di restringersi */
}

.customer-area .filter-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2d3748;
    font-size: 15px;
}

.customer-area .filter-group select {
    width: 100%;
    max-width: 50%;
    padding: 10px 40px 10px 15px;
    border: 2px solid #ced4da;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.5;
    height: 46px; /* Altezza fissa uguale al bottone */
    background-color: white;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 12px center;
    background-repeat: no-repeat;
    background-size: 16px;
    color: #495057;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    box-sizing: border-box;
}

.customer-area .filter-group select:hover {
    border-color: #86bc25;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%2386bc25' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
}

.customer-area .filter-group select:focus {
    outline: none;
    border-color: #86bc25;
    box-shadow: 0 0 0 0.2rem rgba(134,188,37,.25);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%2386bc25' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
}

.customer-area .filter-group select:disabled {
    background-color: #f8f9fa;
    border-color: #e9ecef;
    color: #6c757d;
    cursor: not-allowed;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236c757d' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
}

.customer-area .download-section {
    position: relative;
}

.customer-area .download-section .btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 46px; /* Altezza fissa uguale alla select */
    line-height: 1.5;
    box-sizing: border-box;
}

.customer-area .download-section .btn-primary {
    background-color: #86bc25;
    color: white;
    margin: 0;
}

.customer-area .download-section .btn-primary:hover:not(:disabled) {
    background-color: #6fa01c;
    box-shadow: 0 2px 4px rgba(134,188,37,0.3);
}

.customer-area .download-section .btn:disabled {
    background-color: #6c757d;
    cursor: not-allowed;
    opacity: 0.6;
}

.customer-area .download-progress {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 10px;
    padding: 10px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 6px;
    z-index: 10;
}

.customer-area .progress-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #155724;
}

.customer-area .progress-indicator i {
    animation: customer-spin 1s linear infinite;
}

/* Animazione per Bootstrap Icons */
.bi-spin {
    animation: customer-spin 1s linear infinite !important;
}

@keyframes customer-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* PDF Viewer Customer */
.customer-area .pdf-viewer-container {
    position: relative;
    height: 77vh;
    min-height: 600px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
}

.customer-area .pdf-viewer {
    width: 100%;
    height: 100% !important;
    border: none !important;
    border-radius: 8px;
}

.customer-area .pdf-placeholder,
.customer-area .pdf-loading,
.customer-area .pdf-error {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
}

.customer-area .placeholder-content,
.customer-area .loading-content,
.customer-area .error-content {
    text-align: center;
    color: #6c757d;
}

.customer-area .placeholder-content i,
.customer-area .loading-content i,
.customer-area .error-content i {
    font-size: 48px;
    margin-bottom: 15px;
    display: block;
}

.customer-area .placeholder-content i {
    color: #dee2e6;
}

.customer-area .loading-content i {
    color: #86bc25;
    animation: customer-spin 1s linear infinite;
}

.customer-area .error-content i {
    color: #dc3545;
}

.customer-area .placeholder-content p,
.customer-area .loading-content p,
.customer-area .error-content p {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
}

#download-frame { display: none; visibility:hidden; }

@media (max-width: 992px) {
    .admin-as-client {
        max-width: 60%;
        margin: 0 auto;
    }
    .customer-area .header .header-content .header-content-right {
        justify-content: space-between;
    }
}
@media (max-width: 830px) {
    .admin-as-client {
        max-width: 45%;
    }
}

/* Responsive Customer */
@media (max-width: 768px) {

    .customer-area .header .header-content .header-content-right {
        flex-direction: column;
    }
    .admin-as-client {
        margin-bottom: 1rem;
    }

    .customer-area .customer-report-container {
        padding: 10px;
    }
    
    .customer-area .report-filters {
        flex-direction: column;
        gap: 20px;
        padding: 15px;
        background: white;
        border-radius: 8px;
        box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    }
    
    .customer-area .filter-group {
        margin-right: 0;
        width: 100%;
    }
    
    .customer-area .filter-group select {
        max-width: 100%;
        padding: 14px 40px 14px 15px;
        font-size: 16px; /* Per evitare zoom su iOS */
        height: 54px; /* Altezza maggiore per touch */
    }
    
    .customer-area .filter-group label {
        font-size: 16px;
        margin-bottom: 10px;
    }
    
    .customer-area .pdf-viewer-container {
        height: 64vh;
        min-height: 400px;
    }
    
    .customer-area .download-section {
        width: 100%;
    }
    
    .customer-area .download-section .btn {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
        font-size: 16px;
        height: 54px; /* Altezza uguale alla select */
    }
}

/* Responsive Customer - Schermi molto piccoli */
@media (max-width: 576px) {
    .customer-area .customer-report-container {
        padding: 5px;
    }
    
    .customer-area .report-filters {
        margin-bottom: 15px;
        padding: 12px;
    }
    
    .customer-area .filter-group label {
        font-size: 15px;
        margin-bottom: 8px;
    }
    
    .customer-area .filter-group select {
        padding: 12px 35px 12px 12px;
        font-size: 15px;
        background-size: 14px;
        background-position: right 10px center;
        height: 48px; /* Altezza per schermi piccoli */
    }
    
    .customer-area .download-section .btn {
        padding: 12px 16px;
        font-size: 15px;
        height: 48px; /* Altezza uguale alla select */
    }
}

/* === STILI PAGINA RESEND AREA CLIENTE === */

.customer-area .customer-resend-container {
    /*max-width: 700px;*/
    margin: 0 auto;
    padding: 0px 20px 20px 20px;
}

.customer-area .resend-request-section,
.customer-area .resend-success-section {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.customer-area .resend-request-section a,
.customer-area .resend-success-section a { 
    color: inherit;
    text-decoration: underline;
    transition: all 0.3s ease-in-out;
 }
.customer-area .resend-request-section a:hover,
.customer-area .resend-success-section a:hover { 
    color: inherit;
    text-decoration: none;
 }

.customer-area .resend-subtitle {
    color: #2d3748;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 20px;
}

.customer-area .resend-description {
    color: #4a5568;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 30px;
    margin-left: auto;
    margin-right: auto;
}

.customer-area .resend-action {
    margin-bottom: 30px;
}

.customer-area .resend-action .btn {
    padding: 14px 30px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    min-width: 250px;
    justify-content: center;
}

.customer-area .resend-action .btn-primary {
    background-color: #86bc25;
    color: white;
}

.customer-area .resend-action .btn-primary:hover:not(:disabled) {
    background-color: #6fa01c;
    box-shadow: 0 4px 12px rgba(134,188,37,0.3);
}

.customer-area .resend-action .btn:disabled {
    background-color: #a0aec0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}



.customer-area .resend-help-title {
    color: #2d3748;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
}

.customer-area .resend-help-text {
    color: #718096;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 0;
}

.customer-area .resend-success-help {
    margin-bottom: 30px;
}

.customer-area .resend-visit-site .btn {
    padding: 12px 25px;
    font-size: 15px;
    font-weight: 500;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.customer-area .resend-visit-site .btn-outline-primary {
    color: #86bc25;
    border: 2px solid #86bc25;
    background: transparent;
}

.customer-area .resend-visit-site .btn-outline-primary:hover {
    background-color: #86bc25;
    color: white;
    box-shadow: 0 4px 12px rgba(134,188,37,0.3);
}

/* Responsive Resend */
@media (max-width: 768px) {
    .customer-area .customer-resend-container {
        padding: 20px 15px;
    }
    
    .customer-area .resend-request-section,
    .customer-area .resend-success-section {
        padding: 30px 20px;
    }
    
    .customer-area .resend-subtitle {
        font-size: 20px;
        margin-bottom: 15px;
    }
    
    .customer-area .resend-description {
        font-size: 15px;
        margin-bottom: 25px;
    }
    
    .customer-area .resend-action .btn {
        padding: 16px 20px;
        font-size: 15px;
        min-width: 200px;
    }
    
    .customer-area .resend-help-title {
        font-size: 16px;
    }
}

@media (max-width: 576px) {
    .customer-area .customer-resend-container {
        padding: 15px 10px;
    }
    
    .customer-area .resend-request-section,
    .customer-area .resend-success-section {
        padding: 25px 15px;
    }
    
    .customer-area .resend-action .btn {
        width: 100%;
        min-width: auto;
    }
    
    .customer-area .resend-visit-site .btn {
        width: 100%;
        justify-content: center;
    }
}