/* ============================================================
   PollPoll — ba4bes brand theme (2026 logo kit)
   UI accents: iris + teal. Neutrals invert, accents never do.
   DM Sans for everything, JetBrains Mono for labels and code.
   WCAG 2.1 AA compliant.
   ============================================================ */

/* --- Accents: identical hex in light and dark mode --- */
:root {
  --iris: #836BAC;
  --iris-soft: #A48CCB;
  --iris-deep: #5E4A82;
  --iris-press: #4E3C74;
  --teal: #28837E;
  --teal-soft: #4FB3AD;
  --teal-deep: #1D6763;

  --danger: #E06C75;
  --danger-deep: #B03A48;
  --warning: #D19A4E;
  --warning-deep: #8A5A22;

  /* Accent washes — the 15% tints used by tags, rings and highlights */
  --iris-wash: rgba(131, 107, 172, 0.15);
  --iris-ring: rgba(131, 107, 172, 0.12);
  --iris-focus: rgba(131, 107, 172, 0.28);
  --teal-wash: rgba(40, 131, 126, 0.15);
  --danger-wash: rgba(224, 108, 117, 0.15);
  --warning-wash: rgba(181, 118, 47, 0.15);

  /* Distinct categorical chart colours (Okabe-Ito colour-blind-safe palette). */
  --chart-1: #0072B2;
  --chart-2: #D55E00;
  --chart-3: #009E73;
  --chart-4: #CC79A7;
  --chart-5: #E69F00;
  --chart-6: #56B4E9;

  /* Spacing: 4 / 8 / 16 / 24 / 40 / 64 */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 40px;
  --space-2xl: 64px;

  /* Shape follows the mark: controls 4px, cards 10px, panels 14px */
  --radius-xs: 3px;
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 10px;
  --radius-xl: 14px;
  --radius-pill: 999px;
  --radius-button: 4px;
  --radius-input: 4px;
  --radius-card: 10px;
  --radius-panel: 14px;

  /* Elevation: two levels and a ring, nothing more */
  --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.06);
  --shadow-raised: 0 8px 28px rgba(0, 0, 0, 0.10);
  --shadow-overlay: 0 24px 60px rgba(0, 0, 0, 0.22);
  --ring-iris: 0 0 0 3px rgba(131, 107, 172, 0.12);
  --ring-focus: 0 0 0 3px rgba(131, 107, 172, 0.28);

  /* Motion: fades and colour only — nothing bounces or scales */
  --dur-micro: 120ms;
  --dur-state: 180ms;
  --dur-move: 320ms;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);

  /* Type — DM Sans does display and body, no third family */
  --font-display: 'DM Sans', system-ui, -apple-system, sans-serif;
  --font-body: 'DM Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'SFMono-Regular', 'Courier New', monospace;

  /* The hexagon plate as a clip */
  --clip-hex: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
}

/* --- Light mode (default): warm creme --- */
:root,
[data-theme="light"] {
  --bg: #F5EFE7;
  --surface: #EDE7DB;
  --surface-2: #E4DCCE;
  --border: #DCD4C7;
  --text-1: #2A2420;
  --text-2: #555049;
  --text-3: #7A736B;
  --text-on-accent: #F5EFE7;
  --code-bg: #EDE8DF;

  --iris-text: var(--iris-deep);
  --teal-text: var(--teal-deep);
  --warning-text: var(--warning-deep);
  --accent-hover: var(--iris-deep);

  --success: var(--teal);
  --error: var(--danger-deep);
  --info: var(--iris);
  --header-bg: rgba(245, 239, 230, 0.86);
  --scrim: rgba(26, 23, 20, 0.45);
  --color-scheme: light;
}

/* --- Dark mode: warm brown-black, never cool grey --- */
[data-theme="dark"] {
  --bg: #1A1714;
  --surface: #231F1B;
  --surface-2: #2D2924;
  --border: #3D3830;
  --text-1: #F0E8DC;
  --text-2: #9A9088;
  --text-3: #807870;
  --text-on-accent: #F5EFE7;
  --code-bg: #231F1B;

  --iris-text: var(--iris-soft);
  --teal-text: var(--teal-soft);
  --warning-text: var(--warning);
  --accent-hover: var(--iris-soft);

  --success: var(--teal-soft);
  --error: var(--danger);
  --info: var(--iris-soft);
  --header-bg: rgba(26, 23, 20, 0.86);
  --color-scheme: dark;

  --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.35);
  --shadow-raised: 0 8px 28px rgba(0, 0, 0, 0.45);
  --shadow-overlay: 0 24px 60px rgba(0, 0, 0, 0.6);
}

