
:root {
    --bg: #050607;
    --bg-alt: #09090f;
    --surface: #11131a;
    --surface-alt: #171922;
    --primary: #d4af37;
    --primary-hover: #c29b2a;
    --accent: #f5c451;
    --text: #f7f3e8;
    --text-muted: #b9aa7f;
    --border: rgba(212, 175, 55, 0.2);
    --success: #9ec27b;
    --error: #f87171;
    --radius: 14px;
    --radius-sm: 10px;
    --shadow: 0 18px 48px rgba(0, 0, 0, 0.55);
    --transition: 0.25s ease;
    font-size: 16px;
} 

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: radial-gradient(circle at top, rgba(24, 37, 99, 0.32), transparent 55%),
                radial-gradient(circle at bottom, rgba(148, 90, 255, 0.12), transparent 50%),
                var(--bg);
    color: var(--text);
    min-height: 100vh;
    display: flex;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
    color: inherit;
}

.login-mode {
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 2rem;
}

.login-card {
    background: rgba(11, 15, 25, 0.88);
    backdrop-filter: blur(18px);
    border-radius: 1.4rem;
    padding: 2.75rem 3rem;
    width: min(520px, 100%);
    box-shadow: 0 30px 60px rgba(5, 8, 17, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.25);
    display: flex;
    flex-direction: column;
    gap: 1.6rem;
}

.login-header {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    text-align: center;
    align-items: center;
}

.login-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.35rem 0.85rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 700;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.45), rgba(129, 140, 248, 0.35));
    color: #dde7ff;
}

.login-header h1 {
    margin: 0;
    font-size: 2.35rem;
    font-weight: 700;
}

.login-subtitle {
    margin: 0;
    color: rgba(226, 232, 240, 0.82);
    font-size: 1.05rem;
    letter-spacing: 0.02em;
}

.alert {
    padding: 0.9rem 1.1rem;
    border-radius: var(--radius-sm);
    margin: 1.5rem 0;
    font-size: 0.95rem;
    font-weight: 500;
}

.alert-error {
    background: rgba(244, 63, 94, 0.12);
    border: 1px solid rgba(244, 63, 94, 0.35);
    color: #fda4af;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.login-warning {
    margin-top: 0.6rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: #f87171;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.login-footer {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-top: 0.5rem;
    text-align: center;
}

.login-safety-note {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.68);
}

.login-support {
    font-size: 0.85rem;
    color: rgba(226, 232, 240, 0.6);
}

.login-support a {
    color: rgba(191, 219, 254, 0.95);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

label {
    font-weight: 600;
    font-size: 0.95rem;
}

input,
select {
    border: 1px solid rgba(212, 175, 55, 0.28);
    background: rgba(12, 12, 14, 0.75);
    color: var(--text);
    padding: 0.8rem 1rem;
    border-radius: var(--radius-sm);
    transition: border-color var(--transition), box-shadow var(--transition);
}

input:focus,
select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.22);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    border-radius: var(--radius-sm);
    padding: 0.75rem 1.4rem;
    font-weight: 600;
    transition: background var(--transition), color var(--transition), transform var(--transition);
}

.btn-icon {
    width: 42px;
    height: 42px;
    padding: 0;
    border-radius: 50%;
    border: 1px solid rgba(212, 175, 55, 0.3);
    background: rgba(12, 12, 14, 0.75);
    color: var(--text);
    font-size: 1rem;
}

.btn-icon:hover {
    background: rgba(212, 175, 55, 0.18);
    transform: translateY(-1px);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), #f8d572);
    color: #1a1406;
    box-shadow: 0 10px 24px rgba(212, 175, 55, 0.25);
}

