/* RingHuddle — Standalone Modern Plain CSS (Zero 3rd-party Dependency) */

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

/* The reset above zeroes list padding, which hangs a plain list's markers
   outside its box (the terms, privacy and developer pages, and call
   history's leg list). A list with a class is a styled component and sets
   its own. :where() keeps this from outweighing anything. */
:where(ul:not([class]), ol:not([class])) {
  padding-left: 1.4rem;
}

/* A fieldset is an inset box like the site's others: the browser's groove
   border and the reset's zero padding put its text against the border. */
fieldset {
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  padding: 0.75rem 1rem;
}

fieldset > legend {
  padding: 0 0.35rem;
}

/* A card's forms and inset boxes stack their parts: each block after the
   first starts at least --rh-space-block below the one before. The API key
   and webhook forms' button rows brought no margin of their own and sat on
   the border of the box above them (2026-11-26); one rule here instead of a
   margin on each part. :where() keeps it at zero specificity, so a part's
   own spacing (.mt-md, .m-0) still wins, and a form laid out as a row sets
   its children's to 0. Nothing is pushed down after a label that names a
   field below it, a legend (it sits on the border) or something that
   doesn't show. Measured by ui_constraints::block_spacing. */
:where(article form, article fieldset)
  > :where(:not(label:not(:has(input, select, textarea)), legend, template, input[type="hidden"]))
  + :where(*) {
  margin-block-start: var(--rh-space-block);
}

[x-cloak] {
  display: none !important;
}

:root {
  --rh-font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  --rh-font-heading: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  --rh-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  --rh-primary: #0f766e;
  --rh-primary-rgb: 15, 118, 110;
  --rh-primary-background: #0f766e;
  --rh-primary-border: #0f766e;
  --rh-primary-hover: #115e59;
  --rh-primary-hover-background: #115e59;
  --rh-primary-hover-border: #115e59;
  --rh-primary-focus: rgba(15, 118, 110, 0.25);
  --rh-primary-inverse: #ffffff;
  --rh-primary-underline: rgba(15, 118, 110, 0.5);
  --color-brand-primary: #0f766e;
  --primary: #0f766e;

  --rh-background-color: #f8fafc;
  --rh-card-background-color: #ffffff;
  --rh-surface-color: #ffffff;
  --rh-color: #0f172a;
  --rh-text-color: #0f172a;
  --rh-h2-color: #0f172a;
  --rh-muted-color: #475569;
  --rh-muted-text-color: #475569;
  --rh-muted-border-color: #e2e8f0;
  --rh-border-color: #cbd5e1;
  --rh-border-radius: 8px;
  --rh-placeholder-color: #94a3b8;
  --rh-spacing: 1rem;
  /* The spacing scale (the .mt-*, .mb-* and .gap-* utilities use the same
     steps). --rh-space-block is the least room between two blocks stacked
     in a card; ui_constraints::block_spacing measures it on every page. */
  --rh-space-xs: 0.25rem;
  --rh-space-sm: 0.5rem;
  --rh-space-md: 1rem;
  --rh-space-block: var(--rh-space-sm);
  /* The width of the header, the footer and every page's content: one
     rule, so going from the dashboard to the account page doesn't change
     it. A form on its own (sign in, register) sits narrower inside it. */
  --rh-page-width: 820px;
  --rh-form-element-spacing-vertical: 0.5rem;
  --rh-form-element-spacing-horizontal: 0.75rem;
  --rh-box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
  --rh-ins-color: #16a34a;
  --rh-del-color: #dc2626;
  --rh-code-background: #f1f5f9;

  /* Semantic Notice / Alert / Badge Design Tokens (Light) */
  --rh-error-bg: #fef2f2;
  --rh-error-color: #991b1b;
  --rh-error-border: #fecaca;

  --rh-success-bg: #f0fdf4;
  --rh-success-color: #166534;
  --rh-success-border: #bbf7d0;

  --rh-warning-bg: #fffbeb;
  --rh-warning-color: #92400e;
  --rh-warning-border: #fde68a;
}

[data-theme="dark"] {
  --rh-primary: #2dd4bf;
  --rh-primary-hover: #5eead4;
  --rh-primary-focus: rgba(45, 212, 191, 0.25);
  --rh-background-color: #0f172a;
  --rh-card-background-color: #1e293b;
  --rh-surface-color: #1e293b;
  --rh-color: #f8fafc;
  --rh-text-color: #f8fafc;
  --rh-h2-color: #f8fafc;
  --rh-muted-color: #94a3b8;
  --rh-muted-text-color: #94a3b8;
  --rh-placeholder-color: #64748b;
  --rh-muted-border-color: #334155;
  --rh-border-color: #475569;
  --rh-box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.4), 0 1px 2px -1px rgba(0, 0, 0, 0.3);
  --rh-ins-color: #4ade80;
  --rh-del-color: #f87171;
  --rh-code-background: #0b1220;

  /* Semantic Notice / Alert / Badge Design Tokens (Dark) */
  --rh-error-bg: rgba(239, 68, 68, 0.15);
  --rh-error-color: #fca5a5;
  --rh-error-border: rgba(239, 68, 68, 0.35);

  --rh-success-bg: rgba(34, 197, 94, 0.15);
  --rh-success-color: #86efac;
  --rh-success-border: rgba(34, 197, 94, 0.35);

  --rh-warning-bg: rgba(245, 158, 11, 0.15);
  --rh-warning-color: #fcd34d;
  --rh-warning-border: rgba(245, 158, 11, 0.35);
}

/* Auto theme mode: respect system OS preference unless explicitly overridden */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --rh-primary: #2dd4bf;
    --rh-primary-hover: #5eead4;
    --rh-primary-focus: rgba(45, 212, 191, 0.25);
    --rh-background-color: #0f172a;
    --rh-card-background-color: #1e293b;
    --rh-surface-color: #1e293b;
    --rh-color: #f8fafc;
    --rh-text-color: #f8fafc;
    --rh-h2-color: #f8fafc;
    --rh-muted-color: #94a3b8;
    --rh-muted-text-color: #94a3b8;
    --rh-placeholder-color: #64748b;
    --rh-muted-border-color: #334155;
    --rh-border-color: #475569;
    --rh-box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.4), 0 1px 2px -1px rgba(0, 0, 0, 0.3);
    --rh-ins-color: #4ade80;
    --rh-del-color: #f87171;
    --rh-code-background: #0b1220;

    /* The same semantic tokens as [data-theme="dark"]: without them an
       inline error on a system set to dark was the light theme's pink box
       on a dark card. */
    --rh-error-bg: rgba(239, 68, 68, 0.15);
    --rh-error-color: #fca5a5;
    --rh-error-border: rgba(239, 68, 68, 0.35);

    --rh-success-bg: rgba(34, 197, 94, 0.15);
    --rh-success-color: #86efac;
    --rh-success-border: rgba(34, 197, 94, 0.35);

    --rh-warning-bg: rgba(245, 158, 11, 0.15);
    --rh-warning-color: #fcd34d;
    --rh-warning-border: rgba(245, 158, 11, 0.35);
  }
}

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

body {
  font-family: var(--rh-font-family);
  background-color: var(--rh-background-color);
  color: var(--rh-color);
  line-height: 1.5;
  overflow-x: clip;
  max-width: 100vw;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--rh-color);
  font-weight: 700;
  line-height: 1.25;
}
h1 { font-size: 2.25rem; margin-bottom: 0.5rem; }
h2 { font-size: 1.75rem; margin-bottom: 0.5rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.5rem; }
h4 { font-size: 1.1rem; margin-bottom: 0.5rem; }
p { margin-bottom: 0.75rem; }
a { color: var(--rh-primary); text-decoration: underline; text-underline-offset: 3px; }
a:hover { color: var(--rh-primary-hover); }
/* A number that dials when tapped (`components/phone.html`). It keeps the
   colour of the text around it, so a dotted underline marks it as a link,
   and it never breaks across lines at a dash. */
.phone-link {
  color: inherit;
  text-decoration: underline dotted;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  white-space: nowrap;
}
.phone-link:hover { color: inherit; text-decoration-style: solid; }
small { font-size: 0.875rem; color: var(--rh-muted-color); }
strong { font-weight: 700; }

.container {
  width: 100%;
  max-width: 1140px;
  margin-inline: auto;
  padding-inline: 1rem;
}

button,
a[role="button"],
input[type="submit"],
input[type="button"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.5rem 1.25rem;
  border-radius: var(--rh-border-radius);
  border: 1px solid var(--rh-primary-border);
  background-color: var(--rh-primary-background);
  color: var(--rh-primary-inverse);
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  line-height: 1.4;
}

button:hover,
a[role="button"]:hover,
input[type="submit"]:hover {
  background-color: var(--rh-primary-hover-background);
  border-color: var(--rh-primary-hover-border);
}

.btn-sm, button.btn-sm, a[role="button"].btn-sm {
  font-size: 0.85rem;
  padding: 0.3rem 0.75rem;
  min-height: 32px;
}

.secondary.outline, button.secondary.outline, a[role="button"].secondary.outline {
  background-color: transparent;
  border-color: var(--rh-muted-border-color);
  color: var(--rh-color);
}

.secondary.outline:hover, button.secondary.outline:hover, a[role="button"].secondary.outline:hover {
  background-color: var(--rh-muted-border-color);
}

/* Disabled button states */
button:disabled,
button[disabled],
input[type="submit"]:disabled,
input[type="submit"][disabled],
a[role="button"].disabled,
a[role="button"][aria-disabled="true"] {
  opacity: 0.45;
  cursor: not-allowed !important;
  pointer-events: none !important;
  box-shadow: none !important;
}

.secondary.outline:disabled,
.secondary.outline[disabled],
button.secondary.outline:disabled,
button.secondary.outline[disabled] {
  opacity: 0.35 !important;
  color: var(--rh-muted-color) !important;
  border-color: var(--rh-muted-border-color) !important;
  background-color: transparent !important;
  cursor: not-allowed !important;
  pointer-events: none !important;
}

.contrast.outline, button.contrast.outline, a[role="button"].contrast.outline {
  background-color: transparent;
  border-color: var(--rh-color);
  color: var(--rh-color);
}

.contrast.outline:hover, button.contrast.outline:hover, a[role="button"].contrast.outline:hover {
  background-color: var(--rh-color);
  color: var(--rh-background-color);
}

.btn-danger, button.btn-danger {
  background-color: #b91c1c;
  border-color: #b91c1c;
  color: #ffffff;
}

.btn-danger:hover, button.btn-danger:hover {
  background-color: #991b1b;
  border-color: #991b1b;
}

/* Every text-like input, not a list of types that can miss one (a
   type="url" input went unstyled). The exclusions are the inputs that
   aren't boxes you type into. :where() adds no specificity and
   :is([type], :not([type])) adds one attribute, so this weighs what
   input[type="text"] did and class rules win or lose as before. */
input:where(:not([type="checkbox"], [type="radio"], [type="hidden"], [type="submit"], [type="button"], [type="reset"], [type="file"], [type="image"], [type="range"], [type="color"])):is([type], :not([type])),
select,
textarea {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  background-color: var(--rh-card-background-color);
  color: var(--rh-color);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--rh-primary);
  box-shadow: 0 0 0 3px var(--rh-primary-focus);
}

input::placeholder,
textarea::placeholder {
  color: var(--rh-placeholder-color);
  font-weight: 400 !important;
  opacity: 1;
  transition: opacity 0.15s ease;
}

input:focus::placeholder,
textarea:focus::placeholder {
  opacity: 0.35;
}

select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.65rem center;
  padding-right: 2rem;
  cursor: pointer;
}

label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--rh-muted-color);
  margin-bottom: 0.25rem;
}

input[type="checkbox"] {
  accent-color: var(--rh-primary);
  width: 1.1rem;
  height: 1.1rem;
  cursor: pointer;
}

article {
  background-color: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.95rem;
}

th, td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
}

th {
  font-weight: 700;
  color: var(--rh-color);
}

details {
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  margin-bottom: 0.75rem;
  background-color: var(--rh-card-background-color);
}

summary {
  padding: 0.85rem 1.25rem;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

summary::after {
  content: "+";
  float: right;
  font-weight: 700;
  font-size: 1.2rem;
  line-height: 1;
  color: var(--rh-primary);
  transition: transform 0.2s ease;
}

details[open] summary::after {
  content: "−";
}

details > div.faq-content {
  padding: 0 1.25rem 1.25rem 1.25rem;
  color: var(--rh-muted-color);
}

/* Deleting the account is the one card that can't be undone: it says so
   with its border, the way the danger button does. */
.account-danger-card {
  border-color: var(--rh-error-border);
}

/* Call history "Answered by": the column holds only the toggle, an inline
   disclosure rather than the FAQ's bordered box. Opening it shows a row of
   its own under the call, across the whole table, with one line per phone:
   its name and number, a dot and what it did, how long it was on the call,
   and the minutes it used. The row is in the page from the start and shown
   by CSS, not by a script, so nothing moves when scripts load. The list used
   to sit inside the column and was squeezed to its width. */
details.call-legs {
  border: 0;
  border-radius: 0;
  margin: 0;
  background: none;
}

details.call-legs > summary {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0;
  font-weight: inherit;
}

details.call-legs > summary::after {
  content: "▸";
  float: none;
  font-size: 0.8rem;
  color: var(--rh-muted-color);
}

details.call-legs[open] > summary::after {
  content: "▾";
}

tr.call-legs-row {
  display: none;
}

tr:has(details.call-legs[open]) + tr.call-legs-row {
  display: table-row;
}

/* The call above and its phones read as one: no rule between them. */
tr:has(details.call-legs[open]) > td {
  border-bottom-color: transparent;
}

tr.call-legs-row > td {
  padding-top: 0;
}

/* The table scrolls sideways inside its figure on a phone. The list stays
   in the part of the row that's in view, at the figure's width, rather than
   widening the table or starting off-screen. */
figure:has(.call-legs-row) {
  container-type: inline-size;
}

.call-legs-list {
  position: sticky;
  left: 1rem;
  max-width: calc(100cqi - 2rem);
  list-style: none;
  margin: 0;
  padding: 0.5rem 0.75rem;
  border-left: 2px solid var(--rh-muted-border-color);
  display: grid;
  gap: 0.75rem;
  font-size: 0.875rem;
}

/* Each phone: who it is (name, and its number under it) on the left; what
   it did, how long it was on the call and the minutes it used on the right,
   wrapping rather than clipped; its ring timeline under that. The left
   column is the same width on every line, so the outcomes line up. It used
   to be five columns that clipped with an ellipsis, which cut "picked up,
   didn't press 1" short. */
.call-leg {
  display: grid;
  grid-template-columns: minmax(8rem, 14rem) minmax(0, 1fr);
  column-gap: 1.25rem;
  row-gap: 0.25rem;
  align-items: start;
  margin: 0;
}

/* Beside both what it did and its timeline, so a two-line name and number
   doesn't push the timeline down. */
.call-leg-who {
  grid-row: span 2;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow-wrap: anywhere;
}

.call-leg-what {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 0.75rem;
  row-gap: 0.1rem;
}

/* A phone's ring timeline, under what it did: a bar to the call's scale
   (every phone's bar spans the first ring to the call's last end), with the
   ringing part muted and the talking part coloured by what it did, then the
   times it shows. */
.call-leg-timeline {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: 0.75rem;
  row-gap: 0.1rem;
}

.call-leg-bar {
  position: relative;
  flex: 1 1 8rem;
  min-width: 8rem;
  height: 0.5rem;
  border-radius: 0.25rem;
  background: var(--rh-card-background-color);
  box-shadow: inset 0 0 0 1px var(--rh-muted-border-color);
}

.call-leg-ring,
.call-leg-talk {
  position: absolute;
  top: 0;
  bottom: 0;
  border-radius: 0.25rem;
}

/* A phone that rang for under a second still shows. */
.call-leg-ring {
  min-width: 2px;
  background: var(--rh-muted-color);
  opacity: 0.45;
}

.call-leg-talk {
  min-width: 2px;
  background: var(--rh-success-color);
}

.call-leg-talk-declined {
  background: var(--rh-warning-color);
}

.call-leg-times {
  color: var(--rh-muted-color);
}

/* Too narrow for two columns: who, then what it did, then its timeline. */
@container (max-width: 30rem) {
  .call-leg {
    grid-template-columns: minmax(0, 1fr);
  }
  .call-leg-who {
    grid-row: auto;
  }
  .call-leg-timeline {
    grid-column: 1;
  }
}

.call-leg-name {
  font-weight: 600;
}

.call-leg-number,
.call-leg-time,
.call-leg-min {
  color: var(--rh-muted-color);
}

.call-leg-number {
  font-size: 0.8125rem;
}

.call-leg-outcome {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--rh-muted-color);
}

