/* ra2yee-app-respondent.css v2.1.0 — built 2026-05-26T21:35:24Z from sources/00,10,40 — do not hand-edit */

/* === Tokens, dark-mode overrides, base resets, reduced motion === */

/* =====================================================================
   ra2yee-tokens.css — v2.0 (Phase 1B merge — canonical source of truth)
   Built 2026-05-26 from:
     - #4 tokens-cpx32-idi-canonical.css.md (.ra-* canonical, root tokens)
     - #2 tokens-cpx32-cluster-hybrid.css.md (.t-* hybrid, content-max)
   Per Phase 1B brief — see design-system/phase-1b-merge-decisions.md
   for the per-rule resolution log and Q-NEW token call.

   Do NOT hand-edit. Regenerate from the inputs if changes are needed.
   v1.1 additions: --ra-line-strong, --ra-blue-active, --ra-danger-hover.
   v2.0 changes: --ra-content-max = 1100px (was 980px in idi).

   Usage:  <link rel="stylesheet" href="/assets/ra2yee-tokens.css?v=N">
   Scope:  qnr, dp, idi, groups, pulse, accounts, respondent, rewards.
   Not for: React Native app, marketing static sites.
   ===================================================================== */

:root {
  /* =====================================================================
     Brand colors — Egyptian Blue primary, Deep Blue chrome, Teal accent.
     The "2" in the wordmark is always teal. Cream is the warm off-white
     alternate to paper.
     ===================================================================== */
  --ra-blue:         #1034A6;   /* Egyptian Blue — primary, CTAs, focus, active */
  --ra-blue-hover:   #0B2270;   /* hover on blue surfaces */
  --ra-blue-active:  #08174A;   /* depressed/active state — darker than hover (added v1.1) */
  --ra-blue-deep:    #00207B;   /* operator sidebar bg, hero surfaces */
  --ra-teal:         #11C2A8;   /* secondary, accent, the "2" in the wordmark */
  --ra-teal-hover:   #0EAB94;
  --ra-ink-pure:     #0A1228;   /* near-black for the .dark logo modifier on white */
  --ra-paper:        #FFFFFF;   /* explicit paper for logo color references */
  --ra-cream:        #FAF9F5;   /* warm off-white — alternate surface */
  --ra-cream-2:      #F5F2EA;   /* slightly deeper cream for hover, nesting */

  /* =====================================================================
     Brand-tinted fills (8% / 12% opacity)
     ===================================================================== */
  --ra-blue-tint:  rgba(16, 52, 166, 0.08);
  --ra-blue-tint2: rgba(16, 52, 166, 0.12);
  --ra-teal-tint:  rgba(17, 194, 168, 0.12);
  --ra-teal-tint2: rgba(17, 194, 168, 0.18);

  /* =====================================================================
     Ink ramp (text on light)
     ===================================================================== */
  --ra-ink:    #0A0F1F;        /* body text, primary */
  --ra-ink-2:  #4A5170;        /* secondary text, labels */
  --ra-ink-3:  #8B91A8;        /* tertiary, placeholder, timestamps */

  /* =====================================================================
     Surfaces
     ===================================================================== */
  --ra-surface:     #FFFFFF;   /* cards, modals */
  --ra-bg:          #F7F8FB;   /* page background */
  --ra-bg-2:        #EEF1F8;   /* subtle fills, hover rows, chip bg */
  --ra-line:        #E5E7F0;   /* borders, dividers */
  --ra-line-strong: #C7CEDB;   /* stronger border for emphasized separators (added v1.1) */

  /* =====================================================================
     Semantic (success / warn / danger / info)
     ===================================================================== */
  --ra-success:        #11C2A8;   /* reuse teal */
  --ra-success-text:   #0A7A66;
  --ra-success-tint:   rgba(17, 194, 168, 0.12);

  --ra-warn:           #F5A524;
  --ra-warn-text:      #9A6210;
  --ra-warn-tint:      rgba(245, 165, 36, 0.14);

  --ra-danger:         #E5484D;
  --ra-danger-text:    #A12C30;
  --ra-danger-hover:   #CB3338;   /* hover/active state for danger buttons (added v1.1) */
  --ra-danger-tint:    rgba(229, 72, 77, 0.10);

  --ra-info:           #1034A6;   /* reuse blue */
  --ra-info-text:      #1034A6;
  --ra-info-tint:      rgba(16, 52, 166, 0.08);

  /* =====================================================================
     Typography · Stacks
     Plus Jakarta for body/UI; Manrope for display/wordmark; IBM Plex
     Sans Arabic auto-applied via [dir="rtl"]; JetBrains Mono for code/IDs.
     ===================================================================== */
  --ra-font-sans:    'Plus Jakarta Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --ra-font-body:    'Plus Jakarta Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --ra-font-display: 'Manrope', 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --ra-font-arabic:  'IBM Plex Sans Arabic', system-ui, sans-serif;
  --ra-font-mono:    'JetBrains Mono', ui-monospace, Menlo, Consolas, monospace;

  /* =====================================================================
     Typography · Respondent ramp
     ===================================================================== */
  --ra-fs-display-r:  32px;  --ra-lh-display-r: 40px;
  --ra-fs-h1-r:       24px;  --ra-lh-h1-r:      32px;
  --ra-fs-h2-r:       20px;  --ra-lh-h2-r:      28px;
  --ra-fs-body-r:     16px;  --ra-lh-body-r:    24px;
  --ra-fs-small-r:    14px;  --ra-lh-small-r:   20px;
  --ra-fs-micro-r:    12px;  --ra-lh-micro-r:   18px;

  /* =====================================================================
     Typography · Operator ramp (calibrated against Rewards admin)
     ===================================================================== */
  --ra-fs-display-o:  28px;  --ra-lh-display-o: 36px;
  --ra-fs-h1-o:       22px;  --ra-lh-h1-o:      30px;
  --ra-fs-h2-o:       17px;  --ra-lh-h2-o:      24px;
  --ra-fs-body-o:     14px;  --ra-lh-body-o:    20px;
  --ra-fs-small-o:    13px;  --ra-lh-small-o:   18px;
  --ra-fs-micro-o:    12px;  --ra-lh-micro-o:   16px;
  --ra-fs-nano-o:     11px;  --ra-lh-nano-o:    16px;

  /* =====================================================================
     Typography · Component-specific (operator)
     Match Rewards exactly. Sidebar intentionally smaller than the general ramp.
     ===================================================================== */
  --ra-fs-stat-num:    26px;  --ra-lh-stat-num:    32px;
  --ra-fs-stat-label:  13px;  --ra-lh-stat-label:  18px;
  --ra-fs-sidebar:     13px;  --ra-lh-sidebar:     18px;
  --ra-fs-sidebar-sec: 10px;  --ra-lh-sidebar-sec: 14px;
  --ra-fs-table-head:  10px;  --ra-lh-table-head:  14px;
  --ra-fs-wordmark-sb: 14px;
  --ra-fs-wordmark-md: 22px;
  --ra-fs-wordmark-lg: 32px;

  /* =====================================================================
     Typography · Weights
     ===================================================================== */
  --ra-fw-regular:  400;
  --ra-fw-medium:   500;
  --ra-fw-semibold: 600;
  --ra-fw-bold:     700;

  /* =====================================================================
     Spacing scale (4 / 8 / 12 / 16 / 24 / 32 / 48 / 64)
     ===================================================================== */
  --ra-s-1:   4px;
  --ra-s-2:   8px;
  --ra-s-3:   12px;
  --ra-s-4:   16px;
  --ra-s-6:   24px;
  --ra-s-8:   32px;
  --ra-s-12:  48px;
  --ra-s-16:  64px;

  /* =====================================================================
     Radius
     ===================================================================== */
  --ra-r-sm:   6px;
  --ra-r-md:   10px;
  --ra-r-lg:   16px;
  --ra-r-pill: 999px;

  /* =====================================================================
     Elevation
     ===================================================================== */
  --ra-shadow-1: 0 1px 2px rgba(16, 52, 166, 0.06), 0 1px 3px rgba(10, 15, 31, 0.04);
  --ra-shadow-2: 0 4px 8px rgba(16, 52, 166, 0.08), 0 2px 4px rgba(10, 15, 31, 0.06);
  --ra-shadow-3: 0 12px 24px rgba(16, 52, 166, 0.12), 0 4px 8px rgba(10, 15, 31, 0.08);

  /* =====================================================================
     Motion (one easing, three durations)
     ===================================================================== */
  --ra-ease:       cubic-bezier(0.2, 0, 0, 1);
  --ra-dur-micro:  120ms;
  --ra-dur-base:   200ms;
  --ra-dur-enter:  320ms;

  /* =====================================================================
     Component-bound dimensions
     --ra-content-max resolved to 1100px (cluster wins; see brief Step 2).
     ===================================================================== */
  --ra-h-input-r:      48px;
  --ra-h-input-o:      40px;
  --ra-h-input-sm:     32px;
  --ra-h-topnav-o:     64px;
  --ra-h-topnav-r:     56px;
  --ra-h-topnav:       64px;
  --ra-w-sidebar:      256px;
  --ra-w-sidebar-sm:   64px;
  --ra-w-content:      1280px;
  --ra-w-detail:       900px;
  --ra-w-form:         560px;
  --ra-w-auth:         420px;
  --ra-w-sidebar-team: 240px;   /* legacy team chrome */
  --ra-h-topnav-team:  60px;    /* legacy team chrome */
  --ra-content-max:    1100px;  /* cluster value — Phase 3 syncs IDI down from 980 */

  /* =====================================================================
     Chart palette · series colors in canonical order
     ===================================================================== */
  --ra-chart-1: #1034A6;   /* Egyptian Blue */
  --ra-chart-2: #11C2A8;   /* Teal */
  --ra-chart-3: #00207B;   /* Deep Blue */
  --ra-chart-4: #F5A524;   /* Amber */
  --ra-chart-5: #0A1228;   /* Ink */
  --ra-chart-6: #7C8DC2;   /* Muted Blue */
}

