/* =========================================================================
   Design tokens
   ========================================================================= */
:root {
    --brand: #4f46e5;
    --brand-dark: #3730a3;
    --accent: #a5b4fc;
    --sidebar-w: 280px;
    --sidebar-bg: linear-gradient(180deg, #1e1b4b 0%, #111827 100%);
    --hero-bg: linear-gradient(120deg, #4338ca 0%, #6d28d9 55%, #db2777 120%);
    --page-bg: #f3f5fb;
    --line: #e7eaf3;
    --radius: 18px;
    --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 6px 20px rgba(15, 23, 42, .05);
    --shadow-lg: 0 14px 34px rgba(15, 23, 42, .12);
}

/* Team panel: teal identity */
.panel-team {
    --brand: #0d9488;
    --brand-dark: #0f766e;
    --accent: #5eead4;
    --sidebar-bg: linear-gradient(180deg, #073b3a 0%, #0f172a 100%);
    --hero-bg: linear-gradient(120deg, #0f766e 0%, #0891b2 60%, #6366f1 130%);
}

body {
    font-family: 'Cairo', system-ui, -apple-system, 'Segoe UI', sans-serif;
    background: var(--page-bg);
    color: #1e293b;
}

.min-w-0 { min-width: 0; }
[hidden] { display: none !important; }

/* Bootstrap refinements */
.card { border-radius: var(--radius); }
.card > .card-header:first-child { border-radius: var(--radius) var(--radius) 0 0; }
.card-header { border-bottom-color: var(--line); padding: .9rem 1.1rem; }
.shadow-sm { box-shadow: var(--shadow) !important; }
.btn { border-radius: 12px; }
.btn-sm { border-radius: 10px; }
.form-control, .form-select { border-radius: 12px; border-color: #dbe1ec; }
.form-control:focus, .form-select:focus { border-color: var(--brand); box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--brand) 18%, transparent); }
.btn-primary {
    --bs-btn-bg: var(--brand); --bs-btn-border-color: var(--brand);
    --bs-btn-hover-bg: var(--brand-dark); --bs-btn-hover-border-color: var(--brand-dark);
    --bs-btn-active-bg: var(--brand-dark); --bs-btn-active-border-color: var(--brand-dark);
}
.table > thead th { color: #64748b; font-weight: 600; font-size: .8rem; white-space: nowrap; background: #f8fafc; }
.list-group-item { border-color: #f1f4f9; }
.dropdown-menu { border-radius: 16px; }

/* =========================================================================
   Icon tiles (sidebar, KPIs, alerts…)
   ========================================================================= */
.icon-tile {
    width: 36px; height: 36px; flex-shrink: 0; border-radius: 11px;
    display: inline-flex; align-items: center; justify-content: center;
    color: #fff; font-size: 1rem;
}
.icon-tile-lg { width: 50px; height: 50px; border-radius: 15px; font-size: 1.35rem; }
.tile-indigo  { background: linear-gradient(135deg, #818cf8, #4f46e5); }
.tile-sky     { background: linear-gradient(135deg, #7dd3fc, #0284c7); }
.tile-teal    { background: linear-gradient(135deg, #5eead4, #0d9488); }
.tile-emerald { background: linear-gradient(135deg, #6ee7b7, #059669); }
.tile-amber   { background: linear-gradient(135deg, #fcd34d, #d97706); }
.tile-rose    { background: linear-gradient(135deg, #fda4af, #e11d48); }
.tile-violet  { background: linear-gradient(135deg, #c4b5fd, #7c3aed); }
.tile-lime    { background: linear-gradient(135deg, #bef264, #65a30d); }
.tile-slate   { background: linear-gradient(135deg, #cbd5e1, #475569); }

/* =========================================================================
   Layout: floating sidebar + main
   ========================================================================= */
.app-shell { display: flex; min-height: 100vh; }
.app-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.app-content { padding: 20px 14px 32px; flex: 1; }
@media (min-width: 992px) { .app-content { padding: 24px 24px 40px; } }

.sidebar { width: var(--sidebar-w); flex-shrink: 0; }
.sidebar.offcanvas-lg { --bs-offcanvas-width: var(--sidebar-w); --bs-offcanvas-bg: transparent; border: 0 !important; }
@media (min-width: 992px) {
    .sidebar { position: sticky; top: 0; height: 100vh; padding: 14px 0 14px 14px; transition: width .25s ease; }
    [dir="rtl"] .sidebar { padding: 14px 14px 14px 0; }
}

.sidebar-inner {
    height: 100%; display: flex; flex-direction: column;
    background: var(--sidebar-bg); color: #cbd5e1;
    border-radius: 24px; box-shadow: var(--shadow-lg);
    overflow: hidden; position: relative;
}
.sidebar-inner::after {   /* soft glow in the corner */
    content: ''; position: absolute; width: 220px; height: 220px; border-radius: 50%;
    background: radial-gradient(circle, color-mix(in srgb, var(--brand) 55%, transparent), transparent 70%);
    top: -90px; inset-inline-end: -90px; opacity: .45; pointer-events: none;
}
@media (max-width: 991.98px) { .sidebar-inner { border-radius: 0; } }

.sidebar-brand {
    display: flex; align-items: center; gap: 10px;
    padding: 18px 16px 16px; border-bottom: 1px solid rgba(255, 255, 255, .07);
    position: relative; z-index: 1;
}
.brand-icon {
    width: 42px; height: 42px; flex-shrink: 0; border-radius: 14px;
    display: inline-flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--accent), var(--brand)); color: #fff; font-size: 1.25rem;
    box-shadow: 0 6px 16px color-mix(in srgb, var(--brand) 45%, transparent);
}
.brand-admin { background: linear-gradient(135deg, #475569, #0f172a); }
.brand-sub { font-size: .72rem; color: rgba(255, 255, 255, .5); }

.sidebar-toggle {
    width: 34px; height: 34px; flex-shrink: 0; margin-inline-start: auto;
    display: inline-flex; align-items: center; justify-content: center;
    border: 0; border-radius: 11px; background: rgba(255, 255, 255, .07); color: #cbd5e1;
    transition: background .15s, color .15s;
}
.sidebar-toggle:hover { background: rgba(255, 255, 255, .15); color: #fff; }

.sidebar-nav {
    flex: 1; overflow-y: auto; padding: 4px 12px 12px; position: relative; z-index: 1;
    scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .15) transparent;
}
.nav-section {
    font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
    color: rgba(255, 255, 255, .38); padding: 16px 10px 6px;
}
.side-link {
    position: relative; display: flex; align-items: center; gap: 12px;
    padding: 7px 8px; margin-bottom: 3px; border-radius: 14px;
    color: #cbd5e1; text-decoration: none; font-size: .92rem;
    transition: background .15s, color .15s, transform .15s;
}
.side-link:hover { background: rgba(255, 255, 255, .06); color: #fff; transform: translateX(2px); }
[dir="rtl"] .side-link:hover { transform: translateX(-2px); }
.side-link.active { background: rgba(255, 255, 255, .12); color: #fff; font-weight: 600; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08); }
.side-link.active::before {
    content: ''; position: absolute; inset-inline-start: -12px; top: 9px; bottom: 9px;
    width: 4px; border-radius: 4px; background: var(--accent);
}
.side-icon {
    width: 34px; height: 34px; flex-shrink: 0; border-radius: 11px;
    display: inline-flex; align-items: center; justify-content: center;
    color: #fff; font-size: .95rem; opacity: .9;
    box-shadow: 0 4px 10px rgba(0, 0, 0, .18);
}
.side-link.active .side-icon, .side-link:hover .side-icon { opacity: 1; }
.side-badge {
    min-width: 21px; height: 21px; padding: 0 6px; border-radius: 11px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: .7rem; font-weight: 700; color: #fff; background: #f43f5e;
}
.side-badge-warn { background: #f59e0b; }

.sidebar-user {
    display: flex; align-items: center; gap: 10px; position: relative; z-index: 1;
    margin: 10px 12px 12px; padding: 10px; border-radius: 16px;
    background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .06);
}
.sidebar-user .avatar { box-shadow: 0 0 0 2px var(--accent); }
.user-role { color: rgba(255, 255, 255, .55); }

/* Collapsed ("mini") sidebar — desktop only, remembered in localStorage */
@media (min-width: 992px) {
    .sidebar-mini .sidebar { width: 100px; }
    .sidebar-mini .sidebar-text { display: none !important; }
    .sidebar-mini .sidebar-brand { flex-direction: column; padding: 16px 8px; }
    .sidebar-mini .sidebar-toggle { margin: 0; }
    .sidebar-mini .nav-section { font-size: 0; padding: 0; margin: 12px 14px; border-top: 1px solid rgba(255, 255, 255, .09); }
    .sidebar-mini .side-link { justify-content: center; padding: 7px 0; }
    .sidebar-mini .side-link:hover { transform: none; }
    .sidebar-mini .side-badge { position: absolute; top: 0; inset-inline-end: 8px; min-width: 17px; height: 17px; font-size: .6rem; padding: 0 4px; }
    .sidebar-mini .sidebar-user { justify-content: center; }
}

/* =========================================================================
   Top bar
   ========================================================================= */
.topbar {
    position: sticky; top: 14px; z-index: 1020;
    display: flex; align-items: center; gap: 10px;
    margin: 14px 14px 0; padding: 10px 14px;
    background: rgba(255, 255, 255, .82); backdrop-filter: blur(12px);
    border: 1px solid rgba(231, 234, 243, .9); border-radius: 20px; box-shadow: var(--shadow);
}
@media (min-width: 992px) { .topbar { margin: 14px 24px 0; } }
.topbar-title { font-size: 1.1rem; font-weight: 700; margin: 0; }
.topbar-sub { font-size: .75rem; color: #64748b; }
.icon-btn {
    position: relative; width: 42px; height: 42px; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--line); border-radius: 13px; background: #fff; color: #334155;
    text-decoration: none; font-size: 1.1rem; transition: background .15s, color .15s;
}
.icon-btn:hover { background: color-mix(in srgb, var(--brand) 8%, white); color: var(--brand); }
.bell-dot {
    position: absolute; top: -5px; inset-inline-end: -5px;
    min-width: 19px; height: 19px; padding: 0 5px; border-radius: 10px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: .65rem; font-weight: 700; color: #fff; background: #f43f5e; border: 2px solid #fff;
}
.alerts-menu { width: 310px; }
.user-chip {
    display: flex; align-items: center; gap: 8px; max-width: 230px;
    padding: 4px 12px 4px 4px; border: 1px solid var(--line); border-radius: 14px; background: #fff;
}
[dir="rtl"] .user-chip { padding: 4px 4px 4px 12px; }

/* =========================================================================
   Dashboard
   ========================================================================= */
.hero-card {
    position: relative; overflow: hidden; color: #fff;
    background: var(--hero-bg); border-radius: 24px; box-shadow: var(--shadow-lg);
}
.hero-card-body { position: relative; z-index: 1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.25rem; padding: 28px; }
.hero-card-date { font-size: .8rem; opacity: .8; margin-bottom: .35rem; }
.hero-card-title { font-size: clamp(1.3rem, 2.4vw, 1.75rem); font-weight: 700; margin-bottom: .35rem; }
.hero-card-text { opacity: .9; max-width: 40rem; }
.hero-card-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.hero-card-deco { position: absolute; font-size: 11rem; opacity: .1; bottom: -3.5rem; inset-inline-end: 1rem; }
.btn-glass {
    color: #fff; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .28);
    backdrop-filter: blur(6px);
}
.btn-glass:hover { color: #fff; background: rgba(255, 255, 255, .28); }

.kpi-card {
    display: flex; align-items: center; gap: 14px; height: 100%;
    padding: 18px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow);
    color: inherit; text-decoration: none; transition: transform .15s, box-shadow .15s;
}
.kpi-link:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); color: inherit; }
.kpi-label { font-size: .8rem; color: #64748b; }
.kpi-value { font-size: 1.5rem; font-weight: 700; line-height: 1.25; }
.kpi-sub { font-size: .75rem; color: #94a3b8; }

.notice-card {
    display: flex; flex-wrap: wrap; align-items: center; gap: 14px;
    padding: 16px 18px; border-radius: var(--radius);
    background: #fffbeb; border: 1px solid #fde68a;
}

.donut, .ring { position: relative; flex-shrink: 0; border-radius: 50%; }
.donut { width: 160px; height: 160px; }
.ring { width: 140px; height: 140px; margin: 0 auto; }
.donut-hole {
    position: absolute; inset: 20px; border-radius: 50%; background: #fff;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    box-shadow: inset 0 0 0 1px #f1f5f9;
}
.donut-total { font-size: 1.6rem; font-weight: 700; line-height: 1; }
.donut-caption { font-size: .75rem; color: #64748b; }
.chart-legend { list-style: none; padding: 0; margin: 0; flex: 1; min-width: 160px; }
.chart-legend li { display: flex; align-items: center; gap: 8px; font-size: .85rem; padding: 4px 0; }
.legend-dot { width: 10px; height: 10px; border-radius: 3px; flex-shrink: 0; }

.bar-list { list-style: none; padding: 0; margin: 0; }
.bar-list li + li { margin-top: 14px; }
.bar-track { height: 8px; border-radius: 8px; background: #eef2f7; overflow: hidden; }
.bar-fill { height: 100%; border-radius: 8px; transition: width .6s ease; }

.timeline-feed { list-style: none; margin: 0; padding: 6px 16px; }
.timeline-feed li { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.timeline-feed li + li { border-top: 1px solid #f1f4f9; }

/* =========================================================================
   Auth pages (login, 2FA, confirm)
   ========================================================================= */
.guest {
    min-height: 100vh;
    background: radial-gradient(circle at 20% 0%, #e0e7ff 0, transparent 45%),
                radial-gradient(circle at 90% 20%, #ccfbf1 0, transparent 40%), #f4f6fb;
}
.auth-card { max-width: 440px; margin-top: 5vh; border-radius: 26px; overflow: hidden; background: #fff; box-shadow: var(--shadow-lg); }
.auth-card-head { padding: 32px 28px 26px; text-align: center; color: #fff; background: linear-gradient(135deg, #0d9488, #4f46e5); }
.auth-admin .auth-card-head { background: linear-gradient(135deg, #1e1b4b, #334155); }
.auth-logo {
    width: 66px; height: 66px; margin-bottom: 12px; border-radius: 20px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 1.8rem; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .25);
}
.auth-card-body { padding: 28px; }
/* Honeypot: visually hidden without moving it off-screen (an offset would create horizontal overflow in RTL) */
.hp-field { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.otp-input { letter-spacing: .45em; font-weight: 700; text-align: center; }
.recovery-codes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.recovery-codes code { display: block; padding: 6px 10px; border-radius: 8px; background: #fff; color: #0f172a; text-align: center; }
.qr-box { width: 184px; height: 184px; padding: 10px; border-radius: 18px; background: #fff; border: 1px solid var(--line); }
.qr-box svg { width: 100%; height: 100%; }

/* =========================================================================
   Misc components
   ========================================================================= */
.avatar { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; background: #e2e8f0; flex-shrink: 0; }
.avatar-sm { width: 30px; height: 30px; }
.avatar-lg { width: 64px; height: 64px; }
.avatar-xl { width: 88px; height: 88px; }

.stat-icon { width: 48px; height: 48px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 1.4rem; }
.date-chip { min-width: 56px; padding: .3rem; border-radius: 12px; background: color-mix(in srgb, var(--brand) 10%, white); color: var(--brand); line-height: 1.2; }
.card-hover { transition: transform .15s, box-shadow .15s; }
.card-hover:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg) !important; }

.day-chip { font-size: .75rem; padding: .15rem .55rem; border-radius: 1rem; background: #f1f5f9; color: #94a3b8; text-decoration: line-through; }
.day-chip.on { background: color-mix(in srgb, var(--brand) 12%, white); color: var(--brand); font-weight: 600; text-decoration: none; }

.timeline-track { position: relative; height: 10px; background: #f1f5f9; border-radius: 5px; }
.timeline-bar { position: absolute; top: 0; bottom: 0; background: #c7d2fe; border-radius: 5px; overflow: hidden; }
.timeline-bar.late { background: #fecaca; }
.timeline-fill { height: 100%; background: var(--brand); }
.timeline-bar.late .timeline-fill { background: #dc2626; }

details > summary { cursor: pointer; list-style: none; }
details > summary::-webkit-details-marker { display: none; }

/* Departments */
.dept-badge {
    display: inline-flex; align-items: center; gap: .3rem;
    font-size: .75rem; font-weight: 600; padding: .15rem .6rem; border-radius: 1rem;
    color: var(--dept); background: color-mix(in srgb, var(--dept) 12%, white);
}
.dept-icon {
    width: 44px; height: 44px; flex-shrink: 0; border-radius: 14px;
    display: inline-flex; align-items: center; justify-content: center; font-size: 1.3rem;
    color: #fff; background: var(--dept);
}
.dept-card { border-top: 4px solid var(--dept) !important; }

/* =========================================================================
   Public site
   ========================================================================= */
.site { background: #f8fafc; }
.site-nav { background: rgba(255, 255, 255, .92); backdrop-filter: blur(8px); box-shadow: 0 1px 0 #e2e8f0; }
.hero {
    color: #fff; padding: 5rem 0;
    background: radial-gradient(circle at 15% 20%, rgba(255, 255, 255, .15), transparent 40%),
                linear-gradient(135deg, #312e81 0%, #4f46e5 55%, #0d9488 100%);
}
.hero-kicker { display: inline-block; padding: .3rem .8rem; border-radius: 2rem; background: rgba(255, 255, 255, .15); font-size: .85rem; margin-bottom: 1rem; }
.hero-title { font-size: clamp(2.2rem, 5vw, 3.5rem); font-weight: 700; margin-bottom: 1rem; }
.hero-text { font-size: 1.15rem; opacity: .9; max-width: 36rem; margin-bottom: 2rem; }
.hero-stat {
    display: flex; align-items: center; gap: 1rem; padding: 1rem 1.25rem; border-radius: 1rem;
    background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .2); backdrop-filter: blur(6px);
}
.hero-stat > i { font-size: 1.8rem; opacity: .9; }
.hero-stat-value { font-size: 1.6rem; font-weight: 700; line-height: 1; }
.hero-stat-label { font-size: .85rem; opacity: .85; }
@media (max-width: 991px) {
    .hero-stat { flex-direction: column; text-align: center; gap: .3rem; padding: .8rem .5rem; }
}
.section-title { font-weight: 700; position: relative; display: inline-block; padding-bottom: .5rem; }
.section-title::after { content: ''; position: absolute; inset-inline: 25%; bottom: 0; height: 3px; border-radius: 3px; background: var(--brand); }
.dept-chip {
    display: inline-flex; align-items: center; gap: .4rem; padding: .4rem .9rem; border-radius: 2rem;
    text-decoration: none; font-weight: 600; font-size: .9rem;
    color: var(--dept); background: #fff; border: 1px solid color-mix(in srgb, var(--dept) 35%, white);
    transition: background .15s, color .15s;
}
.dept-chip:hover { background: var(--dept); color: #fff; }
.dept-chip-count { font-size: .75rem; padding: 0 .45rem; border-radius: 1rem; background: color-mix(in srgb, var(--dept) 15%, white); color: var(--dept); }
.dept-section { scroll-margin-top: 90px; }
.member-card {
    display: block; height: 100%; text-align: center; padding: 1.5rem 1rem; border-radius: 1rem;
    background: #fff; color: inherit; text-decoration: none;
    border-top: 4px solid var(--dept); box-shadow: 0 1px 3px rgba(15, 23, 42, .08);
    transition: transform .15s, box-shadow .15s;
}
.member-card:hover { transform: translateY(-4px); box-shadow: 0 .75rem 1.5rem rgba(15, 23, 42, .1); color: inherit; }
.member-card-link { display: inline-block; margin-top: .6rem; font-size: .8rem; font-weight: 600; color: var(--dept); }
.cta { background: linear-gradient(135deg, #eef2ff, #ccfbf1); }
.site-footer { background: #0f172a; color: #94a3b8; font-size: .9rem; }
#team, #resources { scroll-margin-top: 70px; }

/* =========================================================================
   Forms (all modules)
   ========================================================================= */
.app-form { max-width: 1040px; }
.form-section { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 18px; overflow: hidden; }
.form-section-head {
    display: flex; align-items: center; gap: 14px; padding: 16px 20px;
    background: linear-gradient(180deg, #fbfcfe, #fff); border-bottom: 1px solid var(--line);
}
.form-section-title { font-size: 1rem; font-weight: 700; margin: 0; }
.form-section-desc { font-size: .8rem; color: #64748b; margin: 2px 0 0; }
.form-section-body { padding: 20px; margin: 0; }
.form-label { font-weight: 600; font-size: .85rem; color: #334155; margin-bottom: .35rem; }
.req { color: #e11d48; font-weight: 700; }
.form-text { font-size: .75rem; }
.password-rules { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; }
.password-rules li {
    font-size: .78rem; font-weight: 600; color: #64748b; background: #f8fafc;
    border: 1px solid #e2e8f0; border-radius: 999px; padding: 4px 10px;
}
.password-rules li.is-met { color: #047857; background: #ecfdf5; border-color: #a7f3d0; }
.guide-grid { display: grid; gap: 12px; }
.guide-card {
    display: flex; gap: 14px; align-items: flex-start; padding: 14px;
    border: 1px solid var(--line); border-radius: 16px; background: #fff;
}
.guide-card-icon {
    width: 42px; height: 42px; flex-shrink: 0; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    background: #eef2ff; color: var(--brand); font-size: 1.15rem;
}

/* Icon inside inputs / selects (works in RTL and LTR) */
.input-icon { position: relative; }
.input-icon > .bi {
    position: absolute; top: 0; bottom: 0; inset-inline-start: 13px; z-index: 5;
    display: flex; align-items: center; color: #94a3b8; pointer-events: none; font-size: .95rem;
}
.input-icon > .form-control, .input-icon > .form-select { padding-inline-start: 38px; }
.input-icon:focus-within > .bi { color: var(--brand); }
.form-control, .form-select { min-height: 42px; background-color: #fcfdff; }
.form-control:hover, .form-select:hover { border-color: #c5cede; }
textarea.form-control { min-height: auto; }

.form-actions {
    position: sticky; bottom: 14px; z-index: 10;
    display: flex; flex-wrap: wrap; align-items: center; gap: 10px; justify-content: flex-end;
    padding: 12px 16px; margin-top: 4px;
    background: rgba(255, 255, 255, .9); backdrop-filter: blur(10px);
    border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg);
}
.form-actions-hint { margin-inline-end: auto; font-size: .78rem; color: #64748b; }

/* Chips: choices, icons, days, members */
.choice-chips, .icon-picker, .day-picker, .member-picker, .method-picker { display: flex; flex-wrap: wrap; gap: 8px; }
.choice-chip, .member-option {
    display: inline-flex; align-items: center; gap: 6px; cursor: pointer; user-select: none;
    padding: 8px 14px; border-radius: 12px; border: 1px solid #dbe1ec; background: #fff;
    font-weight: 600; font-size: .88rem; color: #475569; transition: all .15s;
}
.choice-chip:hover, .member-option:hover { border-color: var(--brand); color: var(--brand); }
.btn-check:checked + .choice-chip, .btn-check:checked + .member-option {
    background: var(--brand); border-color: var(--brand); color: #fff;
    box-shadow: 0 4px 12px color-mix(in srgb, var(--brand) 35%, transparent);
}
.btn-check:focus-visible + .choice-chip { outline: 2px solid var(--brand); outline-offset: 2px; }
.icon-picker .btn, .day-picker .btn { border-radius: 12px; min-width: 46px; }
.avatar-letter {
    width: 44px; height: 44px; flex-shrink: 0; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--accent), var(--brand));
}
.avatar-letter-sm { width: 24px; height: 24px; font-size: .7rem; }
.btn-check:checked + .member-option .avatar-letter { background: rgba(255, 255, 255, .25); }
.photo-field { display: flex; align-items: center; gap: 16px; padding: 12px; border: 1px dashed #cbd5e1; border-radius: 14px; background: #fafbfd; }
.current-file { font-size: .8rem; color: #64748b; margin-bottom: 6px; }
.field-row { padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: #fafbfd; margin-bottom: 10px; }

/* =========================================================================
   Lists & data (all modules)
   ========================================================================= */
.list-toolbar {
    display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
    padding: 12px; margin-bottom: 16px; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
}
.list-toolbar > .btn:last-child { margin-inline-start: auto; }
.toolbar-filters { display: flex; flex-wrap: wrap; gap: 8px; flex: 1 1 320px; }
.toolbar-filters > .input-icon { flex: 1 1 170px; max-width: 280px; }
.toolbar-filters > .search-box { max-width: 340px; flex-basis: 240px; }
.toolbar-text { font-size: .8rem; color: #64748b; }

.filter-pills { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; background: #f1f4f9; border-radius: 14px; }
.filter-pills a { padding: 7px 14px; border-radius: 10px; font-size: .85rem; font-weight: 600; color: #64748b; text-decoration: none; transition: all .15s; }
.filter-pills a:hover { color: var(--brand); }
.filter-pills a.active { background: #fff; color: var(--brand); box-shadow: 0 1px 4px rgba(15, 23, 42, .1); }

.tab-pills { gap: 6px; padding: 5px; background: #fff; border-radius: 16px; box-shadow: var(--shadow); display: flex; }
.tab-pills .nav-link { border-radius: 12px; color: #64748b; font-weight: 600; font-size: .88rem; padding: 8px 14px; border: 0; background: none; }
.tab-pills .nav-link:hover { color: var(--brand); }
.tab-pills .nav-link.active { background: var(--brand); color: #fff; }

.data-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.data-head { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.data-head-title { font-size: 1rem; font-weight: 700; margin: 0; }
.data-head-count { font-size: .75rem; color: #64748b; }

.data-table { margin: 0; }
.data-table > thead th {
    background: #f8fafc; color: #64748b; font-size: .75rem; font-weight: 700; letter-spacing: .03em;
    padding: 12px 16px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.data-table > tbody td { padding: 13px 16px; border-color: #f1f4f9; }
.data-table > tbody tr { transition: background .12s; }
.data-table > tbody tr:hover > td { background: #fafbff; }
.data-table > tfoot td { background: #f8fafc; font-weight: 700; padding: 12px 16px; }
.row-unread > td { background: color-mix(in srgb, var(--brand) 4%, white); }
.row-unread .cell-title { color: var(--brand); }
.cell-person { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.cell-title { display: block; font-weight: 700; color: #1e293b; }
.cell-sub { display: block; font-size: .78rem; color: #94a3b8; }
.soft-pill { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 20px; background: #f1f5f9; color: #475569; font-size: .78rem; font-weight: 600; }
.status-pill { display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 20px; font-size: .78rem; font-weight: 700; white-space: nowrap; }
.pill-ok { background: #dcfce7; color: #15803d; }
.pill-warn { background: #fef3c7; color: #b45309; }
.amount-bonus { color: #059669; }
.amount-penalty { color: #e11d48; }
.amount-deduction { color: #d97706; }

.row-actions { display: inline-flex; align-items: center; gap: 6px; }
.row-btn {
    width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center;
    border-radius: 10px; border: 1px solid transparent; background: #f1f5f9; color: #475569; transition: all .15s; text-decoration: none;
}
.row-btn-view:hover { background: #e0f2fe; color: #0369a1; }
.row-btn-edit:hover { background: #e0e7ff; color: #4338ca; }
.row-btn-delete:hover { background: #ffe4e6; color: #e11d48; }
.row-btn-warn { background: #fef3c7; color: #b45309; }
.row-btn-ok { background: #dcfce7; color: #15803d; }

.empty-state { text-align: center; padding: 40px 16px; }
.empty-state-icon {
    width: 64px; height: 64px; margin-bottom: 12px; border-radius: 20px;
    display: inline-flex; align-items: center; justify-content: center; font-size: 1.7rem;
    background: color-mix(in srgb, var(--brand) 9%, white); color: var(--brand);
}
.empty-state-text { color: #64748b; font-size: .9rem; }

.info-list { list-style: none; margin: 0; padding: 6px 18px; }
.info-list li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; font-size: .85rem; }
.info-list li + li { border-top: 1px solid #f1f4f9; }
.info-list li span { color: #64748b; }
.detail-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1px; background: var(--line); border-top: 1px solid var(--line); }
.detail-item { background: #fff; padding: 14px 18px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.detail-label { font-size: .75rem; color: #94a3b8; }
.detail-value { font-weight: 600; word-break: break-word; }
.profile-strip { display: flex; align-items: center; gap: 14px; padding: 18px; }
.cv-download {
    display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--radius);
    background: #fff; box-shadow: var(--shadow); color: inherit; text-decoration: none; transition: transform .15s, box-shadow .15s;
}
.cv-download:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); color: inherit; }
.feature-switch { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 16px 18px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); }
.feature-switch.is-on { background: linear-gradient(90deg, #ecfdf5, #fff); }

/* =========================================================================
   Payout methods & accounts
   ========================================================================= */
.payout-icon {
    width: 40px; height: 40px; flex-shrink: 0; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center; font-size: 1.1rem;
    color: #fff; background: var(--method, var(--brand));
}
.payout-icon-lg { width: 50px; height: 50px; border-radius: 15px; font-size: 1.35rem; }
.payout-list { padding: 6px 12px; }
.payout-item { display: flex; align-items: flex-start; gap: 12px; padding: 12px 6px; }
.payout-item + .payout-item { border-top: 1px solid #f1f4f9; }
.payout-details { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; margin: 0; font-size: .82rem; }
.payout-details dt { color: #94a3b8; font-weight: 500; }
.payout-details dd { margin: 0; font-weight: 600; text-align: start; }
.method-card { height: 100%; padding: 18px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); border-top: 4px solid var(--method); }
.method-card.is-off { opacity: .6; }
.field-chip { font-size: .75rem; padding: 3px 10px; border-radius: 20px; background: #f1f5f9; color: #475569; }
.method-option {
    display: inline-flex; align-items: center; gap: 10px; cursor: pointer;
    padding: 8px 14px 8px 8px; border-radius: 14px; border: 2px solid #e2e8f0; background: #fff; font-weight: 600; transition: all .15s;
}
[dir="rtl"] .method-option { padding: 8px 8px 8px 14px; }
.method-option:hover { border-color: var(--method); }
.btn-check:checked + .method-option {
    border-color: var(--method); background: color-mix(in srgb, var(--method) 8%, white);
    box-shadow: 0 4px 14px color-mix(in srgb, var(--method) 25%, transparent);
}
.method-tag { display: inline-flex; align-items: center; gap: 6px; font-size: .8rem; font-weight: 600; color: var(--method); background: color-mix(in srgb, var(--method) 10%, white); padding: 4px 10px; border-radius: 20px; white-space: nowrap; }

/* =========================================================================
   Credentials card (printable)
   ========================================================================= */
.credential-card { max-width: 720px; background: #fff; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-lg); border: 1px solid var(--line); }
.credential-head { display: flex; align-items: center; gap: 12px; padding: 20px 24px; color: #fff; background: var(--hero-bg); }
.credential-body { padding: 24px; }
.credential-list { display: grid; grid-template-columns: auto 1fr; gap: 10px 16px; margin: 0; }
.credential-list dt { color: #64748b; font-weight: 600; font-size: .85rem; white-space: nowrap; }
.credential-list dd { margin: 0; font-weight: 700; word-break: break-all; text-align: start; }
.credential-password { font-family: ui-monospace, Consolas, monospace; font-size: 1.1rem; letter-spacing: .05em; padding: 4px 10px; border-radius: 8px; background: #fef3c7; display: inline-block; }
.credential-note { margin-top: 20px; padding: 12px 14px; border-radius: 12px; background: #f1f5f9; font-size: .8rem; color: #475569; }
.copy-btn.copied { background: #dcfce7; border-color: #16a34a; color: #15803d; }

@media print {
    .sidebar, .topbar, .no-print, .alert, .form-actions { display: none !important; }
    .app-content { padding: 0 !important; }
    body, .app-body { background: #fff !important; }
    .credential-card { box-shadow: none; margin-top: 20px; }
    .credential-head { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* =========================================================================
   Public site: company page & careers
   ========================================================================= */
.site-section { padding: 80px 0; }
.section-kicker { display: inline-block; font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); margin-bottom: .5rem; }
.section-heading { font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 800; margin-bottom: 1rem; }
.section-lead { font-size: 1.05rem; color: #475569; line-height: 1.9; }
.feature-card, .value-card, .service-card, .content-card {
    height: 100%; padding: 22px; border-radius: 20px; background: #fff; box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s;
}
.content-card { height: auto; }
.feature-card { display: flex; gap: 16px; align-items: flex-start; }
.service-card:hover, .value-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.service-card, .value-card { text-align: center; }
.contact-band {
    padding: 44px; border-radius: 28px; color: #fff; position: relative; overflow: hidden;
    background: radial-gradient(circle at 90% 10%, rgba(255, 255, 255, .15), transparent 40%), linear-gradient(135deg, #1e1b4b, #4f46e5 60%, #0d9488);
}
.contact-icon { width: 38px; height: 38px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: rgba(255, 255, 255, .15); }
.team-login-box { display: inline-block; text-align: center; padding: 26px 30px; border-radius: 22px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .2); }
.hero-visual { position: relative; height: 320px; }
.hero-orb-main, .hero-orb {
    position: absolute; display: flex; align-items: center; justify-content: center; border-radius: 28px;
    background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .25); backdrop-filter: blur(6px);
}
.hero-orb-main { width: 150px; height: 150px; top: 85px; inset-inline-start: 110px; font-size: 4rem; border-radius: 40px; }
.hero-orb { width: 72px; height: 72px; font-size: 1.8rem; animation: float 6s ease-in-out infinite; }
.orb-1 { top: 10px; inset-inline-start: 40px; }
.orb-2 { top: 30px; inset-inline-start: 290px; animation-delay: 1s; }
.orb-3 { top: 230px; inset-inline-start: 20px; animation-delay: 2s; }
.orb-4 { top: 240px; inset-inline-start: 300px; animation-delay: 3s; }
@keyframes float { 50% { transform: translateY(-12px); } }
@media (prefers-reduced-motion: reduce) { .hero-orb { animation: none; } }
.footer-links a { color: #94a3b8; text-decoration: none; line-height: 2; }
.footer-links a:hover { color: #fff; }

.page-hero { padding: 64px 0 56px; color: #fff; background: linear-gradient(135deg, #312e81, #4f46e5 60%, #0d9488); }
.page-hero-title { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 800; margin-bottom: .75rem; }
.page-hero-text { font-size: 1.05rem; opacity: .9; max-width: 44rem; margin: 0; }
.job-card {
    display: flex; flex-direction: column; height: 100%; padding: 22px; border-radius: 20px;
    background: #fff; color: inherit; text-decoration: none; box-shadow: var(--shadow);
    border-top: 4px solid var(--dept); transition: transform .2s, box-shadow .2s;
}
.job-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); color: inherit; }
.job-card-link { margin-top: auto; padding-top: 12px; font-weight: 700; color: var(--brand); }
[dir="ltr"] .job-card-link .bi { display: inline-block; transform: scaleX(-1); }
.job-meta { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: .85rem; color: #64748b; }
.job-meta-light { color: rgba(255, 255, 255, .85); }
.check-list { list-style: none; padding: 0; margin: 0; }
.check-list li { position: relative; padding-inline-start: 28px; margin-bottom: 8px; color: #475569; }
.check-list li::before { content: "\F26E"; font-family: "bootstrap-icons"; position: absolute; inset-inline-start: 0; color: #10b981; }
.apply-card { position: sticky; top: 90px; padding: 24px; border-radius: 22px; background: #fff; box-shadow: var(--shadow-lg); scroll-margin-top: 90px; }
.empty-card { background: #fff; border-radius: 20px; box-shadow: var(--shadow); }

/* Amounts and dates stay on one line in tables; free text (notes) may wrap */
.data-table > tbody td, .data-table > tfoot td { white-space: nowrap; }
.data-table > tbody td.small { white-space: normal; min-width: 180px; }

/* Protection page */
.provider-card { height: 100%; padding: 18px; border-radius: 16px; border: 1px solid var(--line); background: #fafbfd; }
.provider-card.is-active { border-color: #10b981; background: linear-gradient(180deg, #ecfdf5, #fff); }
.live-test { margin-top: 14px; padding: 14px; border-radius: 14px; border: 1px dashed #10b981; background: #fff; }
.switch-card { padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); background: #fafbfd; }
.switch-danger { border-color: #fecaca; background: #fff7f7; }

/* Pagination under lists */
.pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 18px; border-top: 1px solid var(--line); background: #fbfcfe; }
.pager-info { font-size: .8rem; color: #64748b; }
.pager-links { display: flex; flex-wrap: wrap; gap: 4px; }
.pager-link {
    min-width: 34px; height: 34px; padding: 0 8px; display: inline-flex; align-items: center; justify-content: center;
    border-radius: 10px; border: 1px solid var(--line); background: #fff; color: #334155; font-size: .85rem; font-weight: 600; text-decoration: none;
    transition: background .15s, color .15s, border-color .15s;
}
.pager-link:hover { border-color: var(--brand); color: var(--brand); }
.pager-link.active { background: var(--brand); border-color: var(--brand); color: #fff; box-shadow: 0 4px 12px color-mix(in srgb, var(--brand) 35%, transparent); }
.pager-link.disabled { opacity: .4; pointer-events: none; }
.pager-gap { min-width: 24px; display: inline-flex; align-items: flex-end; justify-content: center; color: #94a3b8; }
[dir="ltr"] .pager-link .bi { display: inline-block; transform: scaleX(-1); }

/* Team panel pages */
.mini-stat { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; border-radius: 12px; background: #f8fafc; font-size: .85rem; color: #475569; }
.project-card {
    position: relative; height: 100%; display: flex; flex-direction: column; gap: 10px; padding: 18px;
    border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); border-top: 4px solid var(--brand);
    transition: transform .15s, box-shadow .15s;
}
.project-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.project-card.is-new { border-top-color: #f59e0b; }
.project-card-title { display: block; font-weight: 700; color: #0f172a; text-decoration: none; }
.project-card-text { margin: 0; font-size: .85rem; color: #64748b; }
.project-card-foot { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; font-size: .8rem; color: #64748b; }
.project-card-action { position: relative; z-index: 2; }
.resource-tile {
    height: 100%; display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: var(--radius);
    background: #fff; box-shadow: var(--shadow); color: inherit; text-decoration: none; transition: transform .15s, box-shadow .15s;
}
.resource-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); color: inherit; }
.logo-preview { max-width: 140px; max-height: 70px; object-fit: contain; padding: 6px; border-radius: 12px; background: #f8fafc; border: 1px solid var(--line); }

/* Contract preview: an A4-like sheet */
.contract-paper { max-width: 900px; margin: 0 auto; padding: 48px 56px; background: #fff; border-radius: 6px; box-shadow: var(--shadow-lg); }
@media (max-width: 767.98px) { .contract-paper { padding: 22px 16px; } }

/* Project roles (team lead / project manager) */
.role-pill { display: inline-flex; align-items: center; gap: 4px; margin-top: 3px; padding: 1px 8px; border-radius: 20px; font-size: .72rem; font-weight: 700; }
.role-manager { background: #ede9fe; color: #6d28d9; }
.role-lead { background: #e0f2fe; color: #0369a1; }

/* Member picker (projects, group chats) */
.member-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px; max-height: 420px; overflow-y: auto; }
.member-row { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 14px; background: #fff; cursor: pointer; margin: 0; }
.member-row:hover { border-color: var(--brand); }
.member-row:has(input:checked) { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 7%, white); }
.member-row[hidden] { display: none; }

/* =========================================================================
   Chats (messenger): conversation list · conversation · details panel
   ========================================================================= */
.hue-0 { --hue-a: #818cf8; --hue-b: #4f46e5; }
.hue-1 { --hue-a: #5eead4; --hue-b: #0d9488; }
.hue-2 { --hue-a: #fda4af; --hue-b: #e11d48; }
.hue-3 { --hue-a: #fcd34d; --hue-b: #d97706; }
.hue-4 { --hue-a: #7dd3fc; --hue-b: #0284c7; }
.hue-5 { --hue-a: #c4b5fd; --hue-b: #7c3aed; }
.hue-6 { --hue-a: #6ee7b7; --hue-b: #059669; }
.hue-7 { --hue-a: #f9a8d4; --hue-b: #db2777; }
.hue-admin { --hue-a: #475569; --hue-b: #0f172a; }
.hue-text-0 { color: #4338ca; } .hue-text-1 { color: #0f766e; } .hue-text-2 { color: #be123c; } .hue-text-3 { color: #b45309; }
.hue-text-4 { color: #0369a1; } .hue-text-5 { color: #6d28d9; } .hue-text-6 { color: #047857; } .hue-text-7 { color: #be185d; }
.hue-text-admin { color: #0f172a; }

.messenger {
    --msg-h: calc(100dvh - 150px);
    display: grid; grid-template-columns: 340px minmax(0, 1fr);
    height: var(--msg-h); min-height: 520px;
    background: #fff; border-radius: 24px; box-shadow: var(--shadow); overflow: hidden;
    border: 1px solid rgba(231, 234, 243, .9);
}
@media (min-width: 1400px) {
    .messenger.is-room { grid-template-columns: 340px minmax(0, 1fr) 320px; }
    .messenger.is-room.info-closed { grid-template-columns: 340px minmax(0, 1fr); }
    .messenger.info-closed > .msg-info { display: none !important; }
}
@media (max-width: 991.98px) {
    .messenger { grid-template-columns: minmax(0, 1fr); --msg-h: calc(100dvh - 128px); border-radius: 20px; }
    .messenger.is-index > .msg-main { display: none; }
    .messenger.is-room > .msg-sidebar { display: none; }
}

/* ---- conversation list ---- */
.msg-sidebar { display: flex; flex-direction: column; min-height: 0; border-inline-end: 1px solid var(--line); background: #fcfdff; }
.msg-sidebar-head { padding: 18px 16px 12px; display: flex; flex-direction: column; gap: 12px; border-bottom: 1px solid var(--line); }
.msg-sidebar-title { font-size: 1.2rem; font-weight: 800; margin: 0; }
.msg-count { min-width: 22px; height: 22px; padding: 0 7px; border-radius: 11px; background: #f43f5e; color: #fff; font-size: .72rem; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.msg-count-soft { min-width: 22px; padding: 0 7px; border-radius: 11px; background: #f1f5f9; color: #475569; font-size: .72rem; font-weight: 700; text-align: center; }
.msg-new {
    margin-inline-start: auto; width: 38px; height: 38px; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center; font-size: 1.05rem;
    color: #fff; background: linear-gradient(135deg, var(--accent), var(--brand));
    box-shadow: 0 6px 14px color-mix(in srgb, var(--brand) 35%, transparent); transition: transform .15s;
}
.msg-new:hover { color: #fff; transform: translateY(-1px); }
.msg-search { position: relative; }
.msg-search > .bi { position: absolute; inset-inline-start: 13px; top: 50%; transform: translateY(-50%); color: #94a3b8; font-size: .9rem; pointer-events: none; }
.msg-search input {
    width: 100%; height: 40px; padding-inline: 38px 12px; border-radius: 12px;
    border: 1px solid transparent; background: #f1f4f9; font-size: .88rem; outline: none; transition: all .15s;
}
.msg-search input:focus { background: #fff; border-color: var(--brand); box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--brand) 14%, transparent); }
.msg-search-sm input { height: 34px; font-size: .8rem; }
.msg-tabs { display: flex; gap: 4px; padding: 4px; background: #f1f4f9; border-radius: 12px; }
.msg-tabs button { flex: 1; border: 0; background: none; padding: 6px 4px; border-radius: 9px; font-size: .78rem; font-weight: 700; color: #64748b; transition: all .15s; }
.msg-tabs button:hover { color: var(--brand); }
.msg-tabs button.active { background: #fff; color: var(--brand); box-shadow: 0 1px 4px rgba(15, 23, 42, .1); }

.msg-list { flex: 1; overflow-y: auto; padding: 8px; }
.msg-item {
    position: relative; display: flex; align-items: center; gap: 12px; padding: 11px 12px; margin-bottom: 2px;
    border-radius: 14px; color: inherit; text-decoration: none; transition: background .12s;
}
.msg-item:hover { background: #f1f4f9; color: inherit; }
.msg-item.active { background: color-mix(in srgb, var(--brand) 10%, white); }
.msg-item.active::before { content: ''; position: absolute; inset-inline-start: 0; top: 14px; bottom: 14px; width: 3px; border-radius: 3px; background: var(--brand); }
.msg-item-body { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.msg-item-top, .msg-item-bottom { display: flex; align-items: center; gap: 8px; }
.msg-item-name { flex: 1; min-width: 0; font-weight: 700; font-size: .9rem; color: #0f172a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-item-time { font-size: .7rem; color: #94a3b8; white-space: nowrap; }
.msg-item-preview { flex: 1; min-width: 0; font-size: .8rem; color: #64748b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-item-preview b { font-weight: 600; color: #475569; }
.msg-item-preview .bi { font-size: .75rem; }
.msg-item.is-unread .msg-item-name { color: var(--brand-dark); }
.msg-item.is-unread .msg-item-preview { color: #1e293b; font-weight: 600; }
.msg-item.is-unread .msg-item-time { color: var(--brand); font-weight: 700; }
.msg-badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--brand); color: #fff; font-size: .68rem; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.msg-list-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 40px 16px; text-align: center; color: #94a3b8; font-size: .85rem; }
.msg-list-empty .bi { font-size: 2rem; }

/* avatars */
.msg-avatar {
    width: 46px; height: 46px; flex-shrink: 0; border-radius: 15px;
    display: inline-flex; align-items: center; justify-content: center; font-size: 1.15rem; color: #fff;
    background: linear-gradient(135deg, var(--hue-a, #818cf8), var(--hue-b, #4f46e5));
    box-shadow: 0 4px 10px color-mix(in srgb, var(--hue-b, #4f46e5) 25%, transparent);
}
.msg-avatar.is-project { border-radius: 50%; }
.msg-avatar-xl { width: 76px; height: 76px; border-radius: 24px; font-size: 1.9rem; }
.msg-person-avatar {
    width: 36px; height: 36px; flex-shrink: 0; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center; font-size: .78rem; font-weight: 700; color: #fff;
    background: linear-gradient(135deg, var(--hue-a, #818cf8), var(--hue-b, #4f46e5));
}

/* ---- conversation ---- */
.msg-main { position: relative; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.msg-head {
    display: flex; align-items: center; gap: 10px; padding: 12px 16px; min-height: 72px;
    border-bottom: 1px solid var(--line); background: rgba(255, 255, 255, .92); backdrop-filter: blur(8px); z-index: 2;
}
.msg-head-who { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; border: 0; background: none; padding: 0; color: inherit; }
.msg-head-name { display: block; font-weight: 800; font-size: 1rem; color: #0f172a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-head-sub { display: block; font-size: .76rem; color: #64748b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-head-actions { display: flex; gap: 6px; }
.msg-head-btn {
    width: 40px; height: 40px; flex-shrink: 0; border-radius: 12px; border: 1px solid var(--line); background: #fff;
    display: inline-flex; align-items: center; justify-content: center; color: #475569; font-size: 1.05rem; text-decoration: none; transition: all .15s;
}
.msg-head-btn:hover { color: var(--brand); border-color: color-mix(in srgb, var(--brand) 35%, white); background: color-mix(in srgb, var(--brand) 6%, white); }

.msg-scroll {
    flex: 1; overflow-y: auto; padding: 8px clamp(12px, 3vw, 28px) 18px;
    background-color: #f5f7fb;
    background-image: radial-gradient(color-mix(in srgb, var(--brand) 9%, transparent) 1px, transparent 1px);
    background-size: 22px 22px;
}
.msg-older { text-align: center; padding: 6px 0; }
.msg-older button { border: 1px solid var(--line); background: #fff; border-radius: 20px; padding: 5px 14px; font-size: .78rem; font-weight: 600; color: #475569; box-shadow: var(--shadow); }
.msg-older button:hover { color: var(--brand); }
.msg-thread { display: flex; flex-direction: column; min-height: 100%; }

.msg-day { align-self: center; margin: 14px 0 6px; }
.msg-day span { display: inline-block; padding: 4px 14px; border-radius: 20px; background: rgba(255, 255, 255, .95); color: #475569; font-size: .72rem; font-weight: 700; box-shadow: 0 1px 4px rgba(15, 23, 42, .08); }

.msg { display: flex; align-items: flex-start; gap: 8px; margin-top: 12px; animation: msg-in .22s ease-out; }
.msg.is-mine { flex-direction: row-reverse; }
.msg.is-continued { margin-top: 3px; }
.msg.is-continued .msg-row-avatar { visibility: hidden; height: 0; }
.msg.is-removing { opacity: 0; transform: scale(.96); transition: all .2s; }
@keyframes msg-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.msg-bubble {
    position: relative; max-width: min(72%, 580px); padding: 8px 12px 6px; border-radius: 18px;
    background: #fff; box-shadow: 0 1px 2px rgba(15, 23, 42, .08); color: #1e293b;
}
.msg:not(.is-mine):not(.is-continued) .msg-bubble { border-start-start-radius: 6px; }
.msg.is-mine .msg-bubble {
    color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-dark));
    box-shadow: 0 3px 10px color-mix(in srgb, var(--brand) 25%, transparent);
}
.msg.is-mine:not(.is-continued) .msg-bubble { border-start-end-radius: 6px; }
.msg-sender { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; margin-bottom: 3px; font-size: .75rem; }
.msg-sender strong { font-weight: 800; }
.msg-sender span { color: #94a3b8; font-size: .7rem; }
.msg.is-continued .msg-sender { display: none; }
.msg-text { white-space: pre-wrap; overflow-wrap: anywhere; font-size: .92rem; line-height: 1.6; }
.msg-meta { display: flex; align-items: center; justify-content: flex-end; gap: 4px; margin-top: 2px; font-size: .66rem; color: #94a3b8; }
.msg.is-mine .msg-meta { color: rgba(255, 255, 255, .75); }

.msg-tools { display: flex; flex-direction: column; gap: 4px; align-self: center; opacity: 0; transition: opacity .15s; }
.msg:hover .msg-tools, .msg:focus-within .msg-tools { opacity: 1; }
@media (hover: none) { .msg-tools { opacity: .7; } }
.msg-tool { width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line); background: #fff; color: #64748b; font-size: .75rem; display: inline-flex; align-items: center; justify-content: center; box-shadow: var(--shadow); }
.msg-tool:hover { color: var(--brand); }
.msg-tool.is-danger:hover { color: #e11d48; border-color: #fecdd3; }

/* images */
.msg-bubble.has-image { padding: 4px; }
.msg-bubble.has-image .msg-sender { padding: 4px 8px 0; }
.msg-bubble.has-image .msg-text { padding: 4px 8px 0; }
.msg-bubble.has-image .msg-meta { padding: 0 8px 4px; }
.msg-image { display: block; border-radius: 14px; overflow: hidden; background: #e2e8f0; }
.msg-image img { display: block; max-width: 100%; max-height: 320px; min-width: 120px; object-fit: cover; transition: transform .2s; }
.msg-image:hover img { transform: scale(1.02); }

/* files */
.file-ico {
    width: 42px; height: 42px; flex-shrink: 0; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: .62rem; font-weight: 800; letter-spacing: .02em; color: #fff; background: #64748b;
}
.file-ico[data-ext="pdf"] { background: #e11d48; }
.file-ico:is([data-ext="doc"], [data-ext="docx"], [data-ext="txt"]) { background: #2563eb; }
.file-ico:is([data-ext="xls"], [data-ext="xlsx"], [data-ext="csv"]) { background: #059669; }
.file-ico:is([data-ext="ppt"], [data-ext="pptx"]) { background: #ea580c; }
.file-ico:is([data-ext="zip"], [data-ext="rar"], [data-ext="7z"]) { background: #d97706; }
.file-ico:is([data-ext="jpg"], [data-ext="jpeg"], [data-ext="png"], [data-ext="webp"], [data-ext="gif"]) { background: #0891b2; }
.file-ico:is([data-ext="psd"], [data-ext="ai"], [data-ext="xd"], [data-ext="fig"], [data-ext="sketch"]) { background: #7c3aed; }
.file-ico:is([data-ext="mp3"], [data-ext="mp4"]) { background: #db2777; }
.msg-file {
    display: flex; align-items: center; gap: 10px; min-width: 230px; max-width: 340px; padding: 8px;
    border-radius: 14px; background: #f1f5f9; color: inherit; text-decoration: none; transition: background .15s;
}
.msg-file:hover { background: #e2e8f0; color: inherit; }
.msg.is-mine .msg-file { background: rgba(255, 255, 255, .16); }
.msg.is-mine .msg-file:hover { background: rgba(255, 255, 255, .24); }
.msg-file-name { display: block; font-weight: 700; font-size: .84rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-file-size { display: block; font-size: .7rem; opacity: .7; }
.msg-file-dl { width: 32px; height: 32px; flex-shrink: 0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: rgba(15, 23, 42, .06); }
.msg.is-mine .msg-file-dl { background: rgba(255, 255, 255, .2); }

/* voice notes */
.msg-bubble.kind-voice { min-width: 270px; }
.voice { display: flex; align-items: center; gap: 10px; padding: 4px 0 2px; }
.voice-play {
    width: 40px; height: 40px; flex-shrink: 0; border-radius: 50%; border: 0; font-size: 1.25rem;
    display: inline-flex; align-items: center; justify-content: center;
    color: #fff; background: var(--brand); box-shadow: 0 3px 8px color-mix(in srgb, var(--brand) 35%, transparent); transition: transform .12s;
}
.voice-play:hover { transform: scale(1.06); }
.msg.is-mine .voice-play { color: var(--brand); background: #fff; }
.voice-wave { flex: 1; height: 30px; display: flex; align-items: center; gap: 2px; cursor: pointer; }
.voice-wave i { flex: 1; min-width: 2px; border-radius: 2px; background: #cbd5e1; transition: background .1s; }
.voice-wave i.on { background: var(--brand); }
.msg.is-mine .voice-wave i { background: rgba(255, 255, 255, .38); }
.msg.is-mine .voice-wave i.on { background: #fff; }
.voice-time { min-width: 34px; font-size: .72rem; font-weight: 700; font-variant-numeric: tabular-nums; opacity: .8; }

/* loading / empty */
.msg-loading { display: flex; justify-content: center; gap: 6px; padding: 60px 0; }
.msg-loading span { width: 9px; height: 9px; border-radius: 50%; background: var(--brand); opacity: .3; animation: msg-dot 1s infinite; }
.msg-loading span:nth-child(2) { animation-delay: .15s; }
.msg-loading span:nth-child(3) { animation-delay: .3s; }
@keyframes msg-dot { 50% { opacity: 1; transform: translateY(-4px); } }
.msg-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; margin: auto; padding: 70px 16px; text-align: center; color: #64748b; }
.msg-empty strong { color: #0f172a; font-size: 1rem; }
.msg-empty span:last-child { font-size: .85rem; }
.msg-empty-art {
    width: 76px; height: 76px; margin-bottom: 8px; border-radius: 24px; font-size: 2rem;
    display: inline-flex; align-items: center; justify-content: center; color: var(--brand);
    background: color-mix(in srgb, var(--brand) 10%, white);
}

.msg-jump {
    position: absolute; bottom: 110px; inset-inline-end: 22px; z-index: 3;
    width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: #fff; color: #475569;
    box-shadow: var(--shadow-lg); display: inline-flex; align-items: center; justify-content: center;
}
.msg-jump-count { position: absolute; top: -6px; inset-inline-end: -4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: var(--brand); color: #fff; font-size: .66rem; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.msg-toast {
    position: absolute; bottom: 110px; left: 50%; transform: translateX(-50%); z-index: 4; max-width: 90%;
    padding: 9px 16px; border-radius: 12px; background: #0f172a; color: #fff; font-size: .82rem; box-shadow: var(--shadow-lg);
}
.msg-drop {
    position: absolute; inset: 10px; z-index: 5; border-radius: 20px; border: 2px dashed var(--brand);
    background: color-mix(in srgb, var(--brand) 8%, rgba(255, 255, 255, .92)); display: flex; align-items: center; justify-content: center;
    pointer-events: none;
}
.msg-drop div { display: flex; flex-direction: column; align-items: center; gap: 8px; color: var(--brand); font-weight: 700; }
.msg-drop .bi { font-size: 2.6rem; }

/* composer */
.msg-composer { padding: 10px 16px 10px; border-top: 1px solid var(--line); background: #fff; }
.msg-composer.is-sending { opacity: .6; pointer-events: none; }
.msg-compose {
    display: flex; align-items: flex-end; gap: 6px; padding: 5px; border-radius: 24px;
    background: #f1f4f9; border: 1px solid transparent; transition: all .15s;
}
.msg-compose:focus-within { background: #fff; border-color: color-mix(in srgb, var(--brand) 40%, white); box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--brand) 12%, transparent); }
.msg-input {
    flex: 1; min-width: 0; min-height: 42px; max-height: 150px; padding: 10px 6px; resize: none;
    border: 0; outline: none; background: transparent; font-size: .92rem; line-height: 1.5;
}
.msg-icon-btn {
    width: 42px; height: 42px; flex-shrink: 0; margin: 0; border: 0; border-radius: 50%; background: transparent;
    display: inline-flex; align-items: center; justify-content: center; color: #64748b; font-size: 1.15rem; cursor: pointer; transition: all .15s;
}
.msg-icon-btn:hover { background: rgba(15, 23, 42, .06); color: var(--brand); }
.msg-send {
    width: 42px; height: 42px; flex-shrink: 0; border: 0; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center; font-size: 1.05rem; color: #fff;
    background: linear-gradient(135deg, var(--accent), var(--brand)); box-shadow: 0 4px 12px color-mix(in srgb, var(--brand) 35%, transparent);
    transition: transform .12s;
}
.msg-send:hover { transform: scale(1.06); }
.msg-send.is-mic { background: var(--brand); }
[dir="rtl"] .msg-send .bi-send-fill { display: inline-block; transform: scaleX(-1); }
.msg-compose-hint { margin-top: 6px; font-size: .68rem; color: #94a3b8; text-align: center; }

.msg-attach-preview {
    display: flex; align-items: center; gap: 10px; padding: 8px; margin-bottom: 8px;
    border-radius: 16px; background: #f8fafc; border: 1px solid var(--line); animation: msg-in .2s ease-out;
}
.msg-attach-thumb { width: 48px; height: 48px; flex-shrink: 0; border-radius: 12px; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; }
.msg-attach-thumb img { width: 100%; height: 100%; object-fit: cover; }
.msg-attach-thumb .file-ico { width: 48px; height: 48px; }
.msg-recorder {
    display: flex; align-items: center; gap: 10px; padding: 5px; border-radius: 24px;
    background: #fff1f2; border: 1px solid #fecdd3; animation: msg-in .2s ease-out;
}
.msg-rec-dot { width: 10px; height: 10px; flex-shrink: 0; border-radius: 50%; background: #e11d48; animation: rec-pulse 1s infinite; }
@keyframes rec-pulse { 50% { opacity: .25; transform: scale(.8); } }
.msg-rec-time { min-width: 40px; font-weight: 800; font-size: .9rem; color: #be123c; font-variant-numeric: tabular-nums; }
.msg-rec-wave { flex: 1; height: 32px; display: flex; align-items: center; gap: 2px; overflow: hidden; }
.msg-rec-wave i { flex: 1; min-width: 2px; height: 12%; border-radius: 2px; background: #fb7185; transition: height .08s; }

/* ---- details panel ---- */
.msg-info { display: flex; flex-direction: column; min-height: 0; overflow-y: auto; border-inline-start: 1px solid var(--line); background: #fcfdff; }
.msg-info-hero { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 26px 18px 18px; text-align: center; border-bottom: 1px solid var(--line); }
.msg-info-name { font-size: 1.05rem; font-weight: 800; margin: 6px 0 0; }
.msg-type-pill { padding: 3px 12px; border-radius: 20px; background: color-mix(in srgb, var(--brand) 10%, white); color: var(--brand); font-size: .74rem; font-weight: 700; }
.msg-info-actions { display: flex; gap: 8px; margin-top: 8px; }
.msg-info-action {
    display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 76px; padding: 10px 8px;
    border-radius: 14px; background: #fff; border: 1px solid var(--line); color: #475569; font-size: .72rem; font-weight: 700; text-decoration: none; transition: all .15s;
}
.msg-info-action .bi { font-size: 1.1rem; color: var(--brand); }
.msg-info-action:hover { border-color: color-mix(in srgb, var(--brand) 40%, white); color: var(--brand); }
.msg-info-stats { display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--line); }
.msg-info-stats div { display: flex; flex-direction: column; align-items: center; padding: 14px 4px; }
.msg-info-stats div + div { border-inline-start: 1px solid var(--line); }
.msg-info-stats b { font-size: 1.15rem; font-weight: 800; color: #0f172a; }
.msg-info-stats small { font-size: .7rem; color: #64748b; }
.msg-info-section { padding: 16px; border-bottom: 1px solid var(--line); }
.msg-info-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; font-size: .8rem; font-weight: 800; color: #334155; }
.msg-info-empty { font-size: .8rem; color: #94a3b8; }
.msg-info-section .msg-search { margin-bottom: 8px; }
.msg-people, .msg-files { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.msg-person, .msg-file-row { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 12px; color: inherit; text-decoration: none; }
.msg-person:hover, .msg-file-row:hover { background: #f1f4f9; color: inherit; }
.msg-person-name { display: block; font-weight: 700; font-size: .84rem; color: #0f172a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-person-sub { display: block; font-size: .72rem; color: #64748b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-person .dept-badge { font-size: .66rem; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.msg-person.is-admin { background: #f8fafc; }
.msg-files .file-ico { width: 36px; height: 36px; border-radius: 10px; font-size: .56rem; }
.msg-danger { border-bottom: 0; margin-top: auto; }
.msg-info-offcanvas { --bs-offcanvas-width: 340px; }
.msg-info-offcanvas .msg-info { border: 0; }

/* ---- welcome (no conversation selected) ---- */
.msg-welcome {
    align-items: center; justify-content: center; overflow-y: auto;
    background: radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--brand) 9%, transparent) 0, transparent 45%),
                radial-gradient(circle at 80% 80%, color-mix(in srgb, var(--accent) 18%, transparent) 0, transparent 40%), #f8fafc;
}
.msg-welcome-inner { max-width: 600px; padding: 40px 24px; display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.msg-welcome-art { position: relative; width: 160px; height: 120px; margin-bottom: 6px; }
.msg-welcome-art span {
    position: absolute; display: inline-flex; align-items: center; justify-content: center; color: #fff; border-radius: 22px;
    box-shadow: var(--shadow-lg); animation: msg-float 4s ease-in-out infinite;
}
.msg-welcome-art .bubble-a { width: 88px; height: 72px; inset-inline-start: 36px; top: 18px; font-size: 2.2rem; background: linear-gradient(135deg, var(--accent), var(--brand)); border-end-start-radius: 6px; }
.msg-welcome-art .bubble-b { width: 46px; height: 46px; inset-inline-start: 0; top: 0; font-size: 1.2rem; background: linear-gradient(135deg, #fda4af, #e11d48); border-radius: 50%; animation-delay: -1.2s; }
.msg-welcome-art .bubble-c { width: 44px; height: 44px; inset-inline-end: 0; bottom: 0; font-size: 1.15rem; background: linear-gradient(135deg, #fcd34d, #d97706); border-radius: 14px; animation-delay: -2.4s; }
@keyframes msg-float { 50% { transform: translateY(-8px); } }
.msg-welcome-title { font-size: 1.45rem; font-weight: 800; margin: 0; }
.msg-welcome-text { margin: 0; color: #64748b; }
.msg-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; width: 100%; margin: 8px 0; }
@media (min-width: 1200px) { .msg-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.msg-stat { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 16px; background: #fff; box-shadow: var(--shadow); text-align: start; }
.msg-stat b { display: block; font-size: 1.2rem; font-weight: 800; line-height: 1.1; }
.msg-stat small { font-size: .72rem; color: #64748b; }
.msg-welcome-note { font-size: .78rem; color: #64748b; }

/* ---- image viewer ---- */
.msg-lightbox {
    position: fixed; inset: 0; z-index: 2000; display: flex; align-items: center; justify-content: center; padding: 70px 20px;
    background: rgba(15, 23, 42, .88); backdrop-filter: blur(6px); animation: msg-in .15s ease-out;
}
.msg-lightbox img { max-width: 100%; max-height: 100%; border-radius: 12px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.msg-lightbox-close { position: absolute; top: 18px; inset-inline-end: 18px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; font-size: 1.1rem; }
.msg-lightbox-download { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); padding: 9px 18px; border-radius: 12px; background: #fff; color: #0f172a; font-weight: 700; text-decoration: none; }

/* ---- group chat form ---- */
.chat-form-grid { display: grid; gap: 18px; align-items: start; }
@media (min-width: 1200px) { .chat-form-grid { grid-template-columns: minmax(0, 1fr) 320px; } }
.chat-form-grid .app-form, .chat-form-grid .form-section { max-width: none; }
.audience-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.audience-card { position: relative; display: flex; gap: 14px; padding: 16px; margin: 0; border: 2px solid var(--line); border-radius: 18px; background: #fff; cursor: pointer; transition: all .15s; }
.audience-card:hover { border-color: color-mix(in srgb, var(--brand) 40%, white); }
.audience-card:has(input:checked) { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 5%, white); box-shadow: 0 6px 16px color-mix(in srgb, var(--brand) 14%, transparent); }
.audience-card input { position: absolute; opacity: 0; pointer-events: none; }
.audience-card-title { display: block; font-weight: 800; margin-bottom: 2px; }
.audience-card-text { display: block; font-size: .8rem; color: #64748b; }
.audience-card-check { position: absolute; top: 12px; inset-inline-end: 12px; width: 22px; height: 22px; border-radius: 50%; border: 2px solid #cbd5e1; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: .8rem; }
.audience-card:has(input:checked) .audience-card-check { background: var(--brand); border-color: var(--brand); }
.picker-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 12px; }
.picker-toolbar .msg-search { flex: 1 1 240px; max-width: 380px; }
.picker-count { margin-inline-start: auto; padding: 6px 12px; border-radius: 20px; background: color-mix(in srgb, var(--brand) 10%, white); color: var(--brand); font-size: .8rem; font-weight: 700; }
.pick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; max-height: 460px; overflow-y: auto; padding: 2px; }
.pick-card { position: relative; display: flex; align-items: center; gap: 10px; padding: 10px 12px; margin: 0; border: 1px solid var(--line); border-radius: 16px; background: #fff; cursor: pointer; transition: all .15s; }
.pick-card:hover { border-color: color-mix(in srgb, var(--brand) 40%, white); }
.pick-card input { position: absolute; opacity: 0; pointer-events: none; }
.pick-card:has(input:checked) { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 6%, white); }
.pick-card[hidden] { display: none; }
.pick-card .avatar { width: 40px; height: 40px; }
.pick-check { margin-inline-start: auto; width: 22px; height: 22px; flex-shrink: 0; border-radius: 7px; border: 2px solid #cbd5e1; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: .8rem; transition: all .15s; }
.pick-card:has(input:checked) .pick-check { background: var(--brand); border-color: var(--brand); }
.chat-preview { position: sticky; top: 100px; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.chat-preview-head { padding: 26px 18px 18px; text-align: center; color: #fff; background: var(--hero-bg); }
.chat-preview-head .msg-avatar { background: rgba(255, 255, 255, .18); box-shadow: none; border: 1px solid rgba(255, 255, 255, .3); }
.chat-preview-name { display: block; margin-top: 10px; font-weight: 800; font-size: 1.05rem; word-break: break-word; }
.chat-preview-sub { font-size: .8rem; opacity: .85; }
.chat-preview-body { padding: 16px; }
.chat-preview-faces { display: flex; flex-wrap: wrap; gap: 4px; min-height: 36px; }
.chat-preview-faces .avatar { width: 32px; height: 32px; box-shadow: 0 0 0 2px #fff; }
.chat-preview-list { list-style: none; margin: 14px 0 0; padding: 0; font-size: .8rem; color: #475569; display: flex; flex-direction: column; gap: 8px; }
.chat-preview-list .bi { color: var(--brand); }

/* ---- chat pictures ---- */
.msg-avatar-img { object-fit: cover; background: #fff; padding: 0; border: 1px solid var(--line); }
.msg-avatar-sm { width: 38px; height: 38px; border-radius: 12px; font-size: .95rem; }
.msg-off-dot {
    position: absolute; bottom: -3px; inset-inline-end: -3px; width: 20px; height: 20px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center; font-size: .6rem;
    background: #f59e0b; color: #fff; border: 2px solid #fff;
}
.chat-preview-avatar { position: relative; overflow: hidden; }
.chat-preview-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* ---- roles: administration, project manager, team lead ---- */
.msg-role {
    display: inline-flex; align-items: center; gap: 3px; margin-top: 2px; padding: 1px 8px; border-radius: 20px;
    font-style: normal; font-size: .66rem; font-weight: 800; white-space: nowrap;
}
.msg-role-admin { background: #0f172a; color: #fff; }
.msg-role-manager { background: #ede9fe; color: #6d28d9; }
.msg-role-lead { background: #e0f2fe; color: #0369a1; }
.msg-sender .msg-role { margin-top: 0; }
.msg-bubble.role-admin { background: #f8fafc; border-inline-start: 3px solid #0f172a; }
.msg-bubble.role-manager { border-inline-start: 3px solid #7c3aed; }
.msg-bubble.role-lead { border-inline-start: 3px solid #0284c7; }

/* ---- links in messages ---- */
.msg-link { color: var(--brand-dark); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; word-break: break-all; }
.msg.is-mine .msg-link { color: #fff; }

/* ---- disabled chat ---- */
.msg-disabled-bar {
    display: flex; align-items: center; justify-content: center; gap: 8px; padding: 8px 16px;
    background: #fffbeb; border-bottom: 1px solid #fde68a; color: #92400e; font-size: .82rem; font-weight: 700;
}
.msg-state-pill { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 20px; font-size: .72rem; font-weight: 700; }
.msg-state-pill .bi { font-size: .55rem; }
.msg-state-pill.is-on { background: #dcfce7; color: #15803d; }
.msg-state-pill.is-off { background: #fef3c7; color: #b45309; }
.msg-state-pill.is-off .bi { font-size: .7rem; }

/* ---- emoji picker ---- */
.msg-composer { position: relative; }
.msg-emoji-panel {
    position: absolute; bottom: calc(100% - 4px); inset-inline-start: 16px; z-index: 6; width: min(340px, calc(100% - 32px));
    background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg); overflow: hidden; animation: msg-in .15s ease-out;
}
.emoji-tabs { display: flex; gap: 2px; padding: 6px; border-bottom: 1px solid var(--line); background: #f8fafc; }
.emoji-tabs button { flex: 1; border: 0; background: none; border-radius: 10px; padding: 6px; color: #64748b; }
.emoji-tabs button.active, .emoji-tabs button:hover { background: #fff; color: var(--brand); box-shadow: 0 1px 3px rgba(15, 23, 42, .08); }
.emoji-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 2px; padding: 8px; max-height: 220px; overflow-y: auto; }
.emoji-grid .emoji { border: 0; background: none; border-radius: 10px; font-size: 1.35rem; line-height: 1; padding: 6px 0; transition: transform .1s, background .1s; }
.emoji-grid .emoji:hover { background: #f1f5f9; transform: scale(1.18); }

/* ---- administration controls (details panel) ---- */
.msg-admin-box { background: #f8fafc; }
.msg-admin-box .form-text { font-size: .7rem; }
.msg-rename { margin-bottom: 10px; padding: 12px; border-radius: 14px; background: #fff; border: 1px solid var(--line); }
.msg-wa-box textarea { font-size: .78rem; resize: vertical; }
.msg-person-tools { display: inline-flex; align-items: center; gap: 4px; flex-shrink: 0; }
.msg-person-tools .row-btn { width: 30px; height: 30px; font-size: .85rem; }
.msg-wa-btn {
    width: 30px; height: 30px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center;
    background: #dcfce7; color: #16a34a; font-size: .95rem; text-decoration: none; transition: all .15s;
}
.msg-wa-btn:hover { background: #16a34a; color: #fff; }
.msg-wa-btn.is-sent { background: #16a34a; color: #fff; }
.msg-wa-btn.is-missing { background: #f1f5f9; color: #cbd5e1; cursor: not-allowed; }
.msg-add-member { display: flex; gap: 6px; margin-top: 10px; }
.msg-person .msg-role { display: inline-flex; }

/* ---- live notifications (top bar) ---- */
.chat-dot { background: var(--brand); }
.chat-notify-menu { width: 340px; overflow: hidden; }
.chat-notify-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.chat-notify-head .bi { color: var(--brand); }
.chat-notify-list { max-height: 360px; overflow-y: auto; padding: 6px; }
.chat-notify-item { display: flex; align-items: center; gap: 10px; padding: 9px; border-radius: 12px; color: inherit; text-decoration: none; }
.chat-notify-item:hover { background: #f1f4f9; color: inherit; }
.chat-notify-name { display: block; font-weight: 800; font-size: .84rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-notify-text { display: block; font-size: .76rem; color: #64748b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-notify-text b { color: #334155; font-weight: 700; }
.chat-notify-when { font-size: .68rem; color: #94a3b8; }
.chat-notify-empty { padding: 22px 14px; text-align: center; font-size: .82rem; color: #64748b; }
.chat-notify-empty .bi { color: #16a34a; }
.chat-notify-enable { width: 100%; padding: 10px; border: 0; border-top: 1px solid var(--line); background: #f8fafc; color: var(--brand); font-size: .8rem; font-weight: 700; }
.chat-notify-enable:hover { background: color-mix(in srgb, var(--brand) 8%, white); }

.chat-toasts { position: fixed; bottom: 20px; inset-inline-end: 20px; z-index: 1090; display: flex; flex-direction: column; gap: 10px; width: min(360px, calc(100vw - 32px)); }
.chat-toast {
    display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 18px; color: inherit; text-decoration: none;
    background: rgba(255, 255, 255, .97); backdrop-filter: blur(8px); border: 1px solid var(--line);
    box-shadow: 0 16px 40px rgba(15, 23, 42, .18); animation: toast-in .3s cubic-bezier(.2, .9, .3, 1.2);
    border-inline-start: 4px solid var(--brand); transition: opacity .35s, transform .35s;
}
.chat-toast:hover { color: inherit; }
.chat-toast.is-leaving { opacity: 0; transform: translateY(10px); }
.chat-toast-title { display: block; font-size: .72rem; font-weight: 800; color: var(--brand); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-toast-text { display: block; font-size: .84rem; color: #1e293b; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.chat-toast-close { flex-shrink: 0; align-self: flex-start; width: 26px; height: 26px; border: 0; border-radius: 50%; background: #f1f5f9; color: #64748b; font-size: .7rem; }
@keyframes toast-in { from { opacity: 0; transform: translateY(20px) scale(.96); } to { opacity: 1; transform: none; } }

/* =========================================================================
   Version footer (app/version.php)
   ========================================================================= */
.version-footer {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px 10px;
    padding: 4px 16px 18px; font-size: .75rem; color: #94a3b8;
}
.version-dot { opacity: .5; }
.version-badge {
    display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 20px;
    background: #fff; border: 1px solid var(--line); color: #475569; font-weight: 600; box-shadow: var(--shadow);
}
.version-badge .bi { color: var(--brand); font-size: .7rem; }
.version-badge b { color: var(--brand); }
.version-badge-dark { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .12); color: #cbd5e1; box-shadow: none; }
.version-badge-dark b, .version-badge-dark .bi { color: #a5b4fc; }
.version-warn { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 20px; background: #fef3c7; color: #92400e; font-weight: 700; }
.version-guest { padding-top: 0; }

/* ===================== Update 03 (v4.0.0) ===================== */

/* Shared pills */
.pill-bad { background: #ffe4e6; color: #be123c; }
.pill-muted { background: #f1f5f9; color: #64748b; }
.pill-info { background: #e0f2fe; color: #0369a1; }
.score-pill { display: inline-flex; align-items: center; justify-content: center; min-width: 38px; height: 28px; padding: 0 8px; border-radius: 10px; color: #fff; font-weight: 800; font-size: .85rem; }
.audience-card.is-disabled { opacity: .55; cursor: not-allowed; }

/* Library */
.lib-hero { position: relative; overflow: hidden; border-radius: var(--radius); background: linear-gradient(120deg, #312e81 0%, #6d28d9 55%, #db2777 130%); color: #fff; box-shadow: var(--shadow-lg); }
.lib-hero-body { position: relative; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding: 28px; }
.lib-hero-kicker { font-size: .8rem; font-weight: 700; opacity: .85; letter-spacing: .04em; }
.lib-hero-title { font-size: 1.6rem; font-weight: 800; margin: 6px 0; }
.lib-hero-text { opacity: .85; margin-bottom: 16px; max-width: 560px; }
.lib-hero-search { position: relative; display: flex; gap: 8px; max-width: 560px; }
.lib-hero-search > i { position: absolute; inset-inline-start: 14px; top: 50%; transform: translateY(-50%); color: #64748b; }
.lib-hero-search input { flex: 1; min-width: 0; border: 0; border-radius: 12px; padding: 11px 14px; padding-inline-start: 40px; outline: none; }
.lib-hero-stats { display: flex; flex-wrap: wrap; gap: 10px; }
.lib-hero-stat { display: flex; flex-direction: column; align-items: center; min-width: 96px; padding: 14px 10px; border-radius: 16px; background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .22); color: #fff; text-decoration: none; transition: background .15s; }
.lib-hero-stat:hover { background: rgba(255, 255, 255, .25); color: #fff; }
.lib-hero-stat i { font-size: 1.3rem; }
.lib-hero-stat strong { font-size: 1.4rem; line-height: 1.2; }
.lib-hero-stat span { font-size: .75rem; opacity: .85; }
.lib-sections { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; }
.lib-section { display: inline-flex; align-items: center; gap: 8px; flex-shrink: 0; padding: 8px 12px 8px 8px; border-radius: 14px; background: #fff; box-shadow: var(--shadow); color: #334155; text-decoration: none; font-weight: 600; font-size: .88rem; border: 2px solid transparent; }
.lib-section:hover { color: #0f172a; border-color: var(--line); }
.lib-section.active { border-color: var(--brand); color: var(--brand); }
.lib-section-icon { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 10px; background: color-mix(in srgb, var(--sec) 14%, white); color: var(--sec); }
.lib-section-icon-lg { width: 48px; height: 48px; border-radius: 14px; font-size: 1.3rem; flex-shrink: 0; }
.lib-section-count { padding: 1px 8px; border-radius: 20px; background: #f1f5f9; color: #64748b; font-size: .75rem; }
.lib-card { height: 100%; display: flex; flex-direction: column; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); overflow: hidden; transition: transform .15s, box-shadow .15s; }
.lib-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.lib-card.is-draft { opacity: .75; }
.lib-card-media { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: #0f172a; color: #e2e8f0; text-decoration: none; }
.lib-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.lib-card:hover .lib-card-media img { transform: scale(1.04); }
.lib-play { position: absolute; inset: 0; margin: auto; width: 56px; height: 56px; border-radius: 50%; background: rgba(225, 29, 72, .92); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 1.8rem; box-shadow: 0 8px 24px rgba(0, 0, 0, .35); }
.lib-peek { position: absolute; inset: 0; padding: 44px 18px 18px; font-size: .82rem; line-height: 1.6; overflow: hidden; }
.lib-prompt .lib-card-media { background: linear-gradient(135deg, #1e1b4b, #4c1d95); }
.lib-post .lib-card-media { background: linear-gradient(135deg, #0c4a6e, #0369a1); }
.lib-peek-code { font-family: ui-monospace, Consolas, monospace; color: #c4b5fd; }
.lib-peek::after { content: ""; position: absolute; inset: auto 0 0 0; height: 50%; background: linear-gradient(transparent, rgba(15, 23, 42, .85)); }
.lib-type { position: absolute; top: 10px; inset-inline-start: 10px; display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 20px; background: rgba(15, 23, 42, .7); color: #fff; font-size: .72rem; font-weight: 700; backdrop-filter: blur(4px); }
.lib-pin { position: absolute; top: 10px; inset-inline-end: 10px; width: 28px; height: 28px; border-radius: 50%; background: #f59e0b; color: #fff; display: flex; align-items: center; justify-content: center; }
.lib-card-body { flex: 1; display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; }
.lib-card-title { font-weight: 700; color: #0f172a; text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lib-card-title:hover { color: var(--brand); }
.lib-card-text { margin: 0; font-size: .82rem; color: #64748b; }
.lib-card-foot { margin-top: auto; padding-top: 8px; display: flex; align-items: center; gap: 6px; }
.lib-fav.is-on { color: #e11d48; background: #ffe4e6; }
.lib-detail-title { font-size: 1.45rem; font-weight: 800; margin: 0 0 6px; }
.lib-detail-summary { color: #475569; font-size: .95rem; }
.lib-player { background: #000; }
.lib-content { border-radius: 14px; border: 1px solid var(--line); overflow: hidden; }
.lib-content-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 12px; background: #f8fafc; border-bottom: 1px solid var(--line); font-weight: 700; font-size: .85rem; }
.lib-content-head .copy-btn { border: 1px solid var(--line); background: #fff; }
.lib-content-body { padding: 16px; line-height: 1.9; word-break: break-word; }
.lib-content.is-prompt { border-color: #312e81; }
.lib-content.is-prompt .lib-content-head { background: #1e1b4b; color: #c4b5fd; border-color: #312e81; }
.lib-content.is-prompt .lib-content-body { background: #0f172a; color: #e2e8f0; font-family: ui-monospace, Consolas, monospace; font-size: .88rem; }
.lib-tag { padding: 3px 10px; border-radius: 20px; background: color-mix(in srgb, var(--brand) 10%, white); color: var(--brand); font-size: .78rem; font-weight: 600; }
.lib-category { display: flex; align-items: center; gap: 14px; height: 100%; padding: 16px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); border-top: 4px solid var(--sec); }

/* Messages */
.wa-phone { padding: 16px; background: #efeae2; max-height: 460px; overflow-y: auto; }
.wa-bubble { max-width: 92%; margin-inline-start: auto; padding: 10px 12px; border-radius: 12px; border-start-end-radius: 2px; background: #d9fdd3; color: #111b21; font-size: .88rem; line-height: 1.6; box-shadow: 0 1px 1px rgba(0, 0, 0, .1); word-break: break-word; }
.wa-link { color: #027eb5; text-decoration: underline; }
.mail-preview { padding: 14px; background: #f3f5fb; max-height: 560px; overflow-y: auto; }
.wa-pending { margin-bottom: 1rem; padding: 14px 16px; border-radius: var(--radius); background: #ecfdf5; border: 1px solid #a7f3d0; }
.msg-log-body { margin: 6px 0 0; padding: 10px; border-radius: 10px; background: #f8fafc; white-space: pre-wrap; font-family: inherit; font-size: .8rem; max-height: 260px; overflow-y: auto; }
.channel-checks { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.channel-check { display: inline-flex; align-items: center; gap: 5px; margin: 0; padding: 4px 10px; border-radius: 20px; border: 1px solid var(--line); background: #fff; font-size: .82rem; cursor: pointer; }
.channel-check:has(input:checked) { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 8%, white); }
.channel-check.is-disabled { opacity: .5; cursor: not-allowed; }
.channel-check input { margin: 0; }

/* Reports */
.report-range { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.report-range-custom { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.report-range-custom input { width: auto; }
.report-head { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; padding: 20px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); }
.report-head-name { font-size: 1.35rem; font-weight: 800; margin: 0 0 4px; }
.heat-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.heat-head { margin-bottom: 6px; font-size: .72rem; color: #64748b; text-align: center; font-weight: 600; }
.heat-cell { display: inline-flex; align-items: center; justify-content: center; aspect-ratio: 1; min-width: 18px; border-radius: 8px; font-size: .72rem; font-weight: 700; color: #475569; background: #f1f5f9; }
.heat-grid .heat-cell { width: 100%; }
.heat-cell.is-blank { background: transparent; }
.heat-cell.is-off { background: repeating-linear-gradient(45deg, #f8fafc, #f8fafc 4px, #eef2f7 4px, #eef2f7 8px); color: #94a3b8; }
.heat-cell.is-future { opacity: .35; }
.heat-1 { background: #c7d2fe; color: #312e81; }
.heat-2 { background: #818cf8; color: #fff; }
.heat-3 { background: #4f46e5; color: #fff; }
.heat-4 { background: #312e81; color: #fff; }
.heat-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin-top: 12px; font-size: .75rem; color: #64748b; }
.heat-legend .heat-cell { width: 16px; height: 16px; min-width: 16px; border-radius: 4px; }

/* Notices */
.notice-item { border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); border-inline-start: 5px solid #f59e0b; overflow: hidden; }
.notice-item.level-info { border-inline-start-color: #0ea5e9; }
.notice-item.level-final { border-inline-start-color: #e11d48; }
.notice-item.is-open { background: linear-gradient(90deg, #fffdf5, #fff 40%); }
.notice-item-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px 6px; }
.notice-item-body { padding: 4px 16px 12px; color: #334155; font-size: .9rem; line-height: 1.8; }
.notice-item-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 16px; border-top: 1px solid var(--line); background: #fafbfd; }
.notice-deduct { display: inline-flex; gap: 4px; }
.notice-deduct input { width: 110px; }
.notice-banner { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 1rem; padding: 12px 16px; border-radius: var(--radius); background: linear-gradient(90deg, #f59e0b, #d97706); color: #fff; box-shadow: var(--shadow); }
.notice-banner.level-final { background: linear-gradient(90deg, #e11d48, #9f1239); }
.attention-card .list-group-item { padding: 12px 18px; }

/* Attendance */
.att-chip { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 12px; border-radius: 12px; border: 0; font-weight: 700; font-size: .85rem; text-decoration: none; white-space: nowrap; }
.att-in { background: #059669; color: #fff; }
.att-in:hover { background: #047857; }
.att-working { background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0; }
.att-done { background: #f1f5f9; color: #475569; }
.att-pulse { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: #10b981; box-shadow: 0 0 0 0 rgba(16, 185, 129, .6); animation: att-pulse 1.6s infinite; }
@keyframes att-pulse { 70% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); } 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); } }
.att-menu { min-width: 260px; }
.att-today { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding: 20px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); }
.att-action { display: flex; flex-direction: column; gap: 8px; min-width: 220px; }
.att-row-off td { background: #fafbfd; color: #94a3b8; }
.att-row-today td { background: color-mix(in srgb, var(--brand) 5%, white); }

/* Daily reports */
.daily-head { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 16px 18px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); }
.daily-task { border: 1px solid var(--line); border-radius: 14px; background: #fff; transition: border-color .15s, background .15s; }
.daily-task:has(.daily-task-head input:checked) { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 4%, white); }
.daily-task-head { display: flex; align-items: center; gap: 12px; margin: 0; padding: 12px 14px; cursor: pointer; }
.daily-task-head .form-check-input { width: 1.3em; height: 1.3em; margin: 0; flex-shrink: 0; }
.daily-task-body { margin: 0; padding: 0 14px 12px; }
.daily-task:not(:has(.daily-task-head input:checked)) .daily-task-body { display: none; }
.daily-score-hint { height: 100%; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 12px; background: #f5f3ff; color: #5b21b6; font-size: .85rem; }
.daily-block-title { font-weight: 700; margin-bottom: 6px; color: #0f172a; }
.daily-block-body { padding: 12px 14px; border-radius: 12px; background: #f8fafc; line-height: 1.9; color: #334155; }

@media print {
    .sidebar, .topbar, .version-footer, .d-print-none, .notice-banner, .wa-pending { display: none !important; }
    .data-card, .kpi-card, .report-head { box-shadow: none !important; border: 1px solid #e2e8f0; break-inside: avoid; }
}

/* Send page: WhatsApp and e-mail cards */
.send-to { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 20px; background: #f1f5f9; font-size: .85rem; font-weight: 600; }
.send-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); background: #fafbfd; }
.send-card .wa-phone { max-height: 300px; }
.send-card .mail-preview { max-height: 360px; }
[data-wa-manual].is-sent { background: #047857; border-color: #047857; }

/* =========================================================================
   Enterprise theme (v4.0.0): calm neutral surfaces, hairline borders, flush
   navigation, one accent colour. Inter for English, IBM Plex Sans Arabic for Arabic.
   ========================================================================= */
:root {
    --brand: #1d4ed8;
    --brand-dark: #1e40af;
    --accent: #93c5fd;
    --page-bg: #f4f6f9;
    --line: #e3e7ee;
    --radius: 12px;
    --shadow: 0 1px 2px rgba(16, 24, 40, .05);
    --shadow-lg: 0 10px 28px rgba(16, 24, 40, .10);
    --sidebar-bg: #0b1220;
    --ink: #101828;
    --ink-2: #475467;
    --ink-3: #667085;
    --spark: #98a2b3;
    --spark-accent: var(--brand);
    --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
[dir="rtl"] { --font: 'IBM Plex Sans Arabic', 'Cairo', system-ui, sans-serif; }
.panel-team { --brand: #0f766e; --brand-dark: #115e59; --accent: #5eead4; --sidebar-bg: #072624; }

body { font-family: var(--font); color: var(--ink); font-size: .9375rem; -webkit-font-smoothing: antialiased; }
[dir="ltr"] body { letter-spacing: -.003em; }
h1, h2, h3, .fw-bold { letter-spacing: -.01em; }
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, [dir="rtl"] .fw-bold { letter-spacing: 0; }

/* ---- controls ---- */
.btn { border-radius: 8px; font-weight: 500; }
.btn-sm { border-radius: 7px; }
.btn-light.border { background: #fff; border-color: var(--line) !important; color: var(--ink); }
.btn-light.border:hover { background: #f8fafc; }
.form-control, .form-select { border-radius: 8px; border-color: #d0d5dd; }
.badge { border-radius: 6px; font-weight: 600; }
.dropdown-menu { border-radius: 10px; border: 1px solid var(--line) !important; }

/* ---- surfaces: hairline border, almost no shadow ---- */
.card, .data-card, .kpi-card, .form-section, .feature-switch, .resource-tile, .project-card, .notice-item, .lib-card,
.report-head, .att-today, .daily-head, .lib-category, .daily-task, .switch-card {
    border-radius: var(--radius);
    border: 1px solid var(--line) !important;
    box-shadow: var(--shadow) !important;
}
.kpi-card:hover, .resource-tile:hover, .project-card:hover, .lib-card:hover { box-shadow: var(--shadow-lg) !important; }
.data-head { padding: 14px 18px; }
.data-head-title { font-size: .95rem; font-weight: 600; }
.kpi-value { font-weight: 600; }
.table > thead th { background: #f9fafb; color: var(--ink-3); font-weight: 600; font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; }
[dir="rtl"] .table > thead th { text-transform: none; letter-spacing: 0; font-size: .78rem; }
.data-table td { border-color: #f0f2f5; }

/* Icon tiles: tinted square, coloured glyph (instead of gradients) */
.tile-indigo { --tile: #4f46e5; } .tile-sky { --tile: #0284c7; } .tile-teal { --tile: #0d9488; } .tile-emerald { --tile: #059669; }
.tile-amber { --tile: #d97706; } .tile-rose { --tile: #e11d48; } .tile-violet { --tile: #7c3aed; } .tile-lime { --tile: #4d7c0f; } .tile-slate { --tile: #475467; }
.icon-tile[class*="tile-"] { background: color-mix(in srgb, var(--tile) 11%, white); color: var(--tile); border-radius: 8px; }
.score-pill[class*="tile-"] { background: var(--tile); }

/* ---- navigation: flush dark sidebar, monochrome icons, collapsible groups ---- */
@media (min-width: 992px) {
    .sidebar, [dir="rtl"] .sidebar { padding: 0; }
}
.sidebar-inner { background: var(--sidebar-bg); border-radius: 0; box-shadow: none; border-inline-end: 1px solid rgba(255, 255, 255, .04); }
.sidebar-inner::after { display: none; }
.sidebar-brand { padding: 16px; }
.brand-icon { width: 36px; height: 36px; border-radius: 9px; background: var(--brand); box-shadow: none; font-size: 1.05rem; }
.sidebar-toggle { border-radius: 8px; }
.sidebar-nav { padding: 4px 10px 12px; }
.nav-section { font-size: .68rem; font-weight: 600; letter-spacing: .07em; color: rgba(255, 255, 255, .42); padding: 14px 10px 4px; }
[dir="rtl"] .nav-section { text-transform: none; letter-spacing: 0; font-size: .76rem; }
.nav-group-toggle { display: flex; align-items: center; gap: 6px; width: 100%; border: 0; background: none; text-align: start; cursor: pointer; border-radius: 6px; }
.nav-group-toggle:hover { color: rgba(255, 255, 255, .75); }
.nav-group-toggle .bi { font-size: .65rem; transition: transform .2s; }
.nav-group:not(.is-open) .nav-group-items { display: none; }
.nav-group:not(.is-open) .nav-group-toggle .bi { transform: rotate(-90deg); }
[dir="rtl"] .nav-group:not(.is-open) .nav-group-toggle .bi { transform: rotate(90deg); }
.nav-group-dot { width: 7px; height: 7px; border-radius: 50%; background: #f04438; }
.side-link { gap: 10px; padding: 7px 10px; margin-bottom: 1px; border-radius: 7px; font-size: .875rem; color: #c3cad6; }
.side-link:hover, [dir="rtl"] .side-link:hover { transform: none; background: rgba(255, 255, 255, .05); }
.side-link.active { background: rgba(255, 255, 255, .09); box-shadow: none; font-weight: 600; }
.side-link.active::before { inset-inline-start: -10px; top: 7px; bottom: 7px; width: 3px; border-radius: 2px; background: #60a5fa; }
.panel-team .side-link.active::before { background: #5eead4; }
.side-icon[class*="tile-"] { width: 20px; height: 20px; background: transparent; box-shadow: none; color: #8792a6; font-size: 1rem; opacity: 1; }
.side-link.active .side-icon, .side-link:hover .side-icon { color: #fff; }
.side-badge { background: #f04438; border-radius: 6px; }
.sidebar-user { border-radius: 10px; margin: 8px 10px 12px; }
.sidebar-user .avatar { box-shadow: none; }
@media (min-width: 992px) {
    .sidebar-mini .sidebar { width: 76px; }
    .sidebar-mini .nav-group-items { display: block !important; }
    .sidebar-mini .nav-group-toggle { pointer-events: none; }
    .sidebar-mini .nav-group-toggle .bi, .sidebar-mini .nav-group-dot { display: none; }
}

/* ---- top bar: flat, breadcrumb, search ---- */
.topbar { top: 0; margin: 0; min-height: 64px; padding: 10px 24px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: rgba(255, 255, 255, .94); box-shadow: none; }
@media (min-width: 992px) { .topbar { margin: 0; } }
.topbar-crumbs { display: flex; align-items: center; gap: 6px; font-size: .74rem; color: var(--ink-3); }
.topbar-crumbs a { color: inherit; text-decoration: none; }
.topbar-crumbs a:hover { color: var(--brand); }
.topbar-crumbs .bi { font-size: .58rem; }
.topbar-title { font-size: 1.02rem; font-weight: 600; }
.topbar-search { position: relative; align-items: center; width: 250px; }
.topbar-search .bi { position: absolute; inset-inline-start: 11px; color: var(--ink-3); font-size: .85rem; }
.topbar-search input { width: 100%; height: 38px; padding-inline: 32px 12px; border: 1px solid var(--line); border-radius: 8px; background: #f9fafb; font-size: .85rem; outline: none; }
.topbar-search input:focus { border-color: var(--brand); background: #fff; box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 14%, transparent); }
.icon-btn { width: 38px; height: 38px; border-radius: 8px; font-size: 1rem; }
.user-chip { border-radius: 10px; }
.att-chip { height: 38px; border-radius: 8px; }
.app-content { padding: 22px 16px 36px; }
@media (min-width: 992px) { .app-content { padding: 24px 28px 44px; } }

/* ---- hero (team dashboard): calm header card ---- */
.hero-card { background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.hero-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--brand); }
.hero-card-body { padding: 22px 24px; }
.hero-card-date { color: var(--ink-3); opacity: 1; }
.hero-card-title { font-size: 1.35rem; font-weight: 600; }
.hero-card-text { color: var(--ink-2); opacity: 1; }
.btn-glass { color: var(--ink); background: #fff; border: 1px solid var(--line); backdrop-filter: none; }
.btn-glass:hover { color: var(--brand); background: #f8fafc; }
.lib-hero { background: #0b1220; box-shadow: none; }

/* Day navigation arrows point the reading direction */
[dir="ltr"] .nav-step .bi { display: inline-block; transform: scaleX(-1); }

/* =========================================================================
   Admin dashboard
   ========================================================================= */
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.page-head-kicker { font-size: .74rem; font-weight: 500; color: var(--ink-3); text-transform: uppercase; letter-spacing: .06em; }
[dir="rtl"] .page-head-kicker { text-transform: none; letter-spacing: 0; }
.page-head-title { margin: 2px 0 4px; font-size: 1.5rem; font-weight: 600; }
.page-head-text { margin: 0; color: var(--ink-2); font-size: .9rem; }
.page-head-actions { display: flex; flex-wrap: wrap; gap: 8px; }

.stat-tile { display: flex; flex-direction: column; gap: 10px; height: 100%; padding: 16px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); color: inherit; text-decoration: none; transition: border-color .15s, box-shadow .15s; }
.stat-tile.is-link:hover { color: inherit; border-color: color-mix(in srgb, var(--brand) 35%, var(--line)); box-shadow: var(--shadow-lg); }
.stat-tile-head { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: .78rem; font-weight: 500; color: var(--ink-3); }
.stat-tile-go { opacity: 0; transition: opacity .15s; }
.stat-tile:hover .stat-tile-go { opacity: 1; }
[dir="rtl"] .stat-tile-go { transform: scaleX(-1); }
.stat-tile-body { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 8px; }
.stat-tile-value { font-size: 1.55rem; font-weight: 600; line-height: 1.15; color: var(--ink); }
.stat-tile-sub { margin-top: 4px; font-size: .76rem; color: var(--ink-3); }
.stat-tile-sub.tone-good .bi { color: #039855; }
.stat-tile-sub.tone-warning .bi { color: #dc6803; }
.stat-tile-sub.tone-critical .bi { color: #d92d20; }
.sparkline { flex-shrink: 0; overflow: visible; }

.panel { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 16px 18px 0; }
.panel-title { margin: 0; font-size: .97rem; font-weight: 600; }
.panel-sub { margin-top: 2px; font-size: .77rem; color: var(--ink-3); }
.panel-link { font-size: .8rem; font-weight: 500; color: var(--brand); text-decoration: none; white-space: nowrap; }
.panel-link:hover { text-decoration: underline; }
[dir="rtl"] .panel-link .bi { display: inline-block; transform: scaleX(-1); }
.panel-body { flex: 1; padding: 16px 18px 18px; }
.panel-table { margin-top: 12px; }
.panel-table > :not(caption) > * > *:first-child { padding-inline-start: 18px; }
.panel-table > :not(caption) > * > *:last-child { padding-inline-end: 18px; }
.panel-foot-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.panel-foot-stats span { display: block; font-size: .72rem; color: var(--ink-3); }
.panel-foot-stats strong { font-size: 1.05rem; font-weight: 600; }
@media (max-width: 575.98px) { .panel-foot-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.panel-note { margin-top: 14px; font-size: .77rem; color: var(--ink-3); }

/* Charts: thin marks, 2px surface gaps, recessive grid */
.chart-legend-row { display: flex; flex-wrap: wrap; gap: 16px; margin: 0 0 10px; padding: 0; list-style: none; font-size: .78rem; color: var(--ink-2); }
.chart-legend-row li { display: flex; align-items: center; gap: 6px; }
.legend-swatch { display: inline-block; width: 10px; height: 10px; border-radius: 3px; flex-shrink: 0; vertical-align: -1px; }
.chart-plot { position: relative; padding-inline-start: 34px; padding-bottom: 22px; }
.chart-grid { position: absolute; top: 0; bottom: 22px; inset-inline-start: 34px; inset-inline-end: 0; }
.chart-gridline { position: absolute; left: 0; right: 0; border-top: 1px solid #eef0f4; }
.chart-gridline span { position: absolute; inset-inline-end: calc(100% + 8px); top: -8px; font-size: .68rem; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.chart-cols { position: relative; display: flex; align-items: flex-end; gap: 2px; height: 100%; }
.chart-col { position: relative; flex: 1; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; border-radius: 4px; outline: none; }
.chart-col:hover, .chart-col:focus-visible { background: #f2f4f7; }
.chart-col:focus-visible { box-shadow: 0 0 0 2px var(--brand); }
.chart-stack-col { display: flex; flex-direction: column-reverse; gap: 2px; width: min(24px, 70%); }
.chart-stack-col span { display: block; min-height: 3px; }
.chart-stack-col span:last-child { border-radius: 4px 4px 0 0; }
.chart-xlabel { position: absolute; bottom: -20px; font-size: .68rem; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.chart-tip { position: fixed; z-index: 2000; max-width: 240px; padding: 8px 10px; border-radius: 8px; background: #101828; color: #fff; font-size: .75rem; line-height: 1.55; white-space: pre-line; pointer-events: none; box-shadow: var(--shadow-lg); }

.pipeline-bar { display: flex; gap: 2px; height: 14px; }
.pipeline-bar span { display: block; min-width: 4px; outline: none; }
.pipeline-bar span:first-child { border-start-start-radius: 4px; border-end-start-radius: 4px; }
.pipeline-bar span:last-child { border-start-end-radius: 4px; border-end-end-radius: 4px; }
.pipeline-bar span:focus-visible { box-shadow: 0 0 0 2px var(--ink); }
.pipeline-empty { flex: 1; background: #eef0f4; border-radius: 4px; }
.pipeline-legend { display: grid; gap: 7px; margin: 14px 0 0; padding: 0; list-style: none; font-size: .83rem; }
.pipeline-legend li { display: flex; align-items: center; gap: 8px; }
.pipeline-legend strong { min-width: 26px; text-align: end; font-weight: 600; font-variant-numeric: tabular-nums; }
.pipeline-legend .small { min-width: 38px; text-align: end; font-variant-numeric: tabular-nums; }

.meter-head { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 6px; font-size: .8rem; color: var(--ink-2); }
.meter-head strong { color: var(--ink); font-weight: 600; }
.meter-track { height: 8px; border-radius: 4px; background: #dbe7fb; overflow: hidden; }
.meter-fill { height: 100%; border-radius: 4px; background: #2a78d6; }
.meter-danger .meter-track { background: #fde2e1; } .meter-danger .meter-fill { background: #d92d20; }
.meter-good .meter-track { background: #d1fadf; } .meter-good .meter-fill { background: #039855; }

.figure-label { font-size: .77rem; color: var(--ink-3); }
.figure-value { font-size: 2rem; font-weight: 600; line-height: 1.15; }
.figure-list { display: grid; gap: 0; margin: 14px 0 0; }
.figure-list div { display: flex; justify-content: space-between; gap: 8px; padding: 8px 0; border-top: 1px solid #f0f2f5; font-size: .85rem; }
.figure-list dt { font-weight: 400; color: var(--ink-2); }
.figure-list dd { margin: 0; font-weight: 600; }

.action-list { margin: 10px 0 0; padding: 0 8px 8px; list-style: none; }
.action-item { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 8px; color: inherit; text-decoration: none; }
.action-item:hover { background: #f8fafc; color: inherit; }
.action-icon { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; flex-shrink: 0; border-radius: 8px; }
.tone-critical .action-icon { background: #fee4e2; color: #d92d20; }
.tone-warning .action-icon { background: #fef0c7; color: #dc6803; }
.tone-info .action-icon { background: #e0eaff; color: #3538cd; }
.action-text { display: block; font-size: .86rem; font-weight: 500; }
.action-tone { display: block; font-size: .72rem; color: var(--ink-3); }

.rank-list, .activity-list, .agenda-list { margin: 6px 0 0; padding: 0 18px 8px; list-style: none; }
.rank-list li, .activity-list li, .agenda-list li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid #f0f2f5; font-size: .86rem; }
.rank-list li:last-child, .activity-list li:last-child, .agenda-list li:last-child { border-bottom: 0; }
.rank-no { width: 18px; text-align: center; font-size: .8rem; font-weight: 600; color: var(--ink-3); }
.rank-name { flex: 1; color: inherit; text-decoration: none; font-weight: 500; }
.rank-name:hover { color: var(--brand); }
.rank-score { padding: 2px 9px; border-radius: 6px; background: #eff4ff; color: #1d4ed8; font-weight: 600; font-variant-numeric: tabular-nums; }
.agenda-date { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 46px; height: 46px; flex-shrink: 0; border-radius: 8px; background: #f2f4f7; font-size: .64rem; color: var(--ink-3); }
.agenda-date strong { font-size: 1rem; line-height: 1.1; color: var(--ink); }
.page-head-actions .btn { padding: .45rem .9rem; font-size: .875rem; }
.form-control, .form-select { font-size: .875rem; min-height: 38px; }
.form-control-sm, .form-select-sm { min-height: 32px; font-size: .8rem; }
.form-label { font-size: .82rem; font-weight: 500; color: var(--ink-2); }
textarea.form-control { min-height: 0; }

/* =========================================================================
   Sign-in pages (layouts/auth): brand panel + form panel
   ========================================================================= */
.auth-body { min-height: 100vh; margin: 0; background: #fff; }
.auth-is-team { --auth-from: #042f2c; --auth-to: #0f766e; --brand: #0f766e; --brand-dark: #115e59; }
.auth-is-admin { --auth-from: #0b1220; --auth-to: #1e3a8a; --brand: #1d4ed8; --brand-dark: #1e40af; }
.auth-shell { display: grid; grid-template-columns: minmax(380px, 46%) 1fr; min-height: 100vh; }

.auth-brand { position: relative; display: flex; flex-direction: column; justify-content: space-between; padding: 40px 48px; overflow: hidden; color: #fff;
    background: linear-gradient(160deg, var(--auth-from) 0%, var(--auth-to) 140%); }
.auth-brand::before { content: ""; position: absolute; inset: 0; opacity: .5; pointer-events: none;
    background-image: linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
    background-size: 44px 44px; mask-image: radial-gradient(ellipse at 30% 40%, #000 20%, transparent 75%); }
.auth-brand > * { position: relative; }
.auth-brand-name { display: inline-flex; align-items: center; gap: 12px; color: #fff; font-weight: 600; font-size: 1.05rem; text-decoration: none; }
.auth-brand-name:hover { color: #fff; }
.auth-brand-mark { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .18); font-size: 1.1rem; }
.auth-brand-logo { height: 40px; max-width: 140px; object-fit: contain; padding: 4px 8px; border-radius: 10px; background: #fff; }
.auth-brand-main { max-width: 480px; }
.auth-brand-kicker { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border-radius: 20px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .16); font-size: .78rem; font-weight: 500; }
.auth-brand-title { margin: 20px 0 12px; font-size: clamp(1.7rem, 2.6vw, 2.35rem); font-weight: 600; line-height: 1.2; letter-spacing: -.02em; }
[dir="rtl"] .auth-brand-title { letter-spacing: 0; line-height: 1.45; }
.auth-brand-text { margin: 0 0 28px; font-size: .98rem; line-height: 1.7; color: rgba(255, 255, 255, .78); }
.auth-points { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }
.auth-points li { display: flex; align-items: center; gap: 12px; font-size: .92rem; color: rgba(255, 255, 255, .92); }
.auth-points span { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; flex-shrink: 0; border-radius: 9px; background: rgba(255, 255, 255, .1); }
.auth-brand-foot { display: flex; justify-content: space-between; font-size: .78rem; color: rgba(255, 255, 255, .55); }

.auth-main { display: flex; flex-direction: column; padding: 24px 32px; background: #fff; }
.auth-main-top { display: flex; align-items: center; gap: 12px; }
.auth-mobile-brand { display: none; align-items: center; gap: 10px; color: var(--ink); font-weight: 600; text-decoration: none; }
.auth-mobile-brand .auth-brand-mark { background: var(--brand); border: 0; color: #fff; width: 34px; height: 34px; font-size: .95rem; }
.auth-form-wrap { flex: 1; display: flex; flex-direction: column; justify-content: center; width: 100%; max-width: 400px; margin: 0 auto; padding: 32px 0; }
.auth-main-foot { text-align: center; font-size: .76rem; color: var(--ink-3); }

.auth-form-head { margin-bottom: 28px; }
.auth-form-badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 6px; background: color-mix(in srgb, var(--brand) 9%, white); color: var(--brand); font-size: .75rem; font-weight: 600; }
.auth-form-icon { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 12px; background: color-mix(in srgb, var(--brand) 10%, white); color: var(--brand); font-size: 1.4rem; }
.auth-form-title { margin: 14px 0 6px; font-size: 1.6rem; font-weight: 600; letter-spacing: -.02em; }
[dir="rtl"] .auth-form-title { letter-spacing: 0; }
.auth-form-text { margin: 0; color: var(--ink-2); font-size: .9rem; }
.auth-form .form-label { font-weight: 500; color: var(--ink); }
.auth-input { position: relative; }
.auth-input > .bi { position: absolute; top: 50%; inset-inline-start: 13px; transform: translateY(-50%); color: var(--ink-3); pointer-events: none; }
.auth-input .form-control { min-height: 46px; padding-left: 40px; padding-right: 40px; font-size: .92rem; border-radius: 9px; }
.auth-input-btn { position: absolute; top: 50%; inset-inline-end: 6px; transform: translateY(-50%); width: 34px; height: 34px; border: 0; border-radius: 7px; background: transparent; color: var(--ink-3); }
.auth-input-btn:hover { background: #f2f4f7; color: var(--ink); }
.auth-caps { margin-top: 6px; font-size: .78rem; font-weight: 500; color: #b54708; }
.auth-help { margin-top: 8px; font-size: .78rem; color: var(--ink-3); }
.auth-submit { min-height: 46px; border-radius: 9px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.auth-back { display: inline-flex; align-items: center; gap: 6px; margin-top: 18px; font-size: .85rem; color: var(--ink-2); text-decoration: none; }
.auth-back:hover { color: var(--brand); }
.auth-form-wrap .alert { border-radius: 9px; font-size: .88rem; }

@media (max-width: 991.98px) {
    .auth-shell { grid-template-columns: 1fr; }
    .auth-brand { display: none; }
    .auth-mobile-brand { display: inline-flex; }
    .auth-main { padding: 18px 20px; }
}

/* =========================================================================
   Sidebar refinement: coloured glyphs only (no tiles), calm dark surface,
   clear active state, quick filter
   ========================================================================= */
.sidebar-inner { background: #0b1220; }
.panel-team .sidebar-inner { background: #06201e; }
.sidebar-brand { padding: 16px 14px; border-bottom: 1px solid rgba(255, 255, 255, .06); }
.sidebar-brand .fw-bold { font-size: .95rem; font-weight: 600 !important; }
.brand-sub { font-size: .7rem; color: rgba(255, 255, 255, .45); }

/* Icons: the glyph carries the colour; tuned to read on the dark surface */
.side-icon[class*="tile-"] { width: 20px; height: 20px; background: none; box-shadow: none; font-size: 1.02rem; opacity: .9; }
.side-icon.tile-indigo  { color: #8b93ff; }
.side-icon.tile-sky     { color: #4cc3f5; }
.side-icon.tile-teal    { color: #2dd4bf; }
.side-icon.tile-emerald { color: #34d399; }
.side-icon.tile-amber   { color: #fbbf24; }
.side-icon.tile-rose    { color: #fb7185; }
.side-icon.tile-violet  { color: #b794f6; }
.side-icon.tile-lime    { color: #a3e635; }
.side-icon.tile-slate   { color: #a5b0c2; }
.side-link:hover .side-icon, .side-link.active .side-icon { opacity: 1; }

.side-link { height: 36px; padding: 0 10px; gap: 11px; margin-bottom: 2px; border-radius: 8px; color: #b6bfcd; font-size: .86rem; font-weight: 500; }
.side-link:hover { background: rgba(255, 255, 255, .045); color: #f1f4f9; }
.side-link.active { background: rgba(255, 255, 255, .08); color: #fff; font-weight: 600; }
.side-link.active::before { inset-inline-start: -10px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: #fff; }
[dir="rtl"] .side-link.active::before { border-radius: 3px 0 0 3px; }
.side-link:focus-visible { outline: 2px solid #60a5fa; outline-offset: -2px; }

.nav-section, .nav-group-toggle { margin-top: 10px; padding: 8px 10px 6px; font-size: .66rem; font-weight: 600; letter-spacing: .08em; color: rgba(255, 255, 255, .38); }
[dir="rtl"] .nav-section, [dir="rtl"] .nav-group-toggle { font-size: .74rem; letter-spacing: 0; }
.nav-group + .nav-group .nav-group-toggle, .nav-group + .nav-section { border-top: 1px solid rgba(255, 255, 255, .05); padding-top: 14px; }
.nav-group-toggle:hover { color: rgba(255, 255, 255, .7); }

.side-badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; font-size: .68rem; background: #f04438; }
.side-badge-warn { background: #f79009; }

/* Quick filter */
.side-filter { position: relative; margin: 12px 0 4px; }
.side-filter > .bi { position: absolute; top: 50%; inset-inline-start: 11px; transform: translateY(-50%); font-size: .8rem; color: rgba(255, 255, 255, .4); }
.side-filter input { width: 100%; height: 34px; padding-inline: 32px 30px; border: 1px solid rgba(255, 255, 255, .08); border-radius: 8px; background: rgba(255, 255, 255, .04); color: #e2e8f0; font-size: .82rem; outline: none; }
.side-filter input::placeholder { color: rgba(255, 255, 255, .38); }
.side-filter input:focus { border-color: rgba(96, 165, 250, .6); background: rgba(255, 255, 255, .07); }
.side-filter input::-webkit-search-cancel-button { filter: invert(1); opacity: .5; }
.side-filter kbd { position: absolute; top: 50%; inset-inline-end: 8px; transform: translateY(-50%); padding: 0 6px; border: 1px solid rgba(255, 255, 255, .14); border-radius: 4px; background: none; color: rgba(255, 255, 255, .45); font-size: .68rem; font-family: inherit; }
.side-filter input:focus + kbd { display: none !important; }
.side-filter-empty { padding: 14px 10px; font-size: .8rem; color: rgba(255, 255, 255, .45); }
.sidebar-nav.is-filtering .nav-group-items { display: block !important; }
.sidebar-nav.is-filtering .nav-group-toggle .bi { transform: none; }

/* User card */
.sidebar-user { margin: 8px 10px 12px; padding: 10px; border-radius: 10px; background: rgba(255, 255, 255, .04); border: 1px solid rgba(255, 255, 255, .06); }
.sidebar-user .avatar { position: relative; }
.sidebar-user .fw-semibold { font-size: .85rem; }
.user-role { font-size: .72rem; color: rgba(255, 255, 255, .5); }
.sidebar-user .sidebar-toggle { width: 32px; height: 32px; background: transparent; color: #a5b0c2; }
.sidebar-user .sidebar-toggle:hover { background: rgba(240, 68, 56, .15); color: #fda29b; }

@media (min-width: 992px) {
    .sidebar-mini .side-link { height: 40px; }
    .sidebar-mini .side-icon[class*="tile-"] { font-size: 1.15rem; }
}

/* =========================================================================
   Public website (corporate)
   ========================================================================= */
.s-body { --s-brand: #1d4ed8; --s-navy: #0b1220; --s-ink: #101828; --s-ink-2: #475467; --s-ink-3: #667085; --s-line: #e4e7ec; background: #fff; color: var(--s-ink); }
.s-body main { overflow-x: clip; }

/* Buttons */
.s-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 22px; border-radius: 8px; font-weight: 600; font-size: .92rem; transition: background .15s, color .15s, border-color .15s, transform .15s; }
.s-btn:hover { transform: translateY(-1px); }
.s-btn-light { background: #fff; color: var(--s-navy); border: 1px solid #fff; }
.s-btn-light:hover { background: #eef2ff; color: var(--s-navy); }
.s-btn-ghost { background: transparent; color: #fff; border: 1px solid rgba(255, 255, 255, .28); }
.s-btn-ghost:hover { background: rgba(255, 255, 255, .08); color: #fff; border-color: rgba(255, 255, 255, .5); }
.s-btn-dark { min-height: 40px; padding: 0 16px; background: var(--s-navy); color: #fff; border: 1px solid var(--s-navy); font-size: .85rem; }
.s-btn-dark:hover { background: #1f2a44; color: #fff; }
.s-btn-primary { background: var(--s-brand); color: #fff; border: 1px solid var(--s-brand); }
.s-btn-primary:hover { background: #1e40af; color: #fff; }

/* Header */
.s-nav { position: sticky; top: 0; z-index: 1030; background: rgba(255, 255, 255, .9); backdrop-filter: saturate(180%) blur(12px); border-bottom: 1px solid var(--s-line); }
.s-nav .navbar { padding: 12px 0; }
.s-logo { display: inline-flex; align-items: center; gap: 10px; color: var(--s-ink); text-decoration: none; }
.s-logo:hover { color: var(--s-ink); }
.s-logo-mark { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 9px; background: var(--s-navy); color: #fff; font-size: 1rem; }
.s-logo-img { height: 36px; max-width: 150px; object-fit: contain; }
.s-logo-name { font-weight: 700; font-size: 1.02rem; letter-spacing: -.01em; }
.s-logo-light, .s-logo-light:hover { color: #fff; }
.s-logo-light .s-logo-mark { background: rgba(255, 255, 255, .1); }
.s-logo-light .s-logo-img { padding: 4px 8px; border-radius: 8px; background: #fff; }
.s-nav-links .nav-link { padding: 8px 14px !important; color: var(--s-ink-2); font-size: .9rem; font-weight: 500; border-radius: 6px; }
.s-nav-links .nav-link:hover { color: var(--s-ink); background: #f2f4f7; }
.s-nav-lang { display: inline-flex; align-items: center; gap: 6px; padding: 8px 10px; color: var(--s-ink-2); font-size: .85rem; font-weight: 500; text-decoration: none; border-radius: 6px; }
.s-nav-lang:hover { color: var(--s-ink); background: #f2f4f7; }
@media (max-width: 991.98px) {
    .s-nav-links { padding: 8px 0; }
    .s-nav-actions { padding-bottom: 8px; }
}

/* Eyebrows & headings */
.s-eyebrow { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px; color: var(--s-brand); font-size: .78rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
[dir="rtl"] .s-eyebrow { letter-spacing: 0; text-transform: none; font-size: .88rem; }
.s-eyebrow-dark { padding: 6px 12px; border-radius: 20px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14); color: #c7d2fe; }
.s-dot { width: 7px; height: 7px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 4px rgba(52, 211, 153, .18); }
.s-heading { margin-bottom: 16px; font-size: clamp(1.75rem, 3vw, 2.4rem); font-weight: 700; line-height: 1.2; letter-spacing: -.025em; }
[dir="rtl"] .s-heading { letter-spacing: 0; line-height: 1.4; }
.s-lead { color: var(--s-ink-2); font-size: 1.04rem; line-height: 1.8; }
.s-link { display: inline-flex; align-items: center; gap: 6px; color: var(--s-brand); font-weight: 600; text-decoration: none; }
.s-link:hover { gap: 10px; color: #1e40af; }

/* Hero */
.s-hero { position: relative; padding: 110px 0 120px; overflow: hidden; color: #fff; background: var(--s-navy); }
.s-hero::before { content: ""; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(800px 420px at 85% 10%, rgba(59, 130, 246, .35), transparent 70%), radial-gradient(600px 380px at 0% 100%, rgba(20, 184, 166, .18), transparent 70%); }
.s-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .6;
    background-image: linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .045) 1px, transparent 1px);
    background-size: 56px 56px; mask-image: radial-gradient(ellipse at 50% 30%, #000 30%, transparent 75%); }
.s-hero .container { z-index: 1; }
.s-hero-title { margin: 6px 0 20px; font-size: clamp(2.2rem, 4.6vw, 3.6rem); font-weight: 700; line-height: 1.1; letter-spacing: -.035em; }
[dir="rtl"] .s-hero-title { letter-spacing: 0; line-height: 1.35; }
.s-hero-text { max-width: 600px; margin: 0; color: rgba(255, 255, 255, .74); font-size: 1.1rem; line-height: 1.75; }
.s-hero-panel { padding: 22px; border-radius: 16px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .12); backdrop-filter: blur(10px); box-shadow: 0 30px 60px rgba(0, 0, 0, .3); }
.s-hero-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; font-size: .82rem; font-weight: 600; color: rgba(255, 255, 255, .85); }
.s-live { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; color: #6ee7b7; font-size: .76rem; }
.s-live span { width: 7px; height: 7px; border-radius: 50%; background: #34d399; animation: att-pulse 1.8s infinite; }
.s-cap-list { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.s-cap-list li { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 10px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .07); font-size: .92rem; font-weight: 500; }
.s-cap-icon { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 8px; background: rgba(96, 165, 250, .16); color: #93c5fd; }
.s-cap-check { color: #34d399; }
.s-hero-panel-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 14px; color: #c7d2fe; font-size: .85rem; font-weight: 500; text-decoration: none; }
.s-hero-panel-link:hover { color: #fff; }
@media (max-width: 991.98px) { .s-hero { padding: 72px 0 80px; } }

/* Trust strip */
.s-trust { border-bottom: 1px solid var(--s-line); background: #fff; }
.s-trust-item { display: flex; gap: 14px; height: 100%; padding: 28px 24px; border-inline-end: 1px solid var(--s-line); }
.s-trust .col-lg-3:last-child .s-trust-item { border-inline-end: 0; }
.s-trust-item > .bi { flex-shrink: 0; font-size: 1.4rem; color: var(--s-brand); }
.s-trust-title { font-weight: 600; font-size: .95rem; }
.s-trust-text { margin-top: 4px; color: var(--s-ink-3); font-size: .84rem; line-height: 1.6; }
@media (max-width: 991.98px) { .s-trust-item { border-inline-end: 0; border-bottom: 1px solid var(--s-line); padding: 20px 12px; } }

/* Sections */
.s-section { padding: 96px 0; }
.s-section-alt { background: #f8fafc; border-top: 1px solid var(--s-line); border-bottom: 1px solid var(--s-line); }
.s-section-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 44px; }
.s-section-intro { max-width: 460px; margin: 0; color: var(--s-ink-2); line-height: 1.75; }
@media (max-width: 991.98px) { .s-section { padding: 64px 0; } }

/* About */
.s-statement { display: flex; gap: 18px; padding: 26px; border-radius: 14px; border: 1px solid var(--s-line); background: #fff; }
.s-statement-icon { display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px; background: #eff4ff; color: var(--s-brand); font-size: 1.25rem; }
.s-statement-title { margin: 0 0 6px; font-size: 1.05rem; font-weight: 600; }
.s-statement-text { margin: 0; color: var(--s-ink-2); line-height: 1.75; }

/* Services */
.s-service { position: relative; height: 100%; padding: 28px; border-radius: 14px; border: 1px solid var(--s-line); background: #fff; transition: border-color .2s, box-shadow .2s, transform .2s; }
.s-service::after { content: ""; position: absolute; inset: auto 28px 0; height: 2px; background: var(--s-brand); transform: scaleX(0); transition: transform .25s; }
.s-service:hover { border-color: #c7d7fe; box-shadow: 0 18px 40px rgba(16, 24, 40, .08); transform: translateY(-3px); }
.s-service:hover::after { transform: scaleX(1); }
.s-service-icon { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 10px; background: var(--s-navy); color: #fff; font-size: 1.25rem; }
.s-service-no { color: #d0d5dd; font-weight: 700; font-size: 1.1rem; font-variant-numeric: tabular-nums; }
.s-service-title { margin: 22px 0 8px; font-size: 1.08rem; font-weight: 600; }
.s-service-text { margin: 0; color: var(--s-ink-3); font-size: .9rem; line-height: 1.7; }

/* Process */
.s-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 0; padding: 0; list-style: none; counter-reset: none; }
.s-step { position: relative; padding: 0 24px 0 0; }
[dir="rtl"] .s-step { padding: 0 0 0 24px; }
.s-step::before { content: ""; position: absolute; top: 18px; inset-inline-start: 48px; inset-inline-end: 0; height: 1px; background: var(--s-line); }
.s-step:last-child::before { display: none; }
.s-step-no { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; background: var(--s-brand); color: #fff; font-weight: 700; font-size: .9rem; box-shadow: 0 0 0 6px #eff4ff; }
.s-step-icon { display: block; margin: 22px 0 10px; color: var(--s-brand); font-size: 1.5rem; }
.s-step-title { margin: 0 0 8px; font-size: 1.05rem; font-weight: 600; }
.s-step-text { margin: 0; color: var(--s-ink-2); font-size: .9rem; line-height: 1.7; }
@media (max-width: 991.98px) {
    .s-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
    .s-step::before { display: none; }
}
@media (max-width: 575.98px) { .s-steps { grid-template-columns: 1fr; } }

/* Careers */
.s-careers { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding: 44px 48px; border-radius: 18px; color: #fff;
    background: radial-gradient(600px 300px at 100% 0%, rgba(59, 130, 246, .35), transparent 70%), var(--s-navy); }
.s-careers-title { margin: 0 0 8px; font-size: 1.6rem; font-weight: 700; }
.s-careers-text { margin: 0; color: rgba(255, 255, 255, .72); max-width: 540px; }
@media (max-width: 575.98px) { .s-careers { padding: 32px 24px; } }

/* Contact */
.s-contact { display: flex; align-items: center; gap: 14px; height: 100%; padding: 18px; border-radius: 12px; border: 1px solid var(--s-line); background: #fff; color: inherit; text-decoration: none; transition: border-color .15s; }
a.s-contact:hover { border-color: var(--s-brand); color: inherit; }
.s-contact-icon { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; flex-shrink: 0; border-radius: 10px; background: #eff4ff; color: var(--s-brand); font-size: 1.1rem; }
.s-contact-label { display: block; color: var(--s-ink-3); font-size: .78rem; }
.s-contact-value { display: block; font-weight: 600; overflow-wrap: anywhere; }
.s-team-card { height: 100%; padding: 32px; border-radius: 16px; background: #fff; border: 1px solid var(--s-line); box-shadow: 0 18px 40px rgba(16, 24, 40, .06); display: flex; flex-direction: column; }
.s-team-card-icon { display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 12px; background: var(--s-navy); color: #fff; font-size: 1.4rem; }
.s-team-card-title { margin: 20px 0 8px; font-size: 1.25rem; font-weight: 700; }
.s-team-card-text { flex: 1; margin-bottom: 24px; color: var(--s-ink-2); line-height: 1.7; }

/* Footer */
.s-footer { padding: 72px 0 28px; background: var(--s-navy); color: rgba(255, 255, 255, .62); font-size: .9rem; }
.s-footer-text { max-width: 320px; line-height: 1.75; }
.s-footer-title { margin-bottom: 16px; color: #fff; font-size: .86rem; font-weight: 600; }
.s-footer-links { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.s-footer-links a { color: rgba(255, 255, 255, .62); text-decoration: none; }
.s-footer-links a:hover { color: #fff; }
.s-footer-contact li { display: flex; gap: 10px; align-items: flex-start; }
.s-footer-contact .bi { color: rgba(255, 255, 255, .45); margin-top: 2px; }
.s-footer-login { display: inline-flex; align-items: center; gap: 6px; margin-top: 18px; padding: 8px 14px; border-radius: 8px; border: 1px solid rgba(255, 255, 255, .16); color: #fff; font-size: .84rem; text-decoration: none; }
.s-footer-login:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.s-footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 56px; padding-top: 24px; border-top: 1px solid rgba(255, 255, 255, .08); font-size: .8rem; color: rgba(255, 255, 255, .45); }

/* ---- Website motion & "wow" layer ---- */
/* Header over the hero: transparent on top, solid after scrolling */
.s-home .s-nav { position: fixed; inset: 0 0 auto 0; background: transparent; border-bottom-color: transparent; backdrop-filter: none; transition: background .3s, border-color .3s, box-shadow .3s; }
.s-home .s-nav:not(.is-solid) .s-logo, .s-home .s-nav:not(.is-solid) .s-nav-lang, .s-home .s-nav:not(.is-solid) .navbar-toggler { color: #fff; }
.s-home .s-nav:not(.is-solid) .s-nav-links .nav-link { color: rgba(255, 255, 255, .78); }
.s-home .s-nav:not(.is-solid) .s-nav-links .nav-link:hover, .s-home .s-nav:not(.is-solid) .s-nav-lang:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.s-home .s-nav:not(.is-solid) .s-logo-mark { background: rgba(255, 255, 255, .12); }
.s-home .s-nav:not(.is-solid) .s-btn-dark { background: #fff; color: var(--s-navy); border-color: #fff; }
.s-home .s-nav.is-solid { background: rgba(255, 255, 255, .92); backdrop-filter: saturate(180%) blur(12px); border-bottom-color: var(--s-line); box-shadow: 0 6px 24px rgba(16, 24, 40, .06); }
@media (max-width: 991.98px) { .s-home .s-nav:not(.is-solid) .navbar-collapse.show, .s-home .s-nav:not(.is-solid) .navbar-collapse.collapsing { background: var(--s-navy); padding: 0 12px; border-radius: 12px; } }
.s-home .s-hero { padding-top: 170px; }
@media (max-width: 991.98px) { .s-home .s-hero { padding-top: 120px; } }

/* Aurora: slowly drifting blurred light */
.s-aurora { position: absolute; inset: -20%; pointer-events: none; filter: blur(70px); opacity: .7; }
.s-aurora span { position: absolute; width: 46vw; height: 46vw; max-width: 720px; max-height: 720px; border-radius: 50%; mix-blend-mode: screen; }
.s-aurora span:nth-child(1) { top: 5%; inset-inline-end: 5%; background: radial-gradient(circle, rgba(59, 130, 246, .55), transparent 65%); animation: s-drift-a 18s ease-in-out infinite alternate; }
.s-aurora span:nth-child(2) { bottom: 0; inset-inline-start: 0; background: radial-gradient(circle, rgba(20, 184, 166, .38), transparent 65%); animation: s-drift-b 22s ease-in-out infinite alternate; }
.s-aurora span:nth-child(3) { top: 30%; inset-inline-start: 35%; width: 30vw; height: 30vw; background: radial-gradient(circle, rgba(139, 92, 246, .35), transparent 65%); animation: s-drift-c 26s ease-in-out infinite alternate; }
.s-aurora-soft { opacity: .55; }
@keyframes s-drift-a { to { transform: translate(-12%, 14%) scale(1.15); } }
@keyframes s-drift-b { to { transform: translate(16%, -10%) scale(1.1); } }
@keyframes s-drift-c { to { transform: translate(-18%, -16%) scale(.9); } }

/* Gradient headline highlight */
.s-grad { background: linear-gradient(90deg, #93c5fd, #a78bfa, #5eead4, #93c5fd); background-size: 300% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: s-shine 8s linear infinite; }
@keyframes s-shine { to { background-position: 300% 0; } }

/* Hero entrance */
.s-rise { opacity: 0; transform: translateY(18px); animation: s-rise .8s cubic-bezier(.2, .7, .2, 1) forwards; }
.s-rise-2 { animation-delay: .08s; } .s-rise-3 { animation-delay: .18s; } .s-rise-4 { animation-delay: .28s; } .s-rise-5 { animation-delay: .38s; }
@keyframes s-rise { to { opacity: 1; transform: none; } }

.s-btn-glow { box-shadow: 0 0 0 0 rgba(147, 197, 253, .5), 0 10px 30px rgba(59, 130, 246, .35); }
.s-btn-glow:hover { box-shadow: 0 0 0 6px rgba(147, 197, 253, .15), 0 14px 34px rgba(59, 130, 246, .45); }
.s-hero-proof { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 28px 0 0; padding: 0; list-style: none; color: rgba(255, 255, 255, .7); font-size: .88rem; }
.s-hero-proof .bi { color: #34d399; margin-inline-end: 4px; }

/* Hero stage: glass panel + floating cards */
.s-hero-stage { position: relative; padding: 34px 10px; }
.s-hero-stage .s-hero-panel { position: relative; z-index: 1; animation: s-float 7s ease-in-out infinite; }
.s-float-card { position: absolute; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 12px; background: rgba(255, 255, 255, .96); color: var(--s-ink); box-shadow: 0 18px 40px rgba(0, 0, 0, .28); font-size: .8rem; }
.s-float-card strong { display: block; font-size: .84rem; }
.s-float-card small { display: block; color: var(--s-ink-3); }
.s-float-a { top: -6px; inset-inline-start: -18px; animation: s-float 6s ease-in-out infinite reverse; }
.s-float-b { bottom: -4px; inset-inline-end: -14px; animation: s-float 8s ease-in-out 1s infinite; }
.s-float-icon { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 9px; font-size: 1.05rem; }
.s-float-icon.is-green { background: #dcfae6; color: #079455; }
.s-avatars { display: inline-flex; }
.s-avatars i { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; border: 2px solid #fff; background: #dbeafe; color: #1d4ed8; font-size: .8rem; }
.s-avatars i + i { margin-inline-start: -9px; }
.s-avatars i:nth-child(2) { background: #ede9fe; color: #6d28d9; }
.s-avatars i:nth-child(3) { background: #ccfbf1; color: #0f766e; }
@keyframes s-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.s-hero-progress { margin-top: 14px; padding: 12px 14px; border-radius: 10px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .07); font-size: .82rem; color: rgba(255, 255, 255, .8); }
.s-hero-progress-state { color: #6ee7b7; }
.s-bar { height: 6px; margin-top: 8px; border-radius: 4px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.s-bar span { display: block; height: 100%; width: 0; border-radius: 4px; background: linear-gradient(90deg, #60a5fa, #5eead4); animation: s-fill 2.4s .6s cubic-bezier(.2, .7, .2, 1) forwards; }
@keyframes s-fill { to { width: 86%; } }
@media (max-width: 991.98px) { .s-float-card { display: none; } .s-hero-stage { padding: 0; } }

/* Services ribbon */
.s-marquee { overflow: hidden; padding: 18px 0; background: #fff; border-bottom: 1px solid var(--s-line); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.s-marquee-track { display: flex; align-items: center; gap: 28px; width: max-content; animation: s-marquee 40s linear infinite; }
[dir="rtl"] .s-marquee-track { animation-name: s-marquee-rtl; }
.s-marquee:hover .s-marquee-track { animation-play-state: paused; }
.s-marquee span { font-size: 1.15rem; font-weight: 600; color: var(--s-ink); white-space: nowrap; }
.s-marquee .bi { color: var(--s-brand); font-size: .8rem; }
@keyframes s-marquee { to { transform: translateX(-50%); } }
@keyframes s-marquee-rtl { to { transform: translateX(50%); } }

/* Reveal on scroll (only when JS is running) */
.s-motion [data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .7s cubic-bezier(.2, .7, .2, 1), transform .7s cubic-bezier(.2, .7, .2, 1); }
.s-motion [data-reveal].is-visible { opacity: 1; transform: none; }

/* Spotlight following the mouse on service cards */
.s-service[data-spotlight] { overflow: hidden; }
.s-service[data-spotlight]::before { content: ""; position: absolute; inset: 0; opacity: 0; transition: opacity .25s; pointer-events: none;
    background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), rgba(29, 78, 216, .09), transparent 70%); }
.s-service[data-spotlight]:hover::before { opacity: 1; }
.s-service-icon { transition: transform .3s; }
.s-service:hover .s-service-icon { transform: rotate(-6deg) scale(1.08); }

/* Final call to action */
.s-cta { position: relative; overflow: hidden; padding: 110px 0; background: var(--s-navy); color: #fff; }
.s-cta-title { max-width: 760px; margin: 0 auto 14px; font-size: clamp(1.9rem, 3.6vw, 2.9rem); font-weight: 700; line-height: 1.2; letter-spacing: -.03em; }
[dir="rtl"] .s-cta-title { letter-spacing: 0; line-height: 1.4; }
.s-cta-text { max-width: 560px; margin: 0 auto 30px; color: rgba(255, 255, 255, .72); font-size: 1.05rem; }

@media (prefers-reduced-motion: reduce) {
    .s-aurora span, .s-grad, .s-hero-stage .s-hero-panel, .s-float-card, .s-marquee-track, .s-live span { animation: none !important; }
    .s-rise { animation: none; opacity: 1; transform: none; }
    .s-bar span { animation: none; width: 86%; }
}

/* ---- Website: extra sections & all public pages ---- */
/* Reading progress and back to top */
.s-progress { position: fixed; inset: 0 0 auto 0; z-index: 1040; height: 3px; transform: scaleX(0); transform-origin: left; background: linear-gradient(90deg, #60a5fa, #a78bfa, #5eead4); }
[dir="rtl"] .s-progress { transform-origin: right; }
.s-to-top { position: fixed; bottom: 24px; inset-inline-end: 24px; z-index: 1030; display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; border-radius: 12px; background: var(--s-navy, #0b1220); color: #fff; box-shadow: 0 12px 30px rgba(16, 24, 40, .25); text-decoration: none; transition: transform .2s; }
.s-to-top:hover { color: #fff; transform: translateY(-3px); }

/* Rotating words */
.s-rotator { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 18px; font-size: 1.05rem; color: rgba(255, 255, 255, .7); }
.s-rotator-words { position: relative; display: inline-grid; min-width: 220px; height: 1.6em; overflow: hidden; }
.s-rotator-words span { grid-area: 1 / 1; font-weight: 600; color: #fff; white-space: nowrap; transform: translateY(110%); opacity: 0; transition: transform .55s cubic-bezier(.2, .7, .2, 1), opacity .55s; }
.s-rotator-words span.is-active { transform: none; opacity: 1; }
.s-rotator-words span.is-leaving { transform: translateY(-110%); opacity: 0; }
.s-rotator-words::after { content: ""; position: absolute; inset: auto 0 0 0; height: 2px; border-radius: 2px; background: linear-gradient(90deg, #60a5fa, transparent); }

/* Glowing animated border around the hero panel */
.s-hero-stage .s-hero-panel { isolation: isolate; }
.s-hero-stage .s-hero-panel::before { content: ""; position: absolute; inset: -1px; z-index: -1; padding: 1px; border-radius: 17px; pointer-events: none;
    background: conic-gradient(from var(--s-angle, 0deg), transparent 0 70%, rgba(96, 165, 250, .9) 80%, rgba(167, 139, 250, .9) 88%, transparent 96%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: s-spin 6s linear infinite; }
@property --s-angle { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@keyframes s-spin { to { --s-angle: 360deg; } }

/* Scroll hint */
.s-scroll-hint { position: absolute; bottom: 26px; left: 50%; z-index: 1; width: 26px; height: 42px; margin-left: -13px; border: 2px solid rgba(255, 255, 255, .35); border-radius: 14px; }
.s-scroll-hint span { position: absolute; top: 8px; left: 50%; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: #fff; animation: s-wheel 1.8s ease-in-out infinite; }
@keyframes s-wheel { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }
@media (max-width: 991.98px) { .s-scroll-hint { display: none; } }

/* Key figures */
.s-stats { padding: 56px 0; background: #fff; border-bottom: 1px solid var(--s-line); }
.s-stat { text-align: center; }
.s-stat-value { font-size: clamp(2.2rem, 4vw, 3.2rem); font-weight: 700; letter-spacing: -.03em; line-height: 1; font-variant-numeric: tabular-nums;
    background: linear-gradient(135deg, var(--s-navy), var(--s-brand)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.s-stat-label { margin-top: 10px; color: var(--s-ink-3); font-size: .92rem; font-weight: 500; }

/* FAQ */
.s-faq { display: grid; gap: 10px; }
.s-faq-item { border: 1px solid var(--s-line); border-radius: 12px; background: #fff; transition: border-color .2s, box-shadow .2s; }
.s-faq-item[open] { border-color: #c7d7fe; box-shadow: 0 10px 28px rgba(16, 24, 40, .06); }
.s-faq-item summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 22px; cursor: pointer; list-style: none; font-weight: 600; }
.s-faq-item summary::-webkit-details-marker { display: none; }
.s-faq-item summary .bi { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 8px; background: #eff4ff; color: var(--s-brand); transition: transform .25s; }
.s-faq-item[open] summary .bi { transform: rotate(45deg); }
.s-faq-item p { margin: 0; padding: 0 22px 20px; color: var(--s-ink-2); line-height: 1.8; }

/* Inner page header (careers, job, employee card) */
.page-hero { position: relative; overflow: hidden; padding: 84px 0 72px; color: #fff; background: #0b1220; }
.page-hero::before { content: ""; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(700px 360px at 90% 0%, rgba(59, 130, 246, .35), transparent 70%), radial-gradient(500px 300px at 0% 100%, rgba(20, 184, 166, .2), transparent 70%); }
.page-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
    background-image: linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .045) 1px, transparent 1px);
    background-size: 56px 56px; mask-image: radial-gradient(ellipse at 40% 20%, #000 25%, transparent 75%); }
.page-hero .container { position: relative; z-index: 1; }
.page-hero-sm { padding: 64px 0 56px; }
.page-hero-title { font-size: clamp(1.9rem, 4vw, 3rem); font-weight: 700; letter-spacing: -.03em; }
[dir="rtl"] .page-hero-title { letter-spacing: 0; }
.page-hero-text { color: rgba(255, 255, 255, .72); opacity: 1; }
.page-hero .hero-kicker { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px; padding: 6px 12px; border-radius: 20px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14); color: #c7d2fe; font-size: .8rem; font-weight: 600; }
.page-hero .btn-glass { color: #fff; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .18); }
.page-hero .btn-glass:hover { color: #fff; background: rgba(255, 255, 255, .15); }
[dir="ltr"] .page-hero .btn-glass .bi-arrow-right-short { display: inline-block; transform: scaleX(-1); }
.job-meta-light li { color: rgba(255, 255, 255, .78); }

/* Careers cards, job content, application form */
.s-body .job-card, .s-body .content-card, .s-body .apply-card, .s-body .empty-card { border: 1px solid var(--s-line) !important; border-radius: 14px; box-shadow: none !important; background: #fff; }
.s-body .job-card { position: relative; overflow: hidden; border-top: 1px solid var(--s-line) !important; transition: border-color .2s, box-shadow .2s, transform .2s; }
.s-body .job-card::after { content: ""; position: absolute; inset: auto 24px 0; height: 2px; background: var(--dept, var(--s-brand)); transform: scaleX(0); transition: transform .25s; }
.s-body .job-card:hover { transform: translateY(-3px); border-color: #c7d7fe !important; box-shadow: 0 18px 40px rgba(16, 24, 40, .08) !important; }
.s-body .job-card:hover::after { transform: scaleX(1); }
.s-body .job-card-link { color: var(--s-brand); }
.s-body .apply-card { position: sticky; top: 90px; padding: 28px; box-shadow: 0 18px 40px rgba(16, 24, 40, .06) !important; }
.s-body .site-section { padding: 72px 0; }

/* Error pages */
.s-guest { min-height: 100vh; display: flex; flex-direction: column; position: relative; overflow: hidden; background: #0b1220; color: #fff; }
.s-guest > .s-aurora { position: fixed; }
.s-guest-top { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; padding: 22px 12px; }
.s-guest-main { position: relative; z-index: 1; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 32px 12px; }
.s-guest-foot { position: relative; z-index: 1; padding: 20px 12px; color: rgba(255, 255, 255, .45); font-size: .8rem; text-align: center; }
.s-guest .s-btn-ghost { min-height: 36px; padding: 0 12px; font-size: .82rem; }
.s-error { max-width: 560px; text-align: center; }
.s-error-icon { display: inline-flex; align-items: center; justify-content: center; width: 64px; height: 64px; margin-bottom: 18px; border-radius: 16px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14); font-size: 1.7rem; color: #93c5fd; }
.s-error-code { font-size: clamp(5rem, 14vw, 8rem); font-weight: 800; line-height: 1; letter-spacing: -.05em;
    background: linear-gradient(135deg, #fff, #93c5fd 60%, #a78bfa); -webkit-background-clip: text; background-clip: text; color: transparent; }
.s-error-title { margin: 14px 0 10px; font-size: 1.6rem; font-weight: 700; }
.s-error-text { margin: 0 auto 28px; color: rgba(255, 255, 255, .7); }
.s-guest .alert { max-width: 560px; }

@media (prefers-reduced-motion: reduce) {
    .s-rotator-words span { transition: none; }
    .s-hero-stage .s-hero-panel::before, .s-scroll-hint span { animation: none; }
}

/* Credentials page: send panel */
.cred-send { max-width: 1100px; margin: 28px auto 0; }
.cred-send-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.cred-send-note { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 14px; padding: 12px 14px; border-radius: 10px; font-size: .85rem; }
.cred-send-note.is-ok { background: #ecfdf3; color: #05603a; border: 1px solid #abefc6; }
.cred-send-note.is-warn { background: #fffaeb; color: #93370d; border: 1px solid #fedf89; }
.cred-send .wa-phone { max-height: 280px; }
.cred-send .mail-preview { max-height: 420px; }
@media print { .cred-send { display: none !important; } }

/* =========================================================================
   Review (testers) & client link — v4.1.0
   ========================================================================= */
.auth-is-tester { --auth-from: #2e1065; --auth-to: #be185d; --brand: #9333ea; --brand-dark: #7e22ce; }

/* Issue counters (filter links) */
.review-counters { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin-bottom: 1rem; }
.review-counters a {
    display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 14px; background: #fff;
    border: 1px solid var(--line); text-decoration: none; color: #64748b; font-size: .8rem; font-weight: 600;
    border-top: 3px solid #cbd5e1; transition: box-shadow .15s;
}
.review-counters a strong { font-size: 1.35rem; color: #0f172a; line-height: 1.1; }
.review-counters a.is-danger { border-top-color: #dc2626; }
.review-counters a.is-warning { border-top-color: #f59e0b; }
.review-counters a.is-info { border-top-color: #0ea5e9; }
.review-counters a.is-success { border-top-color: #16a34a; }
.review-counters a.active, .review-counters a:hover { box-shadow: var(--shadow-lg); color: var(--brand); }
@media (max-width: 575.98px) { .review-counters { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* Compact counters on the project page */
.review-mini { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.review-mini a { display: flex; flex-direction: column; align-items: center; padding: 8px 4px; border-radius: 12px; background: #f8fafc; text-decoration: none; font-size: .72rem; color: #64748b; text-align: center; }
.review-mini a strong { font-size: 1.15rem; }
.review-mini a.is-danger strong { color: #dc2626; }
.review-mini a.is-warning strong { color: #d97706; }
.review-mini a.is-info strong { color: #0284c7; }
.review-mini a.is-success strong { color: #16a34a; }

/* Items and issues */
.review-item-icon { width: 30px; height: 30px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; background: #f3e8ff; color: #9333ea; }
.review-issue { border-inline-start: 3px solid transparent; }
.review-issue:hover { background: #f8fafc; }
.review-issue-open { border-inline-start-color: #dc2626; }
.review-issue-clarification { border-inline-start-color: #f59e0b; }
.review-issue-fixed { border-inline-start-color: #0ea5e9; }
.review-issue-closed { border-inline-start-color: #16a34a; opacity: .75; }
.review-issue-no { font-size: .78rem; font-weight: 700; color: #94a3b8; min-width: 38px; padding-top: 2px; }
.review-desc { background: #f8fafc; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 12px; }

/* Screenshots */
.review-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; margin: 10px 0; }
.review-shot { position: relative; margin: 0; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: #f1f5f9; aspect-ratio: 4 / 3; }
.review-shot img { width: 100%; height: 100%; object-fit: cover; transition: transform .2s; }
.review-shot a:hover img { transform: scale(1.04); }
.review-shot form { position: absolute; top: 6px; inset-inline-end: 6px; }
.review-shot-del { width: 26px; height: 26px; border: 0; border-radius: 50%; background: rgba(15, 23, 42, .7); color: #fff; font-size: .75rem; display: inline-flex; align-items: center; justify-content: center; }
.review-shot-del:hover { background: #dc2626; }

/* Conversation */
.review-thread { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.review-note { display: flex; gap: 10px; padding: 10px 12px; border-radius: 14px; background: #f8fafc; border: 1px solid var(--line); }
.review-note-icon { width: 32px; height: 32px; flex-shrink: 0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: #e2e8f0; color: #475569; }
.review-note-tester .review-note-icon { background: #ccfbf1; color: #0f766e; }
.review-note-dev .review-note-icon { background: #dbeafe; color: #1d4ed8; }
.review-note-admin .review-note-icon { background: #fef3c7; color: #b45309; }
.review-note-team .review-note-icon { background: #e0e7ff; color: #4f46e5; }
.review-note-client .review-note-icon { background: #fef3c7; color: #b45309; }
.review-kind-fix .review-note-icon, .review-kind-close .review-note-icon { background: #dcfce7; color: #15803d; }
.review-kind-reopen .review-note-icon { background: #fee2e2; color: #b91c1c; }
.review-kind-question { border-color: #fde68a; background: #fffbeb; }
.review-action-fix { border-top: 3px solid #16a34a !important; }
.review-action-ask { border-top: 3px solid #f59e0b !important; }
.review-action-reopen { border-top: 3px solid #dc2626 !important; }

/* Project picker in the tester form */
.review-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 8px; max-height: 340px; overflow: auto; }
.review-pick-item { display: flex; gap: 8px; align-items: center; padding: 9px 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; cursor: pointer; font-size: .88rem; }
.review-pick-item:has(input:checked) { border-color: var(--brand); background: #eef2ff; }

/* Testers' panel & client page shells */
.qa-body, .client-body { --brand: #9333ea; --brand-dark: #7e22ce; min-height: 100vh; display: flex; flex-direction: column; }
.client-body { --brand: #4f46e5; --brand-dark: #3730a3; }
.qa-top, .client-top { position: sticky; top: 0; z-index: 1020; background: rgba(255, 255, 255, .92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); padding: 10px 0; }
.qa-brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: #0f172a; text-decoration: none; }
.qa-brand img { height: 32px; width: auto; }
.qa-brand-mark { width: 34px; height: 34px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #7e22ce, #db2777); color: #fff; }
.qa-brand-mark.client-mark { background: linear-gradient(135deg, #4338ca, #0891b2); }
.qa-brand-sub { font-size: .72rem; font-weight: 700; color: #9333ea; background: #f3e8ff; padding: 2px 8px; border-radius: 20px; }
.qa-link { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 10px; border: 0; background: transparent; color: #475569; font-weight: 600; font-size: .88rem; text-decoration: none; }
.qa-link:hover, .qa-link.active { background: #f1f5f9; color: var(--brand); }
.qa-user { align-items: center; gap: 6px; font-size: .88rem; color: #334155; }
.qa-main, .client-main { flex: 1; padding-top: 24px; padding-bottom: 32px; }
.qa-title { font-size: 1.35rem; font-weight: 700; margin-bottom: 1rem; }
.qa-foot { padding: 16px 12px; font-size: .8rem; color: #94a3b8; text-align: center; }
.qa-project { transition: transform .15s, box-shadow .15s; }
.qa-project:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg) !important; }

/* Client page */
.client-secure { align-items: center; gap: 6px; font-size: .78rem; font-weight: 600; color: #15803d; background: #dcfce7; padding: 4px 10px; border-radius: 20px; }
.client-hero { border-top: 4px solid var(--brand) !important; }
.client-h { font-size: 1.05rem; font-weight: 700; margin-bottom: .75rem; }
.client-question.is-waiting { border-inline-start: 4px solid #f59e0b !important; }
.client-feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.client-post { display: flex; gap: 10px; padding: 12px; border-radius: 14px; border: 1px solid var(--line); }
.client-post.is-client { background: #fffbeb; border-color: #fde68a; }
.client-post.is-team { background: #f8fafc; }
.client-post-icon { width: 34px; height: 34px; flex-shrink: 0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: #e0e7ff; color: #4f46e5; }
.client-post.is-client .client-post-icon { background: #fef3c7; color: #b45309; }
.client-file { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; padding: 6px 12px; border-radius: 10px; background: #fff; border: 1px solid var(--line); text-decoration: none; font-size: .85rem; }
.client-link-box code { display: block; padding: 10px 12px; border-radius: 10px; background: #f1f5f9; word-break: break-all; font-size: .8rem; }

/* Secret review points: tester adds a note and/or a picture, programmer replies only */
.rv-body { --brand: #0f766e; --brand-dark: #115e59; --brand-soft: #ccfbf1; --brand-tint: #f0fdfa; --rv-ink: #10201d; --rv-muted: #5b6b67; min-height: 100vh; display: flex; flex-direction: column; color: var(--rv-ink);
    background: radial-gradient(1200px 420px at 50% -120px, #d5f5ee 0%, rgba(213, 245, 238, 0) 70%), #f4f7f6; }
.rv-body.is-dev { --brand: #1d4ed8; --brand-dark: #1e3a8a; --brand-soft: #dbeafe; --brand-tint: #eff6ff; --rv-ink: #111a2e; --rv-muted: #56627a;
    background: radial-gradient(1200px 420px at 50% -120px, #dbe6ff 0%, rgba(219, 230, 255, 0) 70%), #f4f6fb; }
.rv-body .btn-primary { --bs-btn-bg: var(--brand); --bs-btn-border-color: var(--brand); --bs-btn-hover-bg: var(--brand-dark); --bs-btn-hover-border-color: var(--brand-dark); --bs-btn-active-bg: var(--brand-dark); --bs-btn-active-border-color: var(--brand-dark); }
.rv-body .form-control:focus { border-color: var(--brand); box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--brand) 18%, transparent); }
.rv-top { background: rgba(255, 255, 255, .8); }
.rv-mark { background: linear-gradient(135deg, #0f766e, #0e7490); }
.rv-body.is-dev .rv-mark { background: linear-gradient(135deg, #1d4ed8, #0369a1); }
.rv-wrap { max-width: 780px; }
.rv-main { flex: 1; padding-top: 28px; padding-bottom: 48px; }
.rv-foot { display: flex; align-items: center; justify-content: center; gap: 6px; }
.rv-hp { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }   /* honeypot: hidden without pushing the page wider (no sideways scroll) */
.rv-card { background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px rgba(15, 23, 42, .04); }
.rv-kicker { font-size: .75rem; font-weight: 700; letter-spacing: .04em; color: var(--brand); }
.rv-label { display: block; font-size: .85rem; font-weight: 600; margin: 4px 0 8px; }

/* Hero */
.rv-hero { position: relative; overflow: hidden; display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: end; padding: 24px; margin-bottom: 18px; border-radius: 22px; color: #fff;
    background: linear-gradient(135deg, var(--brand-dark), var(--brand) 60%, #0891b2 140%); box-shadow: 0 14px 34px rgba(15, 118, 110, .22); }
.rv-body.is-dev .rv-hero { background: linear-gradient(135deg, var(--brand-dark), var(--brand) 60%, #6366f1 140%); box-shadow: 0 14px 34px rgba(29, 78, 216, .22); }
.rv-hero::after { content: ""; position: absolute; width: 260px; height: 260px; border-radius: 50%; inset-inline-end: -80px; top: -120px; background: rgba(255, 255, 255, .08); pointer-events: none; }
.rv-hero-main, .rv-hero-side { position: relative; z-index: 1; min-width: 0; }
.rv-hero-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.rv-badge { display: inline-flex; align-items: center; gap: 6px; font-size: .75rem; font-weight: 700; padding: 4px 10px; border-radius: 20px; background: rgba(255, 255, 255, .18); }
.rv-me { padding-inline-start: 4px; background: #fff; color: var(--pc); }
.rv-me .rv-avatar { width: 22px; height: 22px; font-size: .7rem; }
.rv-not-me { border: 1px dashed rgba(255, 255, 255, .6); background: transparent; color: #fff; cursor: pointer; }
.rv-not-me:hover { background: rgba(255, 255, 255, .18); border-style: solid; }
.rv-hero h1 { font-size: 1.6rem; font-weight: 700; margin: 10px 0 6px; overflow-wrap: anywhere; }
.rv-hero p { margin: 0; max-width: 52ch; font-size: .92rem; color: rgba(255, 255, 255, .85); }
.rv-hero-side { display: grid; gap: 12px; }
.rv-stats { display: flex; gap: 8px; }
.rv-stats > div { min-width: 74px; padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, .14); text-align: center; }
.rv-stats i { display: block; font-size: .95rem; opacity: .8; }
.rv-stats strong { display: block; font-size: 1.35rem; line-height: 1.15; }
.rv-stats span { font-size: .72rem; opacity: .85; }
.rv-progress-top { display: flex; justify-content: space-between; font-size: .75rem; margin-bottom: 5px; opacity: .9; }
.rv-progress-bar { height: 8px; border-radius: 8px; background: rgba(255, 255, 255, .2); overflow: hidden; }
.rv-progress-bar span { display: block; height: 100%; border-radius: 8px; background: #fff; transition: width .4s; }

/* Name (first visit) */
.rv-welcome { padding: 28px 24px; text-align: center; }
.rv-welcome-icon, .rv-closed-icon { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 20px; display: grid; place-items: center; font-size: 1.7rem; background: var(--brand-soft); color: var(--brand); }
.rv-welcome h2 { font-size: 1.25rem; font-weight: 700; margin-bottom: 14px; }
.rv-welcome-name { max-width: 420px; margin: 0 auto; text-align: center; }
.rv-welcome .invalid-feedback { display: block; }
.rv-spec-pick { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; max-width: 560px; margin: 0 auto; }
.rv-spec-pick label { position: relative; cursor: pointer; }
.rv-spec-pick input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.rv-spec-pick span { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 12px; border: 1.5px solid var(--line); background: #fff; font-size: .88rem; font-weight: 600; color: #475569; transition: border-color .15s, background .15s, color .15s; }
.rv-spec-pick label:hover span { border-color: var(--brand); }
.rv-spec-pick input:checked + span { border-color: var(--brand); background: var(--brand-tint); color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.rv-spec-pick input:focus-visible + span { outline: 2px solid var(--brand); outline-offset: 2px; }
.rv-welcome-note { margin: 16px auto; max-width: 440px; font-size: .8rem; color: var(--rv-muted); }

/* Composer */
.rv-composer { padding: 18px; margin-bottom: 20px; border-top: 4px solid var(--brand); }
.rv-composer-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.rv-composer-head:not([class*="pc-"]) .rv-avatar { background: var(--brand); }
.rv-composer-head strong { display: block; line-height: 1.2; }
.rv-composer-head span:not(.rv-avatar) { font-size: .78rem; color: var(--rv-muted); }
.rv-note { border-radius: 14px; padding: 12px 14px; resize: vertical; background: #fbfcfc; }
.rv-drop { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 10px; padding: 12px 14px; border: 2px dashed var(--line); border-radius: 14px; cursor: pointer; color: var(--rv-muted); transition: border-color .15s, background .15s; }
.rv-drop:hover, .rv-composer:focus-within .rv-drop { border-color: var(--brand-soft); background: var(--brand-tint); }
.rv-drop.is-invalid { border-color: var(--bs-danger); }
.rv-drop > i { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-size: 1.2rem; background: var(--brand-soft); color: var(--brand); }
.rv-drop strong { display: block; font-size: .88rem; color: var(--rv-ink); }
.rv-drop small { font-size: .76rem; }
.rv-file { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; }
.rv-name-line { margin-inline-start: auto; font-size: .78rem; font-weight: 600; color: var(--brand); overflow-wrap: anywhere; }
.rv-name-line:empty { display: none; }
.rv-preview { display: block; max-width: 240px; max-height: 160px; margin-top: 10px; border-radius: 12px; border: 1px solid var(--line); }
.rv-composer-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.rv-composer-foot small { color: var(--rv-muted); font-size: .76rem; }

/* People: each one keeps a colour on the whole page (pc-0 … pc-11, pc-admin) */
.pc-0 { --pc: #0d9488; --pc-soft: #ccfbf1; --pc-tint: #f0fdfa; }
.pc-1 { --pc: #2563eb; --pc-soft: #dbeafe; --pc-tint: #eff6ff; }
.pc-2 { --pc: #7c3aed; --pc-soft: #ede9fe; --pc-tint: #f5f3ff; }
.pc-3 { --pc: #db2777; --pc-soft: #fce7f3; --pc-tint: #fdf2f8; }
.pc-4 { --pc: #ea580c; --pc-soft: #ffedd5; --pc-tint: #fff7ed; }
.pc-5 { --pc: #16a34a; --pc-soft: #dcfce7; --pc-tint: #f0fdf4; }
.pc-6 { --pc: #4f46e5; --pc-soft: #e0e7ff; --pc-tint: #eef2ff; }
.pc-7 { --pc: #e11d48; --pc-soft: #ffe4e6; --pc-tint: #fff1f2; }
.pc-8 { --pc: #b45309; --pc-soft: #fef3c7; --pc-tint: #fffbeb; }
.pc-9 { --pc: #0891b2; --pc-soft: #cffafe; --pc-tint: #ecfeff; }
.pc-10 { --pc: #4d7c0f; --pc-soft: #ecfccb; --pc-tint: #f7fee7; }
.pc-11 { --pc: #c026d3; --pc-soft: #fae8ff; --pc-tint: #fdf4ff; }
.pc-admin { --pc: #a16207; --pc-soft: #fef08a; --pc-tint: #fefce8; }

.rv-avatar { width: 34px; height: 34px; flex-shrink: 0; border-radius: 50%; display: inline-grid; place-items: center; font-weight: 700; font-size: .9rem; background: var(--pc, var(--brand)); color: #fff; }
.rv-spec { display: inline-flex; align-items: center; gap: 4px; font-size: .68rem; font-weight: 700; padding: 1px 8px; border-radius: 20px; background: var(--pc-soft, #f1f5f9); color: var(--pc, #475569); white-space: nowrap; vertical-align: middle; }

/* Empty / closed */
.rv-empty { padding: 40px 16px; text-align: center; color: var(--rv-muted); }
.rv-empty i { font-size: 2.2rem; color: var(--brand); opacity: .55; }
.rv-empty p { margin: 8px 0 0; }
.rv-closed { max-width: 520px; margin: 6vh auto 0; padding: 36px 28px; text-align: center; background: #fff; border: 1px solid var(--line); border-radius: 24px; box-shadow: 0 20px 50px rgba(15, 23, 42, .08); }
.rv-closed-icon { width: 76px; height: 76px; font-size: 2rem; border-radius: 24px; background: linear-gradient(135deg, #f1f5f9, #e2e8f0); color: #475569; box-shadow: inset 0 0 0 6px #fff, 0 0 0 1px var(--line); }
.rv-closed h1 { font-size: 1.45rem; font-weight: 700; margin: 6px 0 10px; }
.rv-closed p { color: var(--rv-muted); margin: 0 auto; max-width: 42ch; }
.rv-closed-note { display: inline-flex; align-items: center; gap: 8px; margin-top: 20px; padding: 8px 14px; border-radius: 12px; font-size: .82rem; background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }

/* Filter */
.rv-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 14px; }
.rv-filter-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.rv-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 20px; border: 1px solid var(--line); background: #fff; color: #475569; font-size: .82rem; font-weight: 600; transition: background .15s, color .15s, border-color .15s; }
.rv-chip span { min-width: 22px; padding: 0 6px; border-radius: 10px; background: #f1f5f9; font-size: .74rem; text-align: center; }
.rv-chip:hover:not(:disabled) { border-color: var(--brand); color: var(--brand); }
.rv-chip:disabled { opacity: .45; cursor: default; }
.rv-chip.active { background: var(--brand); border-color: var(--brand); color: #fff; }
.rv-chip.active span { background: rgba(255, 255, 255, .22); }
.rv-chip.is-new.active { background: #d97706; border-color: #d97706; }
.rv-chip.is-replied.active { background: #2563eb; border-color: #2563eb; }
.rv-chip.is-done.active { background: #16a34a; border-color: #16a34a; }
.rv-search { position: relative; flex: 1; min-width: 180px; margin: 0; }
.rv-search i { position: absolute; top: 50%; inset-inline-start: 12px; transform: translateY(-50%); color: #94a3b8; pointer-events: none; }
.rv-search .form-control { padding-inline-start: 34px; border-radius: 20px; }
.rv-list .rv-point[hidden] { display: none; }
.rv-more-btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 20px; border: 1px solid var(--line); background: #fff; color: #475569; font-size: .82rem; font-weight: 600; }
.rv-more-btn:hover, .rv-more-btn[aria-expanded="true"] { border-color: var(--brand); color: var(--brand); }
.rv-more-btn.is-on { background: var(--brand-tint); border-color: var(--brand); color: var(--brand); }
.rv-more-count { min-width: 20px; padding: 0 6px; border-radius: 10px; background: var(--brand); color: #fff; font-size: .72rem; text-align: center; }
.rv-more { flex-basis: 100%; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; padding: 14px; border-radius: 16px; background: #fff; border: 1px solid var(--line); }
.rv-more[hidden] { display: none; }
.rv-more label { display: grid; gap: 4px; margin: 0; }
.rv-more label[hidden] { display: none; }
.rv-more label > span { font-size: .74rem; font-weight: 600; color: var(--rv-muted); }
.rv-more .form-select, .rv-more .form-control { font-size: .85rem; border-radius: 10px; }
.rv-more-foot { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: .8rem; color: var(--rv-muted); }
.rv-legend { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 6px; }
.rv-legend-item { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 3px; border-radius: 20px; border: 1px solid var(--pc-soft); background: var(--pc-tint); color: var(--pc); font-size: .78rem; font-weight: 600; }
[dir="rtl"] .rv-legend-item { padding: 3px 3px 3px 10px; }
.rv-legend-item .rv-avatar { width: 22px; height: 22px; font-size: .7rem; }
.rv-legend-item:hover { border-color: var(--pc); }
.rv-legend-item.active { background: var(--pc); border-color: var(--pc); color: #fff; }
.rv-legend-item.active .rv-avatar { background: #fff; color: var(--pc); }
.is-hit { outline: 2px solid var(--pc, var(--brand)); outline-offset: 2px; border-radius: 12px; }
.rv-empty[data-filter-empty] { margin-bottom: 14px; }

/* Points */
.rv-list { list-style: none; margin: 0; padding: 0; counter-reset: rv; display: grid; gap: 14px; }
.rv-point { position: relative; counter-increment: rv; overflow: hidden; border-inline-start: 4px solid #f59e0b; scroll-margin-top: 80px; }
.rv-point.is-replied { border-inline-start-color: #3b82f6; }
.rv-point.is-done { border-inline-start-color: #22c55e; background: #fbfdfb; }
.rv-point:target { box-shadow: 0 0 0 3px var(--brand-soft); }
.rv-point-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px 0; }
.rv-no { font-size: .75rem; font-weight: 700; color: #94a3b8; }
.rv-point-who { flex: 1; min-width: 0; line-height: 1.2; }
.rv-point-who strong { display: block; font-size: .9rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rv-point-head.is-hit { outline-offset: 4px; }
.rv-point-who time { font-size: .74rem; color: #94a3b8; }
.rv-state { display: inline-flex; align-items: center; gap: 4px; font-size: .74rem; font-weight: 700; padding: 3px 10px; border-radius: 20px; background: #fef3c7; color: #b45309; white-space: nowrap; }
.rv-state .bi-dot { margin: -6px -4px; font-size: 1.3rem; }
.rv-state.is-replied { background: #dbeafe; color: #1d4ed8; }
.rv-state.is-done { background: #dcfce7; color: #15803d; }
.rv-state-who { margin-inline-start: 2px; padding: 0 7px; border-radius: 10px; background: var(--pc); color: #fff; font-size: .68rem; max-width: 110px; overflow: hidden; text-overflow: ellipsis; }
.rv-point-body { padding: 12px 16px 4px; }
.rv-text { margin: 0 0 12px; white-space: pre-wrap; font-size: .97rem; line-height: 1.7; overflow-wrap: anywhere; }
.rv-point.is-done .rv-text { color: #64748b; }
.rv-shots { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.rv-shots a { display: block; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: #f8fafc; transition: transform .15s, box-shadow .15s; }
.rv-shots a:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(15, 23, 42, .1); }
.rv-shots img { display: block; max-width: min(100%, 380px); max-height: 280px; }

/* Thread */
.rv-thread { list-style: none; margin: 0 0 12px; padding: 12px 0 0; border-top: 1px dashed var(--line); display: grid; gap: 10px; }
.rv-msg { display: flex; gap: 8px; align-items: flex-start; }
.rv-msg .rv-avatar { width: 28px; height: 28px; font-size: .75rem; }
.rv-bubble { flex: 1; min-width: 0; padding: 8px 12px; border-radius: 14px; border-start-start-radius: 4px; background: var(--pc-tint, #f8fafc); border: 1px solid var(--pc-soft, var(--line)); border-inline-start: 3px solid var(--pc, var(--line)); }
.rv-msg-top strong { color: var(--pc, #0f172a) !important; }
.rv-msg.is-mine .rv-bubble { box-shadow: 0 2px 8px rgba(15, 23, 42, .06); }
.rv-msg.is-hit { outline: 0; }
.rv-msg.is-hit .rv-bubble { box-shadow: 0 0 0 2px var(--pc); }
.rv-msg p { margin: 4px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.rv-msg-top { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; font-size: .76rem; color: #64748b; }
.rv-msg-top strong { color: #0f172a; font-size: .84rem; }
.rv-msg-top time, .rv-event time { margin-inline-start: auto; color: #94a3b8; font-size: .72rem; }
.rv-role { font-size: .66rem; font-weight: 700; padding: 1px 8px; border-radius: 20px; background: #f1f5f9; color: #475569; }
.rv-role.is-tester { background: #ccfbf1; color: #0f766e; }
.rv-role.is-dev, .rv-role.is-team { background: #dbeafe; color: #1d4ed8; }
.rv-role.is-admin { background: #fef3c7; color: #b45309; }
.rv-event { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 10px; font-size: .78rem; color: #475569; background: #f8fafc; border-inline-start: 3px solid var(--pc, var(--line)); }
.rv-event > .bi { font-size: 1rem; }
.rv-event .rv-avatar { width: 22px; height: 22px; font-size: .68rem; }
.rv-event strong { color: var(--pc); }
.rv-event.is-close { background: #f0fdf4; }
.rv-event.is-close > .bi { color: #16a34a; }
.rv-event.is-reopen { background: #fff7ed; }
.rv-event.is-reopen > .bi { color: #ea580c; }
.rv-event p { flex-basis: 100%; margin: 2px 0 0; white-space: pre-wrap; }

/* Reply + actions */
.rv-point-foot { display: flex; gap: 8px; align-items: flex-start; padding: 12px 16px 14px; background: #fafbfc; border-top: 1px solid var(--line); }
.rv-reply { flex: 1; display: flex; gap: 8px; align-items: flex-start; min-width: 0; }
.rv-reply textarea { min-height: 38px; resize: vertical; border-radius: 12px; }
.rv-reply .btn, .rv-actions .btn { border-radius: 12px; white-space: nowrap; }
.rv-actions { display: flex; gap: 8px; }
.rv-people { margin: 10px 0; }
.rv-people-head { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.rv-person { margin: 6px 0; padding: 8px 10px; border-radius: 12px; border: 1px solid var(--pc-soft, var(--line)); background: var(--pc-tint, #f8fafc); border-inline-start: 4px solid var(--pc, var(--line)); }
.rv-person .rv-avatar { width: 26px; height: 26px; font-size: .72rem; }
.rv-person.is-unlinked { opacity: .7; }
.rv-person-name { flex: 1; min-width: 120px; }
.rv-person-spec { width: auto; }
.rv-edit { margin-top: 10px; }
.rv-edit summary { cursor: pointer; font-size: .85rem; font-weight: 600; color: var(--brand); width: fit-content; }
.rv-edit-form { display: grid; gap: 8px; justify-items: start; margin-top: 8px; }
.rv-check { display: flex; align-items: center; gap: 6px; font-size: .85rem; }
@media (max-width: 640px) {
    .rv-main { padding-top: 16px; }
    .rv-hero { grid-template-columns: 1fr; padding: 20px 18px; }
    .rv-stats > div { flex: 1; min-width: 0; }
    .rv-point-foot { flex-direction: column; align-items: stretch; }
    .rv-actions form { flex: 1; }
    .rv-actions .btn { width: 100%; }
    .rv-closed { margin-top: 2vh; padding: 28px 20px; }
    .rv-filter-chips { width: 100%; flex-wrap: wrap; }
    .rv-chip { flex-shrink: 0; }
}

/* ---------- v4.5.0: kind of problem (areas), mentions, several pictures, video links ---------- */
.area-tag { --ac: #475569; --ac-soft: #f1f5f9; display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 20px; font-size: .72rem; font-weight: 700; white-space: nowrap; background: var(--ac-soft); color: var(--ac); border: 1px solid color-mix(in srgb, var(--ac) 22%, transparent); }
.area-tag.is-backend, .tri-chip.is-backend, .area-pill.is-backend, .rv-chip.is-backend     { --ac: #6d28d9; --ac-soft: #ede9fe; }
.area-tag.is-mobile, .tri-chip.is-mobile, .area-pill.is-mobile, .rv-chip.is-mobile         { --ac: #0e7490; --ac-soft: #cffafe; }
.area-tag.is-frontend, .tri-chip.is-frontend, .area-pill.is-frontend, .rv-chip.is-frontend { --ac: #1d4ed8; --ac-soft: #dbeafe; }
.area-tag.is-uiux, .tri-chip.is-uiux, .area-pill.is-uiux, .rv-chip.is-uiux                 { --ac: #be185d; --ac-soft: #fce7f3; }
.area-tag.is-no_design, .tri-chip.is-no_design, .area-pill.is-no_design, .rv-chip.is-no_design { --ac: #b45309; --ac-soft: #fef3c7; }
.area-tag.is-unclear, .tri-chip.is-unclear, .area-pill.is-unclear, .rv-chip.is-unclear     { --ac: #b91c1c; --ac-soft: #fee2e2; }
.area-tag.is-other, .tri-chip.is-other, .area-pill.is-other, .rv-chip.is-other             { --ac: #475569; --ac-soft: #f1f5f9; }
.area-pill.is-both, .rv-chip.is-both { --ac: #5b21b6; --ac-soft: #e0f2fe; }
.area-pill.is-none, .rv-chip.is-none { --ac: #64748b; --ac-soft: #f1f5f9; }

/* Tick chips: kind of problem and mentions */
.tri-block { margin: 12px 0 0; padding: 0; border: 0; min-width: 0; }
.tri-legend { float: none; width: auto; margin: 0 0 6px; padding: 0; font-size: .82rem; font-weight: 700; color: var(--rv-ink, #0f172a); }
.tri-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.tri-chip { position: relative; margin: 0; cursor: pointer; }
.tri-chip input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.tri-chip > span { display: inline-flex; align-items: center; gap: 5px; padding: 5px 11px; border-radius: 20px; border: 1.5px solid var(--line, #e2e8f0); background: #fff; font-size: .8rem; font-weight: 600; color: #475569; transition: border-color .15s, background .15s, color .15s; }
.tri-chip > span small { font-size: .7rem; font-weight: 600; opacity: .75; }
.tri-chip:hover > span { border-color: var(--ac, var(--pc, var(--brand))); }
.tri-chip input:checked + span { border-color: var(--ac, var(--pc, var(--brand))); background: var(--ac-soft, var(--pc-tint, var(--brand-tint, #eff6ff))); color: var(--ac, var(--pc, var(--brand))); }
.tri-chip input:checked + span::before { content: "\2713"; font-weight: 800; }
.tri-chip input:focus-visible + span { outline: 2px solid var(--brand); outline-offset: 2px; }
.tri-chip.is-group > span { border-style: dashed; }
.tri-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--pc, #94a3b8); }
.tri-hint { margin-top: 5px; font-size: .74rem; color: var(--rv-muted, #64748b); }
.rv-tri { margin-top: 4px; }

/* Several pictures */
.rv-drop.is-over { border-color: var(--brand); background: var(--brand-tint); }
.rv-drop-sm { margin-top: 12px; padding: 8px 10px; }
.rv-drop-sm > i { width: 32px; height: 32px; font-size: 1rem; }
.rv-previews { display: flex; flex-wrap: wrap; gap: 8px; }
.rv-previews:not(:empty) { margin-top: 10px; }
.rv-thumb { position: relative; display: block; }
.rv-thumb img { display: block; width: 92px; height: 92px; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); }
.rv-thumb-x { position: absolute; top: -6px; inset-inline-end: -6px; width: 24px; height: 24px; border-radius: 50%; border: 2px solid #fff; background: #dc2626; color: #fff; font-size: .9rem; line-height: 1; display: grid; place-items: center; padding: 0; box-shadow: 0 2px 6px rgba(15, 23, 42, .2); }
.rv-videos { border-radius: 12px; font-size: .88rem; resize: vertical; }

/* Tags of a point */
.rv-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 10px 16px 0; }
.rv-mention { display: inline-flex; align-items: center; gap: 2px; padding: 2px 9px 2px 6px; border-radius: 20px; font-size: .72rem; font-weight: 700; background: var(--pc-tint, #f8fafc); color: var(--pc, #334155); border: 1px solid var(--pc-soft, var(--line)); }
.rv-mention.is-group { border-style: dashed; }
.rv-mention-me { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 20px; font-size: .72rem; font-weight: 800; background: #fef08a; color: #854d0e; animation: rv-ping 1.6s ease-out 2; }
@keyframes rv-ping { 0% { box-shadow: 0 0 0 0 rgba(234, 179, 8, .55); } 100% { box-shadow: 0 0 0 10px rgba(234, 179, 8, 0); } }
.rv-point[data-mine="1"] { box-shadow: inset 0 3px 0 #facc15, 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px rgba(15, 23, 42, .04); }

/* Area filter on the secret page */
.rv-area-chips { flex-basis: 100%; align-items: center; }
.rv-area-label { font-size: .76rem; font-weight: 700; color: var(--rv-muted); margin-inline-end: 2px; }
.rv-chip.is-area:not(.active) i { color: var(--ac, inherit); }
.rv-chip.is-area.active:not([data-area=""]) { background: var(--ac); border-color: var(--ac); }
.rv-chip.is-both.active { background: linear-gradient(90deg, #6d28d9, #0e7490); }
.rv-chip.is-mine { border-color: #facc15; }
.rv-chip.is-mine i { color: #ca8a04; }
.rv-chip.is-mine.active { background: #facc15; border-color: #facc15; color: #422006; }
.rv-chip.is-mine.active i { color: #422006; }

/* Sort / mention form of a point */
.rv-triage { border-top: 1px solid var(--line); background: #fff; }
.rv-triage > summary { padding: 9px 16px; cursor: pointer; font-size: .8rem; font-weight: 700; color: var(--brand); list-style: none; display: flex; align-items: center; gap: 6px; }
.rv-triage > summary::-webkit-details-marker { display: none; }
.rv-triage > summary::after { content: "\25BE"; margin-inline-start: auto; transition: transform .15s; }
.rv-triage[open] > summary::after { transform: rotate(180deg); }
.rv-triage-form { padding: 0 16px 14px; }
.rv-triage-foot { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.rv-triage-foot small { color: var(--rv-muted); font-size: .74rem; }
.rv-event.is-triage { background: #f5f3ff; }
.rv-event.is-triage > .bi { color: #6d28d9; }
.rv-event.is-media { background: #ecfeff; }
.rv-event.is-media > .bi { color: #0e7490; }

/* Video links */
.vid-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; margin-bottom: 12px; }
.vid-card { border-radius: 14px; overflow: hidden; border: 1px solid var(--line, #e2e8f0); background: #fff; }
.vid-play, .vid-frame { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; padding: 0; background: #0f172a; cursor: pointer; text-decoration: none; }
.vid-play img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: .9; transition: opacity .15s; }
.vid-play:hover img { opacity: 1; }
.vid-icon { position: absolute; inset: 0; margin: auto; width: 56px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-size: 1.6rem; color: #fff; background: rgba(220, 38, 38, .92); box-shadow: 0 6px 18px rgba(0, 0, 0, .3); }
.vid-card.is-drive .vid-icon { background: rgba(37, 99, 235, .92); }
.vid-drive { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 4px; color: #fff; font-size: .8rem; font-weight: 600; background: linear-gradient(135deg, #1e3a8a, #0f766e); }
.vid-drive > i { font-size: 1.6rem; }
.vid-card.is-drive button.vid-play .vid-drive { padding-top: 84px; }
.vid-foot { display: flex; align-items: center; gap: 6px; padding: 6px 10px; font-size: .74rem; color: #64748b; }
.vid-foot > .bi-youtube { color: #dc2626; }
.vid-foot > .bi-google { color: #2563eb; }
.vid-foot a { margin-inline-start: auto; text-decoration: none; white-space: nowrap; }

/* Area filter on the team page and the testers' panel */
.area-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: -4px 0 1rem; }
.area-filter-label { font-size: .8rem; font-weight: 700; color: #64748b; margin-inline-end: 4px; }
.area-pill { --ac: #475569; --ac-soft: #f1f5f9; display: inline-flex; align-items: center; gap: 5px; padding: 4px 11px; border-radius: 20px; font-size: .8rem; font-weight: 600; text-decoration: none; background: #fff; color: #334155; border: 1px solid var(--line, #e2e8f0); }
.area-pill i { color: var(--ac); }
.area-pill strong { min-width: 20px; padding: 0 6px; border-radius: 10px; background: var(--ac-soft); color: var(--ac); font-size: .72rem; text-align: center; }
.area-pill:hover { border-color: var(--ac); color: var(--ac); }
.area-pill.active { background: var(--ac); border-color: var(--ac); color: #fff; }
.area-pill.active i { color: #fff; }
.area-pill.active strong { background: rgba(255, 255, 255, .25); color: #fff; }
.review-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
@media (max-width: 640px) {
    .rv-area-chips { flex-wrap: wrap; }
    .vid-list { grid-template-columns: 1fr; }
}
.review-shot-pick { position: relative; display: block; margin: 0; cursor: pointer; }
.review-shot-pick img { display: block; width: 84px; height: 84px; object-fit: cover; border-radius: 10px; border: 2px solid var(--line, #e2e8f0); }
.review-shot-pick input { position: absolute; top: 6px; inset-inline-start: 6px; margin: 0; }
.review-shot-pick:has(input:checked) img { border-color: #dc2626; opacity: .55; }

/* ---------- v4.5.0: all problems page ---------- */
.review-tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.review-tabs a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 12px; background: #fff; border: 1px solid var(--line); color: #475569; font-weight: 600; text-decoration: none; }
.review-tabs a span { min-width: 22px; padding: 0 7px; border-radius: 10px; background: #f1f5f9; font-size: .75rem; text-align: center; }
.review-tabs a:hover { border-color: var(--brand); color: var(--brand); }
.review-tabs a.active { background: var(--brand); border-color: var(--brand); color: #fff; }
.review-tabs a.active span { background: rgba(255, 255, 255, .25); }
.review-counters-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.review-counters a.is-primary { border-top-color: var(--brand); }
.review-search .form-label { color: #64748b; font-weight: 600; }
.review-all { display: grid; gap: 8px; }
.review-all-item { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; border-inline-start: 4px solid #dc2626; transition: box-shadow .15s; }
.review-all-item:hover { box-shadow: var(--shadow-lg); }
.review-all-item.review-issue-clarification { border-inline-start-color: #f59e0b; }
.review-all-item.review-issue-fixed { border-inline-start-color: #0ea5e9; }
.review-all-item.review-issue-closed { border-inline-start-color: #16a34a; opacity: .85; }
@media (max-width: 767.98px) { .review-counters-6 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.rv-chip.is-added { border-color: #94a3b8; }
.rv-chip.is-added.active { background: #334155; border-color: #334155; color: #fff; }

/* ---------- v4.5.0: assignment by the project manager ---------- */
.assignee-tag { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 20px; font-size: .72rem; font-weight: 700; white-space: nowrap; background: #eef2ff; color: #4338ca; border: 1px solid #c7d2fe; }
.assignee-tag.is-late { background: #fef2f2; color: #b91c1c; border-color: #fecaca; }
.assign-card.is-late { box-shadow: inset 0 3px 0 #dc2626 !important; }
.assign-now { display: flex; gap: 10px; align-items: flex-start; }
.assign-avatar { flex-shrink: 0; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; background: #4f46e5; color: #fff; }
.assign-avatar.sm { width: 28px; height: 28px; font-size: .8rem; }
.workload-nums { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; padding-inline-start: 36px; }
.workload-nums a { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 20px; font-size: .74rem; text-decoration: none; background: #f8fafc; color: #475569; border: 1px solid var(--line); }
.workload-nums a strong { font-size: .82rem; }
.workload-nums a.is-working strong { color: #dc2626; }
.workload-nums a.is-fixed strong { color: #0284c7; }
.workload-nums a.is-closed strong { color: #16a34a; }
.workload-nums a.is-late { background: #fef2f2; border-color: #fecaca; color: #b91c1c; }
.workload-nums a:hover { border-color: var(--brand); }
.review-all-item.has-pick { display: flex; align-items: flex-start; gap: 10px; }
.review-all-item.has-pick > a { flex: 1; min-width: 0; }
.review-pick { margin-top: 4px; flex-shrink: 0; width: 1.15em; height: 1.15em; }
.bulk-bar { position: sticky; bottom: 12px; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 14px; margin-bottom: 1rem; border-radius: 14px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-lg); }
.bulk-bar .form-select, .bulk-bar .form-control { width: auto; min-width: 0; flex: 1 1 140px; max-width: 240px; }

/* =====================================================================
   v4.5.0 — polished look for the review pages (secret links + team pages)
   Motion: reveal on scroll, count-up, ripple, pop when filters show a card.
   html.motion is set by app.js only when the visitor allows motion.
   No rule here makes a block scroll.
   ===================================================================== */
:root { --rv-ease: cubic-bezier(.22, 1, .36, 1); --rv-ease-spring: cubic-bezier(.34, 1.56, .64, 1); }

/* ---------- reveal & pop ---------- */
.motion .rv-reveal { opacity: 0; transform: translateY(18px) scale(.985); }
.motion .rv-reveal.is-in { opacity: 1; transform: none; transition: opacity .6s var(--rv-ease), transform .75s var(--rv-ease), box-shadow .25s, border-color .25s; transition-delay: calc(var(--i, 0) * 55ms), calc(var(--i, 0) * 55ms), 0s, 0s; }
@keyframes rv-pop { from { opacity: 0; transform: scale(.97) translateY(8px); } to { opacity: 1; transform: none; } }
.rv-pop { animation: rv-pop .42s var(--rv-ease) both; }
@keyframes rv-slide { from { opacity: 0; transform: translateX(var(--rv-slide, -10px)); } to { opacity: 1; transform: none; } }
[dir="rtl"] { --rv-slide: 10px; }

/* ---------- ripple on buttons ---------- */
.rv-body .btn, .rvx .btn { position: relative; overflow: hidden; isolation: isolate; transition: transform .18s var(--rv-ease), box-shadow .2s, background-color .2s; }
.rv-body .btn:hover, .rvx .btn:hover { transform: translateY(-1px); }
.rv-body .btn:active, .rvx .btn:active { transform: translateY(0) scale(.98); }
.rv-body .btn-primary, .rvx .btn-primary { box-shadow: 0 6px 16px -6px color-mix(in srgb, var(--brand) 70%, transparent); }
.rv-ripple { position: absolute; border-radius: 50%; pointer-events: none; z-index: -1; background: currentColor; opacity: .22; transform: scale(0); animation: rv-ripple .6s ease-out forwards; }
@keyframes rv-ripple { to { transform: scale(2.6); opacity: 0; } }

/* =====================  Secret link pages  ===================== */
.rv-body { background:
    radial-gradient(1100px 520px at 100% -10%, color-mix(in srgb, var(--brand) 9%, transparent), transparent 60%),
    radial-gradient(900px 480px at -10% 30%, color-mix(in srgb, var(--brand) 6%, transparent), transparent 60%),
    #f6f7f9; }
.rv-top { backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); }

/* hero: drifting gradient + floating light */
@keyframes rv-hero-shift { 0% { background-position: 0% 40%; } 100% { background-position: 100% 60%; } }
@keyframes rv-float { 0%, 100% { transform: translate(0, 0) scale(1); } 50% { transform: translate(-30px, 18px) scale(1.08); } }
.rv-hero { background-size: 220% 220% !important; animation: rv-hero-shift 16s ease-in-out infinite alternate; }
.rv-hero::before { content: ""; position: absolute; width: 320px; height: 320px; inset-inline-start: -90px; bottom: -190px; border-radius: 50%; pointer-events: none;
    background: radial-gradient(circle, rgba(255, 255, 255, .22), transparent 65%); animation: rv-float 11s ease-in-out infinite; }
.rv-hero::after { animation: rv-float 14s ease-in-out infinite reverse; }
.rv-hero h1 { letter-spacing: -.01em; text-shadow: 0 2px 18px rgba(0, 0, 0, .12); }
.rv-stats > div { backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); border: 1px solid rgba(255, 255, 255, .16); transition: transform .3s var(--rv-ease), background .3s; }
.rv-stats > div:hover { transform: translateY(-3px); background: rgba(255, 255, 255, .22); }
.rv-stats strong { font-variant-numeric: tabular-nums; }
@keyframes rv-grow { from { width: 0; } }
@keyframes rv-shine { from { transform: translateX(-120%); } to { transform: translateX(220%); } }
.rv-progress-bar span { position: relative; overflow: hidden; width: var(--w, 0%); animation: rv-grow 1.4s var(--rv-ease) .2s both; box-shadow: 0 0 12px rgba(255, 255, 255, .6); }
.rv-progress-bar span::after { content: ""; position: absolute; inset: 0; width: 40%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .0), rgba(15, 118, 110, .25), transparent); animation: rv-shine 2.6s ease-in-out 1.6s infinite; }

/* cards */
.rv-card { transition: transform .3s var(--rv-ease), box-shadow .3s var(--rv-ease), border-color .3s; }
.rv-point:hover { box-shadow: 0 2px 4px rgba(15, 23, 42, .04), 0 18px 40px -12px rgba(15, 23, 42, .14); }
.motion .rv-point.is-in:hover { transform: translateY(-2px); }
.rv-point-head .rv-avatar, .rv-msg .rv-avatar { box-shadow: 0 0 0 3px #fff, 0 0 0 4px var(--pc-soft, transparent); }

/* state: "new" pulses gently */
.rv-state.is-new { gap: 6px; }
.rv-pulse { position: relative; width: 7px; height: 7px; border-radius: 50%; background: #f59e0b; }
.rv-pulse::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: #f59e0b; animation: rv-ring 1.8s ease-out infinite; }
@keyframes rv-ring { from { transform: scale(1); opacity: .7; } to { transform: scale(3); opacity: 0; } }

/* thread items slide in after their card */
.motion .rv-point.is-in .rv-thread > li { animation: rv-slide .5s var(--rv-ease) both; }
.motion .rv-point.is-in .rv-thread > li:nth-child(2) { animation-delay: .06s; }
.motion .rv-point.is-in .rv-thread > li:nth-child(3) { animation-delay: .12s; }
.motion .rv-point.is-in .rv-thread > li:nth-child(n+4) { animation-delay: .18s; }
.rv-bubble { transition: box-shadow .2s, transform .2s var(--rv-ease); }
.rv-msg:hover .rv-bubble { box-shadow: 0 6px 18px -8px rgba(15, 23, 42, .18); }

/* pictures and video zoom softly */
.rv-shots a { overflow: hidden; }
.rv-shots img { transition: transform .5s var(--rv-ease); }
.rv-shots a:hover img { transform: scale(1.04); }
.vid-card { transition: transform .3s var(--rv-ease), box-shadow .3s; }
.vid-card:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -14px rgba(15, 23, 42, .35); }
.vid-icon { transition: transform .3s var(--rv-ease-spring); }
.vid-play:hover .vid-icon { transform: scale(1.12); }

/* chips: springy press, glowing active */
.rv-chip, .tri-chip > span, .area-pill, .rv-legend-item { transition: transform .2s var(--rv-ease-spring), background .2s, color .2s, border-color .2s, box-shadow .2s; }
.rv-chip:active:not(:disabled), .tri-chip:active > span, .area-pill:active, .rv-legend-item:active { transform: scale(.95); }
.rv-chip.active { box-shadow: 0 6px 16px -8px var(--ac, var(--brand)); }
.tri-chip input:checked + span { box-shadow: 0 4px 12px -6px var(--ac, var(--pc, var(--brand))); animation: rv-check .3s var(--rv-ease-spring); }
@keyframes rv-check { 50% { transform: scale(1.06); } }

/* "mentions you" glow */
.rv-point[data-mine="1"] { border-color: #fde68a; }
.rv-mention-me { box-shadow: 0 0 0 0 rgba(234, 179, 8, .5); }

/* new point form */
.rv-composer { border-top: 0; position: relative; overflow: hidden; }
.rv-composer::before { content: ""; position: absolute; inset: 0 0 auto; height: 4px; background: linear-gradient(90deg, var(--brand), color-mix(in srgb, var(--brand) 40%, #6366f1), var(--brand)); background-size: 200% 100%; animation: rv-hero-shift 6s linear infinite alternate; }
.rv-composer:focus-within { box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 12%, transparent), 0 18px 40px -16px rgba(15, 23, 42, .2); }
.rv-note { transition: background .2s, box-shadow .2s; }
.rv-note:focus { background: #fff; }
.rv-drop { transition: border-color .2s, background .2s, transform .25s var(--rv-ease); }
.rv-drop > i { transition: transform .35s var(--rv-ease-spring); }
.rv-drop:hover > i, .rv-drop.is-over > i { transform: translateY(-3px) rotate(-6deg) scale(1.08); }
.rv-drop.is-over { transform: scale(1.01); border-style: solid; }
.rv-thumb { animation: rv-pop .35s var(--rv-ease-spring) both; }
.tri-more { margin-top: 12px; border: 1px dashed var(--line); border-radius: 14px; padding: 2px 12px; transition: background .2s, border-color .2s; }
.tri-more[open] { background: #fbfcfd; border-style: solid; padding-bottom: 10px; }
.tri-more > summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 6px; padding: 8px 0; font-size: .82rem; font-weight: 700; color: var(--rv-ink, #0f172a); }
.tri-more > summary::-webkit-details-marker { display: none; }
.tri-more > summary::after { content: "+"; margin-inline-start: auto; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft, #e0f2fe); color: var(--brand); font-weight: 800; transition: transform .3s var(--rv-ease); }
.tri-more[open] > summary::after { transform: rotate(45deg); }
.tri-optional { font-size: .68rem; font-weight: 600; padding: 1px 8px; border-radius: 20px; background: #f1f5f9; color: #64748b; }
.tri-more .tri-block { margin-top: 2px; }
.motion .tri-more[open] .tri-block, .motion .rv-triage[open] .rv-triage-form { animation: rv-pop .35s var(--rv-ease) both; }

/* filter bar */
.rv-search .form-control { transition: box-shadow .2s, border-color .2s; }
.rv-search .form-control:focus { box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 12%, transparent); }
.motion .rv-more:not([hidden]) { animation: rv-pop .3s var(--rv-ease) both; }

/* =====================  Team pages (.rvx)  ===================== */
.rvx .card { border-radius: 16px; transition: box-shadow .3s var(--rv-ease), transform .3s var(--rv-ease); }
.rvx .card:hover { box-shadow: 0 2px 4px rgba(15, 23, 42, .04), 0 16px 36px -16px rgba(15, 23, 42, .18) !important; }
.rvx .card-header { border-bottom-color: #eef1f5; }

/* tabs */
.rvx .review-tabs { padding: 4px; gap: 4px; width: fit-content; max-width: 100%; flex-wrap: wrap; border-radius: 14px; background: #eef1f6; }
.rvx .review-tabs a { border: 0; background: transparent; transition: background .25s var(--rv-ease), color .2s, box-shadow .25s; }
.rvx .review-tabs a.active { background: #fff; color: var(--brand); box-shadow: 0 4px 14px -6px rgba(15, 23, 42, .25); }
.rvx .review-tabs a.active span { background: var(--brand); color: #fff; }

/* counters */
.rvx .review-counters a { position: relative; overflow: hidden; border-top-width: 0; border-radius: 16px; padding: 14px 14px 12px; transition: transform .3s var(--rv-ease), box-shadow .3s, border-color .3s; }
.rvx .review-counters a::before { content: ""; position: absolute; inset: 0 0 auto; height: 3px; background: var(--rc, #cbd5e1); }
.rvx .review-counters a.is-danger { --rc: #ef4444; } .rvx .review-counters a.is-warning { --rc: #f59e0b; }
.rvx .review-counters a.is-info { --rc: #0ea5e9; } .rvx .review-counters a.is-success { --rc: #22c55e; } .rvx .review-counters a.is-primary { --rc: var(--brand); }
.rvx .review-counters a > .bi { position: absolute; inset-inline-end: 10px; bottom: 6px; font-size: 1.9rem; color: var(--rc, #cbd5e1); opacity: .16; transition: transform .45s var(--rv-ease-spring), opacity .3s; }
.rvx .review-counters a:hover { transform: translateY(-3px); }
.rvx .review-counters a:hover > .bi { transform: scale(1.18) rotate(-8deg); opacity: .3; }
.rvx .review-counters a.active { border-color: var(--rc, var(--brand)); box-shadow: 0 10px 24px -14px var(--rc, var(--brand)); background: color-mix(in srgb, var(--rc, var(--brand)) 5%, #fff); }
.rvx .review-counters a strong { font-variant-numeric: tabular-nums; }

/* list rows */
.rvx .review-all-item { position: relative; border-inline-start-width: 0; transition: transform .3s var(--rv-ease), box-shadow .3s, border-color .3s; }
.rvx .review-all-item::before { content: ""; position: absolute; inset-block: 10px; inset-inline-start: 0; width: 4px; border-radius: 4px; background: var(--st, #ef4444); transition: inset-block .3s var(--rv-ease); }
.rvx .review-all-item.review-issue-clarification { --st: #f59e0b; } .rvx .review-all-item.review-issue-fixed { --st: #0ea5e9; } .rvx .review-all-item.review-issue-closed { --st: #22c55e; }
.rvx .review-all-item:hover { border-color: color-mix(in srgb, var(--st, #ef4444) 35%, var(--line)); box-shadow: 0 14px 30px -18px rgba(15, 23, 42, .3); }
.rvx .review-all-item:hover::before { inset-block: 0; border-radius: 0 4px 4px 0; }
.motion .rvx .review-all-item.is-in:hover { transform: translateY(-2px); }
.rvx .review-all-item .fw-semibold.text-truncate { transition: color .2s; }
.rvx .review-all-item:hover .fw-semibold.text-truncate { color: var(--brand); }
.rvx .review-issue { transition: background .2s; }
.rvx .review-issue:hover { background: #f8fafc; }

/* stepper */
.rv-stepper { list-style: none; display: flex; align-items: flex-start; margin: 12px 0 14px; padding: 0; }
.rv-stepper li { position: relative; flex: 1; display: grid; justify-items: center; gap: 4px; text-align: center; font-size: .74rem; color: #94a3b8; }
.rv-stepper li + li::before { content: ""; position: absolute; top: 15px; inset-inline-end: 50%; width: 100%; height: 3px; background: #e2e8f0; z-index: 0; }
.rv-stepper li.is-done + li::before, .rv-stepper li.is-done + li.is-current::before { background: linear-gradient(90deg, #22c55e, #22c55e); }
.motion .rv-stepper li.is-done + li::before { animation: rv-grow .8s var(--rv-ease) both; }
.rv-step-dot { position: relative; z-index: 1; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: #fff; border: 2px solid #e2e8f0; color: #94a3b8; }
.rv-stepper li.is-done .rv-step-dot { background: #22c55e; border-color: #22c55e; color: #fff; }
.rv-stepper li.is-current .rv-step-dot { border-color: var(--brand); color: var(--brand); box-shadow: 0 0 0 5px color-mix(in srgb, var(--brand) 14%, transparent); }
.rv-stepper li.is-current { color: var(--brand); font-weight: 700; }
.rv-stepper.is-waiting li.is-current .rv-step-dot { border-color: #f59e0b; color: #f59e0b; box-shadow: 0 0 0 5px #fef3c7; }
.rv-stepper.is-waiting li.is-current { color: #b45309; }
.motion .rv-stepper li.is-current .rv-step-dot { animation: rv-breathe 2.4s ease-in-out infinite; }
@keyframes rv-breathe { 50% { box-shadow: 0 0 0 9px color-mix(in srgb, var(--brand) 6%, transparent); } }

/* assignment */
.rvx .assign-avatar { position: relative; background: linear-gradient(135deg, #6366f1, #8b5cf6); }
.rvx .assign-now .assign-avatar::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; padding: 2px; background: conic-gradient(from 0deg, #6366f1, #22d3ee, #a855f7, #6366f1);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: rv-spin 6s linear infinite; }
@keyframes rv-spin { to { transform: rotate(1turn); } }
.rvx .assign-card.is-late { box-shadow: inset 0 3px 0 #dc2626, 0 10px 28px -18px #dc2626 !important; }
.assignee-tag { transition: transform .2s var(--rv-ease-spring); }
.assignee-tag.is-late .bi-alarm { display: inline-block; animation: rv-shake 2.4s ease-in-out infinite; }
@keyframes rv-shake { 0%, 86%, 100% { transform: rotate(0); } 89% { transform: rotate(-14deg); } 93% { transform: rotate(12deg); } 96% { transform: rotate(-6deg); } }

/* workload */
.workload-bar { display: flex; height: 6px; margin: 8px 0 2px; margin-inline-start: 36px; border-radius: 6px; overflow: hidden; background: #f1f5f9; gap: 2px; }
.workload-bar span { width: var(--w); border-radius: 6px; }
.motion .workload-bar span { animation: rv-grow 1.1s var(--rv-ease) .2s both; }
.workload-bar .is-working { background: linear-gradient(90deg, #f87171, #ef4444); }
.workload-bar .is-fixed { background: linear-gradient(90deg, #38bdf8, #0ea5e9); }
.workload-bar .is-closed { background: linear-gradient(90deg, #4ade80, #22c55e); }
.workload .list-group-item { transition: background .2s; }
.workload .list-group-item:hover { background: #f8fafc; }

/* bulk bar: slides up when problems are ticked */
.bulk-count { min-width: 28px; height: 28px; padding: 0 8px; border-radius: 14px; display: inline-grid; place-items: center; background: var(--brand); color: #fff; font-weight: 800; font-size: .85rem; }
[data-bulk] .bulk-bar { transition: transform .45s var(--rv-ease), opacity .3s; }
.motion [data-bulk]:not(.has-selection) .bulk-bar { transform: translateY(24px); opacity: .55; }
[data-bulk].has-selection .bulk-bar { border-color: var(--brand); box-shadow: 0 18px 40px -16px color-mix(in srgb, var(--brand) 55%, transparent); }
.review-all-item.is-picked { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 4%, #fff); }

/* ---------- respect "reduce motion" ---------- */
@media (prefers-reduced-motion: reduce) {
    .rv-body *, .rv-body *::before, .rv-body *::after, .rvx *, .rvx *::before, .rvx *::after { animation: none !important; transition: none !important; }
    .rv-hero { animation: none !important; }
    .motion .rv-reveal { opacity: 1; transform: none; }
}
.review-all { grid-template-columns: minmax(0, 1fr); }   /* rows shrink to the screen: no sideways scroll on phones */

/* =========================================================================
   v4.6.0: secret review links. Status of each point (waiting for mobile, backend, design, review...),
   editing and deleting what one wrote, and a cleaner card.
   ========================================================================= */
.stage-red    { --sc: #e11d48; --sc-soft: #ffe4e6; }
.stage-blue   { --sc: #2563eb; --sc-soft: #dbeafe; }
.stage-orange { --sc: #ea580c; --sc-soft: #ffedd5; }
.stage-violet { --sc: #7c3aed; --sc-soft: #ede9fe; }
.stage-teal   { --sc: #0d9488; --sc-soft: #ccfbf1; }
.stage-cyan   { --sc: #0891b2; --sc-soft: #cffafe; }
.stage-pink   { --sc: #db2777; --sc-soft: #fce7f3; }
.stage-amber  { --sc: #b45309; --sc-soft: #fef3c7; }
.stage-indigo { --sc: #4f46e5; --sc-soft: #e0e7ff; }
.stage-slate  { --sc: #475569; --sc-soft: #e2e8f0; }
.stage-green  { --sc: #16a34a; --sc-soft: #dcfce7; }
.st-red { --st: #e11d48; } .st-blue { --st: #2563eb; } .st-orange { --st: #ea580c; } .st-violet { --st: #7c3aed; } .st-teal { --st: #0d9488; }
.st-cyan { --st: #0891b2; } .st-pink { --st: #db2777; } .st-amber { --st: #d97706; } .st-indigo { --st: #4f46e5; } .st-slate { --st: #64748b; } .st-green { --st: #22c55e; }

/* pill shown in lists and in the conversation */
.stage-pill { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 20px; font-size: .72rem; font-weight: 700; white-space: nowrap;
    background: var(--sc-soft, #f1f5f9); color: var(--sc, #475569); border: 1px solid color-mix(in srgb, var(--sc, #475569) 22%, transparent); }

/* the card: coloured by its status; menus are not cut by the card */
.rv-point { overflow: visible; border-inline-start: 1px solid var(--line); }
.rv-point::before { content: ""; position: absolute; top: -1px; bottom: -1px; inset-inline-start: -1px; width: 5px; background: var(--st, #e11d48); }
[dir="rtl"] .rv-point::before { border-radius: 0 18px 18px 0; }
[dir="ltr"] .rv-point::before { border-radius: 18px 0 0 18px; }
.rv-point:has(.dropdown-menu.show) { z-index: 30; }
.rv-point > :last-child { border-end-start-radius: 17px; border-end-end-radius: 17px; }
.rv-point.is-done { background: linear-gradient(180deg, #fbfefb, #fff 120px); }
.rv-point-head { padding: 16px 18px 0; padding-inline-start: 22px; flex-wrap: wrap; row-gap: 8px; }
.rv-point-body { padding: 12px 18px 6px; padding-inline-start: 22px; }
.rv-point-foot { padding: 12px 18px 14px; padding-inline-start: 22px; }
.rv-point > .rv-tags { padding-inline-start: 22px; }
.rv-triage > summary { padding-inline-start: 22px; }
.rv-no { order: -1; flex-shrink: 0; min-width: 34px; padding: 2px 8px; border-radius: 8px; background: #f1f5f9; color: #64748b; font-size: .72rem; text-align: center; }
.rv-text { font-size: 1rem; color: #0f172a; }

/* status button + menu */
.rv-stage { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px 5px 12px; border-radius: 20px; font-size: .78rem; font-weight: 700; white-space: nowrap; cursor: pointer;
    border: 1px solid color-mix(in srgb, var(--sc) 30%, transparent); background: var(--sc-soft); color: var(--sc); transition: box-shadow .15s; }
.rv-stage:hover, .rv-stage[aria-expanded="true"] { box-shadow: 0 0 0 3px color-mix(in srgb, var(--sc) 16%, transparent); }
.rv-stage .rv-pulse, .rv-stage .rv-pulse::after { background: var(--sc); }
.rv-caret { font-size: .65rem; opacity: .7; transition: transform .15s; }
[aria-expanded="true"] > .rv-caret { transform: rotate(180deg); }
.rv-stage-list { min-width: 230px; padding: 6px; border-radius: 14px; border: 1px solid var(--line); box-shadow: 0 18px 40px -12px rgba(15, 23, 42, .25); }
.rv-stage-list .dropdown-header { font-size: .72rem; font-weight: 700; }
.rv-stage-list .dropdown-item { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 10px; font-size: .86rem; font-weight: 600; color: #334155; }
.rv-stage-list .dropdown-item > .bi:first-child { width: 26px; height: 26px; display: inline-grid; place-items: center; border-radius: 8px; background: var(--sc-soft); color: var(--sc); }
.rv-stage-list .dropdown-item:hover { background: var(--sc-soft); color: var(--sc); }
.rv-stage-list .dropdown-item.active, .rv-stage-list .dropdown-item:disabled { background: var(--sc-soft); color: var(--sc); opacity: 1; }
.rv-stage-list .dropdown-item.active::after { content: "\2713"; margin-inline-start: auto; font-weight: 800; }

/* owner menu */
.rv-kebab { width: 32px; height: 32px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid transparent; background: transparent; color: #64748b; }
.rv-kebab:hover, .rv-kebab[aria-expanded="true"] { background: #f1f5f9; border-color: var(--line); color: #0f172a; }
.rv-point .dropdown-menu:not(.rv-stage-list) { border-radius: 12px; padding: 6px; border: 1px solid var(--line); box-shadow: 0 18px 40px -12px rgba(15, 23, 42, .25); }
.rv-point .dropdown-menu:not(.rv-stage-list) .dropdown-item { display: flex; align-items: center; gap: 8px; border-radius: 8px; font-size: .86rem; padding: 7px 10px; }
.rv-point .dropdown-menu form { margin: 0; }

/* "someone replied" next to the name */
.rv-replied { display: inline-flex; align-items: center; gap: 4px; max-width: 150px; padding: 2px 8px; border-radius: 20px; font-size: .72rem; font-weight: 700; background: var(--pc-tint); color: var(--pc); border: 1px solid var(--pc-soft); }
.rv-replied span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rv-edited { display: inline-flex; align-items: center; gap: 3px; font-size: .7rem; color: #94a3b8; font-style: italic; }

/* editing in place */
.rv-edit-form { display: grid; gap: 8px; margin: 0 0 12px; justify-items: stretch; }
.rv-edit-form[hidden] { display: none; }
.rv-edit-form textarea { border-radius: 12px; }
.rv-edit-foot { display: flex; justify-content: flex-end; gap: 6px; }
[data-rv-view][hidden] { display: none; }

/* pictures with a delete button for their owner */
.rv-shot { position: relative; }
.rv-shot form { position: absolute; top: 6px; inset-inline-end: 6px; margin: 0; }
.rv-shot-del { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; border: 0; background: rgba(15, 23, 42, .72); color: #fff; font-size: .75rem; opacity: 0; transition: opacity .15s, background .15s; }
.rv-shot:hover .rv-shot-del, .rv-shot-del:focus-visible { opacity: 1; }
.rv-shot-del:hover { background: #dc2626; }
@media (hover: none) { .rv-shot-del { opacity: 1; } }

/* comment tools for the writer */
.rv-msg-tools { display: inline-flex; gap: 2px; opacity: 0; transition: opacity .15s; }
.rv-msg:hover .rv-msg-tools, .rv-msg-tools:focus-within { opacity: 1; }
@media (hover: none) { .rv-msg-tools { opacity: 1; } }
.rv-msg-tools form { display: inline; margin: 0; }
.rv-msg-tools button { width: 24px; height: 24px; display: inline-grid; place-items: center; border: 0; border-radius: 6px; background: transparent; color: #64748b; font-size: .78rem; }
.rv-msg-tools button:hover { background: #fff; color: var(--pc, #0f172a); }
.rv-msg-tools form button:hover { color: #dc2626; }
.rv-msg .rv-edit-form { margin: 6px 0 2px; }

/* status entries in the conversation */
.rv-event.is-stage > .bi { color: #6366f1; }

/* footer: solved + status */
.rv-actions { align-items: flex-start; }
.rv-actions form { margin: 0; }
.rv-stage-btn { display: inline-flex; align-items: center; gap: 6px; }

/* status filter */
.rv-chip.is-stage.active { background: var(--sc, var(--brand)); border-color: var(--sc, var(--brand)); color: #fff; }
.rv-chip.is-stage:not(.active) > .bi { color: var(--sc); }
.rv-stage-chips, .rv-area-chips { flex-basis: 100%; align-items: center; }

/* filter panel as one card */
.rv-filter { padding: 14px; border-radius: 18px; background: #fff; border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px rgba(15, 23, 42, .04); }

/* hero: fourth counter */
.rv-stats .is-wait i { color: #fde68a; opacity: 1; }

@media (max-width: 640px) {
    .rv-point-head { padding: 14px 14px 0; padding-inline-start: 18px; }
    .rv-point-body, .rv-point-foot { padding-inline: 14px; padding-inline-start: 18px; }
    .rv-point-who { flex-basis: calc(100% - 100px); }
    .rv-actions { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
    .rv-actions .btn { width: 100%; justify-content: center; }
    .rv-stats { flex-wrap: wrap; }
    .rv-stats > div { flex: 1 1 calc(50% - 8px); }
    .rv-filter { padding: 12px; }
}

/* staff issue page: status card */
.stage-option { display: flex; align-items: center; gap: 8px; width: 100%; padding: 7px 10px; border-radius: 10px; border: 1px solid transparent; background: transparent; font-size: .86rem; font-weight: 600; color: #334155; text-align: start; transition: background .15s, color .15s; }
.stage-option > .bi { width: 26px; height: 26px; display: inline-grid; place-items: center; border-radius: 8px; background: var(--sc-soft); color: var(--sc); }
.stage-option:hover, .stage-option.active, .stage-option:disabled { background: var(--sc-soft); color: var(--sc); }
.stage-option.active { border-color: color-mix(in srgb, var(--sc) 35%, transparent); opacity: 1; }
.stage-option.active::after { content: "\2713"; margin-inline-start: auto; font-weight: 800; }

/* ===== v4.7.0 — review links: photos, who is online, media in replies, compare / link points, similar, search ===== */
.rv-avatar.has-photo { background: #e2e8f0; overflow: hidden; padding: 0; box-shadow: 0 0 0 2px var(--pc, var(--brand)); }
.rv-avatar.has-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rv-photo-btn { cursor: pointer; }
.rv-photo-pick { display: flex; align-items: center; gap: 12px; max-width: 440px; margin: 6px auto 0; padding: 10px 14px; border: 2px dashed var(--line); border-radius: 14px; cursor: pointer; text-align: start; transition: border-color .15s, background .15s; }
.rv-photo-pick:hover { border-color: var(--brand); background: var(--brand-tint); }
.rv-photo-pick.is-invalid { border-color: #dc3545; }
.rv-photo-pick > span:last-of-type { display: flex; flex-direction: column; }
.rv-photo-pick small { color: var(--rv-muted); font-size: .76rem; }
.rv-photo-preview { width: 52px; height: 52px; font-size: 1.3rem; background: var(--brand-soft); color: var(--brand); }

/* Who is online */
.rv-presence { padding: 14px 16px; margin-bottom: 14px; }
.rv-presence-head { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.rv-presence-head small { color: var(--rv-muted); }
.rv-presence-count { min-width: 26px; padding: 1px 8px; border-radius: 12px; background: #dcfce7; color: #15803d; font-weight: 800; font-size: .8rem; text-align: center; }
.rv-presence-more { margin-inline-start: auto; border: 0; background: none; color: var(--brand); font-size: .8rem; font-weight: 600; }
.rv-presence-more[aria-expanded="true"] i { transform: rotate(180deg); display: inline-block; }
.rv-live-dot { width: 10px; height: 10px; border-radius: 50%; background: #cbd5e1; }
.rv-live-dot.is-on { background: #22c55e; box-shadow: 0 0 0 0 rgba(34, 197, 94, .5); animation: rv-live 2s infinite; }
@keyframes rv-live { 70% { box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); } 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); } }
.rv-presence-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; }
.rv-here { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 14px; border: 1px solid var(--line); background: #fff; min-width: 0; transition: border-color .2s, background .2s; }
.rv-here.is-online { border-color: #bbf7d0; background: #f0fdf4; }
.rv-here.is-me { box-shadow: inset 0 0 0 1px var(--pc); }
.rv-person-pic { position: relative; flex-shrink: 0; }
.rv-person-pic .rv-avatar { width: 40px; height: 40px; }
.rv-dot { position: absolute; bottom: 0; inset-inline-end: 0; width: 12px; height: 12px; border-radius: 50%; border: 2px solid #fff; background: #94a3b8; }
.rv-here.is-online .rv-dot { background: #22c55e; }
.rv-here:not(.is-online) .rv-avatar { filter: grayscale(.35); opacity: .85; }
.rv-person-text { display: flex; flex-direction: column; min-width: 0; }
.rv-person-text strong { font-size: .86rem; color: var(--pc); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rv-person-text strong small { color: var(--rv-muted); font-weight: 500; }
.rv-person-meta { font-size: .72rem; color: var(--rv-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rv-here.is-online [data-seen] { color: #15803d; font-weight: 700; }

/* Videos and reply attachments */
.rv-shot.is-video { display: flex; flex-direction: column; gap: 4px; max-width: min(100%, 420px); }
.rv-shot.is-video video { display: block; width: 100%; max-height: 300px; border-radius: 12px; background: #0f172a; border: 1px solid var(--line); }
.rv-video-meta { font-size: .72rem; color: var(--rv-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rv-shot { position: relative; }
.rv-shot .rv-shot-del { z-index: 2; }
.rv-bubble .rv-shots { margin: 8px 0 2px; }
.rv-bubble .rv-shots img { max-height: 180px; max-width: min(100%, 260px); }
.rv-bubble .rv-shot.is-video { max-width: min(100%, 320px); }
.rv-thumb.is-video video { display: block; width: 92px; height: 92px; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); background: #0f172a; }
.rv-thumb-tag { position: absolute; bottom: 4px; inset-inline-start: 4px; padding: 0 5px; border-radius: 6px; background: rgba(15, 23, 42, .75); color: #fff; font-size: .7rem; }
.rv-media-warn { margin-top: 6px; padding: 6px 10px; border-radius: 10px; background: #fef2f2; color: #b91c1c; font-size: .8rem; }
.rv-reply-box { flex: 1; min-width: 0; border-radius: 12px; transition: box-shadow .15s; }
.rv-reply-box.is-over { box-shadow: 0 0 0 2px var(--brand); }
.rv-reply-row { position: relative; }
.rv-reply-row textarea { padding-inline-end: 42px; }
.rv-attach { position: absolute; top: 4px; inset-inline-end: 4px; width: 32px; height: 30px; display: grid; place-items: center; border-radius: 9px; color: var(--rv-muted); cursor: pointer; font-size: 1.05rem; margin: 0; }
.rv-attach:hover { background: var(--brand-tint); color: var(--brand); }
.rv-reply .rv-previews:not(:empty) { margin-top: 8px; }
.rv-reply .rv-thumb img, .rv-reply .rv-thumb.is-video video { width: 64px; height: 64px; }
.rv-reply .rv-name-line:empty { display: none; }

/* Linked points, similar points, compare */
.rv-links { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 16px 10px; }
.rv-link { --lk: #475569; --lk-soft: #f1f5f9; display: inline-flex; align-items: center; gap: 6px; padding: 3px 4px 3px 10px; border-radius: 20px; background: var(--lk-soft); color: var(--lk); font-size: .78rem; font-weight: 700; }
[dir="rtl"] .rv-link { padding: 3px 10px 3px 4px; }
.rv-link.is-conflict { --lk: #b91c1c; --lk-soft: #fee2e2; }
.rv-link.is-duplicate { --lk: #7c3aed; --lk-soft: #ede9fe; }
.rv-link.is-related { --lk: #0369a1; --lk-soft: #e0f2fe; }
.rv-link a, .rv-similar a { color: inherit; font-weight: 800; text-decoration: none; }
.rv-link a:hover, .rv-similar a:hover { text-decoration: underline; }
.rv-link-btn { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border: 0; border-radius: 14px; background: #fff; color: inherit; font-size: .72rem; font-weight: 700; box-shadow: 0 1px 2px rgba(15, 23, 42, .08); }
.rv-link-btn:hover { background: var(--brand); color: #fff; }
.rv-link-x { width: 22px; height: 22px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: inherit; display: grid; place-items: center; }
.rv-link-x:hover { background: rgba(0, 0, 0, .08); }
.rv-similar { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 6px; padding: 3px 10px; border-radius: 20px; background: #fef9c3; color: #854d0e; font-size: .78rem; font-weight: 600; }
.rv-similar-item { display: inline-flex; align-items: center; gap: 4px; }
.rv-similar-score { padding: 0 6px; border-radius: 10px; background: rgba(255, 255, 255, .7); font-size: .68rem; font-weight: 800; }
.rv-similar-live { margin-top: 8px; padding: 10px 12px; border-radius: 12px; background: #fffbeb; border: 1px solid #fde68a; color: #78350f; font-size: .82rem; }
.rv-similar-live > strong { display: block; margin-bottom: 6px; }
.rv-similar-row { display: flex; align-items: center; gap: 8px; padding: 4px 0; border-top: 1px dashed #fde68a; }
.rv-similar-row a { font-weight: 800; color: #92400e; }
.rv-similar-row.is-done .rv-similar-text { text-decoration: line-through; opacity: .7; }
.rv-similar-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rv-relate-new { margin-top: 12px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: #fafbfc; }
.rv-relate-new summary { cursor: pointer; font-weight: 600; font-size: .86rem; color: #475569; }
.rv-relate-new[open] summary { margin-bottom: 8px; color: var(--brand); }
.rv-relate-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 8px; margin-top: 6px; }
.rv-relate-grid label { display: flex; flex-direction: column; gap: 3px; font-size: .76rem; color: var(--rv-muted); margin: 0; }
.rv-relate-note { grid-column: 1 / -1; }
.rv-relate-form { margin-bottom: 12px; padding: 12px; border-radius: 14px; border: 1px solid var(--brand-soft); background: var(--brand-tint); }
.rv-relate-form > strong { font-size: .86rem; color: var(--brand); }
.rv-chip.is-linked.active { background: #b91c1c; border-color: #b91c1c; }
.rv-chip.is-similar.active { background: #a16207; border-color: #a16207; }
.rv-compare .modal-content { border-radius: 18px; }
.rv-compare-kind { margin-inline-start: 10px; }
.rv-compare-note { padding: 8px 12px; border-radius: 10px; background: #fef2f2; color: #991b1b; font-size: .86rem; }
.rv-compare-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.rv-compare-col { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: #fff; border-top: 4px solid var(--st, var(--brand)); }
.rv-compare-col .rv-point-head { border-bottom: 1px solid var(--line); }
.rv-compare-body { padding: 12px 16px; flex: 1; }
.rv-compare-body .rv-text { white-space: pre-wrap; }
.rv-compare-go { margin: 0 16px 14px; align-self: flex-start; }
.rv-compare-diff { margin-top: 16px; }
.rv-compare-diff h3 { font-size: .95rem; font-weight: 700; }
.rv-compare-words { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.rv-compare-words > div { padding: 10px; border-radius: 12px; background: #f8fafc; border: 1px solid var(--line); }
.rv-compare-words p { margin: 6px 0 0; display: flex; flex-wrap: wrap; gap: 4px; }
.rv-compare-words span { padding: 1px 8px; border-radius: 10px; background: #fff; border: 1px solid var(--line); font-size: .76rem; }
.rv-compare-words > div:first-child span { background: #dcfce7; border-color: #bbf7d0; }
@media (max-width: 767.98px) {
    .rv-compare-grid, .rv-compare-words, .rv-relate-grid { grid-template-columns: minmax(0, 1fr); }
}

/* Search */
.rv-search .rv-search-key { position: absolute; top: 50%; inset-inline-end: 10px; transform: translateY(-50%); padding: 1px 7px; border-radius: 6px; background: #f1f5f9; color: #64748b; border: 1px solid var(--line); font-size: .72rem; box-shadow: none; pointer-events: none; }
.rv-search .rv-search-count { position: absolute; top: 50%; inset-inline-end: 40px; transform: translateY(-50%); padding: 0 8px; border-radius: 10px; background: var(--brand-soft); color: var(--brand); font-size: .72rem; font-weight: 700; pointer-events: none; }
.rv-search .form-control { padding-inline-end: 96px; }
.rv-search-scope { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; flex-basis: 100%; font-size: .76rem; color: var(--rv-muted); }
.rv-search-scope label { display: inline-flex; align-items: center; gap: 4px; margin: 0; cursor: pointer; }
mark.rv-hit { padding: 0 2px; border-radius: 4px; background: #fde68a; color: inherit; }
.rv-point.rv-flash { animation: rv-flash 1.4s ease-out; }
@keyframes rv-flash { 0%, 30% { box-shadow: 0 0 0 4px var(--brand-soft), 0 0 0 6px var(--brand); } 100% { box-shadow: none; } }
.rv-toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); z-index: 2000; padding: 8px 16px; border-radius: 20px; background: #0f172a; color: #fff; font-size: .86rem; box-shadow: 0 10px 30px rgba(15, 23, 42, .3); transition: opacity .4s, transform .4s; }
.rv-toast.is-out { opacity: 0; transform: translate(-50%, 10px); }
@media (max-width: 575.98px) {
    .rv-presence-list { grid-template-columns: minmax(0, 1fr); }
    .rv-search .rv-search-key { display: none; }
    .rv-search .rv-search-count { inset-inline-end: 10px; }
    .rv-search .form-control { padding-inline-end: 70px; }
}
@media (prefers-reduced-motion: reduce) {
    .rv-live-dot.is-on, .rv-point.rv-flash { animation: none; }
}
/* Team pages: video files in the gallery and in comments */
.review-shot.is-video video { display: block; width: 100%; max-width: 420px; max-height: 280px; border-radius: 10px; background: #0f172a; }
.review-shot-video { display: inline-flex; align-items: center; gap: 6px; padding: 8px 10px; border-radius: 10px; background: #f1f5f9; font-size: .8rem; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Project page: linked projects and short links */
.plk-item { display: flex; align-items: flex-start; gap: 10px; }
.plk-icon { width: 34px; height: 34px; flex-shrink: 0; display: grid; place-items: center; border-radius: 10px; background: var(--bs-primary-bg-subtle, #e0e7ff); color: var(--brand, #4f46e5); }
.plk-targets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.plk-targets label { margin: 0; cursor: pointer; }
.plk-targets input { position: absolute; opacity: 0; pointer-events: none; }
.plk-targets span { display: flex; align-items: center; gap: 6px; height: 100%; padding: 7px 10px; border: 1px solid var(--bs-border-color, #dee2e6); border-radius: 10px; background: #fff; font-size: .8rem; font-weight: 600; transition: border-color .15s, background .15s; }
.plk-targets input:checked + span { border-color: var(--brand, #4f46e5); background: var(--bs-primary-bg-subtle, #eef2ff); color: var(--brand, #4f46e5); }
.plk-targets input:focus-visible + span { outline: 2px solid var(--brand, #4f46e5); outline-offset: 2px; }
.plk-url { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .86rem; font-weight: 600; word-break: break-all; text-decoration: none; }
.plk-short.is-off .plk-url { color: #94a3b8; text-decoration: line-through; }
.plk-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 6px; font-size: .76rem; color: #64748b; }
.plk-meta form { display: inline; }
.plk-qr { width: 160px; margin: 10px auto 0; padding: 8px; background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; }
.plk-qr svg { display: block; width: 100%; height: auto; }
.plk-edit { margin-top: 10px; }

/* ===== v4.7.0 — attachments grid, popup viewer, keywords, recycle bin ===== */
.md-wrap { display: flex; flex-direction: column; gap: 10px; margin: 4px 0 12px; }
.md-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.md-wrap.is-small .md-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; }
.md-item { position: relative; margin: 0; border-radius: 14px; overflow: hidden; background: #0f172a; aspect-ratio: 4 / 3; box-shadow: 0 1px 2px rgba(15, 23, 42, .08); isolation: isolate; }
.md-item.is-image { background: #f1f5f9; }
.md-open { display: block; width: 100%; height: 100%; color: #fff; }
.md-open img, .md-open video { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .45s cubic-bezier(.2, .8, .2, 1), filter .3s; }
.md-open:hover img, .md-open:hover video, .md-open:focus-visible img { transform: scale(1.06); }
.md-open:focus-visible { outline: 3px solid var(--brand, #4f46e5); outline-offset: -3px; }
.md-play { position: absolute; inset: 0; margin: auto; width: 54px; height: 54px; display: grid; place-items: center; border-radius: 50%; background: rgba(255, 255, 255, .92); color: #0f172a; font-size: 1.7rem; box-shadow: 0 8px 24px rgba(0, 0, 0, .35); transition: transform .25s cubic-bezier(.2, .8, .2, 1); }
.md-play i { margin-inline-start: 3px; }
.md-open:hover .md-play { transform: scale(1.12); }
.md-item.is-video::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(15, 23, 42, .55), transparent 45%); pointer-events: none; }
.md-badge { position: absolute; bottom: 8px; inset-inline-start: 8px; z-index: 1; padding: 2px 8px; border-radius: 10px; background: rgba(15, 23, 42, .7); font-size: .7rem; font-weight: 600; }
.md-zoom { position: absolute; top: 8px; inset-inline-end: 8px; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; background: rgba(15, 23, 42, .55); font-size: .8rem; opacity: 0; transform: scale(.8); transition: opacity .2s, transform .2s; }
.md-open:hover .md-zoom, .md-open:focus-visible .md-zoom { opacity: 1; transform: none; }
.md-del-form { position: absolute; top: 8px; inset-inline-start: 8px; z-index: 2; margin: 0; }
.md-file .md-del-form { position: static; }
.md-del { width: 28px; height: 28px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 8px; background: rgba(220, 38, 38, .92); color: #fff; font-size: .8rem; opacity: .85; transition: opacity .15s, transform .15s; }
.md-del:hover { opacity: 1; transform: scale(1.08); }
.md-file .md-del { background: #fee2e2; color: #b91c1c; }
.md-files { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px; }
.md-file { display: flex; align-items: center; gap: 10px; min-width: 0; padding: 10px 12px; border-radius: 14px; border: 1px solid var(--line, #e2e8f0); background: #fff; transition: border-color .2s, box-shadow .2s, transform .2s; }
.md-file:hover { border-color: var(--brand, #4f46e5); box-shadow: 0 6px 18px rgba(15, 23, 42, .07); transform: translateY(-1px); }
.md-file-icon { position: relative; width: 42px; height: 46px; flex-shrink: 0; display: grid; place-items: center; border-radius: 10px; background: #eef2ff; color: #4f46e5; font-size: 1.3rem; }
.md-file-icon b { position: absolute; bottom: -5px; inset-inline-end: -6px; padding: 0 5px; border-radius: 6px; background: #4f46e5; color: #fff; font-size: .58rem; letter-spacing: .02em; }
.md-file.is-pdf .md-file-icon { background: #fee2e2; color: #dc2626; } .md-file.is-pdf .md-file-icon b { background: #dc2626; }
.md-file.is-json .md-file-icon { background: #fef3c7; color: #b45309; } .md-file.is-json .md-file-icon b { background: #b45309; }
.md-file.is-md .md-file-icon { background: #e0f2fe; color: #0369a1; } .md-file.is-md .md-file-icon b { background: #0369a1; }
.md-file.is-csv .md-file-icon { background: #dcfce7; color: #15803d; } .md-file.is-csv .md-file-icon b { background: #15803d; }
.md-file-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.md-file-text strong { font-size: .84rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.md-file-text small { font-size: .72rem; color: #64748b; }
.md-file-actions { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.md-btn { display: inline-flex; align-items: center; justify-content: center; gap: 4px; width: 32px; height: 32px; padding: 0; border-radius: 9px; background: #f1f5f9; color: #334155; font-size: .74rem; font-weight: 600; text-decoration: none; transition: background .15s, color .15s; }
.md-btn:hover { background: var(--brand, #4f46e5); color: #fff; }
@media (max-width: 575.98px) {
    .md-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .md-files { grid-template-columns: minmax(0, 1fr); }
    .md-btn span { display: none; }
}
.rv-thumb.is-doc { width: 92px; height: 92px; }
.rv-thumb-doc { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; width: 100%; height: 100%; padding: 6px; border-radius: 12px; border: 1px solid var(--line); background: #eef2ff; color: #3730a3; text-align: center; overflow: hidden; }
.rv-thumb-doc b { padding: 1px 6px; border-radius: 6px; background: #4f46e5; color: #fff; font-size: .7rem; }
.rv-thumb-doc small { font-size: .62rem; width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rv-reply .rv-thumb.is-doc { width: 64px; height: 64px; }

/* Popup viewer */
html.vw-open { overflow: hidden; }
.vw { position: fixed; inset: 0; z-index: 2000; display: grid; place-items: center; padding: clamp(8px, 3vw, 32px); }
.vw[hidden] { display: none; }
.vw-backdrop { position: absolute; inset: 0; background: rgba(2, 6, 23, .82); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; transition: opacity .22s ease; }
.vw-panel { position: relative; display: flex; flex-direction: column; width: min(1100px, 100%); max-height: 100%; border-radius: 20px; overflow: hidden; background: #0b1120; color: #e2e8f0; box-shadow: 0 30px 80px rgba(0, 0, 0, .5); opacity: 0; transform: translateY(14px) scale(.96); transition: opacity .25s ease, transform .3s cubic-bezier(.2, .8, .2, 1); }
.vw.is-in .vw-backdrop { opacity: 1; }
.vw.is-in .vw-panel { opacity: 1; transform: none; }
.vw-top { display: flex; align-items: center; gap: 10px; padding: 10px 12px 10px 16px; background: rgba(255, 255, 255, .04); border-bottom: 1px solid rgba(255, 255, 255, .08); }
[dir="rtl"] .vw-top { padding: 10px 16px 10px 12px; }
.vw-count { padding: 2px 9px; border-radius: 10px; background: rgba(255, 255, 255, .1); font-size: .75rem; font-weight: 700; }
.vw-name { flex: 1; min-width: 0; font-size: .88rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vw-tools { display: flex; gap: 4px; }
.vw-btn { width: 36px; height: 36px; display: grid; place-items: center; border: 0; border-radius: 10px; background: rgba(255, 255, 255, .08); color: #fff; text-decoration: none; transition: background .15s, transform .15s; }
.vw-btn:hover { background: rgba(255, 255, 255, .2); color: #fff; transform: translateY(-1px); }
.vw-btn[hidden] { display: none; }
.vw-x:hover { background: #dc2626; }
.vw-stage { position: relative; flex: 1; min-height: 200px; display: grid; place-items: center; overflow: auto; background: radial-gradient(circle at center, #111827, #030712); }
.vw-img { display: block; max-width: 100%; max-height: calc(100vh - 140px); object-fit: contain; cursor: zoom-in; animation: vw-in .3s cubic-bezier(.2, .8, .2, 1); }
.vw-stage.is-zoomed { place-items: start; cursor: zoom-out; }
.vw-stage.is-zoomed .vw-img { max-width: none; max-height: none; cursor: zoom-out; }
.vw-video { display: block; width: 100%; max-height: calc(100vh - 140px); background: #000; animation: vw-in .3s ease; }
.vw-text { width: 100%; height: min(70vh, calc(100vh - 140px)); margin: 0; padding: 18px 20px; overflow: auto; background: #0b1120; color: #e2e8f0; font: .84rem/1.6 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: pre-wrap; word-break: break-word; text-align: start; }
.vw-nav { position: absolute; top: 50%; z-index: 2; width: 46px; height: 46px; margin-top: 4px; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .14); color: #fff; font-size: 1.2rem; backdrop-filter: blur(4px); transition: background .15s, transform .15s; }
.vw-nav:hover { background: rgba(255, 255, 255, .3); transform: scale(1.08); }
.vw-nav.is-prev { inset-inline-start: 12px; }
.vw-nav.is-next { inset-inline-end: 12px; }
.vw-nav[hidden] { display: none; }
.vw[data-type="text"] .vw-nav { top: auto; bottom: 14px; }
@keyframes vw-in { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }
@media (max-width: 575.98px) {
    .vw { padding: 0; }
    .vw-panel { border-radius: 0; height: 100%; }
    .vw-nav { width: 40px; height: 40px; }
}
@media (prefers-reduced-motion: reduce) {
    .vw-panel, .vw-backdrop, .vw-img, .vw-video, .md-open img, .md-open video { transition: none; animation: none; }
}

/* Keywords */
.rv-tagbox { margin-top: 12px; position: relative; }
.rv-tag-field { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-height: 42px; padding: 5px 8px; cursor: text; border-radius: 12px; }
.rv-tag-field:focus-within { border-color: var(--brand); box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--brand) 20%, transparent); }
.rv-tag-input { flex: 1; min-width: 140px; border: 0; outline: 0; background: transparent; padding: 4px 2px; font-size: .9rem; }
.rv-tag { display: inline-flex; align-items: center; gap: 4px; padding: 3px 4px 3px 10px; border-radius: 16px; background: var(--brand-soft, #e0e7ff); color: var(--brand-dark, #3730a3); font-size: .8rem; font-weight: 700; animation: rv-pop .25s ease both; }
[dir="rtl"] .rv-tag { padding: 3px 10px 3px 4px; }
.rv-tag button { width: 20px; height: 20px; padding: 0; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .7); color: inherit; line-height: 1; }
.rv-tag button:hover { background: #fee2e2; color: #b91c1c; }
.rv-tag-drop { position: absolute; z-index: 20; inset-inline: 0; margin-top: 4px; padding: 4px; border-radius: 12px; background: #fff; border: 1px solid var(--line); box-shadow: 0 14px 34px rgba(15, 23, 42, .14); max-height: 260px; overflow: auto; }
.rv-tag-opt { display: flex; justify-content: space-between; width: 100%; padding: 7px 10px; border: 0; border-radius: 8px; background: transparent; font-size: .86rem; text-align: start; }
.rv-tag-opt span { color: #94a3b8; font-size: .74rem; }
.rv-tag-opt:hover, .rv-tag-opt.active { background: var(--brand-tint, #eef2ff); color: var(--brand); }
.rv-tag-suggest { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; }
.rv-tag-suggest small { color: var(--rv-muted, #64748b); font-size: .74rem; }
.rv-tag-sug { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 14px; border: 1px dashed var(--brand); background: transparent; color: var(--brand); font-size: .76rem; font-weight: 600; transition: background .15s, color .15s; }
.rv-tag-sug span { padding: 0 5px; border-radius: 8px; background: var(--brand-soft, #e0e7ff); font-size: .66rem; }
.rv-tag-sug:hover { background: var(--brand); color: #fff; border-style: solid; }
.rv-keywords { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 16px 10px; }
.rv-keyword { display: inline-flex; align-items: center; gap: 2px; padding: 3px 10px; border: 1px solid var(--brand-soft, #e0e7ff); border-radius: 14px; background: var(--brand-tint, #f5f7ff); color: var(--brand-dark, #3730a3); font-size: .76rem; font-weight: 700; transition: background .15s, color .15s, transform .15s; }
.rv-keyword:hover, .rv-keyword.active { background: var(--brand); border-color: var(--brand); color: #fff; transform: translateY(-1px); }
.rv-chip.is-tag.active { background: var(--brand-dark, #3730a3); border-color: var(--brand-dark, #3730a3); }

/* Recycle bin */
.trash-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; background: #f1f5f9; color: #475569; font-size: 1.1rem; }
.trash-icon.is-point { background: #fee2e2; color: #b91c1c; }
.trash-icon.is-comment { background: #e0f2fe; color: #0369a1; }
.trash-icon.is-media { background: #fef3c7; color: #b45309; }

/* ===== v4.7.0 — review link pages: full-width layout, polish and motion (works back to Safari 14 / Chrome 88) ===== */
.rv-body { overflow-x: hidden; }
.container.rv-wrap { max-width: none; width: 100%; padding-left: clamp(10px, 2.2vw, 32px); padding-right: clamp(10px, 2.2vw, 32px); }
.rv-main { padding-top: clamp(12px, 2vw, 24px); }
.rv-hero { border-radius: clamp(16px, 2vw, 26px); padding: clamp(18px, 2.6vw, 34px); }
.rv-hero h1 { font-size: clamp(1.35rem, 1rem + 1.6vw, 2.2rem); }
.rv-hero-side { min-width: min(100%, 420px); }

/* Two columns on wide screens: the points, and a sticky side column with who is online */
.rv-layout { display: block; }
.rv-layout > .rv-aside { margin-bottom: 14px; }
@media (min-width: 1200px) {
    .rv-layout.has-aside { display: grid; grid-template-columns: minmax(0, 1fr) clamp(280px, 22vw, 360px); gap: 18px; align-items: start; }
    .rv-layout.has-aside > .rv-aside { order: 2; position: -webkit-sticky; position: sticky; top: 76px; margin: 0; max-height: calc(100vh - 92px); overflow: auto; scrollbar-width: thin; }
    .rv-layout.has-aside > .rv-col { order: 1; min-width: 0; }
    .rv-aside .rv-presence { margin: 0; }
    .rv-aside .rv-presence-list { grid-template-columns: minmax(0, 1fr); }
}
/* Very wide screens: points flow in two columns, no empty space left between cards */
@media (min-width: 1700px) {
    .rv-list { -webkit-columns: 2 560px; columns: 2 560px; -webkit-column-gap: 18px; column-gap: 18px; }
    .rv-list > .rv-point { -webkit-column-break-inside: avoid; break-inside: avoid; page-break-inside: avoid; display: block; width: 100%; }
}
.rv-composer, .rv-filter, .rv-list > .rv-point { margin-left: 0; margin-right: 0; }

/* Cards: depth on hover, a glow when reached by a link */
.rv-card { transition: box-shadow .25s ease, transform .25s ease, border-color .25s ease; }
.rv-point:hover { box-shadow: 0 2px 4px rgba(15, 23, 42, .05), 0 16px 40px rgba(15, 23, 42, .08); }
@media (hover: hover) and (min-width: 768px) {
    .rv-point:hover { transform: translateY(-2px); }
}
.rv-point:target { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft), 0 16px 40px rgba(15, 23, 42, .1); }

/* Header gets a shadow once the page scrolls (set by app.js) */
.rv-top { transition: box-shadow .25s ease, background .25s ease; }
.rv-body.is-scrolled .rv-top { box-shadow: 0 6px 24px rgba(15, 23, 42, .08); background: rgba(255, 255, 255, .92); }

/* Motion */
.motion .rv-here { animation: rv-pop .4s cubic-bezier(.2, .8, .2, 1) both; }
.motion .rv-here:nth-child(2) { animation-delay: .05s; } .motion .rv-here:nth-child(3) { animation-delay: .1s; }
.motion .rv-here:nth-child(4) { animation-delay: .15s; } .motion .rv-here:nth-child(n+5) { animation-delay: .2s; }
.rv-here.is-online .rv-dot { animation: rv-live 2s infinite; }
.rv-chip, .rv-keyword, .rv-link-btn, .md-btn, .btn { transition-property: background, color, border-color, box-shadow, transform; transition-duration: .18s; }
.rv-chip:active, .rv-keyword:active, .rv-link-btn:active, .btn:active { transform: scale(.96); }
.motion .rv-keyword, .motion .rv-link, .motion .rv-similar { animation: rv-pop .35s ease both; }
details.rv-triage[open] > form, details.rv-relate-new[open] > *:not(summary) { animation: rv-slide .28s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes rv-slide { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.btn-primary { position: relative; overflow: hidden; }
.motion .rv-body .btn-primary::after, .motion .btn-primary.rv-shine::after { content: ""; position: absolute; top: 0; bottom: 0; width: 40%; left: -60%; background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .35), transparent); transform: skewX(-20deg); transition: left .6s ease; pointer-events: none; }
.motion .rv-body .btn-primary:hover::after { left: 120%; }
.rv-progress-bar span { transition: width 1.2s cubic-bezier(.2, .8, .2, 1); }

/* Phones: edge to edge cards with a small gutter, bigger touch targets */
@media (max-width: 575.98px) {
    .container.rv-wrap { padding-left: 8px; padding-right: 8px; }
    .rv-card, .rv-hero { border-radius: 14px; }
    .rv-point-head { padding-left: 12px; padding-right: 12px; }
    .rv-keywords, .rv-links { padding-left: 12px; padding-right: 12px; }
    .rv-kebab, .rv-stage { min-height: 36px; }
    .rv-filter-chips { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; padding-bottom: 2px; max-width: 100%; }
    .rv-filter-chips::-webkit-scrollbar { display: none; }
    .rv-chip { flex-shrink: 0; }
}
/* Tablets */
@media (min-width: 576px) and (max-width: 1199.98px) {
    .rv-presence-list { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
}

/* Older browsers: no color-mix() */
@supports not (color: color-mix(in srgb, red 50%, blue)) {
    .rv-tag-field:focus-within { box-shadow: 0 0 0 .2rem rgba(79, 70, 229, .2); }
}
/* Older browsers: no aspect-ratio */
@supports not (aspect-ratio: 4 / 3) {
    .md-item { height: 0; padding-top: 75%; }
    .md-open { position: absolute; inset: 0; }
}

/* Connection details (administration) */
.rv-conn-line { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; color: #64748b; }
.rv-conn-more { margin-inline-start: auto; padding: 2px 8px; border: 0; border-radius: 8px; background: transparent; color: var(--brand, #4f46e5); font-size: .76rem; font-weight: 600; }
.rv-conn-more:hover { background: rgba(79, 70, 229, .08); }
.rv-conn { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 6px; margin: 8px 0; }
.rv-conn > div { padding: 6px 9px; border-radius: 10px; background: #fff; border: 1px solid #e2e8f0; min-width: 0; }
.rv-conn dt { font-size: .68rem; font-weight: 600; color: #64748b; }
.rv-conn dd { margin: 0; font-size: .8rem; font-weight: 600; overflow-wrap: anywhere; }
.rv-conn-ua { margin-bottom: 8px; padding: 6px 9px; border-radius: 10px; background: #f8fafc; color: #64748b; font: .7rem/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; overflow-wrap: anywhere; }
.rv-visits { border: 1px solid #e2e8f0; border-radius: 10px; background: #fff; }
.rv-visits table { font-size: .74rem; }
.rv-visits th { font-weight: 600; color: #64748b; white-space: nowrap; }
.rv-person.is-removed { opacity: .65; border-style: dashed; }

@media (prefers-reduced-motion: reduce) {
    .rv-card, .rv-point:hover, .motion .rv-here, .motion .rv-keyword, .motion .rv-link, .motion .rv-similar,
    details.rv-triage[open] > form, details.rv-relate-new[open] > *:not(summary), .rv-here.is-online .rv-dot { animation: none !important; transition: none !important; transform: none !important; }
}

/* ===== v4.7.0 — project files (project page and review links) ===== */
.pf-card { overflow: hidden; }
.rv-card.pf-card { margin-bottom: 14px; }
.pf-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line, #e2e8f0); }
.pf-head-icon { width: 40px; height: 40px; flex-shrink: 0; display: grid; place-items: center; border-radius: 12px; background: linear-gradient(135deg, var(--brand, #4f46e5), var(--brand-dark, #3730a3)); color: #fff; font-size: 1.1rem; box-shadow: 0 6px 16px rgba(15, 23, 42, .15); }
.pf-upload { padding: 14px 16px; border-bottom: 1px solid var(--line, #e2e8f0); background: #fafbfc; }
.pf-drop { display: flex; align-items: center; gap: 12px; padding: 14px; margin: 0 0 10px; border: 2px dashed #cbd5e1; border-radius: 14px; background: #fff; cursor: pointer; transition: border-color .15s, background .15s, transform .15s; }
.pf-drop:hover, .pf-drop.is-over { border-color: var(--brand, #4f46e5); background: #f5f7ff; }
.pf-drop.is-over { transform: scale(1.01); }
.pf-drop.is-bad { border-color: #dc2626; background: #fef2f2; }
.pf-drop > i { font-size: 1.8rem; color: var(--brand, #4f46e5); }
.pf-drop > span { display: flex; flex-direction: column; min-width: 0; }
.pf-drop strong { overflow-wrap: anywhere; }
.pf-drop small { color: #64748b; font-size: .76rem; }
.pf-fields { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 8px; }
.pf-fields textarea { grid-column: 1 / -1; }
.pf-progress { position: relative; height: 22px; margin-top: 10px; border-radius: 11px; background: #e2e8f0; overflow: hidden; }
.pf-progress span { position: absolute; inset-block: 0; inset-inline-start: 0; width: 0; background: linear-gradient(90deg, var(--brand, #4f46e5), #22c55e); transition: width .2s ease; }
.pf-progress b { position: relative; display: block; text-align: center; font-size: .72rem; line-height: 22px; color: #0f172a; }
.pf-upload-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-top: 10px; }
.pf-empty { padding: 26px 16px; text-align: center; color: #94a3b8; }
.pf-list { list-style: none; margin: 0; padding: 0; }
.pf-item { padding: 14px 16px; border-bottom: 1px solid var(--line, #e2e8f0); transition: background .2s; }
.pf-item:last-child { border-bottom: 0; }
.pf-item:hover { background: #fafbff; }
.pf-item:target { background: #f5f7ff; box-shadow: inset 3px 0 0 var(--brand, #4f46e5); }
.pf-item.is-latest { background: linear-gradient(90deg, rgba(34, 197, 94, .06), transparent 60%); }
.pf-main { display: flex; align-items: flex-start; gap: 12px; }
.pf-icon { position: relative; width: 48px; height: 52px; flex-shrink: 0; display: grid; place-items: center; border-radius: 12px; background: #eef2ff; color: #4f46e5; font-size: 1.45rem; }
.pf-icon b { position: absolute; bottom: -6px; inset-inline-end: -6px; max-width: 54px; padding: 0 5px; border-radius: 6px; background: #4f46e5; color: #fff; font-size: .56rem; overflow: hidden; text-overflow: ellipsis; }
.pf-item.is-android .pf-icon { background: #dcfce7; color: #16a34a; } .pf-item.is-android .pf-icon b { background: #16a34a; }
.pf-item.is-ios .pf-icon, .pf-item.is-mac .pf-icon { background: #f1f5f9; color: #0f172a; } .pf-item.is-ios .pf-icon b, .pf-item.is-mac .pf-icon b { background: #0f172a; }
.pf-item.is-windows .pf-icon { background: #e0f2fe; color: #0284c7; } .pf-item.is-windows .pf-icon b { background: #0284c7; }
.pf-item.is-archive .pf-icon { background: #fef3c7; color: #b45309; } .pf-item.is-archive .pf-icon b { background: #b45309; }
.pf-item.is-document .pf-icon { background: #fee2e2; color: #dc2626; } .pf-item.is-document .pf-icon b { background: #dc2626; }
.pf-item.is-key .pf-icon { background: #fae8ff; color: #a21caf; } .pf-item.is-key .pf-icon b { background: #a21caf; }
.pf-info { flex: 1; min-width: 0; }
.pf-title { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.pf-title strong { font-size: .95rem; overflow-wrap: anywhere; }
.pf-version { padding: 1px 8px; border-radius: 10px; background: #0f172a; color: #fff; font-size: .7rem; font-weight: 700; }
.pf-latest { padding: 1px 8px; border-radius: 10px; background: #dcfce7; color: #15803d; font-size: .7rem; font-weight: 700; }
.pf-kind { padding: 1px 8px; border-radius: 10px; background: #f1f5f9; color: #475569; font-size: .7rem; font-weight: 600; }
.pf-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 4px; font-size: .74rem; color: #64748b; }
.pf-orig { max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.pf-note { margin: 6px 0 0; font-size: .84rem; color: #334155; white-space: pre-line; }
.pf-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.pf-edit { margin-top: 10px; padding: 10px; border-radius: 12px; background: #f8fafc; }
.pf-more { margin-top: 10px; }
.pf-more > summary { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; cursor: pointer; font-size: .8rem; font-weight: 600; color: #475569; list-style: none; }
.pf-more > summary::-webkit-details-marker { display: none; }
.pf-more > summary:hover { color: var(--brand, #4f46e5); }
.pf-sha { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-weight: 500; color: #94a3b8; font-size: .72rem; }
.pf-sha-full { margin: 8px 0; padding: 6px 10px; border-radius: 10px; background: #f8fafc; font-size: .72rem; overflow-wrap: anywhere; }
.pf-sha-full span { font-weight: 700; color: #64748b; }
.pf-thread { list-style: none; margin: 8px 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pf-comment { display: flex; gap: 8px; animation: rv-pop .3s ease both; }
.pf-avatar { width: 28px; height: 28px; flex-shrink: 0; display: grid; place-items: center; border-radius: 50%; background: #64748b; color: #fff; font-size: .75rem; font-weight: 700; }
.pf-comment.is-dev .pf-avatar { background: #1d4ed8; } .pf-comment.is-tester .pf-avatar { background: #0f766e; }
.pf-comment.is-admin .pf-avatar { background: #a16207; } .pf-comment.is-team .pf-avatar { background: #7c3aed; }
.pf-bubble { flex: 1; min-width: 0; padding: 7px 11px; border-radius: 12px; border-start-start-radius: 4px; background: #f8fafc; border: 1px solid #e2e8f0; }
.pf-comment-top { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: .76rem; }
.pf-comment-top time { color: #94a3b8; }
.pf-bubble p { margin: 4px 0 0; font-size: .86rem; overflow-wrap: anywhere; }
.pf-x { width: 26px; height: 26px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: #94a3b8; }
.pf-x:hover { background: #fee2e2; color: #b91c1c; }
.pf-comment-form { display: flex; gap: 8px; align-items: flex-start; margin-top: 8px; }
.pf-comment-form textarea { resize: vertical; min-height: 34px; border-radius: 10px; }
@media (max-width: 575.98px) {
    .pf-main { flex-wrap: wrap; }
    .pf-actions { width: 100%; justify-content: flex-end; }
    .pf-fields { grid-template-columns: minmax(0, 1fr); }
    .pf-orig { max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .pf-comment, .pf-drop, .pf-progress span { animation: none; transition: none; }
}

/* ===== v4.7.0 — supervisor, my account, recovery code, accordion, private notes ===== */
.rv-sup-badge { background: #0f172a !important; color: #fde68a !important; border-color: #0f172a !important; }
.rv-sup-mark { color: #b45309; font-size: .8em; }
.rv-recover { display: flex; align-items: flex-start; gap: 14px; margin-top: 14px; padding: 18px; border-style: dashed; background: linear-gradient(135deg, #fffbeb, #fff); }
.rv-recover-icon { width: 44px; height: 44px; flex-shrink: 0; display: grid; place-items: center; border-radius: 12px; background: #0f172a; color: #fde68a; font-size: 1.2rem; }
.rv-recover p { margin: 4px 0 10px; font-size: .84rem; color: var(--rv-muted); }
.rv-recover-row { display: flex; gap: 8px; flex-wrap: wrap; }
.rv-code-input { max-width: 240px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .12em; text-transform: uppercase; }

/* Accordion */
.rv-acc-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 10px; font-size: .8rem; color: var(--rv-muted); }
.rv-acc-bar .rv-chip { padding: 4px 10px; font-size: .76rem; }
.rv-acc-toggle { width: 32px; height: 32px; flex-shrink: 0; display: grid; place-items: center; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: #475569; transition: transform .25s ease, background .15s; }
.rv-acc-toggle:hover { background: var(--brand-tint); color: var(--brand); }
.rv-acc-toggle i { transition: transform .25s ease; }
.rv-point.is-collapsed .rv-acc-toggle i { transform: rotate(-90deg); }
[dir="rtl"] .rv-point.is-collapsed .rv-acc-toggle i { transform: rotate(90deg); }
.rv-point-head { cursor: pointer; }
.rv-acc-sum { display: none; flex-basis: 100%; align-items: center; gap: 10px; min-width: 0; padding: 2px 0 4px; font-size: .82rem; color: #475569; }
.rv-acc-sum span { white-space: nowrap; color: #94a3b8; }
.rv-acc-sum .rv-acc-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; color: #334155; }
.rv-point.is-collapsed { padding-bottom: 6px; }
.rv-point.is-collapsed .rv-acc-sum { display: flex; }
.rv-point.is-collapsed > :not(.rv-point-head):not(span[hidden]) { display: none !important; }
.rv-point:not(.is-collapsed) > .rv-point-body { animation: rv-slide .28s cubic-bezier(.2, .8, .2, 1) both; }

/* Private note */
.rv-private { margin: 0 16px 10px; padding: 8px 12px; border-radius: 12px; border: 1px dashed #cbd5e1; background: #f8fafc; }
.rv-private > summary { cursor: pointer; font-size: .8rem; font-weight: 700; color: #334155; list-style: none; }
.rv-private > summary::-webkit-details-marker { display: none; }
.rv-private > summary small { font-weight: 500; color: #94a3b8; margin-inline-start: 6px; }
.rv-private[open] { border-style: solid; border-color: #0f172a22; background: #fffdf5; }
.rv-private-form { margin-top: 8px; }
.rv-private-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.rv-private-others { margin-top: 10px; padding-top: 8px; border-top: 1px dashed #e2e8f0; font-size: .8rem; }
.rv-private-other { margin-top: 6px; padding: 6px 10px; border-radius: 10px; background: #fff; border: 1px solid #e2e8f0; }
.rv-private-other p { margin: 4px 0 0; }

/* My account */
.rv-me-modal .modal-content { border-radius: 18px; }
.rv-me-photo { display: flex; align-items: center; gap: 12px; padding: 10px; border: 2px dashed var(--line); border-radius: 14px; cursor: pointer; }
.rv-me-photo:hover { border-color: var(--brand); background: var(--brand-tint); }
.rv-me-photo > span:last-of-type { display: flex; flex-direction: column; }
.rv-me-photo small { color: var(--rv-muted); font-size: .76rem; }
.rv-me-photo .rv-avatar { width: 56px; height: 56px; font-size: 1.3rem; }
.rv-spec-pick.is-small span { padding: 5px 10px; font-size: .78rem; }
.rv-me-section { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.rv-me-section h3 { font-size: .95rem; font-weight: 700; }
.rv-me-section p { font-size: .8rem; color: var(--rv-muted); }
.rv-code { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.rv-code code { padding: 8px 14px; border-radius: 10px; background: #0f172a; color: #fde68a; font-size: 1.05rem; letter-spacing: .14em; }
.rv-devices { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.rv-devices li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; border: 1px solid var(--line); }
.rv-devices li.is-here { border-color: #bbf7d0; background: #f0fdf4; }
.rv-devices li > i { font-size: 1.2rem; color: #475569; }
.rv-devices li > span { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.rv-devices strong { font-size: .82rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rv-devices small { font-size: .72rem; color: var(--rv-muted); }
.rv-conn-code { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 8px 0; font-size: .76rem; }
.rv-conn-code code { padding: 2px 8px; border-radius: 6px; background: #0f172a; color: #fde68a; letter-spacing: .08em; }

@media (max-width: 575.98px) {
    .rv-recover { flex-direction: column; }
    .rv-code-input { max-width: none; flex: 1; }
    .rv-private { margin-left: 12px; margin-right: 12px; }
}
@media (prefers-reduced-motion: reduce) {
    .rv-acc-toggle, .rv-acc-toggle i, .rv-point:not(.is-collapsed) > .rv-point-body { transition: none; animation: none; }
}