.call-leg-outcome::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--rh-muted-border-color);
  flex-shrink: 0;
}

.call-leg-connected::before {
  background: var(--rh-success-color);
}

.call-leg-declined::before {
  background: var(--rh-warning-color);
}

/* Accessibility: Skip to main content link */
.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  z-index: 1000;
  padding: 0.75rem 1.25rem;
  background: var(--rh-primary-background);
  color: var(--rh-primary-inverse);
  font-weight: 700;
  border-radius: var(--rh-border-radius);
  text-decoration: none;
  transition: top 0.2s ease-in-out;
}
.skip-link:focus {
  top: 1rem;
}
/* `a:hover` outranks `.skip-link`, and its colour is the teal of this
   link's own background: hovered while focused, the link read 1.39:1
   (tests/state_contrast.rs). */
.skip-link:hover {
  color: var(--rh-primary-inverse);
}

/* Accessibility: High-contrast focus rings for keyboard navigation */
:focus-visible {
  outline: 2px solid var(--rh-primary) !important;
  outline-offset: 2px !important;
}

/* Tighter container on the main app */
main.container,
header.container,
footer.container {
  max-width: var(--rh-page-width);
}

/* Header / nav */
header.container {
  padding-inline: var(--rh-spacing, 1rem);
}
.brand {
  font-weight: 700;
  font-size: 1.15rem;
  text-decoration: none;
  color: inherit;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  white-space: nowrap;
  flex-shrink: 0;
}
.brand span {
  display: inline-block;
  font-style: normal;
  line-height: 1;
}

header > nav {
  padding-block: 0.75rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
  margin-bottom: 2rem;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: nowrap;
}
header > nav a {
  text-decoration: none;
  color: var(--rh-color);
}
/* Text links only: on the "Get started" button it outranked the button's
   white text and drew teal on the teal hover background, 1.39:1
   (tests/state_contrast.rs). */
header > nav a:not([role="button"]):hover {
  color: var(--rh-primary);
}

/* Zero out nav margins to prevent pulling brand/phone offscreen on tablets/iPads */
header > nav ul,
header > nav ul:first-of-type,
header > nav ul:last-of-type {
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0;
  padding-right: 0;
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.5rem;
  list-style: none;
}

header > nav ul li {
  margin: 0;
  padding: 0;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

header > nav ul li small {
  max-width: 130px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

header > nav ul li button,
header > nav ul li a[role="button"],
header > nav ul li a {
  margin: 0 !important;
}

@media (max-width: 520px) {
  header.container {
    padding-inline: 0.5rem;
  }
  .brand {
    font-size: 0.95rem;
    gap: 0.25rem;
  }
  .brand-logo {
    width: 1.25rem;
    height: 1.25rem;
  }
  header > nav {
    padding-block: 0.4rem;
    gap: 0.25rem;
  }
  header > nav ul {
    gap: 0.35rem;
  }
  header > nav ul a[role="button"].btn-sm,
  header > nav ul button.btn-sm,
  header > nav ul a.btn-sm {
    padding: 0.25rem 0.5rem !important;
    font-size: 0.75rem !important;
    min-height: 28px !important;
    line-height: 1.2 !important;
    margin: 0 !important;
  }
  header > nav ul li small {
    display: none;
  }
  .lang-toggle {
    padding: 0.2rem 0.4rem !important;
    font-size: 0.75rem !important;
    line-height: 1.2 !important;
  }
}

@media (max-width: 480px) {
  /* On <=480px screens, hide secondary text link in nav so brand + CTA + lang switch fit without clipping */
  header > nav ul li a[href="/login"]:not([role="button"]),
  header > nav ul li:has(> a[href="/login"]:not([role="button"])) {
    display: none;
  }
  .brand {
    font-size: 0.9rem;
    gap: 0.2rem;
  }
  .brand-logo {
    width: 1.15rem;
    height: 1.15rem;
  }
}

.nav-full {
  display: inline;
}
.nav-short {
  display: none;
}
@media (max-width: 480px) {
  .nav-full {
    display: none;
  }
  .nav-short {
    display: inline;
  }
}

@media (max-width: 360px) {
  header.container {
    padding-inline: 0.25rem;
  }
  .brand {
    font-size: 0.82rem;
    gap: 0.15rem;
  }
  .brand-logo {
    width: 1rem;
    height: 1rem;
  }
  header > nav {
    gap: 0.15rem;
  }
  header > nav ul {
    gap: 0.15rem;
  }
  header > nav ul a[role="button"].btn-sm,
  header > nav ul button.btn-sm,
  header > nav ul a.btn-sm {
    padding: 0.15rem 0.2rem !important;
    font-size: 0.65rem !important;
    min-height: 22px !important;
    line-height: 1.1 !important;
  }
  .lang-toggle {
    padding: 0.12rem 0.2rem !important;
    font-size: 0.65rem !important;
    line-height: 1.1 !important;
  }
}

/* Language switch link */
.lang-toggle {
  color: var(--rh-color) !important;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.25rem 0.5rem;
  border-radius: var(--rh-border-radius);
  border: 1px solid var(--rh-muted-border-color);
  white-space: nowrap;
}

/* Footer */
footer.container {
  margin-top: 4rem;
  padding-block: 2rem;
  border-top: 1px solid var(--rh-muted-border-color);
  font-size: 0.85rem;
  color: var(--rh-muted-color);
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}
.footer-col {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.footer-col strong {
  color: var(--rh-color);
  font-size: 0.9rem;
}
.footer-col a {
  color: inherit;
  text-decoration: none;
}
.footer-col a:hover {
  text-decoration: underline;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--rh-muted-border-color);
  font-size: 0.8rem;
}
.footer-bottom a {
  color: var(--rh-muted-color);
  text-decoration: none;
}
.footer-bottom a:hover {
  color: var(--rh-color);
  text-decoration: underline;
}

/* Page header (h1 + action button) */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}
.page-header h1 {
  margin: 0;
}

/* Buttons — standard min-height for mobile touch ergonomics (44px min) */
button,
a[role="button"],
input[type="submit"],
input[type="button"] {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  text-decoration: none;
}

/* Buttons — small + danger variants */
.btn-sm,
button.btn-sm,
a[role="button"].btn-sm {
  min-height: 36px;
  padding: 0.3rem 0.75rem;
  font-size: 0.85rem;
}
.btn-danger,
button.btn-danger,
a[role="button"].btn-danger {
  background-color: #b91c1c !important;
  border-color: #b91c1c !important;
  color: #ffffff !important;
}
.btn-danger:is(:hover, :focus) {
  background-color: #991b1b !important;
  border-color: #991b1b !important;
}

/* Secondary outline danger button for high-consequence actions */
.btn-outline-danger,
button.btn-outline-danger,
a[role="button"].btn-outline-danger {
  background-color: transparent !important;
  border: 1px solid rgba(220, 38, 38, 0.6) !important;
  color: #dc2626 !important;
  transition: all 0.15s ease-in-out;
}
.btn-outline-danger:is(:hover, :focus) {
  background-color: #dc2626 !important;
  border-color: #dc2626 !important;
  color: #ffffff !important;
}

[data-theme="dark"] .btn-outline-danger,
[data-theme="dark"] button.btn-outline-danger,
[data-theme="dark"] a[role="button"].btn-outline-danger {
  color: #f87171 !important;
  border-color: rgba(248, 113, 113, 0.6) !important;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .btn-outline-danger,
  :root:not([data-theme="light"]) button.btn-outline-danger,
  :root:not([data-theme="light"]) a[role="button"].btn-outline-danger {
    color: #f87171 !important;
    border-color: rgba(248, 113, 113, 0.6) !important;
  }
}
/* The dark rules above come later than the hover rule and are as specific,
   so in the dark theme a hovered or focused button kept its light red text
   on the solid red fill, 1.75:1 (tests/state_contrast.rs). */
[data-theme="dark"] .btn-outline-danger:is(:hover, :focus) {
  color: #ffffff !important;
  border-color: #dc2626 !important;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .btn-outline-danger:is(:hover, :focus) {
    color: #ffffff !important;
    border-color: #dc2626 !important;
  }
}

/* An icon from components/icon.html. Its size and stroke are attributes on
   the <svg>, so it draws right before this sheet loads; here it sits on the
   text's baseline like a letter (the -0.125em centres a 1em icon on
   lowercase text) and never shrinks in a flex row. */
.icon {
  display: inline-block;
  vertical-align: -0.125em;
  flex: none;
  overflow: visible;
}

/* The design system page's list of every icon. */
.icon-catalog {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr));
  gap: 0.5rem 1rem;
}
.icon-catalog li {
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.icon-catalog code {
  font-size: 0.75rem;
}

/* Clean icon-based row removal button */
.btn-remove-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  min-height: 30px;
  padding: 0;
  margin: 0;
  border-radius: 6px;
  background: transparent;
  border: 1px solid transparent;
  color: var(--rh-muted-color);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  transition: all 0.15s ease-in-out;
}
.btn-remove-number:is(:hover, :focus-visible) {
  color: #dc2626;
  background-color: rgba(220, 38, 38, 0.1);
  border-color: rgba(220, 38, 38, 0.25);
  outline: none;
}

/* Inline alerts / notices */
.error,
.notice {
  padding: 0.75rem 1rem;
  border-radius: var(--rh-border-radius);
  margin-bottom: 1rem;
  font-size: 0.9rem;
  border: 1px solid;
}
.error {
  color: var(--rh-error-color);
  background: var(--rh-error-bg);
  border-color: var(--rh-error-border);
}
.notice-ok,
.notice-success {
  color: var(--rh-success-color);
  background: var(--rh-success-bg);
  border-color: var(--rh-success-border);
}
.notice-warn {
  color: var(--rh-warning-color);
  background: var(--rh-warning-bg);
  border-color: var(--rh-warning-border);
}

/* Universal Themed Badges & Pills */
/* A badge is a single-line label; in a flex row it would otherwise shrink
   and wrap ("PISOS Y / APARTAMENTOS") with room to spare. Not .hero-tag:
   that is a sentence-length tagline and must wrap on a phone. */
.badge,
.badge-brand,
.badge-ok,
.rh-badge {
  white-space: nowrap;
}

.badge,
.hero-tag,
.badge-brand,
.badge-ok,
.rh-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: var(--rh-card-background-color);
  color: var(--rh-color);
  border: 1px solid var(--rh-muted-border-color);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: all 0.2s ease;
  line-height: 1.2;
}

.hero-tag,
.badge-brand {
  border-color: color-mix(in srgb, var(--rh-primary) 35%, var(--rh-muted-border-color));
  background: color-mix(in srgb, var(--rh-primary) 6%, var(--rh-card-background-color));
}

.badge-off {
  background: var(--rh-muted-border-color);
  color: var(--rh-muted-color);
  border: 1px solid var(--rh-muted-border-color);
}

/* A short failure label ("Sync failed"); the message itself goes in an
   .error under it. Not .badge-off: its muted text on the dark theme's
   border colour is under 4.5:1. */
.badge-error {
  background: var(--rh-error-bg);
  color: var(--rh-error-color);
  border: 1px solid var(--rh-error-border);
}

.hero-tag {
  margin-bottom: 1rem;
}

.hero-tag::before,
.badge-brand::before,
.badge-ok::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--rh-primary);
  box-shadow: 0 0 6px var(--rh-primary);
  flex-shrink: 0;
}

.badge-ok::before {
  background: #16a34a;
  box-shadow: 0 0 6px rgba(22, 163, 74, 0.6);
}

/* Misc text helpers */
.meta {
  display: block;
  font-size: 0.9rem;
  color: var(--rh-muted-color);
  margin-bottom: 0.75rem;
  line-height: 1.4;
}
.empty {
  color: var(--rh-muted-color);
  font-style: italic;
  font-size: 0.9rem;
}
.hint {
  display: block;
  font-size: 0.8rem;
  color: var(--rh-muted-color);
  margin-top: 0.35rem;
  margin-bottom: 0.75rem;
  line-height: 1.35;
}

/* Hero Section with Ambient Backdrop Depth */
.hero {
  position: relative;
  text-align: center;
  padding-block: 2.5rem 1.5rem;
}

.hero::before {
  content: '';
  position: absolute;
  top: -30px;
  left: 50%;
  transform: translateX(-50%);
  width: min(850px, 95vw);
  height: 380px;
  background: radial-gradient(ellipse at center, color-mix(in srgb, var(--rh-primary) 14%, transparent) 0%, color-mix(in srgb, var(--rh-primary) 3%, transparent) 55%, transparent 75%);
  pointer-events: none;
  z-index: -1;
  filter: blur(45px);
}

.hero h1 {
  font-size: clamp(1.95rem, 4.5vw, 2.65rem);
  line-height: 1.15;
  margin-bottom: 1rem;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.hero h1 .hero-line {
  display: inline-block;
  text-wrap: balance;
}

.hero p.lead {
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  color: var(--rh-muted-color);
  max-width: 680px;
  margin-inline: auto;
  margin-bottom: 1.5rem;
  line-height: 1.5;
  text-wrap: balance;
}

.hero-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 0.85rem;
}