/* ============================================================
   Base
   ============================================================ */

html {
  font-size: 15px;
  position: relative;
  min-height: 100%;
  background-color: var(--bg);
  color: var(--text-1);
  color-scheme: var(--color-scheme);
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

body {
  margin-bottom: 60px;
  background-color: var(--bg);
  color: var(--text-1);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* Headings are sentence case, DM Sans 700, tight tracking */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.15;
  color: var(--text-1);
}

h1 { font-size: 2rem; letter-spacing: -0.02em; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.2rem; }
h4, h5 { font-size: 1.05rem; font-weight: 600; }

code, kbd, pre, samp {
  font-family: var(--font-mono);
  font-size: 0.85rem;
}

a {
  color: var(--iris-text);
  text-decoration-color: var(--iris-wash);
  text-underline-offset: 0.18em;
  transition: color var(--dur-micro) var(--ease), text-decoration-color var(--dur-micro) var(--ease);
}

a:hover {
  color: var(--iris-text);
  text-decoration-color: currentColor;
}

hr {
  border-color: var(--border);
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* ============================================================
   Skip link (WCAG 2.1 AA)
   ============================================================ */

.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--iris);
  color: var(--text-on-accent);
  padding: var(--space-sm) var(--space-md);
  text-decoration: none;
  z-index: 100;
  font-family: var(--font-body);
  border-radius: 0 0 var(--radius-sm) 0;
}

.skip-link:focus {
  top: 0;
  color: var(--text-on-accent);
}

/* ============================================================
   Focus: 2px iris outline, 2px offset. Nothing scales.
   ============================================================ */

:focus-visible {
  outline: 2px solid var(--iris);
  outline-offset: 2px;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: var(--ring-focus);
  outline: 2px solid var(--iris);
  outline-offset: 2px;
}

input[type="radio"]:focus,
input[type="checkbox"]:focus {
  outline: 2px solid var(--iris);
  outline-offset: 2px;
}

.option-label:has(:focus) {
  border-color: var(--iris);
  box-shadow: var(--ring-focus);
}

/* ============================================================
   Brand marks
   ============================================================ */

/* The glyph beside the product wordmark. Minimum 20px high, one stroke
   width of clearspace on all four sides. */
.brand-mark {
  height: 26px;
  width: auto;
  display: block;
}

.navbar-brand.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding-block: 0.25rem;
}

.brand-wordmark {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.4rem;
  letter-spacing: -0.02em;
  color: var(--text-1);
  transition: color var(--dur-micro) var(--ease);
}

.brand-wordmark-accent {
  color: var(--iris-text);
}

.navbar-brand:hover .brand-wordmark {
  color: var(--iris-text);
}

/* Horizontal lockup, minimum 120px wide */
.brand-credit {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-3);
  text-decoration: none;
}

.brand-credit img {
  width: 120px;
  height: auto;
  display: block;
}

/* The one decorative device: the hexagon plate as watermark, 4% opacity,
   bleeding off the right edge. Never text over it. */
.brand-watermark {
  position: fixed;
  right: -7vw;
  top: 50%;
  transform: translateY(-50%);
  height: 60vh;
  width: auto;
  opacity: 0.04;
  pointer-events: none;
  user-select: none;
  z-index: -1;
}

@media (max-width: 768px) {
  .brand-watermark {
    display: none;
  }
}

/* ============================================================
   Navbar — the one blurred surface in the system
   ============================================================ */