.btn-primary:hover {
    transform: translateY(-1px);
    background: linear-gradient(135deg, var(--primary-hover), #f1c451);
}

.btn-secondary {
    background: rgba(212, 175, 55, 0.16);
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.btn-secondary:hover {
    background: rgba(212, 175, 55, 0.24);
}

.sidebar {
    width: 270px;
    background: linear-gradient(185deg, rgba(8, 9, 12, 0.96), rgba(15, 14, 10, 0.9));
    backdrop-filter: blur(14px);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    padding: 1.6rem 1.4rem;
    gap: 1.4rem;
    position: sticky;
    top: 0;
    height: 100vh;
    transition: width 0.25s ease, padding 0.25s ease;
}

.sidebar.collapsed {
    width: 80px;
    padding: 1.2rem 1rem;
}

.sidebar.collapsed .sidebar__brand {
    justify-content: center;
}

.sidebar.collapsed .sidebar__brand .brand__title {
    display: none;
}

.sidebar.collapsed .nav-item {
    justify-content: center;
    padding: 0.65rem 0.75rem;
    gap: 0;
}

.sidebar.collapsed .nav-item span {
    display: none;
}

.sidebar.collapsed .sidebar__modes {
    flex-direction: column;
    gap: 0.5rem;
    align-items: center;
}

.sidebar.collapsed .sidebar__mode-btn {
    width: 100%;
    justify-content: center;
    padding: 0.6rem;
}

.sidebar.collapsed .sidebar__mode-btn span {
    display: none;
}

.sidebar.collapsed .nav-item i {
    font-size: 1.1rem;
}

.sidebar.collapsed .sidebar__subnav {
    margin-left: 0;
    align-items: center;
}

.sidebar.collapsed .nav-item--sub {
    justify-content: center;
}

.sidebar.collapsed .sidebar__footer {
    display: flex;
    justify-content: center;
}

.sidebar.collapsed .sidebar__footer .btn span {
    display: none;
}

.sidebar.collapsed .sidebar__footer .btn {
    width: 42px;
    padding: 0.6rem;
    justify-content: center;
}

.sidebar__brand {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    font-size: 1.3rem;
    font-weight: 700;
}

.brand__logo {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.2rem;
}

.sidebar__nav {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.75rem 0.85rem;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    transition: background var(--transition), color var(--transition), transform var(--transition);
    font-weight: 600;
}

.nav-item:hover {
    color: var(--text);
    background: rgba(212, 175, 55, 0.12);
}

.nav-item.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.32), rgba(248, 213, 114, 0.25));
    color: var(--text);
}

.sidebar__subnav {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin: 0.2rem 0 0.6rem 2.25rem;
    transition: margin 0.25s ease;
}

.nav-item--sub {
    font-size: 0.9rem;
    padding: 0.6rem 0.7rem;
    color: rgba(226, 232, 240, 0.7);
}

.nav-item--sub i {
    font-size: 0.75rem;
}

.nav-item--sub.active {
    background: rgba(212, 175, 55, 0.24);
    color: var(--text);
}

.sidebar__divider {
    height: 1px;
    background: var(--border);
    margin: 1rem 0;
}

.sidebar__footer {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.sidebar__footer-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(148, 163, 184, 0.1);
    font-size: 0.75rem;
    text-align: center;
}

.sidebar__confidentiality {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: var(--text-muted);
    line-height: 1.4;
    margin: 0;
}

.sidebar__confidentiality i {
    color: var(--primary);
    font-size: 0.9rem;
}

.sidebar__confidentiality span {
    font-size: 0.7rem;
}

.sidebar__copyright {
    color: var(--text-muted);
    font-size: 0.7rem;
    margin: 0;
    opacity: 0.7;
}

.sidebar.collapsed .sidebar__footer-info {
    display: none;
}

.content {
    flex: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    gap: 1.6rem;
    padding: 1.8rem 2.3rem;
}

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.topbar__info h1 {
    margin: 0;
    font-size: 1.85rem;
    font-weight: 700;
}

.topbar__info p {
    margin: 0.4rem 0 0;
    color: var(--text-muted);
    font-size: 0.97rem;
}