.hero-trust {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  margin-bottom: 2rem;
}

/* Interactive Hero Visual Simulator Card */
.hero-visual-card {
  max-width: 820px;
  margin: 0 auto;
  text-align: left;
  background: var(--rh-card-background-color);
  border: 1px solid color-mix(in srgb, var(--rh-muted-border-color) 70%, var(--rh-primary) 30%);
  border-radius: 1.25rem;
  padding: 1.25rem 1.5rem;
  box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.08), 0 20px 40px -15px color-mix(in srgb, var(--rh-primary) 15%, transparent);
  position: relative;
  overflow: hidden;
}

[data-theme="dark"] .hero-visual-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%), var(--rh-card-background-color);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 15px 40px -10px rgba(0, 0, 0, 0.7), 0 0 1px 1px color-mix(in srgb, var(--rh-primary) 30%, transparent);
}

/* Simulator Card Header */
.sim-card-banner {
  margin-bottom: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
}

.sim-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.2rem 0.55rem;
  border-radius: 9999px;
  background: color-mix(in srgb, var(--rh-primary) 12%, transparent);
  color: var(--rh-primary);
  border: 1px solid color-mix(in srgb, var(--rh-primary) 30%, transparent);
  margin-bottom: 0.35rem;
}

.sim-badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--rh-primary);
}

.sim-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0 0 0.25rem;
  color: var(--rh-color);
}

.sim-card-subtitle {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  margin: 0;
  line-height: 1.4;
}

.hero-visual-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding-bottom: 1rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
}

.hero-visual-status {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--rh-color);
  padding: 0.35rem 0.9rem;
  border-radius: 9999px;
  background: color-mix(in srgb, var(--rh-muted-border-color) 25%, var(--rh-card-background-color));
  border: 1px solid var(--rh-muted-border-color);
  margin-top: 0.75rem;
  width: fit-content;
  max-width: 100%;
  transition: all 0.25s ease;
}

.hero-visual-status.is-ringing {
  border-color: rgba(34, 197, 94, 0.5);
  background: color-mix(in srgb, #22c55e 12%, var(--rh-card-background-color));
}

.hero-visual-status.is-answered {
  border-color: color-mix(in srgb, var(--rh-primary) 50%, transparent);
  background: color-mix(in srgb, var(--rh-primary) 12%, var(--rh-card-background-color));
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  background: transparent;
  border: 1.5px solid var(--rh-muted-color);
  opacity: 0.7;
  transition: all 0.2s ease;
}

.live-dot.pulse-ringing {
  background: #22c55e;
  border-color: #22c55e;
  opacity: 1;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
  animation: pulse-ring 1.5s infinite cubic-bezier(0.66, 0, 0, 1);
}

.live-dot.pulse-active {
  background: var(--rh-primary);
  border-color: var(--rh-primary);
  opacity: 1;
  box-shadow: 0 0 10px var(--rh-primary);
}

@keyframes pulse-ring {
  0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7); }
  70% { box-shadow: 0 0 0 10px rgba(34, 197, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.sim-actions-group {
  display: inline-flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
}

.sim-mode-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.38rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 700;
  border-radius: 9999px;
  margin: 0;
  border: 1px solid color-mix(in srgb, var(--rh-primary) 35%, var(--rh-muted-border-color));
  background: color-mix(in srgb, var(--rh-primary) 8%, var(--rh-card-background-color));
  color: var(--rh-primary);
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1.2;
}

/* Filled as the primary buttons are. `--rh-primary` is the text teal, light
   in the dark theme: as a fill under white text it read 1.86:1 there
   (tests/state_contrast.rs). */
.sim-mode-btn:hover {
  background: var(--rh-primary-background);
  color: var(--rh-primary-inverse);
  box-shadow: 0 2px 8px color-mix(in srgb, var(--rh-primary) 25%, transparent);
}

.sim-mode-btn.active {
  background: var(--rh-primary-background);
  color: var(--rh-primary-inverse);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--rh-primary) 25%, transparent);
}

.btn-sim-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.85rem;
  font-size: 0.76rem;
  font-weight: 700;
  border-radius: 9999px;
  margin: 0;
  width: auto;
  cursor: pointer;
  background: color-mix(in srgb, var(--rh-muted-border-color) 35%, transparent);
  color: var(--rh-muted-color);
  border: 1px solid var(--rh-muted-border-color);
  transition: all 0.2s ease;
}

.btn-sim-toggle:hover {
  background: var(--rh-muted-color);
  color: var(--rh-card-background-color);
}

.hero-visual-grid {
  display: grid;
  grid-template-columns: 1fr auto 1.2fr auto 1.8fr;
  align-items: center;
  gap: 0.75rem;
}

@media (max-width: 768px) {
  .hero-visual-card {
    padding: 1rem 0.85rem;
  }
  .hero-visual-header {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }
  .sim-actions-group {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    gap: var(--rh-space-block);
  }
  /* Side by side when both labels fit on one line, otherwise one per line
     at full width; never two squeezed halves with wrapped labels. */
  .sim-mode-btn {
    flex: 1 1 auto;
    white-space: nowrap;
    justify-content: center;
    text-align: center;
    padding: 0.5rem 0.5rem;
    font-size: 0.76rem;
  }
  .btn-sim-toggle {
    width: 100%;
    text-align: center;
    justify-content: center;
    padding: 0.45rem 1rem;
  }
  .hero-visual-status {
    display: flex;
    justify-content: center;
    text-align: center;
    margin: 0.65rem auto 0 auto;
    font-size: 0.76rem;
    padding: 0.35rem 0.75rem;
    line-height: 1.35;
  }
  .hero-visual-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
  .visual-node {
    justify-content: center;
    text-align: center;
  }
  .visual-arrow {
    transform: rotate(90deg);
    display: flex;
    align-items: center;
    justify-content: center;
    justify-self: center;
    margin: -0.2rem auto;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: color-mix(in srgb, var(--rh-muted-border-color) 40%, transparent);
    border: 1px solid var(--rh-muted-border-color);
  }
  .phone-item {
    padding: 0.6rem 0.75rem;
  }
}

.visual-node {
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 0.75rem;
  padding: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.node-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.node-meta {
  display: flex;
  flex-direction: column;
}

.node-meta strong {
  font-size: 0.8rem;
  color: var(--rh-color);
  line-height: 1.2;
}

.node-meta span {
  font-size: 0.75rem;
  color: var(--rh-muted-color);
  font-family: 'JetBrains Mono', monospace;
}

.visual-arrow {
  color: var(--rh-muted-color);
  opacity: 0.6;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.visual-hub {
  background: color-mix(in srgb, var(--rh-primary) 10%, var(--rh-card-background-color));
  border: 1.5px solid var(--rh-primary);
  border-radius: 0.85rem;
  padding: 0.85rem;
  text-align: center;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--rh-primary) 20%, transparent);
}

.hub-badge strong {
  display: block;
  font-size: 0.85rem;
  color: var(--rh-primary);
  font-weight: 800;
}

.hub-number {
  font-size: 0.75rem;
  font-family: 'JetBrains Mono', monospace;
  color: var(--rh-color);
  margin-top: 0.2rem;
  font-weight: 600;
}

.visual-phones {
  display: flex;
  flex-direction: column;
  gap: var(--rh-space-block);
}

.phone-item {
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 0.6rem;
  padding: 0.45rem 0.65rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.phone-item:hover {
  border-color: var(--rh-primary);
}

.phone-item.ringing {
  border-color: #22c55e;
  background: color-mix(in srgb, #22c55e 12%, var(--rh-card-background-color));
  animation: ring-pulse 1s infinite alternate ease-in-out;
}

@keyframes ring-pulse {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
  100% { transform: scale(1.02); box-shadow: 0 0 10px 2px rgba(34, 197, 94, 0.3); }
}

.phone-item.answered {
  border-color: var(--rh-primary);
  background: color-mix(in srgb, var(--rh-primary) 15%, var(--rh-card-background-color));
  box-shadow: 0 0 12px color-mix(in srgb, var(--rh-primary) 25%, transparent);
}

.phone-item.muted {
  opacity: 0.45;
  filter: grayscale(0.5);
}

.phone-avatar {
  font-size: 1.1rem;
}

.phone-info {
  display: flex;
  flex-direction: column;
}

.phone-info strong {
  font-size: 0.78rem;
  color: var(--rh-color);
  line-height: 1.2;
}

.phone-status {
  font-size: 0.7rem;
  color: var(--rh-muted-color);
}

.phone-item.ringing .phone-status {
  color: #16a34a;
  font-weight: 700;
}

.phone-item.answered .phone-status {
  color: var(--rh-primary);
  font-weight: 700;
}

/* Section Header Depth & Tightened Whitespace */
.section-header {
  text-align: center;
  margin-top: 2.75rem;
  margin-bottom: 1.75rem;
}
.section-header h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.1rem);
  margin-top: 0.5rem;
  margin-bottom: 0.35rem;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.section-header p {
  color: var(--rh-muted-color);
  font-size: 1rem;
  max-width: 580px;
  margin-inline: auto;
  text-wrap: balance;
}

/* Solution Cards Grid with Layered Depth */
.solutions-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.75rem;
  margin-bottom: 1.5rem;
}
@media (min-width: 680px) {
  .solutions-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  /* An odd card out (the developers card) spans its row rather than sit
     alone in half of it. Test: home_solution_cards_fill_every_row_of_their_grid. */
  .solutions-grid > .solution-card:last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }
}

.solutions-extra-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 0.25rem;
  margin-bottom: 3.25rem;
}
@media (min-width: 680px) {
  .solutions-extra-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.solutions-extra-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 0.85rem;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
  transition: border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

[data-theme="dark"] .solutions-extra-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02) 0%, rgba(255, 255, 255, 0) 100%), var(--rh-card-background-color);
  border-color: rgba(255, 255, 255, 0.08);
}

.solutions-extra-card:hover {
  border-color: var(--rh-primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px -4px color-mix(in srgb, var(--rh-primary) 15%, transparent);
}

.solutions-extra-icon {
  font-size: 1.6rem;
  line-height: 1;
  flex-shrink: 0;
}

.solutions-extra-body {
  flex-grow: 1;
  min-width: 0;
}

.solutions-extra-title {
  display: block;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--rh-color);
  line-height: 1.3;
}

.solutions-extra-desc {
  display: block;
  font-size: 0.8rem;
  color: var(--rh-muted-color);
  line-height: 1.3;
  margin-top: 0.15rem;
}

.solutions-extra-arrow {
  color: var(--rh-primary);
  font-weight: 700;
  font-size: 1.1rem;
  flex-shrink: 0;
  transition: transform 0.15s ease;
}

.solutions-extra-card:hover .solutions-extra-arrow {
  transform: translateX(3px);
}

.solution-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 2.25rem 2rem;
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 1.25rem;
  background: var(--rh-card-background-color);
  text-decoration: none;
  color: inherit;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.04), 0 10px 20px -5px rgba(0, 0, 0, 0.03);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease, box-shadow 0.2s ease;
  position: relative;
  overflow: hidden;
}

[data-theme="dark"] .solution-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0) 100%), var(--rh-card-background-color);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 10px 25px -10px rgba(0, 0, 0, 0.5);
}

.solution-card:hover {
  transform: translateY(-4px);
  border-color: var(--rh-primary);
  box-shadow: 0 14px 30px -5px color-mix(in srgb, var(--rh-primary) 18%, transparent), 0 4px 10px rgba(0, 0, 0, 0.05);
}

.solution-card-header {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.85rem;
}
.solution-icon {
  font-size: 2.2rem;
  margin-bottom: 0;
  display: inline-block;
  line-height: 1;
}
.solution-card h3 {
  font-size: 1.35rem;
  margin-top: 0.25rem;
  margin-bottom: 0.65rem;
  letter-spacing: -0.02em;
}
.solution-card p {
  font-size: 0.98rem;
  color: var(--rh-muted-color);
  margin-bottom: 1.5rem;
  line-height: 1.6;
  flex-grow: 1;
}
.solution-card-cta {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--rh-primary);
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

/* Flow diagram container with Layered Depth */
.flow-diagram {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 1.25rem;
  padding: 2rem 1.75rem;
  margin-block: 2.25rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.04), 0 10px 25px -5px rgba(0, 0, 0, 0.03);
}

[data-theme="dark"] .flow-diagram {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0) 100%), var(--rh-card-background-color);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.5);
}

.flow-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.25rem;
  position: relative;
}
.flow-step {
  text-align: center;
  padding: 1.25rem 1rem;
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 0.85rem;
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.flow-step:hover {
  transform: translateY(-2px);
  border-color: var(--rh-primary);
}
.flow-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--rh-primary);
  color: var(--rh-primary-inverse);
  font-weight: 800;
  font-size: 1.05rem;
  margin-bottom: 0.85rem;
  box-shadow: 0 0 12px color-mix(in srgb, var(--rh-primary) 30%, transparent);
}
/* An h3 under the section's h2, styled as the h4 it used to be: the body
   font, not the display font each data-rh-font theme gives h3. */
.flow-diagram .flow-step h3 {
  font-family: inherit;
  font-weight: 700;
  font-variation-settings: normal;
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
  letter-spacing: -0.01em;
}
.flow-step p {
  font-size: 0.88rem;
  color: var(--rh-muted-color);
  margin: 0;
  line-height: 1.4;
}

/* Comparison Table (Desktop) & Comparison Cards (Mobile) */
.comparison-container,
.comparison-desktop {
  display: block;
  overflow-x: auto;
  margin-block: 2rem;
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 1.25rem;
  background: var(--rh-card-background-color);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.04), 0 10px 25px -5px rgba(0, 0, 0, 0.03);
}
table.comparison-table {
  width: 100%;
  margin-bottom: 0;
  border-collapse: collapse;
}
table.comparison-table th,
table.comparison-table td {
  padding: 1rem;
  text-align: left;
  vertical-align: middle;
}
table.comparison-table th.highlight,
table.comparison-table td.highlight {
  background: rgba(var(--rh-primary-rgb, 59, 130, 246), 0.05);
  font-weight: 600;
}

.comparison-mobile {
  display: none;
  margin-block: 1.5rem;
}

@media (max-width: 767px) {
  .comparison-desktop {
    display: none;
  }
  .comparison-mobile {
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }
}

.comparison-card {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  padding: 1.25rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.comparison-card-title {
  font-size: 1rem;
  color: var(--rh-h2-color);
  border-bottom: 1px solid var(--rh-muted-border-color);
  padding-bottom: 0.5rem;
  margin-bottom: 0.75rem;
}

.comparison-card-items {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.comparison-card-winner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.6rem 0.85rem;
  border-radius: var(--rh-border-radius);
  background: rgba(234, 88, 12, 0.08);
  border: 1px solid var(--rh-primary);
}

.comparison-brand-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 700;
  color: var(--rh-primary);
  font-size: 0.85rem;
}

