/* =============================================
   SENTINEL ENGINE - Main Stylesheet
   Dark Gaming/Lottery Theme
   ============================================= */

:root {
    --bg-dark: #0d0d0d;
    --bg-card: #1a1a1a;
    --bg-nav: #111111;
    --bg-input: #2a2a2a;
    --color-primary: #00c8c8;
    --color-accent: #e53935;
    --color-orange: #f59e0b;
    --color-purple: #7c3aed;
    --color-green: #10b981;
    --color-text: #e0e0e0;
    --color-muted: #888;
    --border: #2a2a2a;
    --border-glow: rgba(0,200,200,0.3);
    --nav-height: 50px;
    --banner-height: 60px;
    --bottom-nav-height: 65px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: var(--bg-dark);
    color: var(--color-text);
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 14px;
    min-height: 100vh;
    overflow-x: hidden;
}

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

/* =============================================
   TOP BANNER
   ============================================= */
.top-banner {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--banner-height);
    background: linear-gradient(135deg, #1a0a2e 0%, #2d1b4e 30%, #1a0a0a 70%, #2e1010 100%);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    z-index: 900;
    border-bottom: 1px solid rgba(124,58,237,0.3);
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='60' viewBox='0 0 100 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 30 Q25 10 50 30 T100 30' stroke='rgba(124,58,237,0.1)' fill='none' stroke-width='1'/%3E%3C/svg%3E");
}

.banner-logo {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hamburger {
    background: none;
    border: none;
    color: var(--color-primary);
    font-size: 20px;
    cursor: pointer;
    display: none;
    padding: 8px;
}

.banner-logo img { height: 38px; }

.banner-site-name {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 1px;
}

.banner-sub {
    font-size: 9px;
    color: var(--color-muted);
    display: block;
    line-height: 1;
}

.banner-time {
    display: flex;
    align-items: center;
    gap: 8px;
}

.refresh-btn {
    background: none;
    border: none;
    color: var(--color-primary);
    font-size: 16px;
    cursor: pointer;
    transition: transform 0.3s;
}
.refresh-btn:hover { transform: rotate(180deg); }

.clock {
    background: var(--color-accent);
    color: #fff;
    padding: 4px 14px;
    border-radius: 4px;
    font-size: 18px;
    font-weight: 700;
    font-family: monospace;
    letter-spacing: 2px;
}

/* =============================================
   DESKTOP NAVBAR
   ============================================= */
.desktop-nav {
    position: fixed;
    top: var(--banner-height);
    left: 0; right: 0;
    height: var(--nav-height);
    background: var(--bg-nav);
    display: flex;
    align-items: center;
    z-index: 800;
    border-bottom: 1px solid var(--border);
    padding: 0 8px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 14px;
    height: var(--nav-height);
    color: var(--color-text);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: color 0.2s, background 0.2s;
    white-space: nowrap;
}

.nav-item:hover, .nav-item.active {
    color: var(--color-primary);
    background: rgba(0,200,200,0.08);
}

.nav-arrow { font-size: 10px; opacity: 0.7; }

.nav-dropdown {
    position: relative;
}

.nav-dropdown .dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #1a1a1a;
    min-width: 180px;
    border: 1px solid var(--border);
    border-top: 2px solid var(--color-primary);
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
    z-index: 999;
    border-radius: 0 0 6px 6px;
}

.nav-dropdown:hover .dropdown-menu { display: block; }

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 11px 16px;
    color: var(--color-text);
    font-size: 13px;
    transition: background 0.2s, color 0.2s;
}

.dropdown-item:hover {
    background: rgba(0,200,200,0.1);
    color: var(--color-primary);
}

/* =============================================
   MAIN CONTENT
   ============================================= */
.main-content {
    margin-top: calc(var(--banner-height) + var(--nav-height));
    padding: 20px;
    min-height: calc(100vh - var(--banner-height) - var(--nav-height));
    padding-bottom: 30px;
}

