/* ==========================================================================
   MSC Meeting Scheduler — Arabic (RTL) Dashboard
   Standalone stylesheet. The public pages keep using css/styles.css.
   ========================================================================== */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-soft: #eff6ff;
    --success: #10b981;
    --success-soft: #ecfdf5;
    --warning: #f59e0b;
    --warning-soft: #fffbeb;
    --danger: #ef4444;
    --danger-soft: #fef2f2;

    --bg: #f1f5f9;
    --surface: #ffffff;
    --surface-2: #f8fafc;

    --text: #0f172a;
    --text-2: #475569;
    --text-muted: #94a3b8;
    --on-primary: #ffffff;

    --border: #e2e8f0;
    --border-strong: #cbd5e1;

    --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06);
    --shadow-md: 0 4px 12px rgba(15, 23, 42, .08);
    --shadow-lg: 0 12px 32px rgba(15, 23, 42, .12);

    --r-sm: 8px;
    --r-md: 12px;
    --r-lg: 16px;
    --r-xl: 22px;

    --sidebar-w: 264px;
    --topbar-h: 66px;

    --font: 'Cairo', 'Tajawal', 'Segoe UI', system-ui, -apple-system, sans-serif;
}

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

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.65;
    min-height: 100vh;
}

/* Latin data (emails, times, ids) must stay LTR inside RTL text */
.ltr {
    direction: ltr;
    unicode-bidi: isolate;
    text-align: right;
}

.hidden {
    display: none !important;
}

a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    font-family: inherit;
    font-size: .95rem;
    font-weight: 600;
    line-height: 1.2;
    padding: .7rem 1.25rem;
    border: 1px solid transparent;
    border-radius: var(--r-sm);
    cursor: pointer;
    transition: all .18s ease;
    white-space: nowrap;
    background: none;
}

.btn:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.btn-primary {
    background: var(--primary);
    color: var(--on-primary);
    box-shadow: var(--shadow-sm);
}

.btn-primary:not(:disabled):hover {
    background: var(--primary-dark);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--surface);
    color: var(--text-2);
    border-color: var(--border-strong);
}

.btn-secondary:not(:disabled):hover {
    background: var(--surface-2);
    color: var(--text);
    border-color: var(--text-muted);
}

.btn-ghost {
    background: transparent;
    color: var(--text-2);
}

.btn-ghost:not(:disabled):hover {
    background: var(--surface-2);
    color: var(--text);
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-danger:not(:disabled):hover {
    background: #dc2626;
}

.btn-sm {
    padding: .45rem .85rem;
    font-size: .85rem;
}

.btn-lg {
    padding: .9rem 1.75rem;
    font-size: 1.02rem;
}

.btn-block {
    width: 100%;
}

.btn-icon {
    padding: .45rem;
    width: 34px;
    height: 34px;
    border-radius: var(--r-sm);
    color: var(--text-muted);
}

.btn-icon:hover {
    background: var(--surface-2);
    color: var(--text);
}

.btn-icon.danger:hover {
    background: var(--danger-soft);
    color: var(--danger);
}

/* ==========================================================================
   Forms
   ========================================================================== */

.field {
    margin-bottom: 1.1rem;
}

.field-label {
    display: block;
    font-size: .9rem;
    font-weight: 600;
    color: var(--text-2);
    margin-bottom: .4rem;
}

.field-label .req {
    color: var(--danger);
}

.field-hint {
    font-size: .82rem;
    color: var(--text-muted);
    margin-top: .35rem;
    line-height: 1.5;
}

.input,
.select,
.textarea {
    width: 100%;
    font-family: inherit;
    font-size: .95rem;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-sm);
    padding: .65rem .85rem;
    transition: border-color .15s ease, box-shadow .15s ease;
}

.input:focus,
.select:focus,
.textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}

.input::placeholder {
    color: var(--text-muted);
}

.textarea {
    resize: vertical;
    min-height: 84px;
}

.field-error {
    display: block;
    font-size: .85rem;
    color: var(--danger);
    margin-top: .4rem;
}

