/* RoboLab — public site, auth and dashboard */
:root {
  --rs-ink: #0f1b2d;
  --rs-ink-2: #172a44;
  --rs-accent: #20c3e8;
  --rs-accent-2: #0a8fb0;
  --rs-run: #ff7a1a;
  --rs-run-2: #f05d00;
  --rs-bg: #f2f6fa;
  --rs-line: #dfe6ee;
  --rs-text: #1d2a3a;
  --rs-muted: #66768a;
  --rs-font: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

.rs-body { font-family: var(--rs-font); color: var(--rs-text); background: var(--rs-bg); min-height: 100vh; display: flex; flex-direction: column; }
.rs-main { flex: 1; }
a { color: var(--rs-accent-2); }

/* nav */
.rs-nav { background: linear-gradient(180deg, var(--rs-ink-2), var(--rs-ink)); box-shadow: 0 2px 0 rgba(32, 195, 232, .25); padding: 8px 0; }
.rs-brand { display: flex; align-items: center; gap: 10px; }
.rs-brand span { display: flex; flex-direction: column; line-height: 1.05; }
.rs-brand b { font-weight: 900; font-size: 20px; color: #fff; }
.rs-brand small { font-size: 11px; font-weight: 700; color: #8fb3c9; }
.rs-nav .nav-link { font-weight: 800; color: #cfe3ef; border-radius: 9px; padding: 7px 12px !important; }
.rs-nav .nav-link:hover, .rs-nav .nav-link.active { color: #fff; background: rgba(255, 255, 255, .08); }
.rs-nav .dropdown-menu { border-radius: 12px; border: 0; }
.rs-avatar {
  display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, var(--rs-accent), var(--rs-accent-2)); color: #fff; font-weight: 900; font-size: 13px;
}
.rs-avatar-lg { width: 58px; height: 58px; font-size: 21px; }
.rs-user::after { display: none; }

/* buttons */
.rs-btn-accent { background: var(--rs-accent-2); color: #fff; font-weight: 800; border: 0; border-radius: 11px; }
.rs-btn-accent:hover, .rs-btn-accent:focus { background: #087a97; color: #fff; }
.rs-btn-run {
  background: linear-gradient(180deg, var(--rs-run), var(--rs-run-2)); color: #fff; font-weight: 900; border: 0; border-radius: 12px;
  box-shadow: 0 3px 0 #b84500, 0 8px 20px rgba(255, 122, 26, .3);
}
.rs-btn-run:hover { color: #fff; filter: brightness(1.06); }
.rs-btn-ghost { border: 2px solid rgba(255, 255, 255, .35); color: #fff; font-weight: 800; border-radius: 12px; }
.rs-btn-ghost:hover { background: rgba(255, 255, 255, .1); color: #fff; border-color: #fff; }
.rs-link { font-weight: 800; color: var(--rs-accent-2); text-decoration: none; }
.rs-link:hover { text-decoration: underline; }

/* cards */
.rs-card { background: #fff; border: 1px solid var(--rs-line); border-radius: 16px; box-shadow: 0 6px 20px rgba(15, 27, 45, .05); }
.rs-icon { display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; border-radius: 13px; background: #e6f7fc; color: var(--rs-accent-2); font-size: 22px; }
.rs-icon-lg { width: 64px; height: 64px; font-size: 30px; border-radius: 18px; }

/* hero */
.rs-hero {
  background: radial-gradient(1200px 500px at 85% 0%, rgba(32, 195, 232, .22), transparent 60%), linear-gradient(180deg, var(--rs-ink), #12233b 70%, #152a47);
  color: #eaf5fb; padding: 72px 0 84px; overflow: hidden;
}
.rs-badge { display: inline-flex; align-items: center; gap: 6px; background: rgba(32, 195, 232, .14); color: #8fe7fb; border: 1px solid rgba(32, 195, 232, .35); border-radius: 999px; padding: 5px 13px; font-weight: 800; font-size: 13px; }
.rs-hero-title { font-weight: 900; font-size: clamp(32px, 4.4vw, 52px); line-height: 1.08; margin: 18px 0 16px; letter-spacing: -.5px; }
.rs-hero-text { font-size: 18px; color: #b9cfdd; max-width: 520px; margin-bottom: 28px; }
.rs-hero-stage { position: relative; background: #f3f6f9; border-radius: 18px; box-shadow: 0 30px 80px rgba(0, 0, 0, .45); overflow: hidden; border: 1px solid rgba(255, 255, 255, .12); }
.rs-hero-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: #e6ecf2; border-bottom: 1px solid #d5dde6; }
.rs-hero-bar span { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.rs-hero-bar span:nth-child(2) { background: #febc2e; }
.rs-hero-bar span:nth-child(3) { background: #28c840; }
.rs-hero-bar em { margin-left: 10px; font-style: normal; font-size: 12px; color: #6b7a8c; font-family: ui-monospace, Consolas, monospace; }
.rs-hero-canvas { height: 330px; pointer-events: none; }
.rs-hero-canvas .rl-pin-tip { display: none !important; }
/* the hero preview draws with the lab's editor, but the page doesn't load robolab.css: just the drawing rules */
.rs-hero-canvas { position: relative; overflow: hidden; background: #f3f6f9; }
.rs-hero-canvas .rl-svg { display: block; width: 100%; height: 100%; }
.rs-hero-canvas .rl-grid-dot { fill: #c6d0db; }
.rs-hero-canvas .rl-part-breadboard, .rs-hero-canvas .rl-part-uno { filter: drop-shadow(0 3px 4px rgba(15, 27, 45, .14)); }
.rs-hero-canvas .rl-wire .w-hit { stroke: transparent; fill: none; }
.rs-hero-canvas .rl-wire .w-out { stroke-width: 3.4; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.rs-hero-canvas .rl-wire .w-main { stroke-width: 2.2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.rs-hero-canvas .rl-selbox, .rs-hero-canvas .rl-overlay { display: none; }
.rs-hero .rs-badge { background: rgba(32, 195, 232, .14); color: #8fe7fb; border: 1px solid rgba(32, 195, 232, .35); padding: 5px 13px; font-size: 13px; gap: 6px; }
.rs-hero-code { position: absolute; right: 16px; bottom: 16px; margin: 0; background: rgba(20, 22, 26, .92); color: #e3e6ea; border-radius: 12px; padding: 12px 16px; font-size: 12.5px; line-height: 1.55; box-shadow: 0 10px 30px rgba(0, 0, 0, .3); }
.rs-hero-code .k { color: #c792ea; }
.rs-hero-code .n { color: #f78c6c; }

/* sections */
.rs-section { padding: 72px 0; }
.rs-section-alt { background: #fff; border-top: 1px solid var(--rs-line); border-bottom: 1px solid var(--rs-line); }
.rs-h2 { font-weight: 900; font-size: clamp(24px, 3vw, 34px); margin-bottom: 28px; letter-spacing: -.3px; }
.rs-h3 { font-weight: 900; font-size: 20px; margin-bottom: 14px; }
.rs-feature { padding: 24px; height: 100%; }
.rs-feature h3 { font-size: 18px; font-weight: 900; margin: 14px 0 6px; }
.rs-feature p { color: var(--rs-muted); margin: 0; }
.rs-age { padding: 26px; height: 100%; position: relative; overflow: hidden; }
.rs-age h3 { font-weight: 900; font-size: 20px; }
.rs-age p { color: var(--rs-muted); margin: 0; }
.rs-age-tag { position: absolute; right: 18px; top: 14px; font-weight: 900; font-size: 34px; opacity: .2; }
.rs-age-1 { border-top: 5px solid #22c55e; }
.rs-age-2 { border-top: 5px solid #f2a900; }
.rs-age-3 { border-top: 5px solid #e5484d; }
.rs-example { display: flex; flex-direction: column; gap: 6px; padding: 18px; text-decoration: none; color: var(--rs-text); height: 100%; transition: transform .12s, border-color .12s, box-shadow .12s; }
.rs-example > .bi { font-size: 26px; color: var(--rs-accent-2); }
.rs-example span { font-weight: 900; }
.rs-example em { font-style: normal; font-size: 13px; font-weight: 800; color: var(--rs-run-2); margin-top: auto; }
.rs-example:hover { transform: translateY(-2px); border-color: var(--rs-accent); box-shadow: 0 10px 26px rgba(15, 27, 45, .1); color: var(--rs-text); }
.rs-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; padding: 34px; background: linear-gradient(120deg, #e6f7fc, #fff 60%); }
.rs-cta h2 { font-weight: 900; font-size: 26px; }
.rs-cta p { color: var(--rs-muted); margin: 0; max-width: 620px; }
.rs-teachers { padding-top: 0; }

/* auth */
.rs-auth-page .rs-main { background: radial-gradient(900px 400px at 50% -10%, rgba(32, 195, 232, .16), transparent 70%); }
.rs-auth { display: flex; justify-content: center; padding: 48px 16px 64px; }
.rs-auth-card { width: 100%; max-width: 460px; padding: 34px 32px 28px; }
.rs-auth-head { text-align: center; margin-bottom: 24px; }
.rs-auth-head h1 { font-weight: 900; font-size: 26px; margin: 14px 0 6px; }
.rs-auth-head p { color: var(--rs-muted); margin: 0; }
.rs-auth .form-label { font-weight: 800; font-size: 14px; }
.rs-auth .form-control { border-radius: 11px; font-size: 16px; }
.rs-auth .form-control:focus { border-color: var(--rs-accent); box-shadow: 0 0 0 4px rgba(32, 195, 232, .18); }
.rs-auth-foot { text-align: center; margin-top: 22px; color: var(--rs-muted); }
.rs-roles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rs-role { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 12px; border: 2px solid var(--rs-line); border-radius: 12px; font-weight: 800; cursor: pointer; transition: border-color .12s, background .12s; }
.rs-role .bi { font-size: 20px; color: var(--rs-accent-2); }
.btn-check:checked + .rs-role { border-color: var(--rs-accent-2); background: #e6f7fc; }
.btn-check:focus-visible + .rs-role { box-shadow: 0 0 0 4px rgba(32, 195, 232, .25); }
.rs-note { display: flex; gap: 8px; background: #fff8e6; color: #7a4b00; border-radius: 11px; padding: 10px 12px; font-size: 13.5px; font-weight: 600; }

/* dashboard */
.rs-dash { padding: 36px 12px 64px; }
.rs-dash-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 28px; }
.rs-dash-head h1 { font-weight: 900; font-size: 28px; margin: 0 0 2px; }
.rs-role-pill { display: inline-block; background: #e6f7fc; color: var(--rs-accent-2); font-weight: 800; font-size: 12px; border-radius: 999px; padding: 2px 10px; margin-right: 6px; }
.rs-project { display: flex; flex-direction: column; height: 100%; overflow: hidden; }
.rs-project-thumb {
  display: flex; align-items: center; justify-content: center; height: 120px; color: #fff; font-size: 44px; text-decoration: none;
  background: linear-gradient(135deg, #17607e, #0f4a62); position: relative;
}
.rs-project-thumb::after { content: ''; position: absolute; inset: 0; background-image: radial-gradient(rgba(255, 255, 255, .18) 1px, transparent 1px); background-size: 10px 10px; }
.rs-project-body { padding: 14px 16px 6px; flex: 1; }
.rs-project-body h3 { font-weight: 900; font-size: 17px; margin: 0 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rs-project-body p { margin: 0; color: var(--rs-muted); font-size: 14px; }
.rs-project-body small { color: #95a3b3; }
.rs-project-actions { display: flex; gap: 8px; padding: 10px 16px 16px; }
.rs-project-actions form { margin-left: auto; }
.rs-empty-state { text-align: center; padding: 48px 24px; }
.rs-empty-state h2 { font-weight: 900; font-size: 22px; margin: 16px 0 6px; }
.rs-empty-state p { color: var(--rs-muted); }

/* alerts & footer */
.rs-flash { padding-top: 18px; }
.rs-alert { border-radius: 12px; font-weight: 700; border: 0; }
.rs-alert-ok { background: #e7f8ee; color: #146c3b; }
.rs-footer { padding: 22px 0; color: var(--rs-muted); font-size: 14px; border-top: 1px solid var(--rs-line); background: #fff; }
.rs-footer-langs a { color: var(--rs-muted); text-decoration: none; margin-left: 12px; font-weight: 700; }
.rs-footer-langs a:hover { color: var(--rs-accent-2); }

@media (max-width: 991px) {
  .rs-hero { padding: 44px 0 56px; }
  .rs-hero-canvas { height: 240px; }
  .rs-hero-code { display: none; }
  .rs-section { padding: 48px 0; }
}

/* ---------------- platform pages ---------------- */
.rs-page-head { background: linear-gradient(180deg, var(--rs-ink), #152a47); color: #eaf5fb; padding: 46px 0 52px; }
.rs-page-head h1 { font-weight: 900; font-size: clamp(28px, 3.6vw, 40px); }
.rs-page-head p { color: #b9cfdd; font-size: 17px; margin: 0 auto; max-width: 680px; }
.rs-page-title { font-weight: 900; font-size: 28px; margin-bottom: 18px; }
.rs-back { font-weight: 800; font-size: 14px; color: var(--rs-accent-2); text-decoration: none; }
.rs-page-head .rs-back { color: #8fe7fb; }
.rs-access-pill { display: inline-flex; gap: 6px; align-items: center; margin-top: 16px; background: rgba(34, 197, 94, .16); color: #b9f6ca; border-radius: 999px; padding: 6px 14px; font-weight: 800; }
.rs-box { padding: 20px 22px; }
.rs-box-title { font-weight: 900; font-size: 17px; margin-bottom: 12px; }
.rs-dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0 0 14px; }
.rs-dl dt { font-weight: 700; color: var(--rs-muted); font-size: 14px; }
.rs-dl dd { margin: 0; font-weight: 700; }
.rs-table { --bs-table-bg: transparent; font-size: 14.5px; }
.rs-table th { font-size: 12px; text-transform: uppercase; letter-spacing: .5px; color: var(--rs-muted); font-weight: 800; border-bottom-width: 1px; }
.rs-box.p-0 .rs-table th, .rs-box.p-0 .rs-table td { padding-left: 18px; padding-right: 18px; }
.rs-status { display: inline-block; font-size: 12px; font-weight: 800; border-radius: 999px; padding: 2px 10px; background: #eef2f7; color: #51637a; }
.rs-status-active, .rs-status-paid, .rs-status-trialing { background: #e3f9e9; color: #18794e; }
.rs-status-past_due, .rs-status-pending, .rs-status-incomplete { background: #fff4d6; color: #9a6200; }
.rs-status-canceled, .rs-status-failed, .rs-status-unpaid, .rs-status-refunded, .rs-status-incomplete_expired { background: #fde6ea; color: #b4233c; }
.rs-alert-err { background: #fdecee; color: #8b1d1d; }
.rs-note-err { background: #fdecee; color: #8b1d1d; }
.rs-icon-ok { background: #e3f9e9; color: #18794e; }
.rs-mono { font-family: ui-monospace, 'JetBrains Mono', Consolas, monospace; font-size: 13px; }
.rs-chip { display: inline-flex; align-items: center; gap: 5px; background: #eef6fb; color: var(--rs-accent-2); border-radius: 999px; padding: 4px 11px; font-size: 13px; font-weight: 800; margin: 0 6px 6px 0; }

/* access card */
.rs-access { display: flex; gap: 16px; align-items: flex-start; padding: 22px; height: 100%; }
.rs-access-icon { flex: 0 0 52px; height: 52px; border-radius: 15px; display: flex; align-items: center; justify-content: center; font-size: 26px; }
.rs-access.is-premium { background: linear-gradient(120deg, #e7f8ee, #fff 70%); border-color: #bfe9cf; }
.rs-access.is-premium .rs-access-icon { background: #22c55e; color: #fff; }
.rs-access.is-free .rs-access-icon { background: #fff1e2; color: var(--rs-run-2); }
.rs-access-label { font-size: 12px; font-weight: 900; text-transform: uppercase; letter-spacing: .6px; color: var(--rs-muted); }
.rs-access h3 { font-weight: 900; font-size: 21px; margin: 2px 0 4px; }
.rs-access p { color: var(--rs-muted); margin-bottom: 10px; }
.rs-code-input { font-family: ui-monospace, Consolas, monospace; text-transform: uppercase; letter-spacing: 1.5px; font-weight: 700; }

/* pricing */
.rs-pricing { padding-top: 26px; }
.rs-plan { position: relative; padding: 26px 24px; height: 100%; display: flex; flex-direction: column; }
.rs-plan h3 { font-weight: 900; font-size: 20px; }
.rs-plan-hl { border: 2px solid var(--rs-run); box-shadow: 0 14px 40px rgba(255, 122, 26, .18); }
.rs-plan-tag { position: absolute; top: -12px; right: 18px; background: var(--rs-run); color: #fff; font-size: 12px; font-weight: 900; border-radius: 999px; padding: 3px 12px; }
.rs-plan-price { font-weight: 900; font-size: 34px; letter-spacing: -.5px; }
.rs-plan-price small { font-size: 15px; font-weight: 700; color: var(--rs-muted); letter-spacing: 0; }
.rs-plan-monthly { font-size: 13.5px; font-weight: 800; color: #18794e; }
.rs-plan-desc { color: var(--rs-muted); margin: 10px 0; }
.rs-plan-list { list-style: none; padding: 0; margin: 0 0 18px; flex: 1; }
.rs-plan-list li { display: flex; gap: 8px; padding: 4px 0; font-weight: 600; font-size: 14.5px; }
.rs-plan-list .bi { color: #22c55e; }
.rs-side-card { display: flex; gap: 14px; padding: 22px; }
.rs-side-card h3 { font-weight: 900; font-size: 18px; }
.rs-side-card p { color: var(--rs-muted); margin-bottom: 6px; }

/* courses */
.rs-courses, .rs-lessons { padding-top: 30px; padding-bottom: 60px; }
.rs-course { --c: #0a8fb0; display: flex; flex-direction: column; gap: 8px; padding: 22px; height: 100%; text-decoration: none; color: var(--rs-text); border-top: 5px solid var(--c); transition: transform .12s, box-shadow .12s; }
.rs-course:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(15, 27, 45, .1); color: var(--rs-text); }
.rs-course h3 { font-weight: 900; font-size: 20px; margin: 4px 0 0; }
.rs-course p { color: var(--rs-muted); margin: 0; flex: 1; }
.rs-course-sm { padding: 16px; gap: 10px; }
.rs-course-top { display: flex; justify-content: space-between; align-items: center; }
.rs-course-icon { width: 44px; height: 44px; border-radius: 13px; display: inline-flex; align-items: center; justify-content: center; background: color-mix(in srgb, var(--c) 15%, #fff); color: var(--c); font-size: 22px; }
.rs-course-icon-lg { width: 64px; height: 64px; font-size: 32px; border-radius: 18px; background: rgba(255, 255, 255, .12); color: #fff; }
.rs-course-foot { display: flex; justify-content: space-between; font-size: 13.5px; font-weight: 800; color: var(--rs-muted); }
.rs-level { display: inline-block; font-size: 12px; font-weight: 900; border-radius: 999px; padding: 3px 10px; background: #eef2f7; color: #51637a; }
.rs-level-1 { background: #e3f9e9; color: #18794e; }
.rs-level-2 { background: #fff4d6; color: #9a6200; }
.rs-level-3 { background: #fde6ea; color: #b4233c; }
.rs-progress { height: 8px; background: #eef2f7; border-radius: 999px; overflow: hidden; }
.rs-progress span { display: block; height: 100%; background: linear-gradient(90deg, #22c55e, #20c3e8); border-radius: 999px; }
.rs-progress-sm { height: 5px; margin-top: 4px; }
.rs-course-head h1 { font-size: 32px; }
.rs-lesson-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; max-width: 860px; }
.rs-lesson { display: flex; align-items: center; gap: 16px; padding: 16px 18px; }
.rs-lesson h3 { font-weight: 900; font-size: 17px; margin: 0; }
.rs-lesson small { color: var(--rs-muted); }
.rs-lesson-n { flex: 0 0 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-weight: 900; background: #eef6fb; color: var(--rs-accent-2); }
.rs-lesson.done .rs-lesson-n { background: #22c55e; color: #fff; }
.rs-lesson.locked { opacity: .8; }
.rs-lesson.locked .rs-lesson-n { background: #eef2f7; color: #9aa6b4; }
.rs-free-tag { display: inline-block; background: #e3f9e9; color: #18794e; border-radius: 999px; padding: 0 8px; font-size: 11.5px; font-weight: 900; }

/* teacher */
.rs-class-row { display: flex; align-items: center; gap: 14px; padding: 14px 18px; margin-bottom: 10px; text-decoration: none; color: var(--rs-text); }
.rs-class-row:hover { border-color: var(--rs-accent); color: var(--rs-text); }
.rs-join-code { font-family: ui-monospace, Consolas, monospace; background: #0f1b2d; color: #7df3ff; border-radius: 7px; padding: 3px 9px; font-size: 13px; letter-spacing: 1px; }
.rs-big-code { font-family: ui-monospace, Consolas, monospace; font-weight: 800; font-size: 30px; letter-spacing: 3px; background: #0f1b2d; color: #7df3ff; border-radius: 14px; padding: 14px; margin: 10px 0; }

/* admin */
.rs-admin { padding: 0; }
.rs-admin-side { background: #fff; border-right: 1px solid var(--rs-line); min-height: calc(100vh - 120px); padding: 18px 12px; }
.rs-admin-brand { font-weight: 900; padding: 4px 12px 14px; color: var(--rs-ink); }
.rs-admin-side .nav-link { color: #3c4c60; font-weight: 800; border-radius: 10px; padding: 9px 12px; display: flex; gap: 9px; align-items: center; }
.rs-admin-side .nav-link:hover { background: #f1f6fa; }
.rs-admin-side .nav-link.active { background: #e6f7fc; color: var(--rs-accent-2); }
.rs-admin-main { padding: 26px 28px 60px; min-width: 0; }
.rs-stat { display: flex; gap: 14px; align-items: center; padding: 16px 18px; }
.rs-stat > .bi { font-size: 24px; color: var(--rs-accent-2); background: #e6f7fc; width: 46px; height: 46px; border-radius: 13px; display: flex; align-items: center; justify-content: center; }
.rs-stat span { display: block; font-size: 12.5px; font-weight: 800; color: var(--rs-muted); }
.rs-stat strong { font-size: 22px; font-weight: 900; }
@media (max-width: 991px) {
  .rs-admin-side { min-height: 0; border-right: 0; border-bottom: 1px solid var(--rs-line); }
  .rs-admin-side .nav { flex-direction: row !important; flex-wrap: wrap; }
  .rs-admin-main { padding: 20px 14px 50px; }
}

/* ============================================================
   Theme: replaces Bootstrap's default blue with RoboLab colours
   ============================================================ */
.rs-body {
  --bs-primary: #0a8fb0; --bs-primary-rgb: 10, 143, 176;
  --bs-link-color: #0a8fb0; --bs-link-color-rgb: 10, 143, 176;
  --bs-link-hover-color: #087a97; --bs-link-hover-color-rgb: 8, 122, 151;
  --bs-focus-ring-color: rgba(32, 195, 232, .28);
  --bs-border-radius: 10px;
}
.rs-body .form-control:focus, .rs-body .form-select:focus {
  border-color: var(--rs-accent); box-shadow: 0 0 0 .25rem rgba(32, 195, 232, .2);
}
.rs-body .form-check-input:checked { background-color: var(--rs-accent-2); border-color: var(--rs-accent-2); }
.rs-body .form-check-input:focus { border-color: var(--rs-accent); box-shadow: 0 0 0 .25rem rgba(32, 195, 232, .2); }
.rs-body .form-switch .form-check-input:focus:not(:checked) {
  --bs-form-switch-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%2320c3e8'/%3e%3c/svg%3e");
}
.rs-body .form-range::-webkit-slider-thumb { background: var(--rs-accent-2); }
.rs-body .form-range::-moz-range-thumb { background: var(--rs-accent-2); }
.rs-body .btn-primary { --bs-btn-bg: #0a8fb0; --bs-btn-border-color: #0a8fb0; --bs-btn-hover-bg: #087a97; --bs-btn-hover-border-color: #087a97; --bs-btn-active-bg: #076a83; --bs-btn-active-border-color: #076a83; font-weight: 800; }
.rs-body .btn-outline-secondary { --bs-btn-color: #3c4c60; --bs-btn-border-color: #cdd7e2; --bs-btn-hover-bg: #eef4f9; --bs-btn-hover-color: #1d2a3a; --bs-btn-hover-border-color: #b9c6d4; --bs-btn-active-bg: #e3edf5; --bs-btn-active-color: #1d2a3a; font-weight: 700; }
.rs-body .btn:focus-visible { box-shadow: 0 0 0 .25rem rgba(32, 195, 232, .3); }
.rs-body .pagination { --bs-pagination-color: #0a8fb0; --bs-pagination-hover-color: #087a97; --bs-pagination-focus-color: #087a97; --bs-pagination-focus-box-shadow: 0 0 0 .25rem rgba(32, 195, 232, .2); --bs-pagination-active-bg: #0a8fb0; --bs-pagination-active-border-color: #0a8fb0; --bs-pagination-border-radius: 10px; }
.rs-body .nav-pills { --bs-nav-pills-link-active-bg: #e6f7fc; --bs-nav-pills-link-active-color: #0a8fb0; }
.rs-body .nav-pills .nav-link { font-weight: 800; }
.rs-body .nav-tabs .nav-link.active { color: var(--rs-accent-2); font-weight: 800; }
.rs-body .btn-link { --bs-btn-color: #0a8fb0; --bs-btn-hover-color: #087a97; }
.rs-body .text-primary { color: var(--rs-accent-2) !important; }
.rs-body .bg-primary { background-color: var(--rs-accent-2) !important; }
.rs-body ::selection { background: rgba(32, 195, 232, .28); }

/* dropdowns: light card even inside the dark navbar */
.rs-body .dropdown-menu {
  color-scheme: light;
  --bs-dropdown-bg: #fff;
  --bs-dropdown-color: #1d2a3a;
  --bs-dropdown-border-color: #e3eaf1;
  --bs-dropdown-border-radius: 14px;
  --bs-dropdown-inner-border-radius: 10px;
  --bs-dropdown-padding-x: 6px;
  --bs-dropdown-padding-y: 6px;
  --bs-dropdown-spacer: 8px;
  --bs-dropdown-divider-bg: #edf1f5;
  --bs-dropdown-divider-margin-y: 6px;
  --bs-dropdown-link-color: #2a3a4e;
  --bs-dropdown-link-hover-color: #0f1b2d;
  --bs-dropdown-link-hover-bg: #eef7fb;
  --bs-dropdown-link-active-color: #0a7a97;
  --bs-dropdown-link-active-bg: #e0f4fa;
  --bs-dropdown-item-padding-x: 12px;
  --bs-dropdown-item-padding-y: 8px;
  --bs-dropdown-item-border-radius: 9px;
  --bs-dropdown-header-color: #8a98a8;
  --bs-dropdown-box-shadow: 0 14px 38px rgba(15, 27, 45, .16), 0 2px 6px rgba(15, 27, 45, .06);
  border: 1px solid var(--bs-dropdown-border-color);
  box-shadow: var(--bs-dropdown-box-shadow);
  min-width: 13rem;
  animation: rs-menu-in .14s ease-out;
}
@keyframes rs-menu-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.rs-body .dropdown-item { font-weight: 700; font-size: 14.5px; display: flex; align-items: center; gap: 10px; border-radius: var(--bs-dropdown-item-border-radius); transition: background .12s, color .12s; }
.rs-body .dropdown-item .bi { font-size: 16px; color: #7b8b9e; width: 18px; text-align: center; margin: 0; transition: color .12s; }
.rs-body .dropdown-item:hover .bi, .rs-body .dropdown-item:focus .bi { color: var(--rs-accent-2); }
.rs-body .dropdown-item.active, .rs-body .dropdown-item:active { font-weight: 800; }
.rs-body .dropdown-item.active .bi, .rs-body .dropdown-item:active .bi { color: var(--rs-accent-2); }
.rs-body .dropdown-item:focus-visible { outline: 2px solid rgba(32, 195, 232, .5); outline-offset: -2px; }
.rs-body .dropdown-item.disabled, .rs-body .dropdown-item:disabled { color: #a8b4c1; }
.rs-nav .dropdown-toggle::after { vertical-align: .18em; border-top-width: .32em; border-left-width: .32em; border-right-width: .32em; opacity: .7; }
.rs-nav .nav-link.show { color: #fff; background: rgba(255, 255, 255, .1); }

.rs-menu-head { display: flex; align-items: center; gap: 11px; padding: 8px 10px 10px; margin-bottom: 4px; border-bottom: 1px solid #edf1f5; }
.rs-menu-head div { min-width: 0; line-height: 1.2; }
.rs-menu-head strong { display: block; font-weight: 900; color: var(--rs-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 170px; }
.rs-menu-head small { display: block; color: var(--rs-muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 170px; }
.rs-user-menu { min-width: 15.5rem; }
.rs-body .dropdown-item.rs-item-danger { color: #c0283f; }
.rs-body .dropdown-item.rs-item-danger .bi { color: #d9475d; }
.rs-body .dropdown-item.rs-item-danger:hover, .rs-body .dropdown-item.rs-item-danger:focus { background: #fdecee; color: #a51d33; }
.rs-lang-code {
  display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 22px; padding: 0 6px;
  border-radius: 6px; background: #eef2f7; color: #51637a; font-size: 11.5px; font-weight: 900; letter-spacing: .5px;
}
.rs-body .dropdown-item.active .rs-lang-code { background: var(--rs-accent-2); color: #fff; }
.rs-body .dropdown-item .rs-check { margin-left: auto; color: var(--rs-accent-2); }
.rs-user { display: flex !important; align-items: center; gap: 8px; }

/* avatars */
.rs-avatar-img { object-fit: cover; padding: 0; background: #e6eef5; box-shadow: 0 0 0 2px rgba(255, 255, 255, .9); }
.rs-nav .rs-avatar { box-shadow: 0 0 0 2px rgba(32, 195, 232, .45); }

/* ============================================================
   Profile
   ============================================================ */
.rs-side-nav { padding: 8px; gap: 2px; }
.rs-side-nav .nav-link {
  display: flex; align-items: center; gap: 10px; text-align: left; width: 100%; border: 0; background: none;
  color: #3c4c60; font-weight: 800; border-radius: 10px; padding: 10px 12px;
}
.rs-side-nav .nav-link .bi { font-size: 17px; color: #8a98a8; }
.rs-side-nav .nav-link:hover { background: #f1f6fa; color: var(--rs-ink); }
.rs-side-nav .nav-link.active { background: #e6f7fc; color: var(--rs-accent-2); }
.rs-side-nav .nav-link.active .bi { color: var(--rs-accent-2); }
.rs-dot-ok { width: 9px; height: 9px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, .18); flex: none; }

.rs-avatar-edit { display: flex; align-items: center; gap: 20px; padding: 16px; border-radius: 14px; background: #f6f9fc; border: 1px dashed #d3dde8; }
.rs-avatar-preview { flex: none; width: 96px; height: 96px; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 18px rgba(15, 27, 45, .14); }
.rs-avatar-preview .rs-avatar { box-shadow: 0 0 0 4px #fff; }
.rs-avatar-edit label.btn { cursor: pointer; }
.rs-readonly { background: #f3f6f9; color: #51637a; font-weight: 700; cursor: default; }

.rs-codes-box { background: #fffaf0; border: 1px solid #f7deb0; border-radius: 14px; padding: 16px 18px; }
.rs-codes-box strong { color: #8a5300; }
.rs-codes { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
.rs-codes code { display: block; text-align: center; background: #fff; border: 1px solid #f1e1c2; border-radius: 8px; padding: 6px 8px; color: var(--rs-ink); font-size: 14px; font-weight: 700; letter-spacing: .5px; }
.rs-sub-form { background: #f6f9fc; border: 1px solid var(--rs-line); border-radius: 12px; padding: 14px; height: 100%; }

.rs-tf-setup { display: flex; gap: 24px; align-items: flex-start; padding: 18px; border-radius: 14px; background: #f6f9fc; border: 1px solid var(--rs-line); }
.rs-qr { flex: none; width: 208px; height: 208px; padding: 12px; background: #fff; border-radius: 14px; box-shadow: 0 6px 20px rgba(15, 27, 45, .1); }
.rs-qr img, .rs-qr canvas { display: block; width: 184px !important; height: 184px !important; }
.rs-steps { padding-left: 0; list-style: none; counter-reset: s; margin-bottom: 16px; }
.rs-steps li { counter-increment: s; position: relative; padding-left: 38px; margin-bottom: 12px; font-weight: 700; color: #33445a; }
.rs-steps li::before {
  content: counter(s); position: absolute; left: 0; top: -1px; width: 26px; height: 26px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; background: var(--rs-accent-2); color: #fff; font-weight: 900; font-size: 13px;
}
.rs-secret { margin-top: 6px; display: inline-flex; align-items: center; background: #fff; border: 1px solid var(--rs-line); border-radius: 8px; padding: 4px 10px; }
.rs-secret code { color: var(--rs-ink); font-size: 14px; font-weight: 700; letter-spacing: 1px; word-break: break-all; }
.rs-otp { font-family: ui-monospace, 'JetBrains Mono', Consolas, monospace; font-weight: 800; letter-spacing: 6px; font-size: 22px !important; }
.rs-otp::placeholder { letter-spacing: 4px; color: #b9c4d0; }
.rs-mail-card { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
@media (max-width: 767.98px) {
  .rs-tf-setup { flex-direction: column; align-items: center; }
  .rs-avatar-edit { flex-direction: column; text-align: center; }
}

/* ---------------- teacher: tabs, activities, AI generator, editor, assignments ---------------- */
.rs-tabs { gap: 6px; border-bottom: 1px solid var(--rs-line); }
.rs-tabs .nav-link { font-weight: 800; color: var(--rs-muted); border-radius: 10px 10px 0 0; padding: 9px 16px; border-bottom: 3px solid transparent; }
.rs-tabs .nav-link.active { color: var(--rs-accent-2); border-bottom-color: var(--rs-accent-2); }
.rs-ai-card { padding: 22px; background: linear-gradient(135deg, #fff 0%, #f0fbff 100%); border-color: #bfe9f6; }
.rs-ai-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 14px; }
.rs-ai-head h2 { font-size: 20px; font-weight: 900; margin: 0 0 4px; }
.rs-ai-head p { margin: 0; color: var(--rs-muted); }
.rs-ai-badge { flex: 0 0 48px; height: 48px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; font-size: 24px; color: #fff; background: linear-gradient(135deg, #8e44ff, var(--rs-accent)); }
.rs-ai-prompt { border-radius: 12px; font-size: 15px; }
.rs-ai-ideas { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; font-size: 13px; color: var(--rs-muted); }
.rs-idea { border: 1px solid var(--rs-line); background: #fff; cursor: pointer; font-size: 12.5px; }
.rs-idea:hover { border-color: var(--rs-accent); color: var(--rs-accent-2); }
.rs-ai-parts summary { font-weight: 800; font-size: 13px; color: var(--rs-accent-2); cursor: pointer; }
.rs-part-chips, .rs-assign-classes { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.rs-chip-check input { display: none; }
.rs-chip-check span { display: inline-block; padding: 5px 11px; border-radius: 99px; border: 1px solid var(--rs-line); background: #fff; font-size: 13px; font-weight: 700; cursor: pointer; user-select: none; }
.rs-chip-check input:checked + span { background: var(--rs-accent-2); border-color: var(--rs-accent-2); color: #fff; }
.rs-ai-progress { display: flex; gap: 16px; align-items: center; padding: 18px; border-radius: 14px; background: #fff; border: 1px dashed #9fdcef; }
.rs-ai-robot { font-size: 34px; color: var(--rs-accent-2); animation: rs-bob 1.2s ease-in-out infinite; }
@keyframes rs-bob { 50% { transform: translateY(-5px) rotate(-4deg); } }
.rs-spin-slow { display: inline-block; animation: rs-spin 3s linear infinite; }
@keyframes rs-spin { to { transform: rotate(360deg); } }
.rs-act-row { display: flex; align-items: center; gap: 14px; padding: 14px 16px; margin-bottom: 10px; }
.rs-act-row .min-w-0, .min-w-0 { min-width: 0; }
.rs-act-title { font-weight: 900; color: var(--rs-text); text-decoration: none; font-size: 16px; }
.rs-act-title:hover { color: var(--rs-accent-2); }
.rs-act-actions { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.rs-act-actions form { margin: 0; }
.rs-badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 99px; font-size: 11.5px; font-weight: 800; background: #eef2f6; color: var(--rs-muted); }
.rs-badge-generating { background: #efe6ff; color: #6a2fd1; }
.rs-badge-failed { background: #ffe8ea; color: #c0263a; }
.rs-badge-draft { background: #fff4dc; color: #a46a00; }
.rs-badge-ready, .rs-badge-ok { background: #e2f7ea; color: #1e8a4c; }
.rs-st-new { background: #eef2f6; } .rs-st-started { background: #e6f4fb; color: #0a7898; } .rs-st-submitted { background: #fff4dc; color: #a46a00; } .rs-st-completed { background: #e2f7ea; color: #1e8a4c; }

.rs-editor .rs-ed-head { display: flex; gap: 12px; align-items: center; margin: 10px 0 16px; flex-wrap: wrap; }
.rs-ed-title { flex: 1 1 320px; font-size: 24px; font-weight: 900; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: transparent; padding: 4px 2px; }
.rs-ed-title:focus { box-shadow: none; border-bottom-color: var(--rs-accent); background: transparent; }
.rs-ed-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.rs-ed-status { width: auto; font-weight: 800; }
.rs-save-state { font-size: 13px; font-weight: 700; color: var(--rs-muted); }
.rs-save-ok { color: #1e8a4c; } .rs-save-err { color: #c0263a; }
.rs-validation { padding: 14px 18px; margin-bottom: 18px; border-left: 5px solid #c6d0db; }
.rs-v-good { border-left-color: #22c55e; } .rs-v-bad { border-left-color: #e5484d; }
.rs-v-head { display: flex; gap: 14px; align-items: flex-start; flex-wrap: wrap; }
.rs-v-icon { font-size: 26px; color: #9aa8b6; } .rs-v-good .rs-v-icon { color: #22c55e; } .rs-v-bad .rs-v-icon { color: #e5484d; }
.rs-v-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.rs-v-list { margin: 8px 0 0; padding-left: 20px; font-size: 13.5px; }
.rs-v-err li { color: #b4233c; }
.rs-v-warn summary { font-size: 13px; font-weight: 800; color: #a46a00; cursor: pointer; margin-top: 6px; }
.rs-md, .rs-code { font-size: 13.5px; }
.rs-code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: #0f1b2d; color: #e7f1f8; border-color: #0f1b2d; tab-size: 2; }
.rs-code:focus { background: #13233a; color: #fff; }
.rs-code:disabled { background: #22324a; color: #cfe3ef; }
.rs-md-preview { border: 1px solid var(--rs-line); border-radius: 10px; padding: 14px 16px; min-height: 200px; background: #fbfdfe; }
.rs-md-preview h1, .rs-md-preview h2, .rs-md-preview h3 { font-size: 18px; font-weight: 900; margin-top: 12px; }
.rs-ed-row { display: flex; gap: 8px; align-items: center; margin-bottom: 6px; }
.rs-ed-num { flex: 0 0 24px; height: 24px; border-radius: 50%; background: #e6f7fc; color: var(--rs-accent-2); font-weight: 900; font-size: 12px; display: inline-flex; align-items: center; justify-content: center; }
.rs-ed-opt { padding-left: 32px; }
.rs-quiz-ed { border: 1px solid var(--rs-line); border-radius: 12px; padding: 10px; margin-bottom: 10px; }
.rs-ed-rub input:first-child { flex: 0 0 38%; }
.rs-ed-sub { border: 1px solid var(--rs-line); border-radius: 12px; padding: 12px; }
.rs-radio-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.rs-radio-cards input { display: none; }
.rs-radio-cards span { display: block; border: 1px solid var(--rs-line); border-radius: 10px; padding: 7px 9px; cursor: pointer; height: 100%; }
.rs-radio-cards b { display: block; font-size: 13px; } .rs-radio-cards small { color: var(--rs-muted); font-size: 11.5px; line-height: 1.2; display: block; }
.rs-radio-cards input:checked + span { border-color: var(--rs-accent-2); background: #e9f8fd; box-shadow: inset 0 0 0 1px var(--rs-accent-2); }
.rs-radio-cards input:disabled + span { opacity: .45; cursor: not-allowed; }
.rs-ck-ed { border: 1px solid var(--rs-line); border-radius: 12px; padding: 8px 10px; margin-bottom: 8px; background: #fbfdfe; }
.rs-ck-head { display: flex; align-items: center; gap: 8px; font-size: 13.5px; }
.rs-ck-head .btn-link { padding: 0 4px; }
.rs-ck-params { display: flex; flex-wrap: wrap; gap: 8px; }
.rs-ck-param { font-size: 12px; font-weight: 700; color: var(--rs-muted); display: flex; align-items: center; gap: 4px; }
.rs-ck-param input[type=number] { width: 80px; }
.rs-ck-wide { flex: 1 1 100%; flex-direction: column; align-items: stretch; }

.rs-task { display: block; padding: 14px 16px; text-decoration: none; color: var(--rs-text); height: 100%; border-left: 5px solid #c6d0db; transition: transform .12s, box-shadow .12s; }
.rs-task:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(15, 27, 45, .09); color: var(--rs-text); }
.rs-task-started { border-left-color: var(--rs-accent); } .rs-task-submitted { border-left-color: #f2a900; } .rs-task-completed { border-left-color: #22c55e; } .rs-task-late { border-left-color: #e5484d; }
.rs-task-top { display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; font-weight: 800; color: var(--rs-muted); }
.rs-task-title { display: block; font-size: 16px; font-weight: 900; margin: 6px 0 2px; }
.rs-task-foot { display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; color: var(--rs-muted); margin-top: 10px; }
.rs-task-go { font-weight: 900; color: var(--rs-accent-2); }
.rs-task-grade { background: #fff4dc; color: #a46a00; border-radius: 99px; padding: 1px 8px; }
.rs-task-grade.rs-new { background: var(--rs-run); color: #fff; }
.rs-task-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; text-decoration: none; color: var(--rs-text); border: 1px solid var(--rs-line); margin-bottom: 8px; }
.rs-task-row:hover { border-color: var(--rs-accent); color: var(--rs-text); }
.rs-task-row > .bi:first-child { font-size: 20px; color: var(--rs-accent-2); }
.rs-task-count { font-size: 12.5px; font-weight: 800; color: var(--rs-muted); white-space: nowrap; }
.rs-stat { padding: 14px 16px; text-align: center; }
.rs-stat b { display: block; font-size: 26px; font-weight: 900; color: var(--rs-accent-2); }
.rs-stat span { font-size: 12.5px; color: var(--rs-muted); font-weight: 700; }
.rs-ck-dots { display: flex; gap: 3px; flex-wrap: wrap; max-width: 160px; }
.rs-ck-dots span { width: 12px; height: 12px; border-radius: 3px; background: #e3e9ef; }
.rs-ck-dots span.on { background: #22c55e; }
.rs-fb-row td { background: #f8fbfd; }
@media (max-width: 767px) { .rs-radio-cards { grid-template-columns: 1fr; } .rs-act-row { flex-wrap: wrap; } }
.rs-kind { display: inline-flex; align-items: center; gap: 4px; margin-left: 8px; padding: 2px 9px; border-radius: 99px; font-size: 11.5px; font-weight: 900; vertical-align: middle; }
.rs-kind-challenge { background: #fff1e0; color: #c25500; }
.rs-kind-project { background: #efe6ff; color: #6a2fd1; }

/* ---------------- gamification: level, XP, streak, badges, certificates, portfolio ---------------- */
.rs-game { padding: 18px 20px; }
.rs-game-main { display: flex; align-items: center; gap: 16px; }
.rs-xplevel { flex-shrink: 0; width: 64px; height: 64px; border-radius: 18px; display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #8b5cf6, #6d28d9); box-shadow: 0 6px 16px rgba(109, 40, 217, .3), inset 0 -4px 0 rgba(0, 0, 0, .15); transform: rotate(-4deg); }
.rs-xplevel > span { color: #fff; font-weight: 900; font-size: 28px; transform: rotate(4deg); text-shadow: 0 2px 0 rgba(0, 0, 0, .2); }
.rs-xplevel-sm { width: 40px; height: 40px; border-radius: 12px; }
.rs-xplevel-sm > span { font-size: 18px; }
.rs-xplevel-xs { width: 26px; height: 26px; border-radius: 8px; vertical-align: middle; box-shadow: none; }
.rs-xplevel-xs > span { font-size: 13px; }
.rs-game-info { flex: 1; min-width: 0; }
.rs-game-name { font-size: 15px; margin-bottom: 6px; }
.rs-game-name strong { font-weight: 900; color: #6d28d9; }
.rs-xpbar { height: 14px; border-radius: 99px; background: #ede9fe; overflow: hidden; margin-bottom: 5px; }
.rs-xpbar > span { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #a78bfa, #7c3aed); transition: width .6s ease; }
.rs-game-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 16px; }
.rs-gstat { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 10px 6px; border-radius: 13px; background: var(--rs-bg); text-decoration: none; color: var(--rs-text); }
.rs-gstat > .bi { font-size: 20px; color: var(--rs-muted); }
.rs-gstat strong { font-size: 20px; font-weight: 900; line-height: 1.2; }
.rs-gstat small { color: var(--rs-muted); font-size: 12px; line-height: 1.25; }
.rs-gstat.on > .bi { color: #f97316; }
a.rs-gstat:hover { background: #e6f7fc; color: var(--rs-text); }
.rs-gstat-link > .bi, .rs-gstat-link strong { color: var(--rs-accent-2); }
.rs-game-how { margin: 12px 0 0; font-size: 12.5px; color: var(--rs-muted); }
@media (max-width: 576px) { .rs-game-stats { grid-template-columns: repeat(2, 1fr); } }

.rs-newbadges { padding: 16px 18px; border-color: #fcd34d; background: linear-gradient(180deg, #fffbeb, #fff); }
.rs-newbadges-title { font-weight: 900; color: #b45309; margin-bottom: 10px; }
.rs-medals { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.rs-medal { --b: #64748b; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 3px; padding: 14px 8px 12px; border-radius: 14px; background: #fff; border: 1px solid var(--rs-line); }
.rs-medal-icon { width: 50px; height: 50px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 23px; color: #fff;
  background: var(--b); box-shadow: 0 0 0 4px color-mix(in srgb, var(--b) 18%, transparent), 0 5px 12px color-mix(in srgb, var(--b) 35%, transparent); margin-bottom: 5px; }
.rs-medal strong { font-size: 13.5px; font-weight: 900; line-height: 1.2; }
.rs-medal small { font-size: 11.5px; color: var(--rs-muted); line-height: 1.25; }
.rs-medal.locked { background: #f8fafc; border-style: dashed; }
.rs-medal.locked .rs-medal-icon { background: #cbd5e1; box-shadow: none; }
.rs-medal.locked strong { color: #94a3b8; }

.rs-cert { --c: var(--rs-accent-2); display: flex; gap: 12px; padding: 14px 16px; border-left: 5px solid var(--c); height: 100%; }
.rs-cert .rs-course-icon { flex-shrink: 0; }
.rs-cert-body { min-width: 0; }
.rs-cert code { font-size: 11.5px; }

.rs-ranking .rs-rank-list { list-style: none; padding: 0; margin: 0; }
.rs-rank-list li { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 10px; }
.rs-rank-list li:nth-child(odd) { background: #f8fafc; }
.rs-rank-list li.me { background: #ede9fe; font-weight: 800; }
.rs-rank-pos { width: 28px; height: 28px; flex-shrink: 0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-weight: 900; font-size: 13px; background: #e2e8f0; }
.rs-rank-list li:nth-child(1) .rs-rank-pos { background: #fde047; }
.rs-rank-list li:nth-child(2) .rs-rank-pos { background: #e5e7eb; }
.rs-rank-list li:nth-child(3) .rs-rank-pos { background: #fdba74; }
.rs-rank-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rs-rank-lv { font-size: 12px; color: #6d28d9; font-weight: 800; }
.rs-rank-xp { font-size: 13px; font-weight: 900; min-width: 70px; text-align: right; }

.rs-pf-head { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.rs-pf-avatar { width: 64px; height: 64px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 28px; font-weight: 900; color: #fff;
  background: linear-gradient(135deg, var(--rs-accent), var(--rs-accent-2)); flex-shrink: 0; }
.rs-pf-level { display: flex; align-items: center; gap: 10px; color: var(--rs-muted); }
.rs-pf-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; }
.rs-pf-pick-item { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--rs-line); border-radius: 11px; cursor: pointer; margin: 0; }
.rs-pf-pick-item .form-check-input { margin: 0; flex-shrink: 0; }
.rs-pf-pick-item span { display: flex; flex-direction: column; min-width: 0; }
.rs-pf-pick-item strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rs-pf-pick-item small { color: var(--rs-muted); }

.rs-verify { padding: 18px 20px; }
.rs-verify.ok { border-left: 6px solid #16a34a; }
.rs-verify.bad { border-left: 6px solid #dc2626; color: #991b1b; font-weight: 700; }
.rs-verify-head { font-size: 20px; font-weight: 900; color: #15803d; margin-bottom: 12px; }
.rs-verify-list { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; margin: 0; }
.rs-verify-list dt { color: var(--rs-muted); font-weight: 700; }
.rs-verify-list dd { margin: 0; font-weight: 700; }

/* ---------- payment buttons + PIX page ---------- */
.rs-pay-btns { display: grid; gap: 8px; margin-top: auto; }
.rs-btn-line { border: 2px solid var(--rs-accent-2); color: var(--rs-accent-2); font-weight: 800; border-radius: 11px; background: #fff; }
.rs-btn-line:hover, .rs-btn-line:focus { background: var(--rs-accent-2); color: #fff; }
.rs-btn-pix { background: #32bcad; color: #fff; font-weight: 800; border: 0; border-radius: 11px; }
.rs-btn-pix:hover, .rs-btn-pix:focus { background: #23998d; color: #fff; }
.rs-pix { max-width: 460px; text-align: center; }
.rs-pix-head { display: flex; align-items: center; gap: 14px; text-align: left; padding-bottom: 14px; border-bottom: 1px solid #e6ecf2; margin-bottom: 16px; }
.rs-pix-logo { flex: 0 0 auto; background: #32bcad; color: #fff; font-weight: 900; border-radius: 12px; padding: 8px 12px; font-size: 15px; }
.rs-pix-plan { font-weight: 800; color: #4b5b6b; font-size: 14px; }
.rs-pix-amount { font-weight: 900; font-size: 26px; line-height: 1.1; }
.rs-pix-qr { display: block; margin: 0 auto 12px; width: 240px; height: 240px; max-width: 100%; image-rendering: pixelated; border: 1px solid #e6ecf2; border-radius: 12px; padding: 8px; background: #fff; }
.rs-pix-steps { text-align: left; font-size: 14px; padding-left: 20px; margin-bottom: 14px; }
.rs-pix-code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; }
.rs-pix-status { display: flex; align-items: center; justify-content: center; gap: 8px; background: #fff4d6; color: #9a6200; font-weight: 800; border-radius: 10px; padding: 10px; font-size: 14px; }
.rs-pix-timer { font-variant-numeric: tabular-nums; }
.rs-status-expired { background: #eef1f4; color: #5b6b7b; }
.rs-region-switch { margin-top: 6px; }
.rs-region-switch .btn-link { color: #8fe7fb; font-weight: 800; text-decoration: none; padding: 2px 6px; }
.rs-region-switch .btn-link:hover { color: #fff; text-decoration: underline; }

/* ---------- legal pages ---------- */
.rs-legal-wrap { max-width: 900px; padding-top: 34px; padding-bottom: 50px; }
.rs-legal-nav { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.rs-legal-nav a { padding: 8px 16px; border-radius: 999px; background: #fff; border: 1px solid var(--rs-line); color: #33475b; font-weight: 800; text-decoration: none; font-size: 14.5px; }
.rs-legal-nav a.active { background: var(--rs-accent-2); border-color: var(--rs-accent-2); color: #fff; }
.rs-legal { padding: 34px 40px; font-size: 15.5px; line-height: 1.65; color: #26384b; }
.rs-legal h1 { font-weight: 900; font-size: 30px; margin-bottom: 4px; }
.rs-legal h1 + p em { color: var(--rs-muted); font-style: normal; font-size: 14px; }
.rs-legal h2 { font-weight: 900; font-size: 20px; margin: 30px 0 10px; }
.rs-legal ul { padding-left: 22px; }
.rs-legal li { margin-bottom: 5px; }
.rs-legal a { color: var(--rs-accent-2); font-weight: 700; }
@media (max-width: 600px) { .rs-legal { padding: 22px 18px; } .rs-legal h1 { font-size: 24px; } }

/* ---------- sign-up consent ---------- */
.rs-consent { background: #f6f9fc; border: 1px solid var(--rs-line); border-radius: 14px; padding: 14px 16px; }
.rs-age-opts { display: flex; flex-wrap: wrap; gap: 6px 22px; }
.rs-minor-box { margin-top: 12px; padding-top: 12px; border-top: 1px dashed #cdd9e4; }
.rs-or { text-align: center; margin: 14px 0 10px; position: relative; font-size: 12.5px; color: var(--rs-muted); font-weight: 800; text-transform: uppercase; letter-spacing: .03em; }
.rs-or::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; border-top: 1px solid #dbe5ee; }
.rs-or span { position: relative; background: #f6f9fc; padding: 0 10px; }
.rs-guardian.rs-dim { opacity: .45; }
.rs-danger-box { border: 1px solid #f3c2cb; }