.navbar {
  background-color: var(--header-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-color: var(--border) !important;
}

.navbar-brand {
  color: var(--text-1) !important;
}

.nav-link {
  font-family: var(--font-body);
  font-weight: 500;
  color: var(--text-2) !important;
  font-size: 0.95rem;
  transition: color var(--dur-micro) var(--ease);
}

.nav-link:hover,
.nav-link:focus {
  color: var(--text-1) !important;
}

.navbar-toggler {
  border-color: var(--border);
  border-radius: var(--radius-button);
}

/* ============================================================
   Footer
   ============================================================ */

.footer {
  position: absolute;
  bottom: 0;
  width: 100%;
  white-space: nowrap;
  line-height: 60px;
  height: 60px;
  background-color: var(--surface) !important;
  border-color: var(--border) !important;
  color: var(--text-3);
  font-family: var(--font-body);
  font-size: 0.82rem;
}

.footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.footer a {
  color: var(--iris-text);
}

/* ============================================================
   Buttons — colour depth carries the whole interaction language
   ============================================================ */

.btn {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.9rem;
  border-radius: var(--radius-button);
  padding: 0.55rem 1.3rem;
  border-width: 1px;
  transition: background-color var(--dur-state) var(--ease),
              border-color var(--dur-state) var(--ease),
              color var(--dur-state) var(--ease);
}

.btn:disabled,
.btn.disabled {
  opacity: 0.45;
}

.btn-primary {
  background-color: var(--iris);
  border-color: var(--iris);
  color: var(--text-on-accent);
}

.btn-primary:hover,
.btn-primary:focus {
  background-color: var(--iris-deep);
  border-color: var(--iris-deep);
  color: var(--text-on-accent);
}

.btn-primary:active,
.btn-check:checked + .btn-primary {
  background-color: var(--iris-press) !important;
  border-color: var(--iris-press) !important;
  color: var(--text-on-accent) !important;
}

/* Secondary hover fills solid iris — the fill is the signal */
.btn-outline-primary {
  color: var(--iris-text);
  border-color: var(--iris);
  background-color: transparent;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  background-color: var(--iris);
  border-color: var(--iris);
  color: var(--text-on-accent);
}

.btn-success,
.btn-info {
  background-color: var(--teal);
  border-color: var(--teal);
  color: var(--text-on-accent);
}

.btn-success:hover, .btn-success:focus,
.btn-info:hover, .btn-info:focus {
  background-color: var(--teal-deep);
  border-color: var(--teal-deep);
  color: var(--text-on-accent);
}

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

.btn-outline-secondary:hover, .btn-outline-secondary:focus,
.btn-secondary:hover, .btn-secondary:focus,
.btn-ghost:hover, .btn-ghost:focus {
  background-color: var(--surface-2);
  border-color: var(--border);
  color: var(--text-1);
}

.btn-danger {
  background-color: var(--error);
  border-color: var(--error);
  color: var(--text-on-accent);
}

.btn-danger:hover,
.btn-danger:focus {
  background-color: var(--danger-deep);
  border-color: var(--danger-deep);
  color: var(--text-on-accent);
}

/* Warning is semantic, never decorative — outlined so it stays quiet */
.btn-warning {
  background-color: transparent;
  border-color: var(--warning);
  color: var(--warning-text);
}

.btn-warning:hover,
.btn-warning:focus {
  background-color: var(--warning-wash);
  border-color: var(--warning);
  color: var(--warning-text);
}

.btn-sm {
  font-size: 0.82rem;
  padding: 0.35rem 0.9rem;
}

.btn-lg {
  font-size: 1.05rem;
  padding: 0.75rem 1.6rem;
}

/* ============================================================
   Cards — surface + 1px border + 10px radius + soft shadow
   ============================================================ */

.card {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  transition: border-color var(--dur-state) var(--ease), box-shadow var(--dur-state) var(--ease);
}

/* The card does not lift or scale */
.card:hover {
  border-color: var(--iris);
  box-shadow: var(--shadow-card), var(--ring-iris);
}

.card-header {
  background-color: var(--surface-2);
  border-color: var(--border);
  border-radius: var(--radius-card) var(--radius-card) 0 0 !important;
  color: var(--text-1);
  font-family: var(--font-display);
  font-weight: 600;
  padding: 1rem 1.5rem;
}

.card-header h3,
.card-header h5 {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.015em;
}

/* Accent headers stay hairline + tinted — no colour block cropping the card */
.card-header.bg-primary,
.card-header.bg-success,
.card-header.bg-secondary,
.card-header.bg-info {
  background-color: var(--surface-2) !important;
  color: var(--text-1) !important;
  border-bottom: 1px solid var(--border);
}

.card-header.text-white {
  color: var(--text-1) !important;
}

.card.border-primary {
  border-color: var(--border) !important;
  border-left: 3px solid var(--iris) !important;
}

.card.border-success {
  border-color: var(--border) !important;
  border-left: 3px solid var(--teal) !important;
}

.card-body {
  padding: 1.5rem;
}

.card-footer {
  background-color: var(--surface);
  border-color: var(--border);
  border-radius: 0 0 var(--radius-card) var(--radius-card) !important;
}

/* ============================================================
   Tags and badges — pills, mono, uppercase, 15% accent fill
   ============================================================ */

.badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: var(--radius-pill);
  padding: 0.35em 0.85em;
  border: 1px solid transparent;
}

