*, *::before, *::after { box-sizing: border-box; }
.admin-body { background: #f4f4f4; margin: 0; font-family: Geneva, Tahoma, Verdana, Helvetica, arial, sans-serif; color: #222; overflow-x: hidden; }
.admin-sidebar { position: fixed; top: 0; left: 0; width: 200px; height: 100%; background: #424242; z-index: 30; overflow-y: auto; }
.admin-brand { display: block; padding: 14px 12px; color: #FBC503; font-weight: bold; text-decoration: none; border-bottom: 1px solid #333; }
.admin-sidebar nav a { display: block; color: #fff; text-decoration: none; padding: 10px 12px; }
.admin-sidebar nav a:hover { background: #333; }
.admin-sidebar nav a.on { background: #3c9; }
.admin-backdrop { display: none; }
.admin-wrap-main { margin-left: 200px; min-height: 100vh; overflow-x: hidden; }
.admin-bar { background: #fff; border-bottom: 1px solid #ddd; padding: 8px 16px; display: flex; align-items: center; gap: 10px; font-size: 0.95em; top: 0; z-index: 10; }
.admin-bar-btn { margin-left: auto; }
.admin-toggle { display: none; background: #176cee; color: #fff; border: 0; min-width: 44px; min-height: 44px; padding: 0 12px; cursor: pointer; font-size: 1.2em; line-height: 1; }
.admin-main { max-width: 960px; margin: 16px 20px 40px; }
.admin-wide .admin-main { max-width: none; }
.admin-wide .admin-table { font-size: 0.9em; }
.admin-cards { display: flex; gap: 10px; margin-bottom: 16px; }
.admin-card { background: #fff; border: 1px solid #ddd; padding: 12px 16px; flex: 1; }
.admin-card h3 { margin: 0 0 4px; font-size: 0.8em; color: #666; font-weight: normal; }
.admin-card .num { font-size: 1.6em; color: #176cee; }
.admin-actions { margin: 0; }
a.btn, input.btn, button.btn, .admin-login input[type=submit], .admin-form input[type=submit] {
    display: inline-block; background: #176cee; color: #fff; border: 0; padding: 8px 14px;
    text-decoration: none; cursor: pointer; font-size: 0.95em; line-height: 1.2;
}
.btn-ok {
    display: inline-flex; align-items: center; justify-content: center;
    width: 32px; height: 32px; padding: 0; border: 0; background: #176cee; color: #fff;
    cursor: pointer; font-size: 1.05em; line-height: 1;
}
.admin-table { width: 100%; background: #fff; border-collapse: collapse; }
.admin-table th { background: #424242; color: #fff; padding: 8px; text-align: left; font-weight: normal; }
.admin-table td { border: 1px solid #ddd; padding: 6px 8px; vertical-align: middle; }
.admin-input { width: 56px; text-align: center; padding: 4px; border: 1px solid #ccc; }
.msg { padding: 8px 10px; margin-bottom: 12px; }
.msg.ok { background: #d4edda; }
.msg.err { background: #f8d7da; }
.admin-empty { color: #666; }
.lead-bar { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.lead-bar a {
    display: inline-block; padding: 7px 12px; background: #fff; border: 1px solid #ccc;
    color: #333; text-decoration: none; font-size: 0.9em;
}
.lead-bar a.on { background: #176cee; color: #fff; border-color: #176cee; }
.lead-status-form { margin: 0; }
.lead-status { padding: 6px 8px; border: 1px solid #ccc; font-size: 0.9em; min-height: 36px; }
.lead-status.pending { background: #fff3cd; }
.lead-status.contacted { background: #d4edda; }
.col-sno { width: 52px; text-align: center; }
.admin-pager { display: flex; flex-wrap: nowrap; gap: 4px; margin: 0; align-items: center; }
.admin-pager a, .admin-pager span.off, .admin-pager .pager-gap {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 38px; height: 38px; padding: 0 8px; border-radius: 10px;
    border: 1px solid #e5e7eb; background: #fff; color: #222; text-decoration: none; font-size: 0.9em;
}
.admin-pager a:hover { background: #f3f4f6; }
.admin-pager a.on { background: #176cee; color: #fff; border-color: #176cee; font-weight: 700; }
.admin-pager span.off { color: #c5c5c5; cursor: default; background: #f7f7f7; }
.admin-pager .pager-gap { border: 0; background: transparent; min-width: 22px; color: #888; }
.admin-pager .pager-edge { font-size: 1.15em; line-height: 1; }
.admin-pager-wrap {
    display: flex; flex-wrap: nowrap; justify-content: space-between; align-items: center;
    gap: 12px; padding: 14px 16px; border-top: 1px solid #eee; background: #fff;
}
.admin-pager-right { display: flex; flex-wrap: nowrap; align-items: center; gap: 10px; margin-left: auto; }
.pager-info { font-size: 0.85em; color: #666; white-space: nowrap; }
.games-panel { background: #fff; border: 1px solid #e5e5e5; border-radius: 12px; overflow: hidden; }
.games-toolbar {
    display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center;
    gap: 10px; padding: 12px 14px; border-bottom: 1px solid #eee;
}
.games-meta { color: #555; font-size: 0.9em; }
.games-per-form { margin: 0; }
.games-per-form label {
    display: flex; align-items: center; gap: 8px; margin: 0; width: auto; font-size: 0.9em; font-weight: normal; color: #555;
}
.games-per-form select {
    min-height: 36px; padding: 6px 10px; border: 1px solid #ccc; border-radius: 8px; background: #fff; font-size: 0.95em;
}
.games-form { max-width: 560px; border-radius: 12px; }
.games-form-times { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.games-form-times label { margin-top: 10px; }
.main-pill {
    border: 0; border-radius: 999px; padding: 5px 12px; font-size: 0.8em; cursor: pointer; font-weight: 700;
}
.main-pill.on { background: #d4edda; color: #166534; }
.main-pill.off { background: #eee; color: #555; }
.admin-games-table { border: 0; }
.admin-games-table td { border-left: 0; border-right: 0; }
.admin-login, .admin-form { max-width: 320px; margin: 80px auto; background: #fff; padding: 24px; border: 1px solid #ddd; }
.admin-form { max-width: 420px; margin: 0 0 20px; }
.admin-login h1, .admin-form h1 { margin: 0 0 16px; font-size: 1.1em; }
.admin-login label, .admin-form label { display: block; margin: 10px 0 4px; font-size: 0.9em; }
.admin-login input[type=text], .admin-login input[type=password],
.admin-form input[type=text], .admin-form input[type=password], .admin-form textarea {
    width: 100%; padding: 8px; border: 1px solid #ccc; font-size: 1em;
}
.admin-form.admin-form-editor { max-width: 640px; }
.ad-editor { border: 1px solid #ccc; background: #fff; }
.ad-editor-bar {
    display: flex; flex-wrap: wrap; gap: 4px; padding: 6px; border-bottom: 1px solid #ddd; background: #f7f7f7;
}
.ad-editor-bar button, .ad-editor-bar select {
    min-height: 32px; border: 1px solid #ccc; background: #fff; cursor: pointer; padding: 4px 8px; font-size: 0.85em;
}
.ad-editor-bar button { font-weight: bold; }
.ad-editor-bar input[type=color] { width: 36px; height: 32px; padding: 0; border: 1px solid #ccc; background: #fff; }
.ad-editor-area { min-height: 160px; padding: 10px; outline: none; font-size: 1em; line-height: 1.5; }
.admin-login input[type=submit], .admin-form input[type=submit] { margin-top: 14px; width: 100%; }
.admin-table-title { margin: 0 0 8px; font-size: 1.1em; }
.admin-picks {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 4px 8px;
    max-height: 240px;
    overflow: auto;
    border: 1px solid #ddd;
    padding: 8px;
    background: #fafafa;
}
.admin-picks label { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 0.8em; }
.admin-picks input { width: auto; }
.admin-user-name { margin: 0 0 10px; font-weight: bold; }
.admin-form-check input { width: auto; }
.admin-row-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.admin-row-actions form { margin: 0; }
.admin-menu { position: relative; display: inline-flex; justify-content: flex-end; }
.admin-menu-btn {
    background: transparent; border: 0; cursor: pointer; color: #333;
    min-width: 36px; min-height: 36px; padding: 0; font-size: 1.35em; line-height: 1;
}
.admin-menu-list {
    position: fixed; z-index: 50; min-width: 148px; background: #fff;
    border: 1px solid #ddd; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.16);
}
.admin-menu-list[hidden] { display: none; }
.admin-menu-list a, .admin-menu-list button {
    display: block; width: 100%; box-sizing: border-box; text-align: left;
    background: none; border: 0; padding: 10px 14px; color: #222;
    text-decoration: none; cursor: pointer; font: inherit; font-size: 0.95em;
}
.admin-menu-list form { margin: 0; }
.admin-menu-list a:hover, .admin-menu-list button:hover { background: #f4f4f4; }
.game-row { cursor: pointer; }
.admin-games-table .col-game a { color: inherit; text-decoration: none; }
.admin-games-table .col-game a:hover { text-decoration: underline; }

@media (max-width: 800px) {
    .admin-sidebar {
        width: min(280px, 86vw);
        transform: translateX(-105%);
        transition: transform 0.2s ease;
        box-shadow: none;
    }
    .games-form-times { grid-template-columns: 1fr; }
    .admin-pager-wrap { justify-content: space-between; }
    .admin-sidebar.open {
        transform: translateX(0);
        box-shadow: 4px 0 16px rgba(0, 0, 0, 0.25);
    }
    .admin-sidebar nav a { min-height: 44px; padding: 12px 16px; display: flex; align-items: center; }
    .admin-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.4);
        z-index: 25;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.2s ease;
    }
    .admin-body.nav-open { overflow: hidden; }
    .admin-body.nav-open .admin-backdrop { opacity: 1; pointer-events: auto; }
    .admin-wrap-main { margin-left: 0; width: 100%; }
    .admin-toggle { display: inline-flex; align-items: center; justify-content: center; }
    .admin-bar { padding: 4px 6px; gap: 8px; }
    .admin-main { margin: 0; max-width: none; padding: 0; }
    .admin-table-title { margin: 6px 4px 4px; }
    .admin-cards { flex-direction: column; gap: 6px; margin: 8px; }
    .msg { margin: 6px 8px 8px; padding: 6px 8px; }
    .admin-empty { margin: 8px; }
    .admin-actions { margin: 8px; }
    .admin-login, .admin-form {
        max-width: none;
        width: auto;
        margin: 8px;
        padding: 12px;
    }
    .admin-form { margin: 8px; }
    .admin-login input[type=text], .admin-login input[type=password],
    .admin-form input[type=text], .admin-form input[type=password],
    .admin-login input[type=submit], .admin-form input[type=submit],
    a.btn, input.btn, button.btn {
        min-height: 44px;
        font-size: 16px;
    }
    .admin-table.admin-stack { display: block; background: transparent; border: 0; }
    .admin-table.admin-stack thead,
    .admin-table.admin-stack tr.admin-head { display: none; }
    .admin-table.admin-stack tbody { display: block; }
    .admin-table.admin-stack tr {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px 12px;
        background: #fff;
        border: 1px solid #ddd;
        margin-bottom: 8px;
        padding: 8px;
    }
    .admin-table.admin-stack td {
        border: 0;
        padding: 0;
        min-width: 0;
        overflow-wrap: anywhere;
    }
    .admin-table.admin-stack td[data-label]::before {
        content: attr(data-label);
        display: block;
        font-size: 0.75em;
        color: #666;
        margin-bottom: 4px;
    }
    .admin-table.admin-stack .col-game { grid-column: 1 / -1; font-weight: bold; font-size: 1.05em; }
    .admin-table.admin-stack .col-time { grid-column: 1 / -1; color: #555; font-size: 0.9em; }
    .admin-table.admin-stack .col-yday,
    .admin-table.admin-stack .col-today { min-width: 0; }
    .col-imp { display: flex; align-items: flex-end; }
    .admin-table.admin-stack .col-act { grid-column: 1 / -1; }
    .admin-table.admin-stack .col-act .btn,
    .admin-table.admin-stack .col-act input.btn { width: 100%; }
    .admin-table.admin-stack .admin-input {
        width: 100%;
        min-height: 44px;
        font-size: 16px;
        text-align: center;
    }
    .admin-table-scroll {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 0;
        padding: 0;
    }
    .admin-results-table {
        display: table;
        table-layout: fixed;
        width: 100%;
        min-width: 0;
        background: #fff;
    }
    .admin-results-table tr.admin-head { display: table-row; }
    .admin-results-table th,
    .admin-results-table td {
        padding: 4px 2px;
        white-space: nowrap;
        vertical-align: middle;
        border-left: 0;
        border-right: 0;
    }
    .admin-results-table th:first-child,
    .admin-results-table td:first-child { padding-left: 4px; }
    .admin-results-table th:last-child,
    .admin-results-table td:last-child { padding-right: 4px; }
    .admin-results-table th:first-child,
    .admin-results-table .col-game {
        position: sticky;
        left: 0;
        z-index: 1;
        width: 46%;
        max-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        font-size: 0.82em;
        background: #fff;
    }
    .admin-results-table th:first-child { background: #424242; z-index: 2; }
    .admin-results-table .col-yday,
    .admin-results-table .col-today { width: 18%; text-align: center; }
    .admin-results-table .col-act,
    .admin-results-table th:last-child {
        width: 52px;
        text-align: center;
        padding: 4px 2px;
        font-size: 0.75em;
    }
    .admin-results-table .admin-input {
        width: 40px;
        min-height: 40px;
        padding: 4px 2px;
        font-size: 16px;
    }
    .admin-results-table .btn-ok {
        width: 40px;
        height: 40px;
        min-height: 40px;
        font-size: 1.15em;
    }
    .admin-games-table {
        display: table;
        width: 100%;
        min-width: 0;
        background: #fff;
        table-layout: auto;
    }
    .admin-games-table tr.admin-head { display: table-row; }
    .admin-games-table th,
    .admin-games-table td {
        padding: 4px 3px;
        white-space: nowrap;
        font-size: 0.78em;
        vertical-align: middle;
    }
    .admin-games-table .col-game {
        max-width: 7.5em;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    .admin-games-table .col-act { width: 36px; text-align: center; padding: 2px; }
    .admin-games-table .col-imp { display: table-cell; }
    .admin-games-table .col-imp .btn {
        min-height: 32px;
        padding: 2px 6px;
        font-size: 0.85em;
        width: auto;
    }
    .admin-row-actions { width: 100%; }
    .admin-row-actions .btn, .admin-row-actions input.btn { flex: 1; min-height: 44px; }
    .admin-actions a.btn { width: 100%; text-align: center; }
    .admin-table.admin-stack td { overflow-wrap: anywhere; }
    td.col-imp:empty { display: none; }
    .admin-form-check { min-height: 44px; }
    .msg-body { grid-column: 1 / -1; }
    .admin-menu-btn { min-width: 44px; min-height: 44px; }
    .admin-menu-list a, .admin-menu-list button { min-height: 44px; }
}

/* ==========================================================================
   Khaiwal Ads Admin Styling & Separate Number Section
   ========================================================================== */
.admin-number-card {
    background: #f0f7ff;
    border: 2px solid #2563eb;
    border-radius: 8px;
    padding: 14px 16px;
    margin: 16px 0;
}
.number-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #1e40af;
    font-size: 1.05em;
    margin-bottom: 6px;
}
.number-card-header .badge-required {
    background: #fef08a;
    color: #854d0e;
    font-size: 0.75em;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: bold;
    margin-left: auto;
}
.number-card-desc {
    margin: 0 0 12px 0;
    font-size: 0.88em;
    color: #4b5563;
    line-height: 1.4;
}
.phone-input-wrap {
    display: flex;
    align-items: center;
    gap: 0;
    margin-top: 4px;
}
.phone-input-wrap .input-prefix {
    background: #e5e7eb;
    border: 1px solid #ccc;
    border-right: 0;
    padding: 8px 10px;
    font-size: 0.95em;
    font-weight: bold;
    color: #374151;
    border-radius: 4px 0 0 4px;
    white-space: nowrap;
}
.phone-input-wrap input {
    border-radius: 0 4px 4px 0 !important;
}
.phone-preview-box {
    margin-top: 12px;
    background: #ffffff;
    border: 1px dashed #3b82f6;
    border-radius: 6px;
    padding: 10px 12px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.phone-preview-box .preview-item {
    display: flex;
    align-items: center;
    gap: 8px;
}
.phone-preview-box .preview-lbl {
    font-size: 0.82em;
    color: #6b7280;
}
.phone-preview-box .preview-val {
    font-size: 1.15em;
    color: #111827;
    font-family: monospace;
}
.phone-preview-box .preview-actions {
    display: flex;
    gap: 6px;
}
.preview-btn-wa {
    background: #25d366 !important;
    color: #fff !important;
    font-size: 0.82em !important;
    padding: 5px 10px !important;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
}
.preview-btn-call {
    background: #1f2937 !important;
    color: #f3f4f6 !important;
    font-size: 0.82em !important;
    padding: 5px 10px !important;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
}
.col-num-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #eff6ff;
    border: 1px solid #93c5fd;
    color: #1e3a8a;
    font-weight: bold;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.95em;
}
.num-actions-mini {
    display: flex;
    gap: 4px;
    margin-top: 4px;
}
.num-actions-mini a {
    font-size: 0.75em;
    padding: 2px 6px;
    border-radius: 3px;
    text-decoration: none;
    font-weight: 600;
}
.wa-pill-mini { background: #dcfce7; color: #166534; border: 1px solid #86efac; }
.call-pill-mini { background: #f3f4f6; color: #1f2937; border: 1px solid #d1d5db; }

/* ==========================================================================
   Other Ads / Sponsor Notice Admin Styling
   ========================================================================== */
.other-ads-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: start;
}
@media (max-width: 800px) {
    .other-ads-container {
        grid-template-columns: 1fr;
    }
}
.other-ads-preview-wrap {
    background: #0a0c12;
    border: 2px solid #ffd800;
    border-radius: 14px;
    padding: 20px;
    color: #fff;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    position: sticky;
    top: 20px;
}
.other-ads-preview-title {
    font-size: 0.82em;
    color: #ffd800;
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 0.08em;
    margin-bottom: 12px;
    border-bottom: 1px dashed rgba(255, 216, 0, 0.3);
    padding-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.other-ads-preview-wrap .sponsor-notice-card {
    background: #121520;
    border: 2px dashed #ffd800;
    border-radius: 14px;
    padding: 20px 16px;
    text-align: center;
}
.other-ads-preview-wrap .sponsor-title {
    font-size: 1.35rem;
    font-weight: 800;
    color: #ffd800;
    margin-bottom: 4px;
}
.other-ads-preview-wrap .sponsor-text {
    font-size: 0.95rem;
    color: #e2e8f0;
    font-weight: 600;
    margin-bottom: 6px;
}
.other-ads-preview-wrap .sponsor-contact-name {
    font-size: 1.15rem;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: 0.08em;
    margin: 8px 0;
}
.other-ads-preview-wrap .sponsor-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 12px 0 10px;
}
.other-ads-preview-wrap .btn-sponsor {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    border-radius: 30px;
    font-size: 0.88rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s ease;
}
.other-ads-preview-wrap .btn-wa {
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
    color: #fff !important;
}
.other-ads-preview-wrap .btn-tg {
    background: linear-gradient(135deg, #0088cc 0%, #006699 100%);
    color: #fff !important;
}
.other-ads-preview-wrap .sponsor-note {
    font-size: 0.8rem;
    color: #cbd5e1;
    margin-top: 10px;
    line-height: 1.4;
}