/* ====================================================================
   Dark mode — Pulse and any future opt-in surfaces.
   Activate with <html data-theme="dark"> or media query.
   ==================================================================== */
[data-theme="dark"] {
  --ra-ink:    #F1F3F8;
  --ra-ink-2:  #B5BBD0;
  --ra-ink-3:  #7A8099;
  --ra-surface: #14182A;
  --ra-bg:      #0A0F1F;
  --ra-bg-2:    #1C2238;
  --ra-line:    #2A3050;

  --ra-blue-tint:  rgba(16, 52, 166, 0.20);
  --ra-blue-tint2: rgba(16, 52, 166, 0.28);
  --ra-teal-tint:  rgba(17, 194, 168, 0.20);
  --ra-teal-tint2: rgba(17, 194, 168, 0.28);

  --ra-success-tint:  rgba(17, 194, 168, 0.22);
  --ra-warn-tint:     rgba(245, 165, 36, 0.22);
  --ra-danger-tint:   rgba(229, 72, 77, 0.22);
  --ra-info-tint:     rgba(16, 52, 166, 0.22);

  --ra-shadow-1: 0 1px 2px rgba(0, 0, 0, 0.40), 0 1px 3px rgba(0, 0, 0, 0.24);
  --ra-shadow-2: 0 4px 8px rgba(0, 0, 0, 0.40), 0 2px 4px rgba(0, 0, 0, 0.28);
  --ra-shadow-3: 0 12px 24px rgba(0, 0, 0, 0.50), 0 4px 8px rgba(0, 0, 0, 0.32);
}