.topbar__filters {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.filter {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
}

.section {
    display: none;
    flex-direction: column;
    gap: 1.6rem;
}

.section.active {
    display: flex;
}

.panel {
    background: linear-gradient(155deg, rgba(10, 10, 12, 0.95), rgba(24, 19, 11, 0.88));
    border-radius: var(--radius);
    box-shadow: 0 22px 46px rgba(0, 0, 0, 0.55);
    border: 1px solid var(--border);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.panel__header {
    padding: 1.6rem 2rem 1.2rem;
    border-bottom: 1px solid var(--border);
}

.panel__header h2 {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 700;
}

.panel__header p {
    margin: 0.35rem 0 0;
    color: var(--text-muted);
}

.panel__body {
    padding: 1.8rem 2rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.panel__charts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.4rem;
}

.chart-card {
    background: rgba(14, 14, 18, 0.94);
    border: 1px solid rgba(212, 175, 55, 0.18);
    border-radius: var(--radius-sm);
    box-shadow: 0 16px 28px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.chart-card__header {
    padding: 1rem 1.4rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.16);
}

.chart-card__header h3 {
    margin: 0;
    font-size: 1.05rem;
}

.chart-card__body {
    padding: 1rem 1.2rem 1.2rem;
}

.chart-card canvas {
    width: 100% !important;
    min-width: 100%;
    height: 260px !important;
}

.section-subnav {
    display: inline-flex;
    gap: 0.6rem;
    margin-bottom: 1.4rem;
    background: rgba(12, 12, 14, 0.7);
    padding: 0.35rem;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(212, 175, 55, 0.25);
    box-shadow: inset 0 0 12px rgba(0, 0, 0, 0.35);
}

.btn-subnav {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.95rem;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-weight: 600;
    transition: background var(--transition), color var(--transition), transform var(--transition);
}

.btn-subnav i {
    font-size: 0.85rem;
}

.btn-subnav:hover {
    color: var(--text);
}

.btn-subnav.active {
    background: rgba(212, 175, 55, 0.22);
    color: #1b1406;
    box-shadow: inset 0 0 0 1px rgba(212, 175, 55, 0.35);
}

.subsection {
    display: none;
}

.subsection.active {
    display: block;
}

.panel__footer {
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.2rem;
}

.cards-grid--compact {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.card {
    padding: 1.4rem;
    border-radius: var(--radius-sm);
    background: linear-gradient(165deg, rgba(18, 18, 22, 0.95), rgba(32, 26, 14, 0.82));
    border: 1px solid rgba(212, 175, 55, 0.25);
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.45);
}

.card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top left, rgba(248, 213, 114, 0.25), transparent 70%);
    opacity: 0;
    transition: opacity var(--transition);
}

.card:hover::after {
    opacity: 1;
}

.card__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card__label {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-muted);
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.card__icon {
    font-size: 1.4rem;
    color: var(--primary);
}

.card__value {
    margin: 0;
    font-size: 2rem;
    font-weight: 700;
}

.card__meta {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.92rem;
}

.card.loading {
    opacity: 0.6;
    position: relative;
}

.card.loading::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.08) 50%, transparent 100%);
    animation: shimmer 1.8s infinite;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

.split-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    gap: 1.5rem;
}

.table-stack {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.table-card {
    background: rgba(14, 14, 17, 0.94);
    border: 1px solid rgba(212, 175, 55, 0.18);
    border-radius: var(--radius-sm);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.table-card__header {
    padding: 1rem 1.4rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.16);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.table-card__header h3 {
    margin: 0;
    font-size: 1.05rem;
}

.table-card__header h4 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
}

.table-card__header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    width: 100%;
}

.table-card__body {
    padding: 0.2rem 1.4rem 1.4rem;
    overflow-x: auto;
    width: 100%;
}

.table-card__header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
}

.table-card__body > .data-table {
    margin-top: 0.6rem;
}

.table-select {
    background: rgba(15, 15, 18, 0.85);
    border: 1px solid rgba(212, 175, 55, 0.35);
    color: var(--text);
    padding: 0.45rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    min-width: 180px;
}

.table-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.25);
}

.table-select {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(99, 102, 241, 0.35);
    color: var(--text);
    padding: 0.45rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    min-width: 180px;
}

.table-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.25);
}

.table-card--full {
    margin-top: 1.6rem;
}

.table-card--type {
    margin: 0;
}

.table-card--type .table-card__header {
    gap: 0.6rem;
}

.table-card--type .badge {
    font-weight: 600;
}