/* =============================================
   SIDEBAR (Mobile)
   ============================================= */
.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    z-index: 1000;
}

.sidebar {
    position: fixed;
    top: 0; left: -280px;
    width: 280px;
    height: 100vh;
    background: #111;
    z-index: 1001;
    transition: left 0.3s ease;
    overflow-y: auto;
    border-right: 1px solid var(--border);
}

.sidebar.open { left: 0; }

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: linear-gradient(135deg, #1a0a2e, #2d1b4e);
    border-bottom: 1px solid rgba(124,58,237,0.3);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-text {
    font-weight: 700;
    font-size: 16px;
    color: #fff;
}

.sidebar-close {
    background: none;
    border: none;
    color: #fff;
    font-size: 18px;
    cursor: pointer;
}

.sidebar-nav { padding: 8px 0; }

.sidebar-group {
    margin-top: 4px;
    border-top: 1px solid #222;
}

/* sidebar-group-title: see accordion section below */

.sidebar-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    color: var(--color-text);
    font-size: 13px;
    transition: background 0.2s, color 0.2s;
}

.sidebar-item.sub { padding-left: 32px; }

.sidebar-item:hover, .sidebar-item.active {
    background: rgba(0,200,200,0.1);
    color: var(--color-primary);
}

/* =============================================
   BOTTOM MOBILE NAV
   ============================================= */
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: var(--bottom-nav-height);
    background: #111;
    border-top: 1px solid var(--border);
    z-index: 700;
    overflow-x: auto;
    scrollbar-width: none;
}

.bottom-nav::-webkit-scrollbar { display: none; }

.bottom-nav {
    display: none;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    white-space: nowrap;
}

.bottom-nav-item {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    min-width: 70px;
    color: var(--color-muted);
    font-size: 10px;
    gap: 4px;
    transition: color 0.2s;
}

.bottom-nav-item i { font-size: 18px; }
.bottom-nav-item.active, .bottom-nav-item:hover { color: var(--color-primary); }

/* =============================================
   CARDS & WIDGETS
   ============================================= */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.card-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--color-primary);
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-bottom: 16px;
}

/* =============================================
   STAT BOXES
   ============================================= */
.stat-row {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.stat-box {
    flex: 1;
    min-width: 150px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 16px;
    text-align: center;
}

.stat-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1;
}

.stat-label {
    font-size: 11px;
    color: var(--color-muted);
    margin-top: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* =============================================
   DASHBOARD SPECIFIC
   ============================================= */
.welcome-text {
    color: var(--color-primary);
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 16px;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 20px;
    margin-bottom: 20px;
}

.revenue-chart-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.revenue-donut-container {
    position: relative;
    width: 200px;
    height: 200px;
}

.revenue-donut-label {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%,-50%);
    text-align: center;
}

.revenue-donut-label .pct {
    font-size: 20px;
    font-weight: 700;
    color: #fff;
}

.revenue-footer {
    display: flex;
    gap: 30px;
    margin-top: 16px;
    text-align: center;
}

.revenue-footer-item .label {
    font-size: 11px;
    color: var(--color-muted);
}

.revenue-footer-item .value {
    font-size: 14px;
    font-weight: 700;
    color: var(--color-text);
    margin-top: 2px;
}

.outstd-row {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
}