.comparison-val-win {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--rh-color);
}

.comparison-card-alt {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0.35rem 0.5rem;
  font-size: 0.85rem;
  color: var(--rh-muted-color);
}

.comparison-alt-label {
  font-weight: 500;
}

.comparison-alt-val {
  font-weight: 600;
  color: var(--rh-color);
}

/* Pricing Grid with Layered Depth */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-block: 2.25rem;
}
.pricing-card {
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 1.25rem;
  background: var(--rh-card-background-color);
  padding: 2.25rem 1.75rem;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.04), 0 10px 25px -5px rgba(0, 0, 0, 0.03);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, border-color 0.2s ease;
}

[data-theme="dark"] .pricing-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0) 100%), var(--rh-card-background-color);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.5);
}

.pricing-card:hover {
  transform: translateY(-4px);
  border-color: var(--rh-primary);
  box-shadow: 0 16px 35px -5px color-mix(in srgb, var(--rh-primary) 18%, transparent), 0 4px 10px rgba(0, 0, 0, 0.05);
}

.pricing-card.featured {
  border: 2px solid var(--rh-primary);
  box-shadow: 0 8px 30px -5px color-mix(in srgb, var(--rh-primary) 22%, transparent);
}
.pricing-badge {
  position: absolute;
  top: -12px;
  right: 1.5rem;
}
.pricing-header h3 {
  font-size: 1.35rem;
  margin-bottom: 0.25rem;
  text-wrap: balance;
}
.pricing-header p {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  margin-bottom: 1rem;
}
.pricing-price {
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.25rem;
}
.pricing-price .period {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--rh-muted-color);
}
.pricing-subprice {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  margin-bottom: 1.5rem;
}
.pricing-features {
  list-style: none;
  padding: 0;
  margin: 0 0 2rem;
  flex-grow: 1;
}
.pricing-features li {
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--rh-muted-border-color);
  font-size: 0.92rem;
  display: flex;
  align-items: baseline;
  gap: 0.65rem;
}
.pricing-features li:last-child {
  border-bottom: none;
}
.pricing-features li > span:not(.check) {
  flex: 1;
  line-height: 1.45;
  hyphens: none;
  word-break: normal;
}
.pricing-features .check {
  color: var(--rh-primary);
  font-weight: 700;
  flex-shrink: 0;
}
.pricing-note {
  font-size: 0.8rem;
  text-align: center;
  color: var(--rh-muted-color);
  margin-top: 1rem;
}

/* FAQ Details */
.faq-section {
  margin-block: 3rem;
}
.faq-item {
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  margin-bottom: 0.75rem;
  background: var(--rh-card-background-color);
}
.faq-item summary {
  padding: 1rem 1.25rem;
  font-weight: 600;
  font-size: 1.05rem;
  cursor: pointer;
}
.faq-item summary:focus {
  outline: none;
}
.faq-item summary:focus-visible {
  outline: 2px solid var(--rh-primary);
  outline-offset: 2px;
}
.faq-content {
  padding: 0 1.25rem 1.25rem;
  font-size: 0.95rem;
  color: var(--rh-color);
  line-height: 1.5;
}

/* Number list inside cards */
.number-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.number-list li {
  display: flex;
  align-items: center;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 8px;
  background: var(--rh-card-background-color);
  font-size: 0.95rem;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.number-list li:hover {
  border-color: var(--rh-primary);
}
.number-list li:last-child {
  /* inherit card border */
}

/* Ring group number selection pagination row */
.rg-pagination-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: nowrap;
  margin-top: 0.75rem;
  padding: 0.25rem 0;
}
.rg-pagination-row button {
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  min-height: 36px !important;
  padding: 0.35rem 0.65rem !important;
  font-size: 0.85rem !important;
  margin: 0 !important;
  transition: opacity 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.rg-pagination-row button:disabled,
.rg-pagination-row button[disabled] {
  opacity: 0.35 !important;
  color: var(--rh-muted-color) !important;
  border-color: var(--rh-muted-border-color) !important;
  background-color: transparent !important;
  cursor: not-allowed !important;
  pointer-events: none !important;
}
.rg-pagination-info {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  font-weight: 600;
  white-space: nowrap;
  text-align: center;
  flex-shrink: 1;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Typeahead match highlight */
mark.rg-match-highlight,
.rg-match-highlight {
  background: color-mix(in srgb, var(--rh-primary) 18%, transparent);
  color: var(--rh-primary);
  font-weight: 800;
  border-radius: 3px;
  padding: 0.05rem 0.2rem;
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--rh-primary) 32%, transparent);
}

/* Inline form row: input + button side-by-side */
.row,
.input-action-row {
  display: flex;
  gap: 0.5rem;
  align-items: stretch;
  margin-bottom: 0;
}
.row > *,
.input-action-row > * {
  margin-bottom: 0 !important;
}
.row input,
.row select,
.input-action-row input,
.input-action-row select {
  flex: 1;
  margin-bottom: 0 !important;
  min-height: 44px;
}
.row button,
.row [role="button"],
.input-action-row button,
.input-action-row [role="button"] {
  margin-bottom: 0 !important;
  min-height: 44px;
  white-space: nowrap;
}

/* Articles used as cards */
article {
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.25rem;
}
article > header,
article > footer {
  padding: 0.5rem 0;
  margin: 0 0 0.75rem;
  background: none;
  border-bottom: 1px solid var(--rh-muted-border-color);
}
article > footer {
  margin: 0.75rem 0 0;
  border-bottom: none;
  border-top: 1px solid var(--rh-muted-border-color);
}

/* Compact form spacing */
form label {
  margin-bottom: 0.25rem;
}
form input,
form select {
  margin-bottom: 0.75rem;
}

button[type="submit"],
button[type="button"],
button[type="reset"],
input[type="submit"],
input[type="button"],
input[type="reset"] {
  margin-bottom: 0;
}

/* ==========================================================================
   Dynamic Brand Themes & Typography
   ========================================================================== */

/* Logo styling */
.brand-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  color: var(--rh-primary);
  flex-shrink: 0;
}
.brand-logo svg {
  width: 100%;
  height: 100%;
}

/* Default heading typography is Fraunces (zero font-flash on hard reload) */
h1, h2, h3, .brand strong, .hero h1, .section-header h2 {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 800;
  font-optical-sizing: auto;
  font-variation-settings: "opsz" 72, "wght" 800, "SOFT" 0, "WONK" 0;
  letter-spacing: -0.03em;
}

h1, .hero h1 {
  line-height: 1.12;
  letter-spacing: -0.035em;
  font-weight: 800;
}

h2, .section-header h2 {
  line-height: 1.2;
  letter-spacing: -0.025em;
  font-weight: 700;
}

[data-rh-font="space"] h1,
[data-rh-font="space"] h2,
[data-rh-font="space"] h3,
[data-rh-font="space"] .brand strong,
[data-rh-font="space"] .hero h1,
[data-rh-font="space"] .section-header h2 {
  font-family: 'Space Grotesk', -apple-system, sans-serif;
  font-weight: 700;
  letter-spacing: -0.025em;
}