.table-type-container {
    display: grid;
    gap: 1.2rem;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    margin-top: 1.6rem;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(17, 24, 47, 0.6);
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.12);
}

.data-table thead {
    background: rgba(212, 175, 55, 0.14);
    color: var(--text);
}

.data-table th,
.data-table td {
    padding: 0.75rem 1rem;
    font-size: 0.92rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.1);
    text-align: left;
}

.data-table tbody tr:hover {
    background: rgba(212, 175, 55, 0.12);
}

.data-table--events tbody tr.events-details td {
    font-size: 0.85rem;
    color: var(--text-muted);
    background: rgba(12, 20, 38, 0.85);
    border-bottom: 1px solid rgba(212, 175, 55, 0.08);
}

.data-table--events tbody tr.events-row--even td {
    background: rgba(212, 175, 55, 0.12);
}

.data-table--events tbody tr.events-row--odd td {
    background: rgba(15, 23, 42, 0.4);
}

.data-table--events tbody tr.events-details.events-row--even td {
    background: rgba(212, 175, 55, 0.12);
}

.data-table--events tbody tr.events-details.events-row--odd td {
    background: rgba(15, 23, 42, 0.4);
}

.data-table--events tbody tr.events-row td {
    border-top: 4px solid rgba(14, 19, 33, 0.85);
}

.data-table--events tbody tr:first-child.events-row td {
    border-top: none;
}

.data-table--events tbody tr.events-details td {
    border-bottom: 4px solid rgba(212, 175, 55, 0.35);
    box-shadow: inset 0 -6px 0 rgba(12, 20, 38, 0.8);
}

.data-table--events tbody td .events-comparison {
    display: block;
    font-size: 0.76rem;
    color: var(--text-muted);
    margin-top: 0.2rem;
}

.data-table--events tbody tr.events-details span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-right: 1.2rem;
}

.data-table--events tbody tr.events-details span.events-new-couples {
    margin-left: 1.8rem;
    padding-left: 1.2rem;
    border-left: 2px solid rgba(212, 175, 55, 0.45);
    color: #f9d977;
}

.data-table--events tbody tr.events-details span.events-new-couples strong {
    color: #fbeeaa;
}

.data-table--events tbody tr.events-details span.events-ratio {
    margin-left: 1.8rem;
    padding-left: 1.2rem;
    border-left: 2px solid rgba(59, 130, 246, 0.45);
}

.data-table--events tbody tr.events-details strong {
    color: var(--text);
    font-weight: 600;
}

.data-table--tight th,
.data-table--tight td {
    padding: 0.65rem 0.9rem;
}

.data-table--striped tbody tr:nth-child(even) {
    background: rgba(212, 175, 55, 0.08);
}

.management-tabs {
    display: inline-flex;
    background: rgba(15, 23, 42, 0.6);
    border-radius: var(--radius-sm);
    padding: 0.3rem;
    border: 1px solid rgba(148, 163, 184, 0.12);
}

.btn-tab {
    padding: 0.6rem 1.1rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    color: var(--text-muted);
    transition: background var(--transition), color var(--transition);
}

.btn-tab.active {
    background: rgba(99, 102, 241, 0.22);
    color: #fff;
}

.management-actions {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
    margin: 1.3rem 0 0;
    align-items: center;
}

.management-actions__group {
    display: none;
    align-items: center;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.management-actions__group.active {
    display: flex;
}

.is-hidden {
    display: none !important;
}

.management-table {
    display: none;
    flex-direction: column;
    gap: 1rem;
}

.management-table.active {
    display: flex;
}

.site-subtabs {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(15, 23, 42, 0.6);
    border-radius: var(--radius-sm);
    padding: 0.3rem;
    border: 1px solid rgba(148, 163, 184, 0.12);
}

.btn-subtab {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.45rem 0.9rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    color: var(--text-muted);
    transition: background var(--transition), color var(--transition);
}

.btn-subtab i {
    font-size: 0.9rem;
}

.btn-subtab.active {
    background: rgba(99, 102, 241, 0.22);
    color: #fff;
}

.site-panel {
    display: none;
    flex-direction: column;
    gap: 1.5rem;
}

.site-panel.active {
    display: flex;
}

.site-panel__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1.2rem;
}