/* ====================================================================
   Base resets — opt-in. Wrapped in :where() so specificity is zero
   and apps can override freely.
   ==================================================================== */
:where(html) { scrollbar-gutter: stable; }
:where(*, *::before, *::after) { box-sizing: border-box; }
:where(body) {
  margin: 0;
  font-family: var(--ra-font-sans);
  color: var(--ra-ink);
  background: var(--ra-bg);
  -webkit-font-smoothing: antialiased;
}
:where([dir="rtl"] body) { font-family: var(--ra-font-arabic); }
:where(a) { color: inherit; text-decoration: none; }
:where(svg) { display: block; flex-shrink: 0; }
:where(:focus-visible) {
  outline: 2px solid var(--ra-blue);
  outline-offset: 2px;
}

/* ====================================================================
   Reduced motion — global respect.
   ==================================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* === Logo & wordmark & lockup === */

/* ====================================================================
   .ra-* canonical components — lifted from #4 idi (Phase 1B Step 2).
   Hex literals swept against the v2.0 token set. Per-selector §B.2
   resolutions applied where #4 disagreed with #1/#2/#3.
   ==================================================================== */
.ra2yee-logo {
  display: inline-flex;
  align-items: baseline;
  gap: 0;
  font-family: var(--ra-font-display);
  font-weight: 800;
  font-size: 32px;
  line-height: 1;
  color: var(--ra-paper);
  text-decoration: none;
  letter-spacing: -0.01em;
  user-select: none;
}
.ra2yee-logo .two { color: var(--ra-teal); }
.ra2yee-logo .divider {
  display: inline-block;
  width: 2px;
  height: 0.85em;
  background: rgba(255, 255, 255, 0.7);
  margin: 0 0.35em 0 0.4em;
  align-self: center;
  transform: translateY(0.04em);
}
.ra2yee-logo .product {
  font-weight: 600;
  font-size: 0.7em;
  color: rgba(255, 255, 255, 0.85);
  letter-spacing: 0.02em;
}
.ra2yee-logo.eg-blue { color: var(--ra-blue); }
.ra2yee-logo.eg-blue .divider { background: rgba(16, 52, 166, 0.55); }
.ra2yee-logo.eg-blue .product { color: rgba(16, 52, 166, 0.8); }
.ra2yee-logo.deep-blue { color: var(--ra-blue-deep); }
.ra2yee-logo.deep-blue .divider { background: rgba(0, 32, 123, 0.55); }
.ra2yee-logo.deep-blue .product { color: rgba(0, 32, 123, 0.8); }
.ra2yee-logo.dark { color: var(--ra-ink-pure); }
.ra2yee-logo.dark .divider { background: rgba(10, 18, 40, 0.5); }
.ra2yee-logo.dark .product { color: rgba(10, 18, 40, 0.7); }
.ra2yee-logo.is-tiny .divider,
.ra2yee-logo.is-tiny .product { display: none; }
.ra-wordmark { font-family: var(--ra-font-display); font-weight: 800; color: var(--ra-blue); letter-spacing: -0.01em; }
.ra-wordmark .ra-2 { color: var(--ra-teal); }
.ra-lockup { display: inline-flex; align-items: center; gap: 10px; font-family: var(--ra-font-display); }
.ra-lockup-divider { width: 1px; height: 0.95em; background: var(--ra-line); }
.ra-lockup-app { font-weight: var(--ra-fw-semibold); color: var(--ra-teal); letter-spacing: 0.06em; font-size: 0.78em; }