.field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* Colour picker */
.swatches {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.swatch {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 3px solid transparent;
    cursor: pointer;
    transition: transform .15s ease;
}

.swatch:hover {
    transform: scale(1.12);
}

.swatch.selected {
    border-color: var(--text);
    transform: scale(1.12);
}

/* Member assignment checkboxes */
.check-list {
    display: flex;
    flex-direction: column;
    gap: .25rem;
    max-height: 260px;
    overflow-y: auto;
    border: 1px solid var(--border);
    border-radius: var(--r-sm);
    padding: .5rem;
    background: var(--surface-2);
}

.check-row {
    display: flex;
    align-items: center;
    gap: .7rem;
    padding: .55rem .7rem;
    border-radius: var(--r-sm);
    cursor: pointer;
    transition: background .15s ease;
}

.check-row:hover {
    background: var(--surface);
}

.check-row input {
    width: 17px;
    height: 17px;
    accent-color: var(--primary);
    cursor: pointer;
    flex-shrink: 0;
}

.check-row .who {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.check-row .who strong {
    font-size: .92rem;
    font-weight: 600;
}

.check-row .who span {
    font-size: .8rem;
    color: var(--text-muted);
}

/* ==========================================================================
   Login
   ========================================================================== */

.login-wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: linear-gradient(140deg, #1e3a8a 0%, #2563eb 55%, #3b82f6 100%);
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: var(--surface);
    border-radius: var(--r-xl);
    box-shadow: var(--shadow-lg);
    padding: 2.5rem 2rem;
    text-align: center;
}

.login-card .brand {
    font-size: 2.6rem;
    line-height: 1;
    margin-bottom: .75rem;
}

.login-card h1 {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: .35rem;
}

.login-card .sub {
    color: var(--text-muted);
    font-size: .92rem;
    margin-bottom: 1.75rem;
}

.login-card form {
    text-align: right;
}

.login-foot {
    margin-top: 1.5rem;
    font-size: .85rem;
    color: var(--text-muted);
}

/* ==========================================================================
   App shell
   ========================================================================== */

.topbar {
    position: fixed;
    top: 0;
    inset-inline: 0;
    height: var(--topbar-h);
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.25rem;
    gap: 1rem;
    z-index: 60;
}

.topbar .brand {
    display: flex;
    align-items: center;
    gap: .6rem;
    font-weight: 800;
    font-size: 1.05rem;
}

.topbar .brand .mark {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--primary), #60a5fa);
    color: #fff;
    display: grid;
    place-items: center;
    font-size: 1.1rem;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: .6rem;
}

/* Identity reads as plain text next to the avatar — no pill, no border. */
.user-chip {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-inline-end: .35rem;
}

.user-chip .who {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
    text-align: start;
}

.user-chip .who strong {
    font-size: .88rem;
    font-weight: 700;
}

.user-chip .who span {
    font-size: .74rem;
    color: var(--text-muted);
}

.avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--primary-soft);
    color: var(--primary-dark);
    display: grid;
    place-items: center;
    font-weight: 800;
    font-size: .95rem;
    flex-shrink: 0;
}

.menu-toggle {
    display: none;
}

/* Sidebar */
.sidebar {
    position: fixed;
    top: var(--topbar-h);
    inset-inline-start: 0;
    width: var(--sidebar-w);
    height: calc(100vh - var(--topbar-h));
    background: var(--surface);
    border-inline-end: 1px solid var(--border);
    padding: 1.25rem .85rem;
    overflow-y: auto;
    z-index: 50;
}

.nav-group-label {
    font-size: .74rem;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: .04em;
    padding: 0 .75rem;
    margin: 1.25rem 0 .5rem;
}

.nav-group-label:first-child {
    margin-top: 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: .75rem;
    width: 100%;
    padding: .7rem .8rem;
    border: none;
    background: none;
    border-radius: var(--r-sm);
    font-family: inherit;
    font-size: .95rem;
    font-weight: 600;
    color: var(--text-2);
    cursor: pointer;
    text-align: start;
    transition: all .15s ease;
    margin-bottom: .15rem;
}

.nav-item:hover {
    background: var(--surface-2);
    color: var(--text);
}

.nav-item.active {
    background: var(--primary-soft);
    color: var(--primary-dark);
}

.nav-item .ico {
    font-size: 1.15rem;
    width: 1.5rem;
    text-align: center;
    flex-shrink: 0;
}

.nav-item .badge {
    margin-inline-start: auto;
    background: var(--border);
    color: var(--text-2);
    font-size: .74rem;
    font-weight: 700;
    padding: .1rem .5rem;
    border-radius: 999px;
}

.nav-item.active .badge {
    background: var(--primary);
    color: #fff;
}