.site-panel__header h3 {
    margin: 0;
}

.site-panel__header p {
    margin: 0.3rem 0 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.site-panel__meta {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.site-panel--annonce {
    gap: 1.2rem;
}

.site-annonce-status {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    align-items: center;
    justify-content: flex-end;
    margin-left: auto;
}

.site-annonce-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.8rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 600;
    background: rgba(15, 23, 42, 0.86);
    border: 1px solid rgba(148, 163, 184, 0.18);
    color: var(--text-muted);
    text-transform: none;
}

.site-annonce-chip--alert {
    background: rgba(248, 113, 113, 0.15);
    border-color: rgba(248, 113, 113, 0.4);
    color: #fecaca;
}

.site-annonce-chip--info {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.4);
    color: #bae6fd;
}

.site-annonce-chip--status.is-active {
    background: rgba(74, 222, 128, 0.18);
    border-color: rgba(74, 222, 128, 0.35);
    color: #bbf7d0;
}

.site-annonce-chip--status.is-expired {
    background: rgba(248, 113, 113, 0.12);
    border-color: rgba(248, 113, 113, 0.4);
    color: #fecaca;
}

.site-annonce-chip--status.is-inactive {
    background: rgba(148, 163, 184, 0.15);
    border-color: rgba(148, 163, 184, 0.32);
    color: rgba(226, 232, 240, 0.86);
}

.site-annonce-chip--date {
    font-weight: 500;
}