/* === Respondent forms — inputs, selects, textareas, field labels, respondent table & card === */

.ra-topnav--respondent { height: var(--ra-h-topnav-r); padding: 0 20px; }
.ra-field-label {
  display: block;
  font-family: var(--ra-font-sans);
  font-weight: var(--ra-fw-semibold);
  font-size: 12px;
  color: var(--ra-ink);
  margin: 0 0 6px;
}
.ra-field-required::after {
  content: ''; display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--ra-danger);
  margin-left: 6px;
  transform: translateY(-1px);
}
.ra-input,
.ra-textarea,
.ra-select {
  display: block; width: 100%;
  height: var(--ra-h-input-o);
  padding: 0 12px;
  background: var(--ra-paper);
  border: 1px solid var(--ra-line);
  border-radius: var(--ra-r-md);
  font-family: var(--ra-font-sans);
  font-size: 14px;
  color: var(--ra-ink);
  transition: border-color var(--ra-dur-micro) var(--ra-ease),
              box-shadow var(--ra-dur-micro) var(--ra-ease);
}
.ra-textarea { height: auto; min-height: 96px; padding: 10px 12px; resize: vertical; }
.ra-input:hover, .ra-textarea:hover, .ra-select:hover { border-color: var(--ra-ink-3); }
.ra-input:focus, .ra-textarea:focus, .ra-select:focus {
  outline: none;
  border-color: var(--ra-blue);
  box-shadow: 0 0 0 4px var(--ra-blue-tint2);
}
.ra-input:disabled, .ra-textarea:disabled, .ra-select:disabled {
  background: var(--ra-bg-2); color: var(--ra-ink-3); cursor: not-allowed;
}
.ra-field-help { font-family: var(--ra-font-sans); font-size: 12px; color: var(--ra-ink-3); margin: 6px 0 0; }
.ra-input--respondent, .ra-textarea--respondent, .ra-select--respondent {
  height: var(--ra-h-input-r); font-size: 16px; padding: 0 14px;
}
.ra-card--respondent { padding: 22px 28px; border-radius: var(--ra-r-lg); }
.ra-table--respondent th {
  font-family: var(--ra-font-sans);
  font-size: 12px; font-weight: var(--ra-fw-semibold);
  letter-spacing: 0; text-transform: none;
  color: var(--ra-ink-2); padding: 12px 14px;
}
.ra-table--respondent td { padding: 12px 14px; font-size: 15px; }