.sidebar-note {
    margin-top: 1.5rem;
    padding: .9rem;
    background: var(--primary-soft);
    border-radius: var(--r-md);
    font-size: .82rem;
    color: #1e40af;
    line-height: 1.6;
}

/* Main */
.main {
    margin-top: var(--topbar-h);
    margin-inline-start: var(--sidebar-w);
    padding: 1.75rem;
    min-height: calc(100vh - var(--topbar-h));
}

.view {
    display: none;
    animation: fade .25s ease;
}

.view.active {
    display: block;
}

@keyframes fade {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.view-head {
    margin-bottom: 1.5rem;
}

.view-head h1 {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: .25rem;
}

.view-head p {
    color: var(--text-2);
    font-size: .95rem;
    max-width: 68ch;
}

.backdrop {
    display: none;
}

/* ==========================================================================
   Cards
   ========================================================================== */

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-sm);
    padding: 1.4rem;
    margin-bottom: 1.4rem;
}

.card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1.1rem;
}

.card-head h2 {
    display: flex;
    align-items: center;
    gap: .55rem;
    font-size: 1.12rem;
    font-weight: 700;
}

/* The one-line explanation under every card title — the core of the
   "guided" dashboard: every section says what it is for. */
.card-hint {
    font-size: .87rem;
    color: var(--text-2);
    margin-top: .3rem;
    line-height: 1.6;
    max-width: 72ch;
}

.card-actions {
    display: flex;
    gap: .5rem;
    flex-wrap: wrap;
}

/* ==========================================================================
   Guided next-steps tracker
   ========================================================================== */

.guide {
    background: linear-gradient(135deg, #1e3a8a, #2563eb);
    color: #fff;
    border-radius: var(--r-lg);
    padding: 1.5rem;
    margin-bottom: 1.4rem;
    box-shadow: var(--shadow-md);
}

.guide h2 {
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: .3rem;
}

.guide .guide-sub {
    font-size: .9rem;
    opacity: .85;
    margin-bottom: 1.25rem;
}

.steps {
    display: flex;
    flex-direction: column;
    gap: .6rem;
}

.step {
    display: flex;
    align-items: center;
    gap: .9rem;
    padding: .85rem 1rem;
    border-radius: var(--r-md);
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .14);
    transition: background .18s ease;
}

.step.done {
    background: rgba(255, 255, 255, .06);
    border-color: transparent;
}

.step.current {
    background: rgba(255, 255, 255, .96);
    color: var(--text);
    border-color: transparent;
    box-shadow: var(--shadow-md);
}

.step .num {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-weight: 800;
    font-size: .88rem;
    flex-shrink: 0;
    background: rgba(255, 255, 255, .2);
}

.step.done .num {
    background: var(--success);
    color: #fff;
}

.step.current .num {
    background: var(--primary);
    color: #fff;
}

.step .txt {
    flex: 1;
    min-width: 0;
}

.step .txt strong {
    display: block;
    font-size: .96rem;
    font-weight: 700;
}

.step .txt span {
    font-size: .83rem;
    opacity: .82;
    line-height: 1.5;
}

.step.current .txt span {
    color: var(--text-2);
    opacity: 1;
}

.step.done .txt {
    opacity: .6;
}

.step .btn {
    flex-shrink: 0;
}

/* Inline call-to-action banner used inside views */
.cta-banner {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.15rem;
    background: var(--warning-soft);
    border: 1px solid #fde68a;
    border-radius: var(--r-md);
    margin-bottom: 1.4rem;
}

.cta-banner .ico {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.cta-banner .txt {
    flex: 1;
    min-width: 0;
}

.cta-banner .txt strong {
    display: block;
    font-size: .95rem;
    color: #92400e;
}

.cta-banner .txt span {
    font-size: .86rem;
    color: #b45309;
    line-height: 1.55;
}

.cta-banner.info {
    background: var(--primary-soft);
    border-color: #bfdbfe;
}

.cta-banner.info .txt strong {
    color: #1e40af;
}

.cta-banner.info .txt span {
    color: #1d4ed8;
}

/* ==========================================================================
   Stats
   ========================================================================== */

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
    margin-bottom: 1.4rem;
}

.stat {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    padding: 1.15rem;
    display: flex;
    align-items: center;
    gap: .9rem;
}

.stat .ico {
    width: 46px;
    height: 46px;
    border-radius: var(--r-md);
    display: grid;
    place-items: center;
    font-size: 1.3rem;
    background: var(--primary-soft);
    flex-shrink: 0;
}

