/* ============================================
   REPTIC.CM ADMIN — Light mode, high contrast
   ============================================ */

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #F1F5F9; }
::-webkit-scrollbar-thumb { background: linear-gradient(#209AD7, #D97706); border-radius: 4px; }
::selection { background: #209AD7; color: #fff; }

/* ─── SIDEBAR NAV (sidebar reste dark) ─── */
.adm-nav {
    display: flex; align-items: center; gap: 0.75rem;
    padding: 0.6rem 0.875rem;
    color: rgba(255,255,255,0.60);
    font-size: 0.875rem; font-weight: 500;
    border-radius: 0.625rem;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    background: transparent;
    width: 100%;
}
.adm-nav:hover {
    color: #fff;
    background: rgba(255,255,255,0.08);
}
.adm-nav.active {
    color: #fff;
    background: linear-gradient(135deg, rgba(32,154,215,0.25), rgba(245,158,11,0.12));
    border-color: rgba(32,154,215,0.40);
    box-shadow: 0 2px 10px rgba(32,154,215,0.20);
}
.adm-nav i { flex-shrink: 0; }

/* ─── CARDS ─── */
.adm-card {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.25s ease;
}
.adm-card:hover { border-color: rgba(32,154,215,0.35); box-shadow: 0 4px 20px rgba(32,154,215,0.08); }

.adm-stat {
    background: linear-gradient(135deg, rgba(32,154,215,0.07), rgba(217,119,6,0.04));
    border: 1px solid #E2E8F0;
    border-radius: 1rem;
    padding: 1.25rem 1.5rem;
}
.adm-stat-num {
    font-size: 2rem; font-weight: 800; line-height: 1;
    background: linear-gradient(135deg, #1575A8, #D97706);
    -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
    margin-bottom: 0.25rem;
}
.adm-stat-label {
    font-size: 0.7rem; font-weight: 600;
    color: #64748B;
    text-transform: uppercase; letter-spacing: 0.1em;
}

/* ─── BUTTONS ─── */
.adm-btn-primary {
    display: inline-flex; align-items: center; gap: 0.5rem;
    background: linear-gradient(135deg, #209AD7, #1575A8);
    color: #fff;
    padding: 0.6rem 1.25rem;
    border-radius: 0.625rem;
    font-weight: 600; font-size: 0.875rem;
    border: none; cursor: pointer;
    box-shadow: 0 4px 14px rgba(32,154,215,0.28);
    transition: all 0.22s ease;
    text-decoration: none;
}
.adm-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(32,154,215,0.42);
}
.adm-btn-gold {
    display: inline-flex; align-items: center; gap: 0.5rem;
    background: linear-gradient(135deg, #F59E0B, #D97706);
    color: #fff; padding: 0.6rem 1.25rem;
    border-radius: 0.625rem; font-weight: 600; font-size: 0.875rem;
    border: none; cursor: pointer;
    box-shadow: 0 4px 14px rgba(217,119,6,0.28);
    transition: all 0.22s ease; text-decoration: none;
}
.adm-btn-gold:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(217,119,6,0.42); }

.adm-btn-ghost {
    display: inline-flex; align-items: center; gap: 0.5rem;
    background: #F8FAFC;
    color: #334155;
    padding: 0.5rem 1rem; border-radius: 0.5rem;
    font-weight: 500; font-size: 0.8rem;
    border: 1px solid #CBD5E1;
    cursor: pointer; transition: all 0.2s ease; text-decoration: none;
}
.adm-btn-ghost:hover {
    background: #F1F5F9;
    border-color: rgba(32,154,215,0.45);
    color: #1575A8;
}

.adm-btn-danger {
    display: inline-flex; align-items: center; gap: 0.5rem;
    background: #FEF2F2;
    color: #DC2626;
    padding: 0.5rem 1rem; border-radius: 0.5rem;
    font-weight: 500; font-size: 0.8rem;
    border: 1px solid #FECACA;
    cursor: pointer; transition: all 0.2s ease;
}
.adm-btn-danger:hover { background: #FEE2E2; color: #B91C1C; border-color: #FCA5A5; }

/* ─── BADGES ─── */
.adm-badge {
    display: inline-flex; align-items: center; gap: 0.3rem;
    padding: 0.2rem 0.625rem;
    border-radius: 9999px;
    font-size: 0.7rem; font-weight: 600;
    border: 1px solid;
}
.adm-badge-blue   { background: #EFF6FF; color: #1D4ED8; border-color: #BFDBFE; }
.adm-badge-green  { background: #F0FDF4; color: #15803D; border-color: #BBF7D0; }
.adm-badge-yellow { background: #FFFBEB; color: #B45309; border-color: #FDE68A; }
.adm-badge-red    { background: #FEF2F2; color: #DC2626; border-color: #FECACA; }
.adm-badge-gray   { background: #F8FAFC; color: #475569; border-color: #E2E8F0; }

/* ─── FORMS ─── */
.adm-label {
    display: block; font-size: 0.8rem; font-weight: 600;
    color: #374151;
    margin-bottom: 0.4rem;
}
.adm-label-required::after { content: ' *'; color: #DC2626; }

.adm-input,
.adm-textarea,
.adm-select {
    width: 100%;
    padding: 0.65rem 0.875rem;
    border-radius: 0.625rem;
    background: #F8FAFC;
    border: 1px solid #CBD5E1;
    color: #0F172A;
    font-size: 0.875rem;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: all 0.2s ease;
}
.adm-input::placeholder, .adm-textarea::placeholder { color: #94A3B8; }
.adm-input:focus, .adm-textarea:focus, .adm-select:focus {
    background: #FFFFFF;
    border-color: #209AD7;
    box-shadow: 0 0 0 3px rgba(32,154,215,0.12);
}
.adm-textarea { min-height: 120px; resize: vertical; }
.adm-select option { background: #fff; color: #0F172A; }
.adm-checkbox {
    width: 1.05rem; height: 1.05rem; accent-color: #209AD7;
    cursor: pointer; vertical-align: middle;
}

/* ─── TABLES ─── */
.adm-table-wrapper {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    border-radius: 0.875rem;
    overflow: hidden;
}
.adm-table { width: 100%; border-collapse: collapse; }
.adm-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-size: 0.7rem; font-weight: 700;
    color: #64748B;
    text-transform: uppercase; letter-spacing: 0.1em;
    border-bottom: 1px solid #E2E8F0;
    background: #F8FAFC;
}
.adm-table td {
    padding: 0.875rem 1rem;
    font-size: 0.875rem;
    color: #1E293B;
    border-bottom: 1px solid #F1F5F9;
}
.adm-table tr:last-child td { border-bottom: none; }
.adm-table tbody tr:hover { background: #F8FAFC; }

/* ─── PAGINATION ─── */
.adm-pagination {
    display: flex; gap: 0.4rem;
    align-items: center; justify-content: center;
    margin-top: 1.5rem;
}
.adm-pagination a, .adm-pagination span {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 2rem; height: 2rem;
    padding: 0 0.6rem;
    border-radius: 0.5rem;
    font-size: 0.8rem; font-weight: 500;
    background: #F8FAFC;
    color: #475569;
    border: 1px solid #E2E8F0;
    text-decoration: none;
    transition: all 0.18s ease;
}
.adm-pagination a:hover { background: rgba(32,154,215,0.08); color: #1575A8; border-color: rgba(32,154,215,0.3); }
.adm-pagination .active {
    background: linear-gradient(135deg, #209AD7, #1575A8);
    color: #fff; border-color: transparent;
}

/* ─── TOGGLE SWITCHES ─── */
.adm-toggle {
    display: inline-flex; align-items: center; gap: 0.75rem;
    cursor: pointer; user-select: none;
    padding: 0.4rem 0;
}
.adm-toggle input[type="checkbox"] {
    position: absolute; opacity: 0; pointer-events: none;
    width: 0; height: 0;
}
.adm-toggle-slider {
    position: relative; flex-shrink: 0;
    width: 2.5rem; height: 1.4rem;
    border-radius: 9999px;
    background: #CBD5E1;
    border: 1px solid #94A3B8;
    transition: all 0.25s ease;
}
.adm-toggle-slider::before {
    content: '';
    position: absolute; top: 1px; left: 1px;
    width: 1.15rem; height: 1.15rem;
    border-radius: 50%;
    background: #fff;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}
.adm-toggle input:checked ~ .adm-toggle-slider {
    background: linear-gradient(135deg, #209AD7, #1575A8);
    border-color: rgba(32,154,215,0.4);
    box-shadow: 0 4px 12px rgba(32,154,215,0.25);
}
.adm-toggle input:checked ~ .adm-toggle-slider::before {
    transform: translateX(1.1rem);
}
.adm-toggle-label {
    font-size: 0.875rem; color: #334155;
    font-weight: 500;
}
.adm-toggle input:disabled ~ .adm-toggle-slider { opacity: 0.4; cursor: not-allowed; }

/* ─── TABS ─── */
.adm-tabs {
    display: flex; gap: 0.4rem;
    border-bottom: 1px solid #E2E8F0;
    padding-bottom: 0;
    overflow-x: auto;
}
.adm-tab {
    display: inline-flex; align-items: center; gap: 0.4rem;
    padding: 0.6rem 1rem;
    font-size: 0.85rem; font-weight: 600;
    color: #64748B;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    cursor: pointer;
    transition: all 0.18s ease;
    text-decoration: none;
    white-space: nowrap;
}
.adm-tab:hover {
    color: #1E293B;
    background: #F8FAFC;
}
.adm-tab.active {
    color: #1575A8;
    border-bottom-color: #209AD7;
    background: rgba(32,154,215,0.06);
}

/* ─── PANELS for tabbed forms ─── */
.adm-tab-panel { animation: tabFadeIn 0.2s ease; }
@keyframes tabFadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

/* ─── KBD / CODE ─── */
code {
    font-family: 'JetBrains Mono', 'Consolas', monospace;
    background: #F1F5F9;
    padding: 0.1rem 0.4rem;
    border-radius: 0.25rem;
    font-size: 0.78rem;
    color: #D97706;
}

/* ─── MAIL TEMPLATE PREVIEW ─── */
.mail-preview-iframe {
    width: 100%;
    min-height: 400px;
    border: 1px solid #E2E8F0;
    border-radius: 0.875rem;
    background: #fff;
}