.site-annonce-form {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.site-annonce-form .form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.site-annonce-form label span {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.35rem;
    color: var(--text-muted);
}

.site-annonce-form textarea {
    resize: vertical;
    min-height: 140px;
}

.site-annonce-switches {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.site-annonce-switches .toggle {
    min-width: 220px;
}

.site-annonce-actions {
    margin-top: 0.6rem;
}

.site-form {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.site-hours-builder,
.site-tariffs-builder {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.site-hours-row,
.site-tariff-row {
    display: grid;
    gap: 0.9rem;
    padding: 1rem;
    border-radius: var(--radius-sm);
    background: rgba(12, 20, 38, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.12);
    position: relative;
}

.site-hours-row__grid {
    display: grid;
    gap: 0.9rem;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.site-hours-row__prices {
    display: grid;
    gap: 0.8rem;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}

.site-hours-row__note {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    grid-column: 1 / -1;
}

.site-tariff-row {
    grid-template-columns: minmax(160px, 200px) minmax(120px, 160px) minmax(180px, 1fr);
}

.site-hours-row label,
.site-tariff-row label {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.site-hours-row select,
.site-hours-row input,
.site-hours-row textarea,
.site-tariff-row input,
.site-tariff-row textarea {
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: var(--radius-sm);
    padding: 0.6rem 0.75rem;
    color: var(--text);
}

.site-hours-row textarea,
.site-tariff-row textarea {
    resize: vertical;
    min-height: 70px;
}

.site-row-actions {
    position: absolute;
    top: 0.6rem;
    right: 0.6rem;
    display: flex;
    gap: 0.4rem;
}

.site-row-actions button {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.18);
    border: 1px solid transparent;
    color: var(--text-muted);
    transition: background var(--transition), color var(--transition);
}

.site-row-actions button:hover {
    color: var(--text);
    background: rgba(99, 102, 241, 0.35);
}

.site-tariffs header h4 {
    margin: 0;
}

.site-tariffs header p {
    margin: 0.25rem 0 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.site-notes textarea {
    width: 100%;
    min-height: 110px;
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: var(--radius-sm);
    padding: 0.75rem 0.9rem;
    color: var(--text);
    resize: vertical;
}

.site-soirees-group {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-top: 1.6rem;
}

.site-hours-preview {
    margin-top: 1.8rem;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.site-hours-preview__header h4 {
    margin: 0;
}

.site-hours-preview__header p {
    margin: 0.2rem 0 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.site-hours-preview table td,
.site-hours-preview table th {
    font-size: 0.88rem;
}

.site-soirees-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0 0.5rem;
}

.site-soirees-filter .btn-subtab {
    padding: 0.35rem 0.75rem;
}

.site-soirees-filter .btn-subtab.active {
    background: rgba(212, 175, 55, 0.22);
    color: #fff;
}

.site-soiree-flags {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.9rem;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(148, 163, 184, 0.18);
    background: rgba(15, 23, 42, 0.6);
    font-weight: 600;
    cursor: pointer;
    color: var(--text-muted);
}

.toggle input {
    width: 18px;
    height: 18px;
    accent-color: #6366f1;
}

.modal__dialog--wide {
    width: min(1600px, 98vw);
    max-height: 92vh;
}

.modal__dialog--wide .modal__body {
    max-height: calc(92vh - 4.5rem);
    overflow-y: auto;
}

.site-soiree-form {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
}

.site-soiree-form .form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.site-soiree-form > label {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.site-soiree-form label span {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.35rem;
    color: var(--text-muted);
}

.site-soiree-form input[type="text"],
.site-soiree-form input[type="number"],
.site-soiree-form input[type="date"],
.site-soiree-form input[type="time"],
.site-soiree-form select,
.site-soiree-form textarea {
    width: 100%;
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: var(--radius-sm);
    padding: 0.65rem 0.8rem;
    color: var(--text);
}

.site-soiree-form textarea {
    resize: vertical;
    min-height: 120px;
}

.site-soiree-flyer {
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(260px, 1fr) minmax(200px, 35%);
    align-items: start;
}

.site-soiree-flyer__preview {
    display: none;
    flex-direction: column;
    gap: 0.6rem;
}

.site-soiree-flyer__preview.is-visible {
    display: flex;
}

.site-soiree-flyer__preview img {
    max-height: 220px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    border: 1px solid rgba(148, 163, 184, 0.18);
}

@media (max-width: 768px) {
    .site-soiree-flyer {
        grid-template-columns: 1fr;
    }
}
.pagination {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
    align-items: center;
}

.pagination button {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    background: rgba(99, 102, 241, 0.18);
}

.pagination button[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
}

.modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 100;
}

.modal.active {
    display: flex;
}

.modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(2, 6, 23, 0.65);
    backdrop-filter: blur(6px);
    cursor: pointer;
}

.modal__dialog {
    position: relative;
    background: rgba(12, 12, 16, 0.94);
    border-radius: var(--radius);
    padding: 1.2rem 1.4rem 1.4rem;
    width: min(520px, 92vw);
    border: 1px solid rgba(212, 175, 55, 0.25);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.6);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.modal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.18);
}

.modal__header h3 {
    margin: 0;
    font-size: 1.2rem;
}

.modal__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid transparent;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    transition: background var(--transition), color var(--transition), transform var(--transition);
}

.modal__close:hover {
    color: var(--text);
    border-color: rgba(212, 175, 55, 0.35);
    background: rgba(212, 175, 55, 0.12);
    transform: translateY(-1px);
}

.modal__body {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 0.5rem;
}

.modal__form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.modal__form label {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    font-weight: 600;
}

.modal__form input[type="password"] {
    text-align: center;
    letter-spacing: 0.5rem;
    font-size: 1.6rem;
    padding: 0.8rem 1rem;
}

.modal__error {
    min-height: 1.2rem;
    color: var(--error);
    font-size: 0.9rem;
    margin: 0;
}

.modal__body .form-grid-small {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.8rem;
}

.modal__body textarea {
    min-height: 120px;
}

.modal__footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.6rem;
}

.toast-container {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    z-index: 150;
}

.toast {
    padding: 1rem 1.2rem;
    border-radius: var(--radius-sm);
    background: rgba(12, 12, 14, 0.9);
    border: 1px solid rgba(212, 175, 55, 0.28);
    min-width: 240px;
    box-shadow: var(--shadow);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--text);
    animation: toast-in 0.3s ease forwards;
}

.toast--success {
    border-color: rgba(148, 213, 156, 0.4);
    color: #d7f2d7;
}

.toast--error {
    border-color: rgba(244, 63, 94, 0.35);
    color: #fecdd3;
}

@keyframes toast-in {
    from {
        transform: translateY(10px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.2rem;
}

.form-actions {
    display: flex;
    align-items: flex-end;
}

.analysis-results {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.analysis-block {
    background: rgba(14, 14, 18, 0.92);
    border-radius: var(--radius-sm);
    border: 1px solid rgba(212, 175, 55, 0.18);
    padding: 1.4rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    color: var(--text);
}

.analysis-block header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.analysis-block header h3 {
    margin: 0;
}

.analysis-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.9rem;
}

.metric {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.metric span:first-child {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.metric strong {
    font-size: 1.1rem;
}

.analysis-table-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(520px, 1fr));
    gap: 1.2rem;
    margin-top: 0.6rem;
}

.table-card--analysis .table-card__header {
    padding: 0.9rem 1.2rem;
}

.table-card--analysis .table-card__body {
    padding: 0.4rem 1.2rem 1.2rem;
    max-height: 420px;
    overflow-y: auto;
    overflow-x: auto;
}

.table-card--analysis table {
    margin-top: 0;
    width: 100%;
    min-width: 620px;
}

.table-empty {
    text-align: center;
    padding: 0.75rem;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.85rem;
    padding: 0.35rem 0.6rem;
    border-radius: 999px;
    background: rgba(212, 175, 55, 0.18);
    border: 1px solid rgba(212, 175, 55, 0.35);
}

.badge--success {
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.35);
    color: #6ee7b7;
}

.badge--danger {
    background: rgba(244, 63, 94, 0.15);
    border-color: rgba(244, 63, 94, 0.35);
    color: #fda4af;
}

canvas {
    width: 100% !important;
    height: 260px !important;
}

#clientsPie {
    max-height: 200px !important;
    height: 200px !important;
}

#eventsTable tbody tr:nth-child(odd) {
    background: rgba(15, 23, 42, 0.55);
}