.stat.ok .ico {
    background: var(--success-soft);
}

.stat.warn .ico {
    background: var(--warning-soft);
}

.stat .val {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.1;
}

.stat .lbl {
    font-size: .85rem;
    color: var(--text-muted);
}

/* ==========================================================================
   Page (booking page) cards
   ========================================================================== */

.page-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

.page-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-inline-start: 4px solid var(--primary);
    border-radius: var(--r-md);
    padding: 1.15rem;
    transition: box-shadow .18s ease, transform .18s ease;
}

.page-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.page-card .top {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    margin-bottom: .75rem;
}

.page-card .emoji {
    font-size: 1.6rem;
    line-height: 1;
}

.page-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.4;
}

.page-card .desc {
    font-size: .85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.page-card .meta {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin: .85rem 0;
}

.page-card .row-actions {
    display: flex;
    gap: .4rem;
    flex-wrap: wrap;
    padding-top: .85rem;
    border-top: 1px solid var(--border);
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    font-size: .78rem;
    font-weight: 600;
    padding: .22rem .6rem;
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--text-2);
    border: 1px solid var(--border);
}

.pill.ok {
    background: var(--success-soft);
    color: #047857;
    border-color: #a7f3d0;
}

.pill.warn {
    background: var(--warning-soft);
    color: #b45309;
    border-color: #fde68a;
}

.pill.info {
    background: var(--primary-soft);
    color: #1d4ed8;
    border-color: #bfdbfe;
}

.pill.muted {
    color: var(--text-muted);
}

/* Role badges */
.role-badge {
    font-size: .74rem;
    font-weight: 700;
    padding: .18rem .55rem;
    border-radius: 999px;
    white-space: nowrap;
}

.role-admin {
    background: #ede9fe;
    color: #6d28d9;
}

.role-hr_head {
    background: var(--primary-soft);
    color: #1d4ed8;
}

.role-hr_member {
    background: var(--success-soft);
    color: #047857;
}

/* ==========================================================================
   Tables
   ========================================================================== */

.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--r-md);
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: .9rem;
    min-width: 640px;
}

thead th {
    background: var(--surface-2);
    font-size: .8rem;
    font-weight: 700;
    color: var(--text-2);
    text-align: start;
    padding: .8rem 1rem;
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}

tbody td {
    padding: .8rem 1rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

tbody tr:last-child td {
    border-bottom: none;
}

tbody tr:hover {
    background: var(--surface-2);
}

.cell-actions {
    display: flex;
    gap: .25rem;
}

.muted {
    color: var(--text-muted);
}

/* Filter tabs */
.tabs {
    display: flex;
    gap: .4rem;
    flex-wrap: wrap;
    margin-bottom: 1.1rem;
}

.tab {
    font-family: inherit;
    font-size: .87rem;
    font-weight: 600;
    padding: .45rem .9rem;
    border-radius: 999px;
    border: 1px solid var(--border-strong);
    background: var(--surface);
    color: var(--text-2);
    cursor: pointer;
    transition: all .15s ease;
    display: inline-flex;
    align-items: center;
    gap: .4rem;
}

.tab:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.tab.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

.tab .count {
    background: rgba(0, 0, 0, .08);
    border-radius: 999px;
    padding: 0 .4rem;
    font-size: .78rem;
}

.tab.active .count {
    background: rgba(255, 255, 255, .25);
}

/* ==========================================================================
   Empty states — every one is a call to action, never a dead end
   ========================================================================== */

.empty {
    text-align: center;
    padding: 2.75rem 1.5rem;
    border: 2px dashed var(--border-strong);
    border-radius: var(--r-md);
    background: var(--surface-2);
}

.empty .ico {
    font-size: 2.6rem;
    margin-bottom: .75rem;
    opacity: .75;
}

.empty h3 {
    font-size: 1.08rem;
    font-weight: 700;
    margin-bottom: .4rem;
}

.empty p {
    color: var(--text-2);
    font-size: .9rem;
    max-width: 46ch;
    margin: 0 auto 1.25rem;
    line-height: 1.65;
}

/* ==========================================================================
   Modals
   ========================================================================== */

.modal {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .55);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    z-index: 100;
    backdrop-filter: blur(3px);
}

.modal.open {
    display: flex;
}