[data-rh-font="system"] h1,
[data-rh-font="system"] h2,
[data-rh-font="system"] h3,
[data-rh-font="system"] .brand strong,
[data-rh-font="system"] .hero h1,
[data-rh-font="system"] .section-header h2 {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* Palette: Rotary Orange */
[data-rh-theme="rotary"],
:root[data-rh-theme="rotary"],
html[data-rh-theme="rotary"] {
  --rh-primary: #ea580c !important;
  --rh-primary-background: #ea580c !important;
  --rh-primary-border: #ea580c !important;
  --rh-primary-hover: #c2410c !important;
  --rh-primary-hover-background: #c2410c !important;
  --rh-primary-hover-border: #c2410c !important;
  --rh-primary-focus: rgba(234, 88, 12, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(234, 88, 12, 0.5) !important;
}

/* Palette: Signal Flare (High-Vis Safety Orange) */
[data-rh-theme="flare"],
:root[data-rh-theme="flare"],
html[data-rh-theme="flare"] {
  --rh-primary: #ff5400 !important;
  --rh-primary-background: #ff5400 !important;
  --rh-primary-border: #ff5400 !important;
  --rh-primary-hover: #e04800 !important;
  --rh-primary-hover-background: #e04800 !important;
  --rh-primary-hover-border: #e04800 !important;
  --rh-primary-focus: rgba(255, 84, 0, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(255, 84, 0, 0.5) !important;
}

/* Palette: Sunset Persimmon (California Warmth) */
[data-rh-theme="persimmon"],
:root[data-rh-theme="persimmon"],
html[data-rh-theme="persimmon"] {
  --rh-primary: #f97316 !important;
  --rh-primary-background: #f97316 !important;
  --rh-primary-border: #f97316 !important;
  --rh-primary-hover: #ea580c !important;
  --rh-primary-hover-background: #ea580c !important;
  --rh-primary-hover-border: #ea580c !important;
  --rh-primary-focus: rgba(249, 115, 22, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(249, 115, 22, 0.5) !important;
}

/* Palette: Burnt Terracotta (Architectural Clay) */
[data-rh-theme="terracotta"],
:root[data-rh-theme="terracotta"],
html[data-rh-theme="terracotta"] {
  --rh-primary: #c2410c !important;
  --rh-primary-background: #c2410c !important;
  --rh-primary-border: #c2410c !important;
  --rh-primary-hover: #9a3412 !important;
  --rh-primary-hover-background: #9a3412 !important;
  --rh-primary-hover-border: #9a3412 !important;
  --rh-primary-focus: rgba(194, 65, 12, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(194, 65, 12, 0.5) !important;
}

/* Palette: Telegraph Emerald */
[data-rh-theme="emerald"],
:root[data-rh-theme="emerald"],
html[data-rh-theme="emerald"] {
  --rh-primary: #047857 !important;
  --rh-primary-background: #047857 !important;
  --rh-primary-border: #047857 !important;
  --rh-primary-hover: #065f46 !important;
  --rh-primary-hover-background: #065f46 !important;
  --rh-primary-hover-border: #065f46 !important;
  --rh-primary-focus: rgba(4, 120, 87, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(4, 120, 87, 0.5) !important;
}

/* Palette: Deep Ocean Teal */
[data-rh-theme="ocean"],
:root[data-rh-theme="ocean"],
html[data-rh-theme="ocean"] {
  --rh-primary: #0f766e !important;
  --rh-primary-background: #0f766e !important;
  --rh-primary-border: #0f766e !important;
  --rh-primary-hover: #115e59 !important;
  --rh-primary-hover-background: #115e59 !important;
  --rh-primary-hover-border: #115e59 !important;
  --rh-primary-focus: rgba(15, 118, 110, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(15, 118, 110, 0.5) !important;
}

/* Palette: Glacial Spruce */
[data-rh-theme="spruce"],
:root[data-rh-theme="spruce"],
html[data-rh-theme="spruce"] {
  --rh-primary: #155e75 !important;
  --rh-primary-background: #155e75 !important;
  --rh-primary-border: #155e75 !important;
  --rh-primary-hover: #164e63 !important;
  --rh-primary-hover-background: #164e63 !important;
  --rh-primary-hover-border: #164e63 !important;
  --rh-primary-focus: rgba(21, 94, 117, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(21, 94, 117, 0.5) !important;
}

/* Palette: Phosphor Cyan */
[data-rh-theme="cyan"],
:root[data-rh-theme="cyan"],
html[data-rh-theme="cyan"] {
  --rh-primary: #0891b2 !important;
  --rh-primary-background: #0891b2 !important;
  --rh-primary-border: #0891b2 !important;
  --rh-primary-hover: #0e7490 !important;
  --rh-primary-hover-background: #0e7490 !important;
  --rh-primary-hover-border: #0e7490 !important;
  --rh-primary-focus: rgba(8, 145, 178, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(8, 145, 178, 0.5) !important;
}

/* Palette: Signal Mint (Accessible Deep Mint / Teal) */
[data-rh-theme="mint"],
:root[data-rh-theme="mint"],
html[data-rh-theme="mint"] {
  --rh-primary: #0f766e !important;
  --rh-primary-background: #0f766e !important;
  --rh-primary-border: #0f766e !important;
  --rh-primary-hover: #115e59 !important;
  --rh-primary-hover-background: #115e59 !important;
  --rh-primary-hover-border: #115e59 !important;
  --rh-primary-focus: rgba(15, 118, 110, 0.25) !important;
  --rh-primary-inverse: #ffffff !important;
  --rh-primary-underline: rgba(15, 118, 110, 0.5) !important;
}
[data-theme="dark"][data-rh-theme="mint"],
:root[data-theme="dark"][data-rh-theme="mint"],
html[data-theme="dark"][data-rh-theme="mint"] {
  --rh-primary: #2dd4bf !important;
  --rh-primary-hover: #5eead4 !important;
}
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"])[data-rh-theme="mint"] {
    --rh-primary: #2dd4bf !important;
    --rh-primary-hover: #5eead4 !important;
  }
}

/* Palette: Seafoam Signal (#16baae) */
[data-rh-theme="seafoam"],
:root[data-rh-theme="seafoam"],
html[data-rh-theme="seafoam"] {
  --rh-primary: #0d9488 !important;
  --rh-primary-background: #16baae !important;
  --rh-primary-border: #16baae !important;
  --rh-primary-hover: #12a399 !important;
  --rh-primary-hover-background: #12a399 !important;
  --rh-primary-hover-border: #12a399 !important;
  --rh-primary-focus: rgba(22, 186, 174, 0.25) !important;
  --rh-primary-inverse: #042f2e !important;
  --rh-primary-underline: rgba(22, 186, 174, 0.5) !important;
}
[data-theme="dark"][data-rh-theme="seafoam"],
:root[data-theme="dark"][data-rh-theme="seafoam"],
html[data-theme="dark"][data-rh-theme="seafoam"] {
  --rh-primary: #16baae !important;
}

/* Palette: Electric Aqua (#23cfc3) */
[data-rh-theme="aqua"],
:root[data-rh-theme="aqua"],
html[data-rh-theme="aqua"] {
  --rh-primary: #0d9488 !important;
  --rh-primary-background: #23cfc3 !important;
  --rh-primary-border: #23cfc3 !important;
  --rh-primary-hover: #1ab3a8 !important;
  --rh-primary-hover-background: #1ab3a8 !important;
  --rh-primary-hover-border: #1ab3a8 !important;
  --rh-primary-focus: rgba(35, 207, 195, 0.25) !important;
  --rh-primary-inverse: #042f2e !important;
  --rh-primary-underline: rgba(35, 207, 195, 0.5) !important;
}
[data-theme="dark"][data-rh-theme="aqua"],
:root[data-theme="dark"][data-rh-theme="aqua"],
html[data-theme="dark"][data-rh-theme="aqua"] {
  --rh-primary: #23cfc3 !important;
}

/* Prevent horizontal overflow during copy expansion.
   overflow-wrap only breaks a word that would otherwise overflow. Do not add
   `word-break: break-word` here: it also makes every word count as breakable
   when tables and flex items size themselves, so a table column shrinks below
   its words and splits them ("Create|d", "Remo|ve"), with room to spare. */
h1, h2, h3, h4, p, article, .flow-step, .solution-card, .pricing-card {
  overflow-wrap: break-word;
}

.nowrap { white-space: nowrap; }
/* A long address (a webhook URL) on one line, cut short with an ellipsis
   rather than widen a phone screen; the element's title has all of it. */
.one-line {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Data tables (call history, transactions) sit in a <figure>. Dates, numbers
   and amounts never wrap, so on a narrow phone the table scrolls sideways
   inside its figure instead of widening the page. */
figure {
  margin: 0 0 1rem;
  overflow-x: auto;
}

/* Short lists inside a card (passkeys, API keys): the name and its details
   on the left, the action on the right. Rows rather than table columns: the
   account card is too narrow for a multi-column table at any viewport. */
.item-list {
  list-style: none;
  padding: 0;
  margin-left: 0;
}
.item-list > li {
  list-style: none;
  margin: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--rh-muted-border-color);
}
.item-list > li:first-child {
  border-top: 1px solid var(--rh-muted-border-color);
}
.item-list .item-main {
  /* Below 14rem the name and dates would squeeze into a narrow column
     beside the button; the button moves to the next line instead. */
  flex: 1 1 14rem;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.item-list .item-meta {
  color: var(--rh-muted-color);
  font-size: 0.85rem;
}
.item-list > li > form {
  flex-shrink: 0;
}

/* ==========================================================================
   Semantic Design Tokens & Reusable Component Classes (.rh-*)
   ========================================================================== */
.rh-card {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  box-shadow: var(--rh-box-shadow);
  padding: 1.5rem;
  /* Its parts (the simulator's header, callbox and phones) are a stack. */
  display: flex;
  flex-direction: column;
  gap: var(--rh-space-md);
}

.rh-card-highlight {
  border-color: var(--rh-primary) !important;
  border-width: 2px;
}

.rh-mono {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
}

.rh-font-heading {
  font-family: var(--rh-font-heading, inherit);
}

.rh-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: 9999px;
  background: var(--rh-background-color);
  color: var(--rh-color);
  border: 1px solid var(--rh-muted-border-color);
}

.rh-badge-accent {
  background: rgba(234, 88, 12, 0.12);
  color: var(--rh-primary);
  border-color: var(--rh-primary);
}

.rh-badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--rh-primary);
}

.rh-badge-dot-active {
  background: #22c55e;
}

.rh-phone-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  border-radius: var(--rh-border-radius);
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
}

.rh-phone-val {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--rh-primary);
}

/* ─── iOS-Inspired App Patterns & Tiered Routing Canvas ───────────────────── */

/* iOS Segmented Control (WCAG 2.1 AA & Keyboard Nav Compliant) */
.ios-segmented-control {
  display: flex;
  background: var(--rh-card-background-color, #f1f5f9);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 12px;
  padding: 4px;
  gap: 4px;
  margin: 0 0 1rem 0;
  width: 100%;
  max-width: 480px;
}

.segment-option {
  flex: 1;
  margin: 0;
  position: relative;
  cursor: pointer;
  display: flex;
}

.segment-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

.segment-label {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.55rem 0.85rem;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--rh-muted-color);
  background: transparent;
  transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  min-height: 44px;
  text-align: center;
  user-select: none;
}

.segment-option:hover .segment-label {
  color: var(--rh-color);
}

.segment-option.active .segment-label,
.segment-option input:checked + .segment-label {
  background: var(--rh-background-color, #ffffff);
  color: var(--rh-color, #0f172a);
  font-weight: 700;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.08);
}

.segment-option input:focus-visible + .segment-label {
  outline: 2px solid var(--rh-primary);
  outline-offset: 2px;
}

/* Escalation Flow Timeline */
.tier-flow-timeline {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.75rem 1rem;
  background: var(--rh-background-color);
  border: 1px dashed var(--rh-muted-border-color);
  border-radius: 10px;
  margin: 0.75rem 0 1.25rem;
  overflow-x: auto;
  font-size: 0.82rem;
}

.tier-flow-timeline .flow-step {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  font-weight: 600;
}

.tier-flow-timeline .flow-meta {
  font-size: 0.75rem;
  color: var(--rh-muted-color);
  font-weight: 500;
}

.tier-flow-timeline .flow-arrow {
  color: var(--rh-muted-color);
  font-size: 0.85rem;
  flex-shrink: 0;
}

/* Grouped Inset Section (iOS TableView style) */
.tier-inset-section {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 12px;
  margin-bottom: 0.85rem;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.tier-inset-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65rem 1rem;
  background: rgba(125, 125, 125, 0.04);
  border-bottom: 1px solid var(--rh-muted-border-color);
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tier-title-group {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.tier-header-desc {
  font-size: 0.8rem;
  color: var(--rh-muted-color);
}

/* Badges for Tiers with WCAG AA/AAA High Contrast */
.tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  letter-spacing: 0.01em;
}

/* Step badges. One rule per step: these were defined twice, and the later
   colours won while this block's borders still applied, so step 1 showed a
   blue badge with an orange border. */
.tier-1-badge {
  background: #e3f2fd;
  color: #0d47a1;
  border: 1px solid #90caf9;
}

/* #e65100 on #fff3e0 is 3.45:1; #bf360c is 5.1:1 (WCAG AA needs 4.5:1). */
.tier-2-badge {
  background: #fff3e0;
  color: #bf360c;
  border: 1px solid #ffb74d;
}

.tier-3-badge {
  background: #fce4ec;
  color: #880e4f;
  border: 1px solid #f48fb1;
}

.tier-sim-badge {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #86efac;
}

[data-theme="dark"] .tier-1-badge {
  background: #0d47a1;
  color: #e3f2fd;
  border-color: #0d47a1;
}

[data-theme="dark"] .tier-2-badge {
  background: #bf360c;
  color: #fff3e0;
  border-color: #bf360c;
}

[data-theme="dark"] .tier-3-badge {
  background: #880e4f;
  color: #fce4ec;
  border-color: #880e4f;
}

[data-theme="dark"] .tier-sim-badge {
  background: rgba(22, 163, 74, 0.22);
  color: #dcfce7;
  border-color: rgba(74, 222, 128, 0.5);
}

/* Tier Inset List Items */
.tier-number-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tier-number-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
  flex-wrap: wrap;
  gap: 0.75rem;
  min-height: 48px;
  background: var(--rh-card-background-color);
  transition: background 0.15s ease;
}

.tier-number-row:last-child {
  border-bottom: none;
}

.tier-number-row:hover {
  background: rgba(125, 125, 125, 0.02);
}

.empty-tier-row {
  padding: 1.25rem 1rem;
  text-align: center;
  color: var(--rh-muted-color);
  font-size: 0.85rem;
}

.tier-num-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.tier-device-icon {
  font-size: 1.1rem;
}

.tier-phone-text {
  font-size: 0.95rem;
  color: var(--rh-color);
}

.tier-label-tag {
  font-size: 0.8rem;
  color: var(--rh-muted-color);
  margin-left: 0.4rem;
  background: var(--rh-background-color);
  padding: 0.1rem 0.45rem;
  border-radius: 4px;
  border: 1px solid var(--rh-muted-border-color);
}

.tier-row-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.tier-select-sm {
  margin: 0;
  padding: 0.35rem 2rem 0.35rem 0.65rem;
  font-size: 1rem;
  min-height: 44px;
  width: auto;
  border-radius: 6px;
  background: var(--rh-background-color);
}

/* A step card row's edit form: its fields line up at the top, so the
   validation message under one doesn't lift it above the next. */
.row-edit-form > *,
.rg-rename-form > *,
.add-number-fields > * {
  /* Rows: their items sit side by side, not stacked (see the card stack
     rule at the top). */
  margin-block-start: 0;
}
.row-edit-form {
  display: flex;
  align-items: flex-start;
  width: 100%;
}
.row-edit-form input,
.row-edit-form .row-edit-step {
  font-size: 0.85rem;
  padding: 0.2rem 0.5rem;
  margin-bottom: 0.2rem;
  height: 34px;
  min-height: 34px;
}
.row-edit-form .row-edit-step {
  padding-right: 2rem;
}

/* A step card row (phone or gate code) is text on the left and its buttons
   on the right (.row-actions, in .tier-number-display), centred on the
   whole row. The text reads in lines:
     .row-head    its name and what it does now (status, on shift), pills
                  after the name; a phone with no name puts its number here
     .row-line    the number or PIN, after its icon
     .row-detail  a code's uses and hours, which may wrap
   The text column takes the width the buttons leave: a long name ends in
   an ellipsis and the uses wrap, and neither pushes a button off screen.
   The flow tab draws each row twice (the scripts' and the server's, which
   the scripts replace), and both use these classes. The schedules tab's
   phone cards head with the same phone text and edit button
   (dashboard/phone_row_main.html), their controls below. */
.row-main {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
  flex: 1;
}
/* The name gives way to its pills, not the other way round: it shrinks to
   an ellipsis and they stay on its line. But it keeps 4rem of itself: a
   pill that would take that too (the do-not-forward tag, on a phone)
   wraps under the name instead. The 4rem is the name's flex basis, which
   is what the line break measures, and it grows from there to its own
   width (max-width), no further, so a short name keeps its pills beside
   it. With nowrap and a zero floor, a named phone with the tag lost its
   name entirely at 375 px and the tag ran under the buttons (2026-11-26).
   A phone with no name has its number here instead, which can't shrink,
   so its pills may wrap under it on a screen too narrow for both. */
.row-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
  min-width: 0;
}
.row-head > * {
  flex: none;
}
.row-head > .row-title {
  flex: 1 1 4rem;
  max-width: max-content;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.row-line {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
}
.row-number {
  font-size: 0.95rem;
}
.row-detail {
  font-size: 0.78rem;
  line-height: 1.35;
  overflow-wrap: break-word;
}
/* A row's small status pill: replaces an inline size on each one. */
.badge.row-pill {
  font-size: 0.7rem;
  padding: 0.1rem 0.4rem;
}
.row-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex: none;
}
.btn-row-edit {
  padding: 0.1rem 0.35rem;
  font-size: 0.85rem;
  line-height: 1;
}

.tier-escalate-indicator {
  text-align: center;
  color: var(--rh-muted-color);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0;
  margin: -0.25rem 0 0.6rem;
}

/* Alpine AJAX In-Flight Transitions & Busy States */
[aria-busy="true"] {
  opacity: 0.7;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

/* A card changes at once and is confirmed in the background
   (ts/instant.ts): while its post is out it stays as it is, usable. */
[data-card][aria-busy="true"],
[data-card] [aria-busy="true"] {
  opacity: 1;
  pointer-events: auto;
}

/* One of two controls a guess turns over (data-flip-class, ts/instant.ts):
   a vacation's Resume, or the picker that starts one. */
.is-hidden {
  display: none !important;
}

/* A row being removed: greyed out until the answer takes it away. */
[data-removing] {
  opacity: 0.45;
  pointer-events: none;
}

.tier-number-row {
  transition: background-color 0.2s ease;
}

.bulk-textarea {
  width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.95rem;
  line-height: 1.6;
  border-radius: 8px;
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  padding: 0.75rem 1rem;
  resize: vertical;
}

.bulk-textarea:focus {
  border-color: var(--rh-primary);
  outline: none;
  box-shadow: 0 0 0 2px var(--rh-primary-focus);
}

/* ==========================================================================
   Universal Floating Undo Toast & Feedback System
   ========================================================================== */
.rh-undo-toast-container {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  max-width: 90vw;
}

.rh-undo-toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.65rem 1rem;
  background: #1e293b;
  color: #f8fafc;
  border-radius: 9999px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3), 0 8px 10px -6px rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.88rem;
  font-weight: 500;
  animation: rh-toast-slide-up 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  transition: all 0.2s ease;
  backdrop-filter: blur(8px);
}

[data-theme="light"] .rh-undo-toast {
  background: #0f172a;
  color: #f8fafc;
}

.rh-undo-toast.rh-toast-exiting {
  opacity: 0;
  transform: translateY(12px) scale(0.95);
  pointer-events: none;
}

.rh-undo-toast .rh-undo-msg {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 340px;
}

.rh-undo-toast .rh-undo-btn {
  background: #3b82f6;
  color: #ffffff;
  border: none;
  border-radius: 9999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  line-height: 1.2;
  margin: 0;
  min-height: auto;
  transition: background-color 0.15s ease, transform 0.1s ease;
}

.rh-undo-toast .rh-undo-btn:hover {
  background: #2563eb;
  transform: scale(1.03);
}

.rh-undo-toast .rh-undo-btn:active {
  transform: scale(0.97);
}

.rh-undo-toast .rh-undo-kbd {
  font-size: 0.72rem;
  font-family: inherit;
  background: rgba(0, 0, 0, 0.25);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.rh-undo-toast .rh-undo-dismiss {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0 0.2rem;
  margin: 0;
  min-height: auto;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  transition: color 0.15s ease;
}

.rh-undo-toast .rh-undo-dismiss:hover {
  color: #ffffff;
}

@keyframes rh-toast-slide-up {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ── Ring Group Navigation Tabs & Mobile Segmented Control ────────────────── */
.rg-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
  margin-bottom: 1.5rem;
}

.tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: none !important;
  border: none !important;
  border-bottom: 2px solid transparent !important;
  border-radius: 0 !important;
  padding: 0.6rem 1rem !important;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--rh-muted-color);
  cursor: pointer;
  white-space: nowrap;
  margin: 0;
  min-height: 44px;
  transition: all 0.15s ease-in-out;
}

.tab-btn:hover {
  color: var(--rh-color);
}

.tab-btn.tab-btn-active {
  color: var(--rh-primary) !important;
  border-bottom-color: var(--rh-primary) !important;
}

.tab-label-short {
  display: none;
}
.tab-label-full {
  display: inline;
}

@media (max-width: 640px) {
  .rg-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    background: var(--rh-card-background-color);
    border: 1px solid var(--rh-muted-border-color);
    border-radius: 8px;
    padding: 3px;
    gap: 2px;
  }
  .tab-btn {
    justify-content: center;
    padding: 0.4rem 0.15rem !important;
    font-size: 0.8rem;
    gap: 0.25rem;
    border-radius: 6px !important;
    border-bottom: none !important;
    min-height: 38px;
    min-width: 0;
  }
  .tab-btn.tab-btn-active {
    background: var(--rh-background-color) !important;
    color: var(--rh-color) !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  }
  .tab-label-short {
    display: inline;
  }
  .tab-label-full {
    display: none;
  }
}