#eventsTable tbody tr:nth-child(even) {
    background: rgba(11, 17, 32, 0.75);
}

#eventsTable tbody tr.special-1 td {
    background: rgba(233, 30, 99, 0.18);
}

#eventsTable tbody tr.special-3 td {
    background: rgba(63, 81, 181, 0.18);
}

#eventsTable tbody tr.special-5 td {
    background: rgba(0, 150, 136, 0.18);
}

#eventsTable tbody tr.special-6 td {
    background: rgba(255, 152, 0, 0.2);
}

#eventsTable tbody tr.special-1:hover td,
#eventsTable tbody tr.special-3:hover td,
#eventsTable tbody tr.special-5:hover td,
#eventsTable tbody tr.special-6:hover td {
    filter: brightness(1.1);
}

@media (max-width: 1024px) {
    .sidebar {
        position: fixed;
        inset: 0 auto 0 0;
        transform: translateX(-100%);
        transition: transform var(--transition);
        z-index: 120;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .content {
        padding: 1.4rem;
    }

    .topbar {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .topbar__filters {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 640px) {
    body.app {
        flex-direction: column;
    }

    .topbar__filters {
        flex-direction: column;
        align-items: stretch;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    canvas {
        height: 280px !important;
    }

    .management-actions {
        flex-direction: column;
        align-items: stretch;
    }
}

.site-panel--drinks {
    gap: 1.5rem;
}

.site-drinks {
    display: grid;
    grid-template-columns: minmax(220px, 280px) 1fr;
    gap: 1.4rem;
}

.site-drinks__categories {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.site-drink-category {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: var(--radius-sm);
    padding: 0.85rem;
    transition: border var(--transition), box-shadow var(--transition), transform var(--transition);
}

.site-drink-category.active {
    border-color: rgba(212, 175, 55, 0.45);
    box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.35);
}

.site-drink-category__select {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
    width: 100%;
    background: none;
    border: none;
    color: inherit;
    text-align: left;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
}

.site-drink-category__name {
    font-size: 1rem;
}

.site-drink-category__label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.site-drink-category__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.6rem;
}

.site-drink-category__status {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.15);
    color: rgba(226, 232, 240, 0.85);
}

.site-drink-category__status.is-open {
    background: rgba(74, 222, 128, 0.18);
    color: #bbf7d0;
}

.site-drink-category__status.is-closed {
    background: rgba(248, 113, 113, 0.15);
    color: #fecaca;
}

.site-drink-category__actions {
    display: inline-flex;
    gap: 0.4rem;
}

.site-drink-category__actions .btn-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: var(--text-muted);
    transition: background var(--transition), color var(--transition);
}

.site-drink-category__actions .btn-icon:hover {
    color: var(--text);
    background: rgba(148, 163, 184, 0.22);
}

.site-drinks__content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(148, 163, 184, 0.15);
    border-radius: var(--radius-sm);
    padding: 1rem;
}