.outstd-box {
    flex: 1;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.outstd-icon {
    width: 40px; height: 40px;
    background: rgba(0,200,200,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    font-size: 18px;
}

.outstd-val { font-size: 24px; font-weight: 700; color: #fff; }
.outstd-lbl { font-size: 11px; color: var(--color-muted); }

.angka-tolak-box {
    flex: 0 0 auto;
    min-width: 200px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 14px 20px;
}

.angka-tolak-title { font-size: 13px; font-weight: 700; color: #fff; margin-bottom: 4px; }
.angka-tolak-val { font-size: 12px; color: var(--color-muted); }

/* =============================================
   FORM ELEMENTS
   ============================================= */
.form-group { margin-bottom: 16px; }

.form-label {
    display: block;
    font-size: 12px;
    color: var(--color-muted);
    margin-bottom: 6px;
}

.form-control {
    width: 100%;
    background: var(--bg-input);
    border: 1px solid #3a3a3a;
    color: var(--color-text);
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.form-control:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(0,200,200,0.15);
}

.form-control::placeholder { color: #555; }

select.form-control {
    appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23888' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

textarea.form-control { resize: vertical; min-height: 100px; }

.btn {
    display: inline-block;
    padding: 11px 24px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s;
    letter-spacing: 0.5px;
}

.btn-primary {
    background: var(--color-green);
    color: #fff;
    width: 100%;
}

.btn-primary:hover { background: #0ea574; }

.btn-danger {
    background: var(--color-accent);
    color: #fff;
    width: 100%;
}

.btn-danger:hover { background: #c62828; }

/* =============================================
   CUSTOM SELECT DROPDOWN
   ============================================= */
.custom-select-wrap {
    position: relative;
}

.custom-select-trigger {
    width: 100%;
    background: var(--bg-input);
    border: 1px solid #3a3a3a;
    color: var(--color-text);
    padding: 10px 36px 10px 14px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: border-color 0.2s;
}

.custom-select-trigger:hover, .custom-select-wrap.open .custom-select-trigger {
    border-color: var(--color-primary);
}

.custom-select-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0; right: 0;
    background: #222;
    border: 1px solid #3a3a3a;
    border-top: 2px solid var(--color-primary);
    border-radius: 0 0 6px 6px;
    z-index: 500;
    box-shadow: 0 8px 24px rgba(0,0,0,0.6);
}

.custom-select-wrap.open .custom-select-dropdown { display: block; }

.custom-select-search {
    padding: 8px;
    border-bottom: 1px solid #333;
}

.custom-select-search input {
    width: 100%;
    background: var(--bg-input);
    border: 1px solid #444;
    color: var(--color-text);
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 13px;
    outline: none;
}

.custom-select-option {
    padding: 10px 14px;
    cursor: pointer;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #ccc;
    transition: background 0.15s;
}

.custom-select-option:hover { background: rgba(0,200,200,0.1); color: var(--color-primary); }
.custom-select-option.selected { color: var(--color-primary); }
.custom-select-option .check-icon { color: var(--color-primary); }

/* =============================================
   EMPTY STATE
   ============================================= */
.empty-state {
    background: var(--bg-card);
    border: 1px solid rgba(229,57,53,0.5);
    border-radius: 8px;
    padding: 60px 30px;
    text-align: center;
    max-width: 500px;
    margin: 40px auto;
}

.empty-state-title {
    color: var(--color-primary);
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.empty-state-text {
    color: var(--color-muted);
    font-size: 13px;
    margin-bottom: 24px;
    line-height: 1.6;
}

/* =============================================
   PAGE TITLE
   ============================================= */
.page-title {
    color: var(--color-primary);
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #222;
}

/* =============================================
   SESSION CARD
   ============================================= */
.session-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-left: 4px solid var(--color-green);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 16px;
}

.session-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(16,185,129,0.15);
    color: var(--color-green);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 12px;
}

/* =============================================
   ALERT
   ============================================= */
.alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 16px;
    font-size: 13px;
}

.alert-success { background: rgba(16,185,129,0.1); border: 1px solid var(--color-green); color: var(--color-green); }
.alert-danger { background: rgba(229,57,53,0.1); border: 1px solid var(--color-accent); color: #ef5350; }
.alert-info { background: rgba(0,200,200,0.1); border: 1px solid var(--color-primary); color: var(--color-primary); }

/* =============================================
   TABLE
   ============================================= */
.table-wrap { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; font-size: 13px; }

th {
    background: #1e1e1e;
    color: var(--color-primary);
    padding: 10px 12px;
    text-align: left;
    font-size: 11px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border-bottom: 1px solid var(--border);
}

td {
    padding: 10px 12px;
    border-bottom: 1px solid #1e1e1e;
    color: var(--color-text);
}

tr:hover td { background: rgba(255,255,255,0.02); }

/* =============================================
   LOGIN PAGE
   ============================================= */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0d0d1a 0%, #1a0d0d 50%, #0d0d0d 100%);
    position: relative;
    overflow: hidden;
}

.login-bg-left {
    position: absolute;
    top: 0; left: 0;
    width: 40%;
    height: 100%;
    background: linear-gradient(135deg, #0a1628 0%, #0d2040 100%);
    clip-path: polygon(0 0, 70% 0, 100% 100%, 0 100%);
}

.login-bg-right {
    position: absolute;
    top: 0; right: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(135deg, #2a0a0a 0%, #1a0505 100%);
    clip-path: polygon(30% 0, 100% 0, 100% 100%, 0 100%);
}

/* Circuit board decorations */
.login-page::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(0,150,255,0.05) 0%, transparent 40%),
        radial-gradient(circle at 85% 50%, rgba(255,80,0,0.08) 0%, transparent 40%);
    pointer-events: none;
}

.login-box {
    position: relative;
    background: rgba(10,10,10,0.95);
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    padding: 48px 40px;
    width: 100%;
    max-width: 480px;
    z-index: 10;
    box-shadow: 0 20px 60px rgba(0,0,0,0.8);
}

.login-logo {
    text-align: center;
    margin-bottom: 36px;
}

.login-logo img { height: 60px; }

.login-logo-text {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 6px;
}

.login-logo-icon {
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, var(--color-purple), #4c1d95);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.login-logo-icon::before {
    content: 'S';
    font-size: 28px;
    font-weight: 900;
    color: #fff;
    font-style: italic;
}

.login-title {
    font-size: 24px;
    font-weight: 800;
    color: #fff;
    letter-spacing: 2px;
}

.login-subtitle {
    font-size: 12px;
    color: var(--color-orange);
    letter-spacing: 3px;
    font-weight: 600;
    text-transform: uppercase;
    text-align: center;
    margin-bottom: 32px;
}

.login-prompt {
    text-align: center;
    color: var(--color-muted);
    font-size: 13px;
    margin-bottom: 20px;
}

.login-input-wrap {
    position: relative;
    margin-bottom: 14px;
}

.login-input {
    width: 100%;
    background: #1e1e1e;
    border: 1px solid #333;
    color: #fff;
    padding: 13px 16px;
    border-radius: 6px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.login-input:focus { border-color: var(--color-primary); }
.login-input::placeholder { color: #555; }

.pw-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: #333;
    border: none;
    color: #888;
    width: 32px;
    height: 32px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.btn-login {
    width: 100%;
    background: var(--color-accent);
    color: #fff;
    border: none;
    padding: 14px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 1px;
    margin-top: 8px;
    transition: background 0.2s, transform 0.1s;
}

.btn-login:hover { background: #c62828; }
.btn-login:active { transform: scale(0.99); }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 768px) {
    .hamburger { display: flex; }
    .desktop-nav { display: none; }

    .main-content {
        margin-top: var(--banner-height);
        padding: 12px;
        padding-bottom: calc(var(--bottom-nav-height) + 16px);
    }

    .bottom-nav { display: flex; }

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

    .outstd-row { flex-direction: column; }
    .angka-tolak-box { min-width: unset; }

    .login-box { margin: 16px; padding: 32px 24px; }
    .login-bg-left, .login-bg-right { display: none; }
}

@media (max-width: 480px) {
    .stat-row { flex-direction: column; }
}

/* =============================================
   SCROLLBAR
   ============================================= */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #111; }
::-webkit-scrollbar-thumb { background: #333; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #555; }

/* =============================================
   SIDEBAR ACCORDION (collapsible groups)
   ============================================= */
.sidebar-group-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    font-size: 11px;
    font-weight: 700;
    color: var(--color-primary);
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    user-select: none;
    transition: background 0.2s;
}

.sidebar-group-title:hover { background: rgba(0,200,200,0.06); }

.sg-arrow {
    font-size: 10px;
    transition: transform 0.25s;
    color: #555;
}

.sidebar-sub {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.sidebar-sub.open { max-height: 400px; }

.sidebar-group-title.expanded .sg-arrow {
    transform: rotate(180deg);
}

/* =============================================
   MOBILE TOUCH FIXES
   ============================================= */
.sidebar-toggle,
.hamburger,
.sidebar-close,
.sidebar-item,
.bottom-nav-item,
.nav-item,
.btn,
.btn-login {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

/* Ensure sidebar-toggle is always tappable */
.sidebar-toggle {
    min-height: 44px;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

/* =============================================
   MOBILE RESPONSIVE IMPROVEMENTS
   ============================================= */

/* Top banner improvements */
.top-banner {
    padding: 0 12px;
    height: var(--banner-height);
}
.banner-time { gap: 6px; }
.clock { font-size: 16px !important; }

/* Bottom nav better touch targets */
.bottom-nav-item { padding: 8px 4px 6px; min-width: 52px; }
.bottom-nav-item span { font-size: 9px; }
.bottom-nav-item i { font-size: 17px; }

/* Main content mobile padding */
@media (max-width: 768px) {
    .main-content { padding: 10px 10px; }
    .top-banner { padding: 0 10px; }
    .banner-site-name { font-size: 13px; }
    .banner-sub { font-size: 9px; }
    .banner-logo img { height: 30px; }
}

/* ── Inbox mobile ── */
@media (max-width: 600px) {
    .inbox-layout { flex-direction: column !important; gap: 10px !important; }
    .manual-panel { width: 100% !important; min-width: unset !important; max-width: unset !important; }
    .inbox-table-wrap { overflow-x: auto; }
    .inbox-table th:nth-child(2),
    .inbox-table td:nth-child(2) { display: none; }
}

/* ── Dashboard mobile ── */
@media (max-width: 600px) {
    .stat-card { padding: 14px 12px; }
    .stat-value { font-size: 20px; }
    .chart-wrap { height: 180px !important; }
}

/* ── Generic table scroll on mobile ── */
@media (max-width: 768px) {
    .table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    table { min-width: 480px; }
}

/* ── Sidebar overlay improvements ── */
@media (max-width: 768px) {
    .sidebar-overlay { z-index: 1050; }
    .sidebar { max-width: 82vw; }
}

/* ── Rekap mobile improvements ── */
@media (max-width: 600px) {
    .rk-head { gap: 8px; }
    .rk-stats { font-size: 11px; line-height: 1.7; }
    .rk-tabs { gap: 0; }
    .rk-tab { padding: 8px 10px; font-size: 11px; }
    .rk-finput { width: 90px; }
    .rk-sort { font-size: 11px; padding: 6px 6px; }
}

/* ── Modal mobile full screen ── */
@media (max-width: 600px) {
    .mo { padding: 0; align-items: flex-end; }
    .mb { border-radius: 14px 14px 0 0; max-width: 100% !important; max-height: 92vh; overflow-y: auto; }
    .mbd { padding: 14px; }
    .mh { padding: 12px 14px; }
    .mf { padding: 10px 14px; }
}

/* ── Form inputs mobile ── */
@media (max-width: 480px) {
    input[type="text"], input[type="number"], input[type="password"],
    select, textarea { font-size: 16px !important; } /* prevent iOS zoom */
}

/* ── Sesi aktif mobile ── */
@media (max-width: 600px) {
    .sesi-info-grid { grid-template-columns: 1fr 1fr !important; }
    .sesi-actions { flex-direction: column !important; }
    .sesi-btn { width: 100%; }
}

/* ── Banner buttons (rtb) mobile ── */
@media (max-width: 480px) {
    .rtb { padding: 3px 7px; font-size: 8.5px; }
    .banner-time { gap: 4px; }
}