.badge.bg-primary {
  background-color: var(--iris-wash) !important;
  border-color: var(--iris);
  color: var(--iris-text) !important;
}

.badge.bg-info,
.badge.bg-success {
  background-color: var(--teal-wash) !important;
  border-color: var(--teal);
  color: var(--teal-text) !important;
}

.badge.bg-danger {
  background-color: var(--danger-wash) !important;
  border-color: var(--error);
  color: var(--error) !important;
}

.badge.bg-warning {
  background-color: var(--warning-wash) !important;
  border-color: var(--warning);
  color: var(--warning-text) !important;
}

.badge.bg-secondary,
.badge.bg-light {
  background-color: var(--surface-2) !important;
  border-color: var(--border);
  color: var(--text-2) !important;
}

.badge.bg-light.text-success {
  color: var(--teal-text) !important;
}

.badge.bg-light.text-primary {
  color: var(--iris-text) !important;
}

.badge.bg-light.text-secondary {
  color: var(--text-2) !important;
}

/* Poll codes read as data, not decoration */
.badge.code-tag {
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  background-color: var(--surface-2) !important;
  border-color: var(--border);
  color: var(--text-1) !important;
}

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

.form-label {
  font-family: var(--font-body);
  font-weight: 500;
  color: var(--text-1);
  font-size: 0.95rem;
}

.form-control,
.form-select {
  background-color: var(--bg);
  border: 1px solid var(--border);
  color: var(--text-1);
  border-radius: var(--radius-input);
  font-family: var(--font-body);
  transition: border-color var(--dur-state) var(--ease), box-shadow var(--dur-state) var(--ease);
}

.form-control:focus,
.form-select:focus {
  background-color: var(--bg);
  border-color: var(--iris);
  color: var(--text-1);
}

.form-control::placeholder {
  color: var(--text-3);
}

.form-text {
  color: var(--text-3);
  font-size: 0.82rem;
}

.form-check-label {
  font-family: var(--font-body);
  color: var(--text-1);
}

.form-check-input {
  border-color: var(--border);
  background-color: var(--bg);
  border-radius: var(--radius-xs);
}

.form-check-input:checked {
  background-color: var(--iris);
  border-color: var(--iris);
}

.form-check-input[type="radio"] {
  border-radius: 50%;
}

.input-group-text {
  background-color: var(--surface-2);
  border-color: var(--border);
  color: var(--text-2);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  border-radius: var(--radius-input);
}