.site-drinks__header {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.site-drinks__header h4 {
    margin: 0;
}

.site-drinks__header p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.site-drinks__table {
    overflow-x: auto;
}

.site-drinks-table__actions {
    display: inline-flex;
    gap: 0.4rem;
}

.site-drinks-empty {
    padding: 1.2rem;
    text-align: center;
    color: var(--text-muted);
    background: rgba(15, 23, 42, 0.6);
    border: 1px dashed rgba(148, 163, 184, 0.3);
    border-radius: var(--radius-sm);
}

@media (max-width: 1024px) {
    .site-drinks {
        grid-template-columns: 1fr;
    }
}

.sidebar__modes {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.sidebar__mode-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.45rem 0.6rem;
    border-radius: var(--radius-sm);
    background: transparent;
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.sidebar__mode-btn:hover {
    border-color: rgba(212, 175, 55, 0.35);
    color: var(--text);
}

.sidebar__mode-btn.active {
    background: rgba(212, 175, 55, 0.18);
    border-color: rgba(212, 175, 55, 0.45);
    color: var(--text);
}

/* Clients tabs */
.clients-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
    flex-wrap: wrap;
}

.clients-tab {
    padding: 0.5rem 1rem;
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 0.375rem;
    color: rgba(226, 232, 240, 0.7);
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
}

.clients-tab:hover {
    background: rgba(30, 41, 59, 0.7);
    color: rgba(226, 232, 240, 0.9);
}

.clients-tab.active {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(99, 102, 241, 0.2));
    border-color: rgba(59, 130, 246, 0.5);
    color: rgba(226, 232, 240, 1);
}

.clients-tab-panel {
    display: none;
}

.clients-tab-panel.active {
    display: block;
}

.clients-stats-header {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stat-card {
    padding: 1rem;
    background: rgba(30, 41, 59, 0.5);
    border-radius: 0.5rem;
    border: 1px solid rgba(148, 163, 184, 0.2);
    min-width: 200px;
}

.stat-card__label {
    font-size: 0.875rem;
    color: rgba(148, 163, 184, 0.8);
    margin-bottom: 0.5rem;
}

.stat-card__value {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text);
}

.clients-filters {
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: rgba(30, 41, 59, 0.5);
    border-radius: 0.5rem;
}

.clients-filters h4 {
    margin: 0 0 0.75rem 0;
    font-size: 0.875rem;
    color: rgba(148, 163, 184, 0.8);
}

.clients-filters__group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.email-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.email-indicator--green {
    background: #22c55e;
}

.email-indicator--red {
    background: #ef4444;
}

.events-ratio {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.ratio-indicator {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    padding: 0 0.5rem;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.3), rgba(99, 102, 241, 0.3));
    border: 2px solid rgba(59, 130, 246, 0.5);
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1;
    white-space: nowrap;
}

/* Menu sidebar visible sur mobile */
@media (max-width: 768px) {
    .sidebar {
        position: fixed !important;
        top: 0;
        left: 0;
        height: 100vh;
        z-index: 1000;
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
        transform: translateX(0) !important;
    }
    
    .sidebar__nav {
        display: flex !important;
        flex-direction: column;
    }
    
    .sidebar__nav .nav-item {
        display: flex !important;
        width: 100%;
    }
}

/* S'assurer que le sidebar est toujours visible */
.sidebar {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Conteneur pour les graphiques */
.chart-container {
    position: relative;
    height: 400px;
    margin-bottom: 2rem;
}

.chart-container canvas {
    max-height: 100%;
}

