/* Fatturazione Elettronica Styles - Premium Dark Mode */

.amm-container {
    padding: 20px;
    height: calc(100vh - var(--header-h));
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.amm-content-scroll {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.amm-table-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #161616;
    padding: 15px 20px;
    border-radius: 8px 8px 0 0;
    border: 1px solid #333;
    border-bottom: none;
    gap: 20px;
}

.amm-filter-group {
    display: flex;
    gap: 8px;
    align-items: center;
}

.mu-btn-toggle {
    background: #2a2a2a;
    border: 1px solid #444;
    color: #eee;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 800;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s ease;
}

.mu-btn-toggle:hover {
    background: #3a3a3a;
    border-color: #555;
}

.mu-btn-toggle.active {
    background: #000;
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 10px rgba(255, 204, 0, 0.2);
}

.centered-search-box {
    flex: 1;
    max-width: 600px;
    position: relative;
    display: flex;
    align-items: center;
}

.centered-search-box i {
    position: absolute;
    left: 15px;
    color: #666;
    font-size: 1rem;
    pointer-events: none;
}

.centered-search-box input {
    width: 100%;
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 20px;
    padding: 10px 15px 10px 45px;
    color: #fff;
    font-size: 0.9rem;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: all 0.3s ease;
}

.centered-search-box input:focus {
    border-color: var(--primary);
    background: #333;
    box-shadow: 0 0 10px rgba(255, 204, 0, 0.15);
}

.amm-stats-box {
    text-align: right;
    font-size: 11px;
    font-weight: 800;
    color: #888;
    letter-spacing: 0.5px;
}

.amm-stats-box .highlight {
    color: var(--primary);
    font-size: 1.25rem;
    font-weight: 900;
    margin-left: 5px;
}

/* Status Badges */
.status-badge {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.5px;
    display: inline-block;
    text-transform: uppercase;
}

.status-badge.ricevute {
    background: rgba(255, 77, 0, 0.1);
    color: #ff4d00;
    border: 1px solid rgba(255, 77, 0, 0.2);
}

.status-badge.inviate {
    background: rgba(0, 255, 136, 0.1);
    color: #00ff88;
    border: 1px solid rgba(0, 255, 136, 0.2);
}

/* Amministrazione Modal */
.amm-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    animation: ammFadeIn 0.3s ease;
}

.amm-modal-content {
    width: 90%;
    max-width: 900px;
    background: #161616;
    border: 1px solid #333;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    max-height: 85vh;
}

.amm-modal-header {
    padding: 20px 25px;
    background: #1c1c1c;
    border-bottom: 1px solid #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.amm-modal-header h2 {
    margin: 0;
    color: var(--primary);
    font-size: 1.25rem;
    font-weight: 900;
    letter-spacing: 1px;
}

.amm-modal-close {
    color: #ef4444;
    cursor: pointer;
    font-size: 2rem;
    font-weight: bold;
    line-height: 0.8;
    transition: color 0.2s;
}

.amm-modal-close:hover {
    color: #f87171;
}

.amm-modal-body {
    padding: 25px;
    overflow-y: auto;
    flex: 1;
    color: #eee;
    background: #0f0f0f;
}

/* Details Layout inside Modal */
.det-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

.det-box {
    background: #161616;
    border: 1px solid #222;
    padding: 15px 20px;
    border-radius: 8px;
}

.det-box h4 {
    margin: 0 0 8px 0;
    color: #888;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 800;
}

.det-box p {
    margin: 0;
    font-size: 1.05rem;
    font-weight: bold;
    color: #ffffff;
}

.det-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.det-table th {
    background: #161616;
    color: #888;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 15px;
    border-bottom: 2px solid #333;
    text-align: left;
}

.det-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #222;
    font-size: 0.95rem;
}

.det-table tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

@keyframes ammFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