/* Form field validation and helper annotations */
.field-validation-msg {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  margin-top: 0.25rem;
}

.field-valid {
  color: var(--rh-ins-color, #2e7d32) !important;
}

.field-invalid {
  color: var(--rh-del-color, #c62828) !important;
}

/* Accessible screen-reader only utility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   Dashboard Components & Structural Layout Utilities
   ========================================================================== */

/* Universal Layout & Alignment Utilities */
.flex-row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.flex-row-start {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.flex-center {
  display: flex;
  align-items: center;
}

.flex-wrap {
  flex-wrap: wrap;
}

.flex-nowrap {
  flex-wrap: nowrap;
}

/* A flex row whose items line up along their bottom edge: a labelled field
   beside its button. */
.flex-end {
  display: flex;
  align-items: flex-end;
}

/* The flex item that takes the row's spare width (a text field beside its
   button), wrapping onto its own line below 12rem. */
.flex-fill {
  flex: 1 1 12rem;
  min-width: 0;
}

.gap-xs { gap: 0.25rem; }
.gap-sm { gap: 0.5rem; }
.gap-md { gap: 0.75rem; }
.gap-1  { gap: 1rem; }
.gap-lg { gap: 1.5rem; }

.m-0 { margin: 0 !important; }
.mr-sm { margin-right: 0.5rem !important; }
.ml-sm { margin-left: 0.5rem !important; }
.mt-sm { margin-top: 0.5rem !important; }
/* An option under a radio choice (the API key form's groups and confirm box). */
.option-indent { display: block; margin-left: 1.75rem; }
.mt-md { margin-top: 1rem !important; }
.mt-lg { margin-top: 1.5rem !important; }
.mt-xl { margin-top: 2rem !important; }
.mt-2xl { margin-top: 3rem !important; }
.mb-xs { margin-bottom: 0.25rem; }
.mb-sm { margin-bottom: 0.5rem; }
.mb-md { margin-bottom: 1rem; }
.mb-lg { margin-bottom: 1.5rem; }
.mb-xl { margin-bottom: 2rem; }

.text-right { text-align: right; }
.tabular-nums { font-variant-numeric: tabular-nums; }
.text-success { color: var(--rh-success-color); } /* #059669 was 3.8:1 on white */
.text-primary { color: var(--rh-primary) !important; }
.text-muted { color: var(--rh-muted-color); }
.text-label-caps {
  font-size: 0.75rem;
  color: var(--rh-muted-color);
  display: block;
  text-transform: uppercase;
  font-weight: 700;
}
.text-label-caps-md {
  font-size: 0.8rem;
  color: var(--rh-muted-color);
  display: block;
  text-transform: uppercase;
  font-weight: 700;
}

.w-full { width: 100% !important; }
.text-center { text-align: center !important; }
.text-left { text-align: left !important; }
.d-none { display: none !important; }
.font-mono { font-family: var(--rh-font-mono, monospace) !important; }

.btn-passkey {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  /* Room for "Confirm with your passkey" on one line on a 320 px phone. */
  padding-inline: 0.75rem;
}

/* The sign-in and step-up pages, for an account with a passkey and an
   authenticator: the code form waits behind a link under the passkey
   button (routes::auth::second_factor). A <details>, so it opens without
   scripts; drawn as a link, not the FAQ's bordered box. */
details.other-method {
  border: 0;
  border-radius: 0;
  margin: 1rem 0 0;
  background: none;
}
details.other-method > summary {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.25rem 0;
  font-weight: 400;
  font-size: 0.9rem;
  text-align: center;
  color: var(--rh-primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}
details.other-method > summary:hover {
  color: var(--rh-primary-hover);
}
details.other-method > summary::after {
  content: none;
}
details.other-method[open] > summary {
  margin-bottom: 0.5rem;
}

.stat-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}
.stat-tile {
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  padding: 0.75rem 1rem;
  border-radius: var(--rh-border-radius, 6px);
  text-align: center;
}
.stat-tile-value {
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1.2;
}

.account-panel-box {
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  padding: 1rem;
  border-radius: var(--rh-border-radius, 6px);
}
.account-card-title {
  margin: 0;
  font-size: 1.1rem;
}
.account-card-desc {
  margin: 0.25rem 0 0 0;
  font-size: 0.95rem;
}
.referral-input {
  margin: 0;
  flex: 1;
  min-width: 240px;
  background: var(--rh-card-background-color);
  color: var(--rh-primary);
  border: 1px solid var(--rh-border-color);
}
.api-key-code {
  font-size: 1rem;
  background: var(--rh-card-background-color);
  color: var(--rh-color);
  border: 1px solid var(--rh-border-color);
  padding: 0.5rem 0.75rem;
  border-radius: 4px;
  user-select: all;
  word-break: break-all;
}

/* Authenticator setup (two_factor_setup.html) */
.totp-qr {
  display: block;
  width: 200px;
  max-width: 100%;
  height: auto;
  margin: 1rem auto;
  border: 1px solid var(--rh-border-color);
  border-radius: 8px;
}
.recovery-codes {
  columns: 2;
  margin: 0;
  padding-left: 2.5em;
  font-family: var(--rh-font-mono);
}

/* Page Header */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.page-header h1 {
  margin-bottom: 0.25rem;
}
.page-header p {
  color: var(--rh-muted-color);
  margin: 0;
  font-size: 0.9rem;
}

/* Account Pool Bar */
.account-pool-bar {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 1.1rem 1.25rem;
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 12px;
  margin-bottom: 2rem;
  box-sizing: border-box;
  max-width: 100%;
}
.account-pool-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}
.account-pool-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.account-pool-balance {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.account-pool-mins {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--rh-primary);
}
.account-pool-badge-low {
  font-size: 0.75rem;
  padding: 0.15rem 0.55rem;
  border-radius: 9999px;
  background: #fef3c7;
  color: #92400e;
  font-weight: 600;
  border: 1px solid #fde68a;
  line-height: 1.2;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}
[data-theme="dark"] .account-pool-badge-low {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.4);
}
.account-pool-toggle-wrap {
  display: flex;
  align-items: center;
}
.account-toggle-label {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  cursor: pointer;
  user-select: none;
  margin: 0;
}
.account-toggle-text {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--rh-color);
}
.switch-control {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}
.switch-control input {
  opacity: 0;
  width: 0;
  height: 0;
  margin: 0;
  position: absolute;
}
.switch-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--rh-border-color, #cbd5e1);
  transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 24px;
}
.switch-slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: #ffffff;
  transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
}
.switch-control input:checked + .switch-slider {
  background-color: var(--rh-primary, #0f766e);
}
.switch-control input:focus-visible + .switch-slider {
  box-shadow: 0 0 0 3px var(--rh-primary-focus, rgba(15, 118, 110, 0.25));
}
.switch-control input:checked + .switch-slider:before {
  transform: translateX(20px);
}
.account-pool-details {
  border-top: 1px solid var(--rh-muted-border-color);
  padding-top: 0.75rem;
}
.account-pool-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}
.account-pool-text {
  font-size: 0.85rem;
  line-height: 1.45;
  color: var(--rh-muted-color);
  margin: 0;
  text-wrap: pretty;
  max-width: 72ch;
}
.account-pool-explainer-warning {
  color: #b45309;
}
[data-theme="dark"] .account-pool-explainer-warning {
  color: #fbbf24;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .account-pool-explainer-warning {
    color: #fbbf24;
  }
}
.account-pool-refill-form {
  margin: 0;
}
.account-pool-refill-form button {
  min-height: 36px;
  font-size: 0.85rem;
  padding: 0.35rem 0.85rem;
  white-space: nowrap;
}
@media (max-width: 600px) {
  .account-pool-body {
    flex-direction: column;
    align-items: stretch;
  }
  .account-pool-refill-form button {
    width: 100%;
  }
}

/* Dashboard Empty State */
.dash-empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  background: var(--rh-card-background-color);
  border: 1px dashed var(--rh-border-color);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  max-width: 680px;
  margin: 0 auto 3rem auto;
}
.dash-empty-state p.empty {
  font-size: 1.1rem;
  color: var(--rh-color);
  max-width: 480px;
  margin: 0;
  line-height: 1.45;
}
.dash-empty-pricing {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 0.85rem 1.25rem;
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 10px;
  max-width: 520px;
}
.dash-empty-price {
  color: var(--rh-primary);
  font-size: 1.1rem;
  font-weight: 700;
  margin-left: 0.4rem;
}
.dash-empty-features-list {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  text-align: center;
  line-height: 1.35;
}

/* Pricing Banner on New Ring Group Page */
.rg-pricing-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 0.9rem 1.15rem;
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 10px;
  margin-bottom: 1.5rem;
}
.rg-pricing-amount {
  display: block;
  color: var(--rh-primary);
  font-size: 1.15rem;
  font-weight: 700;
  margin-top: 0.15rem;
}
.rg-pricing-features {
  display: block;
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  margin-top: 0.15rem;
}

/* Account Billing & Payment Method Cards */
.account-billing-card,
.account-card-widget {
  margin-bottom: 1.5rem;
}
.account-card-info {
  margin-top: 0.25rem;
  font-size: 0.95rem;
  color: var(--rh-color);
}

/* Ring Group Card */
.rg-card {
  margin-bottom: 2.5rem;
  border-radius: 14px;
  padding: 1.5rem;
  overflow-x: hidden;
}
.rg-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
  padding-bottom: 1rem;
}
.rg-card-header h2 {
  margin: 0;
  font-size: 1.4rem;
  cursor: pointer;
}
.btn-ghost-sm {
  background: none;
  border: none;
  padding: 0.2rem 0.35rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--rh-muted-color);
}
.rg-rename-form {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0;
  flex-wrap: nowrap;
}
.rg-rename-input {
  margin: 0 !important;
  font-size: 1.1rem !important;
  font-weight: 700 !important;
  padding: 0.25rem 0.5rem !important;
  min-width: 180px !important;
  width: auto !important;
}
/* A flex row centred on its tallest item: as plain inline text the label,
   the number and the pill sat on one baseline at three font sizes, which
   left the small pill hanging low. Wraps on a narrow phone. */
.rg-inbound-wrap {
  margin-top: var(--rh-space-block);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: 0.35rem;
  row-gap: 0.25rem;
}
.rg-inbound-label {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
}
.rg-inbound-phone {
  font-size: 1.15rem;
  color: var(--rh-primary);
}
/* "Call it now" under the number until its first call, then "It rang"
   for an hour (templates/dashboard/call_now.html). */
.rg-call-now {
  margin: 0.6rem 0 0;
  max-width: 40rem;
}
.rg-call-now-ask,
.rg-call-now-done {
  border: 1px solid var(--rh-muted-border-color);
  border-left: 4px solid var(--rh-primary);
  border-radius: 10px;
  padding: 0.6rem 0.85rem;
  background: var(--rh-card-background-color);
  font-size: 0.9rem;
}
.rg-call-now-done {
  border-left-color: var(--rh-success-color);
  margin: 0;
}
.rg-call-now-done .icon {
  color: var(--rh-success-color);
}
.rg-call-now-heading {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.25rem;
}
.rg-call-now-line,
.rg-call-now-stopped {
  margin: 0;
}
.rg-call-now-number {
  font-size: 1.05rem;
  white-space: nowrap;
}
.rg-call-now-why {
  display: block;
  margin-top: 0.25rem;
  color: var(--rh-muted-color);
}
.rg-call-now-stopped {
  margin-top: 0.35rem;
  color: var(--rh-muted-color);
  font-size: 0.85rem;
}
.rg-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  /* Three buttons (call history, pause, delete) don't fit one phone row. */
  flex-wrap: wrap;
}

/* Call history and Pause beside the group's name; Delete is in the footer. */
.rg-header-actions .btn-sm {
  min-height: 38px;
}

/* The card's footer: the subscription in one line, its note behind a "?",
   and Delete. Under the steps, since none of it is needed often. */
.rg-card > footer.rg-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
}
.rg-sub-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--rh-space-block) 0.4rem;
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  min-width: 0;
}
.rg-sub-minutes {
  font-weight: 700;
  color: var(--rh-primary);
}
.rg-sub-help[open] {
  flex-basis: 100%;
}
.rg-sub-help-text {
  margin: 0.35rem 0 0;
  font-size: 0.8rem;
}
.rg-card-footer .rg-delete-btn {
  margin: 0;
}

/* A small "?" that opens a line or two of help: the flow tab's "How steps
   work" and the footer's talk time note. Not the FAQ's bordered box. */
details.help-toggle {
  border: 0;
  border-radius: 0;
  margin: 0;
  background: none;
}
details.help-toggle > summary {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0;
  min-height: 28px;
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--rh-muted-color);
}
details.help-toggle > summary::after {
  content: none;
}
.help-toggle-mark,
.rg-sub-help > summary > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 50%;
  border: 1px solid var(--rh-muted-border-color);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1;
}
.rg-sub-help > summary {
  min-width: 28px;
  justify-content: center;
}

/* The flow tab's intro: above the steps while the group is new, inside
   the "How steps work" toggle after. */
.flow-intro {
  margin-bottom: 1rem;
}
.flow-help .flow-intro-text {
  margin-top: 0.4rem;
}

/* Under the step cards: "How steps work" and "Edit all as text". An open
   help toggle drops to a line of its own under them. */
.steps-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  margin: -0.25rem 0 0.25rem;
}
.steps-toolbar .btn-bulk-toggle {
  margin-left: auto !important;
}
.steps-toolbar .flow-help[open] {
  flex-basis: 100%;
  order: 2;
}

/* Call settings, below the steps: each checkbox with its hint showing,
   lined up under its text rather than under the box. */
/* Each switch is its own form (it posts itself; docs/frontend.md). */
form.call-setting {
  margin: 0;
}
.call-setting + .call-setting {
  margin-top: 0.75rem;
}
.call-setting-hint {
  display: block;
  padding-left: 1.7rem;
  margin-top: var(--rh-space-block);
  font-size: 0.8rem;
  line-height: 1.4;
}

/* The account's minute pool sits below the groups; this short alert above
   them links down to it when it is low with auto-reload off. */
.pool-low-alert {
  margin-bottom: 1.5rem;
}
.pool-low-alert a {
  font-weight: 600;
}
.account-pool-bar {
  scroll-margin-top: 1rem;
}

/* "Now / Next" above the step cards. */
/* "Now / Next" at the top of the flow tab. Read at a glance: a small
   "Now" label over what a call does, in large type; "Next" a quieter line
   under it; an accent stripe and a dot in the tone's colour (data-tone,
   rendered by the server and kept by Alpine): green when phones ring,
   amber when the caller hears a message, red when calls are turned away. */