.form-floating > .form-control-plaintext::placeholder,
.form-floating > .form-control::placeholder {
  color: var(--text-3);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder,
.form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* ============================================================
   Alerts — a tint and a hairline, never a colour block
   ============================================================ */

.alert {
  border-width: 1px;
  border-radius: var(--radius-card);
  font-family: var(--font-body);
}

.alert-success {
  background-color: var(--teal-wash);
  border-color: var(--teal);
  color: var(--teal-text);
}

.alert-danger {
  background-color: var(--danger-wash);
  border-color: var(--error);
  color: var(--error);
}

.alert-info {
  background-color: var(--iris-wash);
  border-color: var(--iris);
  color: var(--iris-text);
}

.alert-warning {
  background-color: var(--warning-wash);
  border-color: var(--warning);
  color: var(--warning-text);
}

.alert-link {
  color: inherit;
  font-weight: 600;
}

/* ============================================================
   List groups
   ============================================================ */

.list-group-item {
  background-color: var(--bg);
  border-color: var(--border);
  color: var(--text-1);
  font-family: var(--font-body);
}

.list-group-item:first-child {
  border-radius: var(--radius-card) var(--radius-card) 0 0;
}

.list-group-item:last-child {
  border-radius: 0 0 var(--radius-card) var(--radius-card);
}

/* ============================================================
   Tables — structure from hairlines, not colour fills
   ============================================================ */

.table {
  color: var(--text-1);
  border-color: var(--border);
}

.table thead th {
  background-color: var(--surface-2);
  color: var(--text-2);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  border-bottom: 1px solid var(--border);
}

.table-striped > tbody > tr:nth-of-type(odd) > * {
  background-color: var(--surface);
  color: var(--text-1);
}

.table-striped > tbody > tr:nth-of-type(even) > * {
  background-color: var(--bg);
  color: var(--text-1);
}

.table-hover > tbody > tr:hover > * {
  background-color: var(--surface-2);
  color: var(--text-1);
}

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

.modal-content {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow-overlay);
}

.modal-backdrop.show {
  background-color: var(--scrim);
  backdrop-filter: blur(3px);
  opacity: 1;
}

.modal-header {
  border-color: var(--border);
  font-family: var(--font-display);
}

.modal-header.bg-primary {
  background-color: var(--surface-2) !important;
  color: var(--text-1) !important;
}

.modal-footer {
  border-color: var(--border);
}

/* ============================================================
   Voting page
   ============================================================ */

.vote-container {
  max-width: 600px;
  margin: var(--space-xl) auto;
  padding: var(--space-md);
}

.poll-question {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: var(--text-1);
  line-height: 1.15;
  letter-spacing: -0.015em;
}

.options-list {
  margin-bottom: 1.5rem;
}

.option-item {
  margin-bottom: 0.75rem;
}

.option-label {
  display: flex;
  align-items: center;
  padding: 1rem;
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  cursor: pointer;
  transition: background-color var(--dur-state) var(--ease),
              border-color var(--dur-state) var(--ease),
              box-shadow var(--dur-state) var(--ease);
  font-family: var(--font-body);
  font-size: 1.05rem;
  min-height: 60px;
}

.option-label:hover {
  background-color: var(--surface-2);
  border-color: var(--iris);
}

.option-label:has(:checked) {
  border-color: var(--iris);
  background-color: var(--iris-wash);
  box-shadow: var(--ring-iris);
}

.option-label input[type="radio"],
.option-label input[type="checkbox"] {
  width: 22px;
  height: 22px;
  margin-right: 1rem;
  cursor: pointer;
  flex-shrink: 0;
  accent-color: var(--iris);
}

.option-text {
  flex-grow: 1;
  font-size: 1.05rem;
  color: var(--text-1);
}

.btn-submit {
  width: 100%;
  padding: 1rem;
  font-size: 1.05rem;
  font-weight: 600;
  min-height: 60px;
  font-family: var(--font-display);
}

.error-message,
.poll-closed {
  text-align: center;
  padding: var(--space-xl);
}

.closed-message {
  color: var(--error);
  font-weight: 600;
  font-size: 1.25rem;
}

.info-message {
  background-color: var(--iris-wash);
  color: var(--text-1);
  padding: 0.75rem;
  border-radius: var(--radius-card);
  margin-bottom: 1rem;
  border: 1px solid var(--iris);
  font-family: var(--font-body);
}

@media (max-width: 576px) {
  .vote-container {
    padding: 0.5rem;
  }

  .poll-question {
    font-size: 1.2rem;
  }

  .option-label {
    padding: 0.75rem;
    font-size: 1rem;
  }

  .option-text {
    font-size: 1rem;
  }
}

/* ============================================================
   Poll group navigation
   ============================================================ */

.poll-group-progress {
  margin-bottom: 1.5rem;
  text-align: center;
}

.progress-text {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-2);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.progress-indicators {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  align-items: center;
}

.progress-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--border);
  display: inline-block;
  transition: background-color var(--dur-state) var(--ease);
}

