body {
    margin: 0;
    font-family: Arial, sans-serif;
    display: flex;
    background-color: #f6f8fa;
}

.dashboard-container {
    display: flex;
    width: 100%;
}

.sidebar {
    width: 220px;
    background-color: #111827;
    color: white;
    padding: 20px;
    height: 100vh;
}

.sidebar h2 {
    font-size: 20px;
    margin-bottom: 20px;
}

.sidebar ul {
    list-style: none;
    padding: 0;
}

.sidebar li {
    margin: 10px 0;
    cursor: pointer;
}

.sidebar li.active {
    font-weight: bold;
    color: #10b981;
}

.main-content {
    flex-grow: 1;
    padding: 20px;
}

.cards {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    width: 100px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    font-size: 16px;
}

table {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

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

table th {
    background-color: #f0f2f5;
}

.sidebar li a {
    color: white;
    text-decoration: none;
}

.sidebar li.active a {
    color: #10b981;
    /* ugyanaz a zöld, mint az active li-nél */
    font-weight: bold;
}

.view-orders-button {
    background-color: #2563eb;
    /* kék */
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
    display: inline-block;
}

.view-orders-button:hover {
    background-color: #1d4ed8;
}

.green-button {
    background-color: #22c55e;
    /* tailwind green-500 */
    color: white;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.green-button:hover {
    background-color: #16a34a;
    /* tailwind green-600 */
}

/* Badge stílusok */
.badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 9999px;
    font-size: 12px;
    font-weight: 600;
    color: white;
    margin-left: 8px;
}

.badge.green {
    background-color: #22c55e;
    /* zöld */
}

.badge.red {
    background-color: #ef4444;
    /* piros */
}

.balance-value.green {
    color: #22c55e;
    /* zöld */
}

.balance-value.red {
    color: #ef4444;
    /* piros */
}

.input {
    background: #fff;
}

/* ────────────────────────────────────────────── */
/* ÚJ: Refund & KPI kiegészítő stílusok          */
/* ────────────────────────────────────────────── */

/* Rugalmas törés a KPI-kártyáknál kisebb képernyőn */
.cards {
    flex-wrap: wrap;
}

/* Kis felirat a kártyák tetején (Users, Revenue, stb.) */
.card small {
    color: #666;
    display: block;
    margin-bottom: 4px;
}

/* Refunds (Gross) kártya – negatív szám pirossal */
.card--neg strong {
    color: #b00020;
}

/* Recent Orders refund sor – halvány zöld háttér */
.row-refund {
    background: #e6ffed;
}

/* REFUND jelvény a Bundle oszlopban */
.badge-refund {
    background: #0f5132;
    color: #fff;
}

/* Negatív összegek kiemelése */
.amount-neg {
    color: #b00020;
    font-weight: 600;
}

/* Ha .table class-t használsz (HTML-ben már így szerepel), igazítsuk a default táblastílushoz */
.table {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

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

.table th {
    background-color: #f0f2f5;
}

.orange-button {
    background-color: #f59e0b;
    /* narancs */
    color: white;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    padding: 6px 12px;
    transition: background-color 0.2s ease;
}

.orange-button:hover {
    background-color: #d97706;
}

.export-buttons {
    display: flex;
    align-items: center;
    gap: 220px;
    /* távolság a gombok között */
    margin-bottom: 20px;
}

.export-buttons form {
    margin: 0;
    /* form alapértelmezett margó eltávolítása */
}

/* CSR Modal */
.csr-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.csr-modal-content {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    width: 500px;
    max-height: 90%;
    overflow-y: auto;
    position: relative;
}

.csr-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
}

.csr-actions button {
    margin: 6px;
    padding: 8px 14px;
    border: none;
    background: #003b3b;
    color: #fff;
    border-radius: 8px;
    cursor: pointer;
}

.csr-actions button:hover {
    background: #006060;
}

.csr-qr {
    margin: 12px 0;
    text-align: center;
}

.csr-actions {
    margin: 12px 0;
}

/* ────────────────────────────────────────────── */
/* CSR Modal – Busy overlay + spinner             */
/* ────────────────────────────────────────────── */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.csr-modal-content .csr-busy-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.75);
    display: none;
    /* alapból rejtve */
    align-items: center;
    justify-content: center;
    z-index: 10;
    backdrop-filter: blur(1px);
}

.csr-modal-content .csr-busy-overlay .csr-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid rgba(0, 0, 0, 0.2);
    border-top-color: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
}

.csr-modal-content.is-busy .csr-busy-overlay {
    display: flex;
    /* busy állapotban jelenjen meg */
}

.csr-modal-content.is-busy *:not(.csr-busy-overlay) {
    pointer-events: none;
    /* lezárja az interakciót */
    user-select: none;
}

/* Modal base (CSP-barát: nincs inline style a HTML-ben) */
.modal {
    display: none;
}

.modal.open {
    display: block;
}

.modal .modal-content {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .12);
    max-width: 560px;
    margin: 10vh auto;
    padding: 16px 18px;
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 16px;
}

.badge-danger {
    background-color: #ef4444;
    color: #fff;
    display: inline-block;
    padding: 2px 8px;
    border-radius: 9999px;
    font-size: 12px;
    line-height: 1.6;
    font-weight: 600;
}

.button-outline {
    background: transparent;
    color: #111;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 6px 12px;
    cursor: pointer;
}

.button-outline:hover {
    border-color: #bbb;
}