.modal-box {
    background: var(--surface);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 520px;
    max-height: 92vh;
    overflow-y: auto;
    animation: pop .2s ease;
}

.modal-box.wide {
    max-width: 640px;
}

@keyframes pop {
    from {
        opacity: 0;
        transform: scale(.96) translateY(8px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.15rem 1.4rem;
    border-bottom: 1px solid var(--border);
}

.modal-head h3 {
    font-size: 1.1rem;
    font-weight: 700;
}

.modal-body {
    padding: 1.4rem;
}

.modal-intro {
    font-size: .88rem;
    color: var(--text-2);
    background: var(--surface-2);
    border-inline-start: 3px solid var(--primary);
    padding: .75rem .9rem;
    border-radius: var(--r-sm);
    margin-bottom: 1.25rem;
    line-height: 1.65;
}

.modal-foot {
    display: flex;
    justify-content: flex-end;
    gap: .6rem;
    padding: 1.1rem 1.4rem;
    border-top: 1px solid var(--border);
    background: var(--surface-2);
    border-radius: 0 0 var(--r-lg) var(--r-lg);
}

.close-x {
    background: none;
    border: none;
    font-size: 1.4rem;
    line-height: 1;
    color: var(--text-muted);
    cursor: pointer;
    padding: .25rem .5rem;
    border-radius: var(--r-sm);
}

.close-x:hover {
    background: var(--surface-2);
    color: var(--text);
}

/* ==========================================================================
   Toasts, spinner, misc
   ========================================================================== */

.toasts {
    position: fixed;
    bottom: 1.25rem;
    inset-inline-start: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: .6rem;
    z-index: 200;
    max-width: min(400px, calc(100vw - 2.5rem));
}

.toast {
    display: flex;
    align-items: flex-start;
    gap: .7rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-inline-start: 4px solid var(--primary);
    border-radius: var(--r-md);
    box-shadow: var(--shadow-lg);
    padding: .85rem 1rem;
    font-size: .9rem;
    animation: slide .22s ease;
}

@keyframes slide {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.toast.success {
    border-inline-start-color: var(--success);
}

.toast.error {
    border-inline-start-color: var(--danger);
}

.toast.warning {
    border-inline-start-color: var(--warning);
}

.spinner {
    display: inline-block;
    width: 15px;
    height: 15px;
    border: 2px solid currentColor;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin .7s linear infinite;
    vertical-align: -2px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-row {
    text-align: center;
    padding: 2rem;
    color: var(--text-muted);
}

/* WhatsApp shortcut on booked candidates */
.wa-link {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
}

.wa-link:hover {
    color: #128c4a;
    text-decoration: none;
}

.wa-badge {
    display: inline-grid;
    place-items: center;
    width: 21px;
    height: 21px;
    border-radius: 50%;
    background: #25d366;
    color: #fff;
    font-size: .7rem;
    flex-shrink: 0;
}

.wa-link:hover .wa-badge {
    background: #128c4a;
}

/* Copyable booking link */
.copy-field {
    display: flex;
    gap: .5rem;
    align-items: stretch;
}

.copy-field .input {
    font-size: .82rem;
    direction: ltr;
    text-align: left;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 1024px) {
    .menu-toggle {
        display: inline-flex;
    }

    .sidebar {
        transform: translateX(100%);
        transition: transform .25s ease;
        box-shadow: var(--shadow-lg);
    }

    .sidebar.open {
        transform: none;
    }

    .main {
        margin-inline-start: 0;
    }

    .backdrop.show {
        display: block;
        position: fixed;
        inset: var(--topbar-h) 0 0 0;
        background: rgba(15, 23, 42, .45);
        z-index: 45;
    }
}

@media (max-width: 640px) {
    .main {
        padding: 1.1rem;
    }

    .topbar {
        padding: 0 .85rem;
    }

    .topbar .brand span:not(.mark) {
        display: none;
    }

    .user-chip .who {
        display: none;
    }

    .user-chip {
        margin-inline-end: 0;
    }

    .field-row {
        grid-template-columns: 1fr;
    }

    .view-head h1 {
        font-size: 1.28rem;
    }

    .step {
        flex-wrap: wrap;
    }

    .step .btn {
        width: 100%;
    }

    .card {
        padding: 1.1rem;
    }

    .guide {
        padding: 1.15rem;
    }

    .toasts {
        inset-inline: .75rem;
        bottom: .75rem;
        max-width: none;
    }
}