.now-next {
  --now-accent: var(--rh-success-color);
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-left: 4px solid var(--now-accent);
  border-radius: 10px;
  padding: 0.85rem 1rem 0.85rem 1.1rem;
  margin-bottom: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: var(--rh-space-sm);
}
.now-next[data-tone="warn"] {
  --now-accent: var(--rh-warning-color);
}
.now-next[data-tone="stop"] {
  --now-accent: var(--rh-error-color);
}
.now-next p {
  margin: 0;
}
.now-next-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--rh-muted-color);
  margin-bottom: 0.15rem;
}
.now-next-now .now-next-label {
  color: var(--now-accent);
}
.now-next-now .now-next-label::before {
  content: "";
  display: inline-block;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--now-accent);
  margin-right: 0.4rem;
  vertical-align: 0.05em;
}
.now-next-what {
  display: block;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--rh-color);
}
.now-next-what::first-letter {
  text-transform: uppercase;
}
.now-next-next {
  font-size: 0.9rem;
  color: var(--rh-color);
}
.now-next-then {
  display: block;
}
.now-next-tz {
  font-size: 0.8rem;
  color: var(--rh-muted-color);
}
.flow-intro-text {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  margin: 0;
  max-width: 520px;
}
.flow-tip-text {
  font-size: 0.8rem;
  color: var(--rh-muted-color);
  margin: 0.25rem 0 0 0;
  font-style: italic;
}
.voicemail-guard-label {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0;
  font-size: 0.85rem;
  cursor: pointer;
  user-select: none;
}
.btn-bulk-toggle {
  margin: 0 !important;
  font-size: 0.8rem !important;
  padding: 0.25rem 0.6rem !important;
}

.step-card {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 10px;
  padding: 1rem;
  margin-bottom: 1.25rem;
}
.step-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
}
.step-badge {
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  white-space: nowrap !important;
  width: auto !important;
  flex-shrink: 0 !important;
}
.rg-card button,
.rg-card .btn-sm,
.rg-card .tab-btn,
.rg-card .badge {
  white-space: nowrap !important;
  width: auto !important;
  flex-shrink: 0 !important;
}
.step-note {
  font-size: 0.8rem;
  color: var(--rh-muted-color);
}
.step-controls {
  display: flex;
  align-items: flex-end;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.step-label {
  font-size: 0.75rem;
  color: var(--rh-muted-color);
  margin-bottom: 0.2rem;
  display: block;
}

.conference-burn-estimator {
  margin: 0.75rem 0 1rem;
  padding: 0.85rem 1rem;
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  font-size: 0.875rem;
  color: var(--rh-color);
}
.conference-burn-box {
  background: var(--rh-card-background-color);
  padding: 0.6rem 0.85rem;
  border-radius: 6px;
  border: 1px dashed var(--rh-border-color);
  margin: 0.5rem 0;
  color: var(--rh-color);
}
.conference-burn-title {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--rh-muted-color);
  letter-spacing: 0.02em;
}
.conference-burn-calc {
  font-weight: 500;
  margin-top: 0.2rem;
  color: var(--rh-color);
}
.conference-burn-autoreload-on {
  color: var(--rh-ins-color);
}
.conference-burn-autoreload-off {
  color: #b45309;
}
[data-theme="dark"] .conference-burn-autoreload-off {
  color: #fbbf24;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .conference-burn-autoreload-off {
    color: #fbbf24;
  }
}

.tier-numbers-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.tier-number-empty {
  padding: 0.75rem;
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  text-align: center;
}
.tier-number-row {
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}
/* Never wraps: the buttons stay beside the text, centred on it (see
   .row-main). */
.tier-number-display {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.5rem;
  width: 100%;
  min-width: 0;
}
/* A phone that keeps sending calls to voicemail: a warning across the
   bottom of its row, with its snooze and remove buttons. */
.vm-streak {
  flex-basis: 100%;
  min-width: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 0.75rem;
}
.vm-streak-text {
  flex: 1 1 18rem;
  min-width: 0;
  margin: 0;
  font-size: 0.85rem;
}
.vm-streak-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.step-reorder-actions {
  display: inline-flex;
  gap: 0.25rem;
  align-items: center;
  margin-right: 0.25rem;
}
/* On a phone, ↑ over ↓ in a narrow column, so four buttons side by side
   don't leave the row's text a sliver; and the step card and its rows
   give up some inset, which on a 375 px screen was a third of the width
   (the step card sits inside the ring group's card). */
@media (max-width: 575px) {
  .step-card {
    padding: 0.75rem;
  }
  .tier-number-row {
    padding-inline: 0.25rem;
  }
  .rg-card {
    padding: 1rem;
  }
  .row-actions {
    gap: 0.25rem;
  }
  /* With the move buttons, a 2×2 block: ↑ over ↓, then edit over remove. */
  .row-actions:has(> .step-reorder-actions) {
    display: grid;
    grid-auto-flow: column;
    grid-template-rows: 26px 26px;
    row-gap: 2px;
    align-items: center;
    justify-items: center;
  }
  .row-actions > .step-reorder-actions {
    grid-row: span 2;
  }
  .row-actions:has(> .step-reorder-actions) .btn-remove-number {
    height: 26px;
    min-height: 26px;
  }
  /* Enough, at 375 px, for a phone with no name to keep its number and
     its shift on one line. */
  .tier-number-display {
    gap: 0.35rem;
  }
  .row-head {
    column-gap: 0.35rem;
  }
  .row-line {
    gap: 0.3rem;
  }
  .row-number {
    font-size: 0.9rem;
  }
  .badge.row-pill {
    gap: 0.3rem;
    letter-spacing: 0.02em;
  }
  .row-actions .step-reorder-actions {
    flex-direction: column;
    gap: 2px;
    margin-right: 0;
  }
  .row-actions .step-reorder-actions .btn-reorder {
    min-height: 26px !important;
    padding: 0 0.4rem !important;
  }
}
.btn-reorder {
  min-height: 30px !important;
  padding: 0.15rem 0.45rem !important;
  font-size: 0.8rem !important;
  margin: 0 !important;
}

/* Add Phone Form */
.add-number-card {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 10px;
  padding: 1.25rem;
  margin-top: 1.5rem;
}
/* An h3 under the group's h2, in the body font (see .flow-step h3). Later
   in the file than the data-rh-font h3 rules, which it overrides. */
h3.add-number-title {
  font-family: inherit;
  font-weight: 700;
  font-variation-settings: normal;
  letter-spacing: normal;
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
}
.add-number-fields {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: flex-start;
}
.add-number-label {
  font-size: 0.75rem;
  color: var(--rh-muted-color);
  margin-bottom: 0.25rem;
  display: block;
  white-space: nowrap;
}
.add-number-btn-wrap {
  margin-top: 1.2rem;
}

/* A gate code's fields (dashboard/code_fields.html), in the add-code card
   and a code's edit form: side by side on a wide screen, each with the
   share and the least width it had as inline styles. */
.code-field { flex: 1; min-width: 100px; }
.code-field-label { flex: 1.5; min-width: 140px; }
.code-field-pin { flex: 1; min-width: 110px; }
.code-field-expires { flex: 1.5; min-width: 170px; }
.code-field-max { flex: 1; min-width: 100px; }
.code-field-hours { flex: 1.2; min-width: 190px; }
.code-field-step { flex: 1.2; min-width: 170px; }
.code-edit-form { width: 100%; }
.code-custom-hours,
.add-number-fields > .times-in {
  flex-basis: 100%;
}
.code-time-input { width: 8rem; }

/* Date and time inputs never outgrow their box. In Safari on an iPhone,
   WebKit gives a date input an intrinsic minimum width from its own value
   layout that ignores the flex item it sits in, and the gate code form's
   "Stops working" ran over "Max uses" (2026-11-27). min-width: 0 and a
   block box with the box's width keep it in; on iOS (the -webkit-touch-
   callout query matches only there) the native appearance goes too, since
   it brings the minimum back, so the height and the value's alignment are
   set by hand. Chromium never showed it: see tests/dashboard_layout.rs. */
input[type="date"],
input[type="datetime-local"],
input[type="time"] {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
input[type="date"],
input[type="datetime-local"] {
  display: block;
  width: 100%;
}
@supports (-webkit-touch-callout: none) {
  input[type="date"],
  input[type="datetime-local"],
  input[type="time"] {
    -webkit-appearance: none;
    appearance: none;
    min-height: 44px;
  }
  input::-webkit-date-and-time-value {
    text-align: left;
    min-width: 0;
  }
}

/* On a phone, a gate code form's fields stack one per line: side by side
   at 375 px each got a sliver, and the date field overflowed in Safari. */
@media (max-width: 575px) {
  .add-number-fields > .code-field,
  .add-number-fields > .add-number-btn-wrap {
    flex: 1 1 100%;
    min-width: 0;
  }
  .add-number-fields > .code-field input,
  .add-number-fields > .code-field select {
    width: 100%;
  }
}

/* The calendar card (dashboard/calendar_card.html) and the page that
   previews an address (calendar_add.html). A sync error is a sentence that
   may hold a whole URL: it takes a line of its own under the feed and breaks
   anywhere, rather than running the row past the card as one line in a
   pill (the pill says only "Sync failed"). */
.calendar-feed-error,
.calendar-wrap-note {
  flex-basis: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
}
.calendar-feed-error {
  margin: 0;
  padding: 0.5rem 0.75rem;
}
.calendar-feed-name {
  min-width: 0;
  overflow-wrap: anywhere;
}
.calendar-help {
  margin-top: 0.75rem;
  font-size: 0.9rem;
}
.calendar-help summary {
  cursor: pointer;
  font-weight: 600;
}
.calendar-help .calendar-help-service {
  font-family: inherit;
  font-size: 0.95rem;
  margin: 1rem 0 0.35rem;
}
.calendar-help-steps {
  margin: 0 0 0.35rem;
  padding-left: 1.4rem;
}
.calendar-help-note,
.calendar-help-warn {
  margin-bottom: 0.25rem;
}
.calendar-preview {
  margin-top: 1.5rem;
}
.calendar-preview h2 {
  font-size: 1.15rem;
  overflow-wrap: anywhere;
}
.calendar-preview h3 {
  font-size: 1rem;
}
/* An Airbnb calendar's check-in and check-out times: under the add form's
   fields, and on the feed's row. They wrap rather than widen the card on a
   phone. */
.calendar-stay-times {
  border: 0;
  padding: 0;
  margin-top: 0.5rem;
}
.calendar-stay-times-fields {
  flex-wrap: wrap;
}

/* Bulk Text Editor */
.bulk-editor-card {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 10px;
  padding: 1.25rem;
}
.bulk-textarea {
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 0.75rem;
}

/* Tab 2: Schedules */
.sched-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1rem;
}
.sched-intro-text {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  margin: 0;
  max-width: 540px;
}
.sched-card {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 10px;
  overflow: hidden;
}
.sched-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.sched-row {
  padding: 1rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.sched-row-display {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  width: 100%;
}
.sched-label {
  font-size: 0.75rem;
  color: var(--rh-muted-color);
  margin-bottom: 0.2rem;
  display: block;
}


.step-mode-select {
  min-width: 195px;
  font-size: 0.82rem;
  min-height: 36px;
  padding: 0.2rem 2rem 0.2rem 0.5rem;
  margin: 0;
}
.step-timeout-select {
  min-width: 125px;
  font-size: 0.82rem;
  min-height: 36px;
  padding: 0.2rem 2rem 0.2rem 0.5rem;
  margin: 0;
}
.shift-select {
  min-width: 165px;
  font-size: 0.82rem;
  min-height: 36px;
  padding: 0.2rem 2rem 0.2rem 0.5rem;
  margin: 0;
}
.vacation-select {
  min-width: 180px;
  font-size: 0.82rem;
  min-height: 36px;
  padding: 0.2rem 2rem 0.2rem 0.5rem;
  margin: 0;
}

/* ==========================================================================
   Ring Group Creation Form (ring_group_new.html)
   ========================================================================== */

.field-label-caps {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--rh-muted-color);
  margin-bottom: 0.35rem;
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.mt-lg {
  margin-top: 1.5rem;
}

.rg-new-card {
  max-width: 540px;
  margin: 1rem auto;
  padding: 1.25rem;
  border-radius: 12px;
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
}

.rg-new-header {
  padding: 0;
  margin: 0 0 1.25rem;
  background: none;
  border-bottom: none;
}
.rg-new-header h1 {
  margin: 0 0 0.35rem;
  font-size: 1.75rem;
}
.rg-new-header p {
  color: var(--rh-muted-color);
  margin: 0;
  font-size: 0.9rem;
}

.rg-field-group {
  margin-bottom: 1.25rem;
}

.rg-area-code-input {
  width: 90px !important;
  flex: 0 0 90px !important;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.rg-search-btn {
  margin: 0 !important;
  min-height: 44px !important;
  white-space: nowrap !important;
  flex: 1;
}

.rg-field-hint {
  margin-top: var(--rh-space-block);
  display: block;
  font-size: 0.8rem;
  color: var(--rh-muted-color);
}

.rg-status-text {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--rh-muted-color);
}
.rg-status-text.status-error {
  color: var(--rh-del-color, #c62828);
}

.rg-suggestions {
  margin-top: 0.75rem;
}
.rg-suggestions-label {
  display: block;
  margin-bottom: 0.45rem;
  font-size: 0.85rem;
  color: var(--rh-muted-color);
}
.rg-suggestion-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.rg-suggestion-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0 !important;
  padding: 0.45rem 0.75rem !important;
  min-height: 40px;
  font-size: 0.85rem;
  width: auto !important;
}
.rg-suggestion-chip-label {
  font-weight: 400;
  color: var(--rh-muted-color);
}

.rg-filter-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.rg-filter-input {
  margin: 0 !important;
  padding-right: 2.25rem !important;
}
.rg-filter-clear-btn {
  position: absolute;
  right: 0.4rem;
  background: none !important;
  border: none !important;
  padding: 0.25rem 0.5rem !important;
  cursor: pointer;
  color: var(--rh-muted-color) !important;
  font-size: 1.1rem !important;
  line-height: 1 !important;
  min-height: auto !important;
  width: auto !important;
}
.rg-filter-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 0.35rem;
  min-height: 1.2rem;
}
.rg-filter-hint {
  font-size: 0.75rem;
  color: var(--rh-muted-color);
  display: block;
}
.rg-carrier-searching {
  font-size: 0.75rem;
  color: var(--rh-primary);
  font-weight: 500;
  white-space: nowrap;
  margin-left: 0.5rem;
}