.progress-dot.current {
  background-color: var(--iris);
  width: 14px;
  height: 14px;
}

.progress-dot.answered {
  background-color: var(--teal);
}

.poll-group-navigation {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
  justify-content: center;
}

.btn-skip {
  background-color: var(--surface);
  color: var(--text-2);
  border: 1px solid var(--border);
}

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

.btn-next {
  background-color: var(--iris);
  color: var(--text-on-accent);
}

.btn-next:hover {
  background-color: var(--iris-deep);
  color: var(--text-on-accent);
}

.poll-group-complete {
  margin-top: 1.5rem;
  text-align: center;
  padding: 1rem;
  background-color: var(--surface);
  border-radius: var(--radius-card);
  border: 1px solid var(--border);
}

.poll-group-complete p {
  margin-bottom: 1rem;
  color: var(--text-2);
}

/* ============================================================
   Display mode toggle (dashboard)
   ============================================================ */

.display-mode-toggle {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-3);
}

.display-mode-toggle .toggle-label {
  font-weight: 400;
}

.toggle-switch {
  position: relative;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  transition: background-color var(--dur-state) var(--ease), border-color var(--dur-state) var(--ease);
}

.toggle-slider::before {
  content: "";
  position: absolute;
  height: 20px;
  width: 20px;
  left: 2px;
  bottom: 2px;
  background-color: var(--text-3);
  border-radius: 50%;
  transition: transform var(--dur-move) cubic-bezier(0.16, 1, 0.3, 1),
              background-color var(--dur-state) var(--ease);
}

.toggle-switch input:checked + .toggle-slider {
  background-color: var(--iris-wash);
  border-color: var(--iris);
}

.toggle-switch input:checked + .toggle-slider::before {
  transform: translateX(22px);
  background-color: var(--iris);
}

.toggle-switch input:focus-visible + .toggle-slider {
  box-shadow: var(--ring-focus);
}

/* ============================================================
   Eyebrow labels — the one place uppercase is allowed
   ============================================================ */

.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--iris-text);
  margin-bottom: 0.4rem;
}

.eyebrow.teal {
  color: var(--teal-text);
}

/* Mono counters do the job emoji would do elsewhere */
.meta-mono {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-2);
}

/* ============================================================
   Thank you page
   ============================================================ */

.thank-you-container {
  max-width: 600px;
  margin: var(--space-2xl) auto;
  padding: var(--space-lg);
  text-align: center;
}

.thank-you-icon {
  font-size: 2.5rem;
  display: block;
  margin-bottom: var(--space-md);
  color: var(--teal-text);
}

.thank-you-container h1 {
  margin-bottom: var(--space-lg);
}

.thank-you-container .lead {
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--text-2);
  margin-bottom: var(--space-lg);
}

.thank-you-container .meta-mono {
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: var(--space-lg);
}

.completed-message {
  color: var(--teal-text);
  font-weight: 600;
}

.social-links {
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border);
}

.social-intro {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-3);
  margin-bottom: var(--space-md);
}

.social-links .btn-ghost i {
  font-size: 1.15rem;
  line-height: 1;
}

.thank-you-credit {
  margin-top: var(--space-lg);
}

/* ============================================================
   QR panel
   ============================================================ */

.qr-code-container {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-md);
  background-color: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  min-height: 120px;
  min-width: 120px;
}

.qr-code-container img,
.qr-code-container svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* ============================================================
   Spinner
   ============================================================ */

.spinner-border.text-primary {
  color: var(--iris) !important;
}

/* ============================================================
   Utility overrides
   ============================================================ */

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

.text-primary {
  color: var(--iris-text) !important;
}

.text-success,
.text-info {
  color: var(--teal-text) !important;
}

.text-danger {
  color: var(--error) !important;
}

.text-warning {
  color: var(--warning-text) !important;
}

.border-success {
  border-color: var(--teal) !important;
}

.border-primary {
  border-color: var(--iris) !important;
}

.bg-primary {
  background-color: var(--iris) !important;
}

.bg-success,
.bg-info {
  background-color: var(--teal) !important;
}

.bg-secondary {
  background-color: var(--surface-2) !important;
}

.bg-light {
  background-color: var(--surface) !important;
}