.rg-results-fieldset {
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
}
.rg-results-list {
  margin: 0.25rem 0 0.5rem;
}
.number-list li.selected {
  border-color: var(--rh-primary);
  background: var(--rh-primary-focus);
}
.rg-number-choice-label {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  width: 100%;
  cursor: pointer;
  margin: 0;
}
.rg-number-choice-body {
  flex: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem;
}
.rg-number-digits {
  font-size: 1.05rem;
}
.rg-number-sub {
  font-size: 0.8rem;
  color: var(--rh-muted-color);
}

.rg-empty-filter {
  padding: 1rem;
  text-align: center;
  background: var(--rh-card-background-color);
  border: 1px dashed var(--rh-muted-border-color);
  border-radius: 8px;
  margin-bottom: 0.75rem;
}
.rg-empty-filter-text {
  margin: 0 0 0.5rem;
  font-size: 0.85rem;
  color: var(--rh-muted-color);
}
.rg-empty-filter-btn {
  margin: 0 !important;
  padding: 0.25rem 0.75rem !important;
  font-size: 0.8rem !important;
  width: auto !important;
}

.rg-submit-btn {
  margin: 0 !important;
  min-height: 44px !important;
  /* Takes the row; below ~14rem beside Cancel it gets a line of its own
     (the row wraps) instead of being squeezed into a narrow column. */
  flex: 1 1 14rem;
}
.rg-cancel-btn {
  margin: 0 !important;
  min-height: 44px !important;
}
.rg-footnote {
  margin-top: 0.75rem;
  margin-bottom: 0;
  text-align: center;
  font-size: 0.8rem;
  color: var(--rh-muted-color);
}

/* ==========================================================================
   Auth, Account, Error, and Landing Components
   ========================================================================== */

/* Authentication & Account Layout */
.auth-wrap {
  max-width: 380px;
}
.auth-wrap-centered {
  max-width: 400px;
  margin: 0 auto;
}
.email-verify-wrap {
  max-width: 480px;
  margin: 0 auto;
}
.google-auth-wrap {
  margin-bottom: 20px;
}
.btn-google {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  text-decoration: none;
  background: #ffffff !important;
  color: #3c4043 !important;
  border: 1px solid #dadce0 !important;
  border-radius: 6px !important;
  padding: 9px !important;
  font-weight: 500;
  font-size: 14px;
  box-shadow: 0 1px 2px rgba(60, 64, 67, 0.08);
}
.auth-divider {
  display: flex;
  align-items: center;
  margin: 18px 0;
  color: var(--rh-muted-color);
  font-size: 13px;
}
.auth-divider hr {
  flex: 1;
  border: none;
  border-top: 1px solid var(--rh-muted-border-color);
  margin: 0;
}
.auth-divider span {
  padding: 0 10px;
}

/* Status & Verification Pages */
.verify-status-wrap {
  max-width: 440px;
  margin: 3rem auto;
  text-align: center;
}
.verify-icon {
  font-size: 2.5rem;
  margin: 0;
}
.billing-success-card {
  max-width: 480px;
  margin: 3rem auto;
  text-align: center;
}

/* Error Pages */
.error-page-wrap {
  text-align: center;
  padding: 4rem 0;
}
/* The reference a report quotes: a 32-digit trace id, which must wrap on a
   phone rather than push the page sideways. */
.error-page-reference {
  overflow-wrap: anywhere;
  user-select: all;
}

/* The signed-in pages' "Report a problem" line, under the content. */
.report-problem {
  margin-top: 2rem;
  text-align: center;
}

.error-page-code {
  font-size: 3rem;
  margin: 0;
}

/* Terms & Regulatory Notice */
.terms-alert {
  background: var(--rh-card-background-color, #fff);
  border: 2px solid var(--rh-primary);
  border-radius: 8px;
  padding: 1.25rem;
  margin-bottom: 2rem;
}
.terms-alert h2 {
  color: var(--rh-primary);
  margin-top: 0;
  font-size: 1.25rem;
}
.terms-alert p:last-child {
  margin-bottom: 0;
}

/* Landing & Solution Pages */
.phone-status-label {
  font-size: 0.68rem;
  opacity: 0.8;
}
.section-header-compact {
  margin-top: 1rem;
  margin-bottom: 1.5rem;
}
.section-header-compact h2 {
  font-size: 1.5rem;
}
.section-header-sm {
  margin-top: 0.5rem;
  margin-bottom: 1.5rem;
}
.section-header-sm h2 {
  font-size: 1.4rem;
}
.solution-steps-list {
  padding-left: 1.25rem;
}
.solution-pricing-card {
  max-width: 540px;
  margin-inline: auto;
  margin-block: 2.5rem;
}
.closing-cta-card {
  text-align: center;
  padding: 2.5rem 1.5rem;
  margin-top: 3rem;
  background: var(--rh-card-background-color);
}
.closing-cta-card h2 {
  margin-bottom: 0.75rem;
}
.closing-cta-lead {
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
}
.btn-cta-lg {
  padding: 0.75rem 2rem !important;
  font-size: 1.1rem !important;
}

/* Modal Dialog
   Every modal fits the screen it is on, and every part of it can be reached
   (tests/modal_fit.rs). On an iPhone the delete dialog was taller than the
   screen and its buttons were out of reach (2026-11-30): the backdrop was
   100vh, which in Safari is the viewport with its toolbars hidden, so taller
   than what shows; the card was centred with align-items, which pushes a
   card taller than its box off the top as well as the bottom; and nothing
   scrolled.

   - The backdrop is the visible viewport (dvh, vh where dvh is unknown), and
     keeps clear of the safe areas.
   - The card is at most the backdrop's height. Its header and footer keep
     their size and its body scrolls between them, so the buttons are on
     screen without scrolling.
   - Where even the header and footer leave the body too little room (a
     short screen, below), the card takes its full height and the backdrop
     scrolls instead. The card is centred by its auto margins, not
     align-items: an auto margin never goes below 0, so the card's top is
     never above the top of what scrolls (align-items: safe center does the
     same, but only from Safari 17.6).
   - While a modal is open the page behind doesn't scroll (the :has rule).
     Alpine's x-show hides a closed modal with an inline display: none. */
.modal-backdrop {
  position: fixed;
  inset: 0;
  margin: 0;
  height: 100vh;
  height: 100dvh;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  display: flex;
  z-index: 1000;
  padding:
    max(1rem, env(safe-area-inset-top))
    max(1rem, env(safe-area-inset-right))
    max(1rem, env(safe-area-inset-bottom))
    max(1rem, env(safe-area-inset-left));
  overflow-y: auto;
  overscroll-behavior: contain;
}

html:has(.modal-backdrop:not([x-cloak]):not([style*="display: none"])) {
  overflow: hidden;
}

.modal-card {
  background: var(--rh-card-background-color);
  color: var(--rh-color);
  border: 1px solid var(--rh-border-color);
  border-radius: var(--rh-border-radius);
  max-width: 480px;
  width: 100%;
  margin: auto;
  max-height: 100%;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2), 0 10px 10px -5px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  animation: modal-pop 0.15s ease-out;
}

@keyframes modal-pop {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(4px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.modal-header {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.15rem 1.25rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
}

.modal-header h2 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 600;
}

.modal-close-btn {
  background: none;
  border: none;
  font-size: 1.25rem;
  color: var(--rh-muted-color);
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  line-height: 1;
}

/* The delete modal's warning icon, beside its text. */
.modal-warn-icon {
  font-size: 1.2rem;
  line-height: 1.2;
}

.modal-close-btn:hover {
  color: var(--rh-color);
}

.modal-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.modal-summary-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  background: var(--rh-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: 6px;
  padding: 1rem;
}

.modal-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.95rem;
}

.modal-summary-label {
  color: var(--rh-muted-color);
}

/* A value wraps (a group's name can be 80 characters) rather than push
   its row wider than the card. */
.modal-summary-value {
  font-weight: 600;
  min-width: 0;
  overflow-wrap: anywhere;
}
.modal-total-highlight {
  font-size: 1.05rem;
  font-weight: 700;
}

.modal-terms-text {
  font-size: 0.85rem;
  color: var(--rh-muted-color);
  line-height: 1.45;
  margin: 0;
}

.modal-footer {
  flex: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--rh-muted-border-color);
  background: var(--rh-background-color);
}

/* The footer's buttons share a line when they fit and each takes a whole
   line when they don't ("Permanently Delete Group" alone is most of a phone's
   card). A button in a form grows as a flex item, not by width: the delete
   dialog sits in a .rg-card, whose buttons are width: auto !important. */
.modal-footer > * {
  flex: 1 1 auto;
}
.modal-footer > form {
  display: flex;
}
.modal-footer > form > button {
  flex: 1 1 auto;
}

/* A short screen: a phone on its side with its toolbars out. The header and
   footer would leave the body only a sliver, so the card is as tall as it
   needs and the backdrop scrolls. 22rem is above the header, footer and a
   few lines of body. */
@media (max-height: 22rem) {
  .modal-card {
    max-height: none;
  }
  .modal-body {
    overflow-y: visible;
  }
}







/* ==========================================================================
   Developers page (/developers): a stack of cards. The three ways in (API,
   rh, MCP) side by side, a contents card, the guides, then one card per
   group of operations, each operation set off by a rule, with its method
   as a coloured tag and its fields as rows.
   ========================================================================== */
.developers {
  display: flex;
  flex-direction: column;
  gap: var(--rh-space-md);
  margin-bottom: 2rem;
}
.developers code {
  font-family: var(--rh-font-mono);
  font-size: 0.875em;
  overflow-wrap: anywhere;
}
.developers :not(pre) > code {
  background: var(--rh-code-background);
  border-radius: 4px;
  padding: 0.05em 0.3em;
}
.developers p {
  line-height: 1.6;
}
.dev-intro p:last-child {
  margin-bottom: 0;
}
.dev-ways {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  gap: var(--rh-space-sm);
}
.dev-way {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-top: 3px solid var(--rh-primary);
  border-radius: var(--rh-border-radius);
  padding: 0.85rem 1rem;
  display: flex;
  flex-direction: column;
  gap: var(--rh-space-xs);
}
.dev-way-title {
  font-family: inherit;
  font-size: 1rem;
  margin: 0;
}
.dev-way p {
  font-size: 0.9rem;
  color: var(--rh-muted-color);
  margin: 0;
  flex: 1;
}
.dev-way a {
  font-size: 0.9rem;
  font-weight: 600;
}
.dev-section {
  background: var(--rh-card-background-color);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  padding: 1.25rem 1.5rem;
  scroll-margin-top: 1rem;
}
@media (max-width: 600px) {
  .dev-section {
    padding: 1rem;
  }
}
.dev-section > :last-child {
  margin-bottom: 0;
}
.dev-section-title {
  font-size: 1.4rem;
  margin: 0 0 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--rh-muted-border-color);
}
.dev-subtitle {
  font-family: inherit;
  font-size: 1.05rem;
  margin: 1.25rem 0 0.5rem;
}
.dev-code {
  background: var(--rh-code-background);
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
  padding: 0.75rem 1rem;
  margin: 0 0 0.75rem;
  line-height: 1.5;
}
/* Long lines wrap rather than scroll: a scrolling box needs keyboard
   access of its own (axe: scrollable-region-focusable), and on a phone
   half the command would be out of sight. */
.dev-code code {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 0.85rem;
}
.dev-toc-title {
  font-size: 1.1rem;
  margin: 0 0 0.75rem;
}
.dev-toc-groups {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: var(--rh-space-md);
}
@media (max-width: 600px) {
  .dev-toc-groups {
    grid-template-columns: 1fr;
  }
}
.dev-toc-heading {
  font-family: inherit;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--rh-muted-color);
  margin: 0 0 var(--rh-space-block);
}
.dev-toc-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr));
  gap: 0 var(--rh-space-md);
}
.dev-toc-groups > div:first-child .dev-toc-list {
  grid-template-columns: 1fr;
}
.dev-toc-list a {
  display: inline-block;
  padding: 0.3rem 0;
  min-height: 32px;
}
.dev-conventions {
  display: grid;
  grid-template-columns: 9rem 1fr;
  gap: var(--rh-space-sm) var(--rh-space-md);
  margin: 0;
}
.dev-conventions dt {
  font-weight: 700;
}
.dev-conventions dd {
  margin: 0;
  line-height: 1.55;
}
@media (max-width: 600px) {
  .dev-conventions {
    grid-template-columns: 1fr;
    row-gap: var(--rh-space-xs);
  }
  .dev-conventions dd {
    margin-bottom: var(--rh-space-sm);
  }
}
.dev-op {
  display: flex;
  flex-direction: column;
  gap: var(--rh-space-sm);
  padding: 1.1rem 0;
  border-top: 1px solid var(--rh-muted-border-color);
  scroll-margin-top: 1rem;
}
.dev-section-title + .dev-op {
  border-top: none;
  padding-top: 0.25rem;
}
.dev-op:last-child {
  padding-bottom: 0;
}
.dev-op > * {
  margin: 0;
}
.dev-op-title {
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.6;
}
.dev-op-title code {
  font-size: 0.95rem;
}
.dev-method {
  display: inline-block;
  min-width: 4.2em;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.4rem;
  margin-right: 0.35rem;
  border-radius: 4px;
  border: 1px solid var(--rh-muted-border-color);
  vertical-align: 0.1em;
}
.dev-method-get {
  background: var(--rh-success-bg);
  color: var(--rh-success-color);
  border-color: var(--rh-success-border);
}
.dev-method-post {
  background: var(--rh-primary-focus);
  color: var(--rh-color);
  border-color: var(--rh-primary);
}
.dev-method-put,
.dev-method-patch {
  background: var(--rh-warning-bg);
  color: var(--rh-warning-color);
  border-color: var(--rh-warning-border);
}
.dev-method-delete {
  background: var(--rh-error-bg);
  color: var(--rh-error-color);
  border-color: var(--rh-error-border);
}
.dev-notes {
  font-size: 0.9rem;
  color: var(--rh-muted-color);
  padding-left: 1.4rem;
}
.dev-fields {
  display: flex;
  flex-direction: column;
  gap: var(--rh-space-block);
}
.dev-fields-title {
  font-family: inherit;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--rh-muted-color);
  margin: 0;
}
.dev-fields-title code {
  text-transform: none;
  letter-spacing: 0;
  color: var(--rh-color);
}
.dev-field-list {
  list-style: none;
  padding: 0;
  border: 1px solid var(--rh-muted-border-color);
  border-radius: var(--rh-border-radius);
}
.dev-field-list li {
  padding: 0.5rem 0.75rem;
  font-size: 0.9rem;
}
.dev-field-list li + li {
  border-top: 1px solid var(--rh-muted-border-color);
}
.dev-field-name {
  font-weight: 700;
}
.dev-field-kind {
  color: var(--rh-muted-color);
  font-size: 0.85rem;
}
.dev-field-desc {
  display: block;
  margin-top: 0.15rem;
  line-height: 1.5;
}
