/*!*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** css ../../node_modules/.pnpm/next@15.5.18_@opentelemetry+api@1.9.1_@playwright+test@1.60.0_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[2]!../../node_modules/.pnpm/next@15.5.18_@opentelemetry+api@1.9.1_@playwright+test@1.60.0_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/next/dist/build/webpack/loaders/postcss-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[3]!./src/styles/tokens.css ***!
  \*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
:root {
  /* Monochrome ramp, V1 warm neutral, hue 35°, low saturation across
     the whole scale so blanks, borders, muteds and inks read as a single
     coherent grey family without yellow. */
  --bg-page: #f5f3ef;  /* canvas */
  --bg:      #fbf9f6;  /* surface (sidebars, top bars) */
  --bg-2:    #efede7;  /* recessed / hover */
  --card:    #ffffff;  /* elevated */

  /* Foreground */
  --fg:        #141312;
  --fg-2:      #292624;
  --fg-3:      #484642;
  --muted:     #edeae5;
  --muted-fg:  #68635c;
  --muted-fg-2:#8d8982;

  /* Borders, same hue, stepped lightness */
  --border:          #dedbd2;
  --border-soft:     #e5e2db;
  --border-strong:   #cdc8be;
  --border-hairline: #e8e4de;

  /* Ink (same as fg / fg-2, kept for semantic clarity) */
  --ink:      #141312;
  --ink-soft: #292624;

  /* Clinical teal accent */
  --accent:     #2d5b6e;
  --accent-soft:#3a7589;
  --accent-bg:  rgba(45,91,110,0.10);

  /* Brand teal, call-to-action (sampled from the Certuma logo) */
  --cta:       #226265;
  --cta-hover: #1a4f51;
  --cta-fg:    #ffffff;
  --cta-bg:    rgba(34,98,101,0.10);

  /* Tier signal colors, desaturated enough to coexist on V1 surfaces */
  --tier-review: #79613b;   --tier-review-bg: rgba(121,97,59,0.10);
  --tier-live:   #9c4e44;   --tier-live-bg:   rgba(156,78,68,0.13);
  --tier-done:   #4f6743;   --tier-done-bg:   rgba(79,103,67,0.12);
  --tier-new:    #68635c;   --tier-new-bg:    rgba(104,99,92,0.10);
  --tier-ai:     #2d5b6e;   --tier-ai-bg:     rgba(45,91,110,0.10);

  /* Status (typical) */
  --status-online: #22c55e;
  --status-live:   #ef4444;
  --status-away:   #a8a29e;

  /* Radius */
  --r-card:    22px;
  --r-card-sm: 16px;
  --r-btn:     14px;
  --r-btn-sm:  12px;
  --r-chip:     8px;
  --r-input:   12px;
  --r-row:     12px;
  --r-tab:     10px;

  /* Fonts */
  --font:         "Manrope", system-ui, sans-serif;
  --font-display: "Plus Jakarta Sans", "Manrope", system-ui, sans-serif;

  /* Heights */
  --h-toolbar: 32px;
  --h-input:   36px;
  --h-input-tb: 32px;
  --h-row:     56px;

  /* Shadows, match ink hue at low sat so they reinforce, not warm up */
  --shadow-pop:  0 10px 30px -16px rgba(20,19,18,0.20);
  --shadow-modal: 0 24px 80px -24px rgba(20,19,18,0.30);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body, #root {
  height: 100%;
  font-family: var(--font);
  letter-spacing: -0.012em;
  background: var(--bg-page);
  color: var(--fg);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "ss01";
}
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; background: none; border: 0; color: inherit; }
input, textarea, select { font: inherit; color: inherit; letter-spacing: inherit; }
img, svg { display: block; max-width: 100%; }
ul, ol { list-style: none; }
strong { font-weight: 600; }

/* Utilities */
.tabular { font-variant-numeric: tabular-nums; font-feature-settings: "tnum", "ss01", "tnum"; }
.t-eyebrow {
  font-size: 10.5px; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted-fg);
}
.t-display { font-family: var(--font-display); font-weight: 700; letter-spacing: -0.018em; }
.t-meta { color: var(--muted-fg); letter-spacing: 0.008em; font-size: 12.5px; }
.t-tight { letter-spacing: -0.018em; }
.t-loose { letter-spacing: 0.012em; }

/* Avatars */
.av {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 9999px;
  background: var(--ink); color: var(--bg);
  font-family: var(--font-display);
  font-weight: 700; font-size: 11.5px; letter-spacing: 0.002em;
  flex-shrink: 0; overflow: hidden; position: relative;
}
.av-sm { width: 24px; height: 24px; font-size: 10.5px; }
.av-md { width: 36px; height: 36px; font-size: 13px; }
.av-lg { width: 44px; height: 44px; font-size: 15px; }
.av-xl { width: 56px; height: 56px; font-size: 18px; }
.av img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
/* El hairline era el fondo oscuro (--ink) mezclandose en el borde antialiased del
   recorte circular: en el sub-pixel del borde el color = foto*a + ink*(1-a), y al
   ser ink oscuro deja una linea. Cuando hay foto el fondo sobra, asi que lo hacemos
   transparente: el borde mezcla con la pagina (clara) y no queda ninguna linea. */
.av:has(img) { background: transparent; }
.av-no-ring { border: 0; box-shadow: none; }
.av-soft { background: var(--muted); color: var(--fg); }
.av-with-status {
  overflow: visible;
}
.av-with-status::after {
  content: "";
  position: absolute;
  bottom: -1px; right: -1px;
  width: 9px; height: 9px;
  border-radius: 9999px;
  background: var(--status-online);
  box-shadow: 0 0 0 2px var(--bg);
}

/* Anillo del mockup: 2px de hueco del color de la tarjeta + linea gris fina
   alrededor (--border). El hueco separa la linea del recorte circular para que
   el avatar quede definido tanto con foto como con iniciales. */
:is(.card, .kpi, .toast, .modal) .av:not(.av-no-ring):not(.av-soft):not(.av-more) {
  border: 2px solid var(--card);
  box-shadow: 0 0 0 1px var(--border);
}
/* Igual, pero para avatares sobre barras/sidebars (UserMenu); el halo casa con
   el color de esa superficie (--bg) para quedar invisible. */
.av-ring:not(.av-no-ring):not(.av-soft):not(.av-more) {
  border: 0;
  box-shadow: 0 0 0 2px var(--bg);
}
/* Solo el halo del color de la tarjeta, sin ninguna linea gris alrededor. */
.av-gapring:not(.av-no-ring):not(.av-soft):not(.av-more),
:is(.card, .kpi, .toast, .modal) .av.av-gapring:not(.av-no-ring):not(.av-soft):not(.av-more) {
  border: 0;
  box-shadow: 0 0 0 2px var(--card);
}
/* El mismo anillo gris-con-hueco de las tarjetas/notificaciones, pero para avatares
   fuera de una tarjeta (p.ej. el del top bar): 2px de hueco del color del canvas
   (--bg-page) + linea fina --border. Asi el avatar de cuenta luce igual que el resto. */
.av-pageline:not(.av-no-ring):not(.av-soft):not(.av-more) {
  border: 2px solid var(--bg-page);
  box-shadow: 0 0 0 1px var(--border);
}
.av-with-status.live::after { background: var(--status-live); }
.av-with-status.away::after { background: var(--status-away); }
.av-group { display: inline-flex; }
.av-group .av + .av { margin-left: -8px; }
.av-group .av-more {
  background: var(--bg); color: var(--muted-fg);
  border: 1px dashed var(--border-strong);
  box-shadow: none; font-weight: 600;
}

/* Tier chips */
.chip-tier {
  display: inline-flex; align-items: center;
  height: 22px; padding: 0 9px;
  font-size: 11px; font-weight: 600; letter-spacing: 0.01em;
  border-radius: var(--r-chip);
  white-space: nowrap;
}
.tier-review { background: var(--tier-review-bg); color: var(--tier-review); }
.tier-live   { background: var(--tier-live-bg);   color: var(--tier-live); }
.tier-done   { background: var(--tier-done-bg);   color: var(--tier-done); }
.tier-new    { background: var(--tier-new-bg);    color: var(--tier-new); }
.tier-ai     { background: var(--tier-ai-bg);     color: var(--tier-ai); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--btn-gap, 7px);
  height: var(--h-toolbar);
  padding: 0 14px;
  font-family: var(--font);
  font-size: 13px; font-weight: 500;
  border-radius: var(--r-btn);
  border: 1px solid transparent;
  letter-spacing: -0.01em;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color .14s, border-color .14s, color .14s;
}
.btn-primary { background: var(--cta); color: var(--cta-fg); }
.btn-primary:hover { background: var(--cta-hover); }
/* Mockup-style CTA: dark ink instead of teal (matches /landing-v2 reference) */
.btn-ink { background: var(--ink-soft); color: var(--bg); }
.btn-ink:hover { background: var(--ink); }
.btn-secondary { background: transparent; color: var(--fg-2); border-color: var(--border-strong); }
.btn-secondary:hover { background: var(--muted); }
.btn-ghost { background: transparent; color: var(--fg-2); }
.btn-ghost:hover { background: var(--muted); }
.btn-icon { width: var(--h-toolbar); padding: 0; color: var(--fg-2); border-radius: var(--r-btn-sm); }
.btn-icon:hover { background: var(--muted); }
/* Filled icon buttons keep their light foreground (and white spinner). */
.btn-primary.btn-icon { color: var(--cta-fg); }
.btn-primary.btn-icon:hover { background: var(--cta-hover); }
.btn-ink.btn-icon { color: var(--bg); }
.btn-ink.btn-icon:hover { background: var(--ink); }
.btn-sm { height: 28px; font-size: 12.5px; padding: 0 11px; --btn-gap: 6px; }
.btn-sm.btn-icon { width: 28px; padding: 0; }
.btn-lg { height: 38px; font-size: 13.5px; padding: 0 16px; }

/* Disabled / busy state. Loading buttons keep their colour (the spinner is the
   feedback) but stop responding; plain-disabled buttons dim subtly. */
.btn:disabled:not([data-loading="true"]),
.btn[aria-disabled="true"]:not([data-loading="true"]) { opacity: .5; cursor: default; }
.btn[data-loading="true"] { cursor: default; pointer-events: none; }
/* Filled CTAs go flat monochrome grey when disabled, rather than a dimmed teal
   (a faded brand colour reads oddly). Loading buttons keep their colour above. */
.btn-primary:disabled:not([data-loading="true"]),
.btn-ink:disabled:not([data-loading="true"]),
.btn-primary[aria-disabled="true"]:not([data-loading="true"]),
.btn-ink[aria-disabled="true"]:not([data-loading="true"]) {
  background: var(--muted);
  color: var(--muted-fg);
  border-color: transparent;
  opacity: 1;
}

/* Async CTA spinner -------------------------------------------------------- */
.cta-spinner { display: block; }
.cta-spinner-track { opacity: .25; }
.cta-spinner-arc { opacity: 1; }
/* Only animate while actually visible, so hidden slots don't repaint. */
.btn-spinner-slot[data-show="true"] .cta-spinner,
.btn[data-loading="true"] .cta-spinner { animation: cta-spin 1.4s linear infinite; }
@keyframes cta-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .btn-spinner-slot[data-show="true"] .cta-spinner,
  .btn[data-loading="true"] .cta-spinner { animation-duration: 2.4s; }
}

/* Animated-size reveal: the spinner slot grows from 0 width and the negative
   margin cancels the button gap while collapsed, so the label never jumps. */
.btn-spinner-slot {
  display: inline-grid;
  grid-template-columns: 0fr;
  margin-right: calc(-1 * var(--btn-gap, 7px));
  opacity: 0;
  transition: grid-template-columns .3s cubic-bezier(.33, 0, .2, 1),
              margin-right .3s cubic-bezier(.33, 0, .2, 1),
              opacity .22s ease;
}
.btn-spinner-slot[data-show="true"] {
  grid-template-columns: 1fr;
  margin-right: 0;
  opacity: 1;
}
.btn-spinner-clip { display: inline-flex; align-items: center; overflow: hidden; min-width: 0; }
/* Icon-only buttons swap their glyph for the spinner while loading. */
.btn-icon[data-loading="true"] > :not(.btn-spinner-slot) { display: none; }
.btn-icon .btn-spinner-slot { margin-right: 0; }
.btn-icon[data-loading="true"] .btn-spinner-slot { grid-template-columns: 1fr; }

/* Inputs */
.input {
  display: inline-flex; align-items: center; gap: 8px;
  height: var(--h-input);
  padding: 0 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-input);
  font-size: 13.5px; letter-spacing: -0.005em;
  width: 100%;
  transition: border-color .14s, box-shadow .14s;
}
.input:hover { border-color: var(--border-strong); }
.input:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-bg); }
.input input, .input textarea { background: transparent; border: 0; outline: 0; width: 100%; letter-spacing: inherit; }
.input.h-tb { height: var(--h-input-tb); }

/* Multiline shell hugs the textarea (height: auto, no own min-height) so the
   bordered box and the field resize together: dragging the textarea shorter
   shrinks the container too instead of leaving dead space below. The wrapper's
   bottom/right padding insets the native resize grip a few px off the corner so
   it no longer sits jammed against both borders. The textarea owns its
   min-height so the wrapper follows it exactly. */
.input.input-multiline { padding: 0 4px 4px 0; align-items: stretch; height: auto; }
.input.input-multiline > textarea { padding: 9px 12px; resize: vertical; border-radius: inherit; display: block; }

/* Styled native select: drop the OS arrow and overlay a lucide chevron. */
.select-field { position: relative; }
.select-field__control {
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
  border: 0; outline: 0; width: 100%; background: transparent;
  padding-right: 20px; cursor: pointer;
}
.select-field__control:disabled { cursor: default; }
.select-field__icon {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  pointer-events: none; color: var(--muted-fg);
}
.label {
  display: block;
  font-size: 12.5px; font-weight: 500; color: var(--fg-2);
  letter-spacing: 0.008em;
  margin-bottom: 7px;
}

/* Cards */
.card {
  background: var(--card);
  border-radius: var(--r-card);
  padding: 22px;
}

/* Settings action rows own their vertical rhythm via padding; the last row in a
   card drops its bottom padding so the card's own padding isn't doubled there. */
.settings-action-row {
  padding: 12px 0;
}
.card > .settings-action-row:last-child {
  padding-bottom: 0;
}

.alert {
  padding: 10px 12px;
  border-radius: var(--r-input);
  border: 1px solid var(--border);
  font-size: 12.5px;
  line-height: 1.45;
  letter-spacing: 0.005em;
}
.alert-success { background: var(--accent-bg); border-color: var(--accent); color: var(--fg); }
.alert-error { background: #fff1f2; border-color: #fecdd3; color: #9f1239; }
.alert-info { background: var(--cta-bg); border-color: var(--cta); color: var(--fg-2); }

/* Custom teal checkbox: the native box is overlaid invisibly on the styled .box so
   it keeps full keyboard/click behaviour, while the check animates in on :checked. */
.checkbox { position: relative; display: inline-flex; flex-shrink: 0; }
.checkbox input {
  position: absolute; inset: 0; width: 100%; height: 100%;
  margin: 0; opacity: 0; cursor: pointer;
}
.checkbox .box {
  width: 18px; height: 18px; border-radius: 6px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--card); color: var(--bg);
  border: 1px solid var(--border-strong);
  transition: background-color .14s, border-color .14s, box-shadow .14s;
}
.checkbox .box svg { display: block; opacity: 0; transform: scale(.6); transition: opacity .14s, transform .14s; }
.checkbox input:checked + .box { background: var(--accent); border-color: var(--accent); }
.checkbox input:checked + .box svg { opacity: 1; transform: scale(1); }
.checkbox input:focus-visible + .box { box-shadow: 0 0 0 3px var(--accent-bg); }

/* Tabs (pill segmented), slightly more contrasted track so it pops on bg-page */
.tabs {
  display: inline-flex; padding: 3px; gap: 2px;
  background: var(--bg-2);
  border-radius: var(--r-tab);
  border: 1px solid var(--border-hairline);
}
.tabs button {
  height: 28px; padding: 0 12px;
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12.5px; font-weight: 500; color: var(--muted-fg);
  letter-spacing: -0.005em;
  border-radius: calc(var(--r-tab) - 3px);
  transition: background-color .14s, color .14s;
}
.tabs button:hover { color: var(--fg); }
.tabs button.on {
  background: var(--bg);
  color: var(--fg);
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(20,19,18,0.06);
}
.tabs button .count {
  font-size: 11.5px; color: var(--muted-fg-2);
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.005em;
}
.tabs button.on .count { color: var(--muted-fg); }

/* Row */
.row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 120px 56px;
  align-items: center;
  grid-column-gap: 14px;
  column-gap: 14px;
  padding: 13px 16px;
  border-radius: var(--r-row);
  cursor: pointer;
  transition: background-color .14s;
}
.row:hover { background: var(--bg-2); }
.row .name { font-size: 13.5px; font-weight: 600; color: var(--fg); letter-spacing: -0.01em; }
.row .summary {
  margin-top: 2px; font-size: 12.5px; color: var(--muted-fg);
  line-height: 1.45; letter-spacing: 0.003em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.row .chip-col { display: flex; justify-content: center; }
.row .time-col {
  text-align: right;
  font-size: 12px; color: var(--muted-fg);
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.005em;
}

/* KPI tiles */
.kpi {
  background: var(--card);
  border-radius: var(--r-card);
  padding: 16px 18px;
  min-width: 0;
}
.kpi .lbl {
  font-size: 10.5px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--muted-fg);
}
.kpi .num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 26px;
  margin-top: 4px;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.022em;
  color: var(--fg);
}
.kpi .delta {
  display: inline-flex; align-items: center; gap: 4px;
  margin-top: 4px;
  font-size: 11.5px; font-weight: 500; color: var(--accent);
  letter-spacing: 0.003em;
}
.kpi .delta.muted { color: var(--muted-fg); }

/* Lucide helper */
.lu { stroke-width: 1.8; }

/* Link */
.link-soft { color: var(--fg-2); font-weight: 500; cursor: pointer; transition: color .14s; }
.link-soft:hover { color: var(--ink); }
.link-strong { color: var(--fg); font-weight: 600; cursor: pointer; transition: color .14s; }
.link-strong:hover { color: var(--ink); }

/* kbd */
.kbd-group {
  display: inline-flex; align-items: center; gap: 2px;
  padding: 2px 6px;
  border: 1px solid var(--border);
  background: var(--bg);
  border-radius: 6px;
  font-size: 11px; font-weight: 600; color: var(--muted-fg);
  letter-spacing: 0.02em;
  height: 22px;
}

/* Toast */
.toast-stack {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: 24px;
  display: flex; flex-direction: column-reverse; align-items: center; gap: 8px;
  z-index: 1000;
  pointer-events: none;
}
.toast {
  pointer-events: auto;
  position: relative;
  display: grid;
  grid-template-columns: 22px 1fr 24px;
  align-items: center;
  grid-column-gap: 12px;
  column-gap: 12px;
  padding: 14px 16px;
  background: var(--card);
  border-radius: 18px;
  border: 1px solid var(--border-hairline);
  box-shadow: var(--shadow-pop);
  min-height: 56px;
  min-width: 320px;
  max-width: 380px;
  animation: toast-in .18s ease;
}
@keyframes toast-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.toast .ic-wrap {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 38px; width: 22px;
}
.toast .body { font-size: 13.5px; font-weight: 500; color: var(--fg);
               line-height: 1.42; letter-spacing: -0.003em; }
.toast .body .sub { display: block; margin-top: 2px; font-weight: 400;
                    color: var(--muted-fg); font-size: 12.5px; letter-spacing: 0.005em; }
.toast .x {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; border-radius: 7px;
  color: var(--muted-fg); cursor: pointer;
  align-self: center;
  transition: background-color .14s, color .14s;
}
.toast .x:hover { background: var(--muted); color: var(--fg); }

/* Modal */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 900;
  background: rgba(20,19,18,0.30);
  display: flex; align-items: center; justify-content: center;
  padding: 28px;
  animation: fade-in .16s ease;
}
@keyframes fade-in {
  from { opacity: 0; } to { opacity: 1; }
}
.modal {
  background: var(--card);
  border-radius: 22px;
  border: 1px solid var(--border-hairline);
  box-shadow: var(--shadow-modal);
  width: 440px;
  max-width: 100%;
  animation: modal-in .18s ease;
}
@keyframes modal-in {
  from { opacity: 0; transform: scale(0.97); }
  to   { opacity: 1; transform: scale(1); }
}

/* Chat typing indicator, plain dots, opacity-only animation */
.typing-dots {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 0;
}
.typing-dots span {
  width: 5px; height: 5px; border-radius: 9999px;
  background: var(--muted-fg);
  opacity: 0.25;
  animation: typing-dot 1.2s ease-in-out infinite;
}
.typing-dots span:nth-child(2) { animation-delay: 0.18s; }
.typing-dots span:nth-child(3) { animation-delay: 0.36s; }
@keyframes typing-dot {
  0%, 80%, 100% { opacity: 0.25; }
  40%           { opacity: 0.9; }
}

@keyframes msg-in {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}
.msg-in { animation: msg-in .22s ease; }
.modal-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  padding: 22px 22px 0;
}
.modal-header h3 {
  font-family: var(--font-display);
  font-size: 16px; font-weight: 700; letter-spacing: -0.014em;
}
.modal-body { padding: 14px 22px 6px; font-size: 13.5px; color: var(--fg-2); line-height: 1.55; letter-spacing: 0.005em; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; padding: 18px 22px 22px; }

/* Sparkline */
.spark { width: 100%; height: 44px; }
.spark .line { stroke: var(--accent); stroke-width: 1.8; fill: none; }
.spark .area { fill: url(#sparkfill); }

/* Bar chart bars */
.bar { background: var(--accent); border-radius: 6px; }
.bar.on { background: var(--ink); }

/* Generic divider */
.divider-h { height: 1px; background: var(--border-hairline); }

/* Scrollbar tweak, default */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 9999px; }
::-webkit-scrollbar-thumb:hover { background: var(--muted-fg-2); }
::-webkit-scrollbar-track { background: transparent; }

/* Subtle scrollbar inside floating popups (cmd palette, dropdowns).
   The thumb is inset symmetrically via a transparent content-box border so it
   never kisses the panel edge on either side, and the track is pulled in
   top/bottom by more than the panel's corner radius so it clears the rounded
   corners. The inset must stay equal left/right: an asymmetric border clips the
   rounded thumb on the wider side and it renders as a half-pill. */
.subtle-scroll { scrollbar-gutter: stable; }
.subtle-scroll::-webkit-scrollbar { width: 12px; }
.subtle-scroll::-webkit-scrollbar-track {
  background: transparent;
  margin: 12px 0;
}
.subtle-scroll::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 9999px;
  border: 3px solid transparent;
  background-clip: content-box;
}
.subtle-scroll::-webkit-scrollbar-thumb:hover {
  background: var(--muted-fg-2);
  background-clip: content-box;
}

/* ─── Patient & auth page shells ────────────────────────────────────────── */

/* Full-viewport centered column used by patient-facing screens
   (PatientLink.tsx, PatientStatus.tsx) */
.patient-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 22px 48px;
  background: var(--bg-page);
}

/* Elevated white card that forms the patient session panel.
   maxWidth is always set inline per-screen (560 / 620); this provides
   the card chrome, centering within the shell, and comfortable padding. */
.patient-card {
  width: 100%;
  background: var(--card);
  border-radius: var(--r-card);
  border: 1px solid var(--border-hairline);
  box-shadow: var(--shadow-pop);
  padding: 28px 26px 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Public patient intake (link/[slug] -> PatientLink.tsx). Header floats on the
   canvas and the intake lives in a single card, no nested-card chrome, to match
   the reference link aesthetic. */
.plink {
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.plink-card { width: 100%; text-align: left; }
.plink-tiers { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }
.plink-tier {
  position: relative;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr) auto;
  align-items: center;
  grid-gap: 12px;
  gap: 12px;
  padding: 13px 14px;
  border-radius: var(--r-row);
  border: 1px solid var(--border-soft);
  cursor: pointer;
  transition: background-color .14s, border-color .14s, box-shadow .14s;
}
.plink-tier:hover { background: var(--bg-2); }
.plink-tier input { position: absolute; opacity: 0; width: 0; height: 0; }
.plink-tier:has(input:checked) { background: var(--accent-bg); border-color: var(--accent); }
.plink-tier:has(input:focus-visible) { box-shadow: 0 0 0 3px var(--accent-bg); }
.plink-dot {
  width: 16px; height: 16px; border-radius: 9999px;
  border: 1.5px solid var(--border-strong);
  display: inline-flex; align-items: center; justify-content: center;
  transition: border-color .14s;
}
.plink-dot::after {
  content: ""; width: 8px; height: 8px; border-radius: 9999px;
  background: var(--accent); transform: scale(0); transition: transform .14s;
}
.plink-tier:has(input:checked) .plink-dot { border-color: var(--accent); }
.plink-tier:has(input:checked) .plink-dot::after { transform: scale(1); }
.plink-tier-title { font-size: 13.5px; font-weight: 600; color: var(--fg); letter-spacing: -0.01em; }
.plink-tier-desc { display: block; font-size: 12px; color: var(--muted-fg); margin-top: 2px; letter-spacing: 0.008em; line-height: 1.45; }
.plink-tier-price { font-family: var(--font-display); font-weight: 700; font-size: 17px; letter-spacing: -0.018em; }
.plink-pending {
  margin-top: 16px;
  padding: 16px;
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--bg-2);
  border: 1px solid var(--border-soft);
  border-radius: var(--r-card-sm);
}

/* Full-height flex-column container for the patient chat view
   (PatientChat.tsx); header + scroll area + composer stack vertically. */
.patient-chat {
  display: flex;
  flex-direction: column;
  height: 100vh;
  background: var(--bg-page);
  max-width: 680px;
  width: 100%;
  margin: 0 auto;
}

/* Full-viewport centered column for auth / payment / status screens
   (payment-return-view.tsx, fixture-payment-complete.tsx,
   unsubscribe/page.tsx, resource-states.tsx) */
.auth-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 22px 48px;
  background: var(--bg-page);
}

/* Elevated centered card inside .auth-page.
   maxWidth is always set inline per-screen (380 to 560); this provides
   the card chrome and text alignment. */
.auth-card {
  width: 100%;
  background: var(--card);
  border-radius: var(--r-card);
  border: 1px solid var(--border-hairline);
  box-shadow: var(--shadow-pop);
  padding: 28px 26px 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* App shell and responsive screen repair */
.app-shell {
  display: flex;
  height: 100vh;
  background: var(--bg-page);
}
.app-main {
  flex: 1 1;
  min-width: 0;
  overflow-y: auto;
}
.top-bar {
  min-width: 0;
}
.top-bar > * {
  min-width: 0;
}

/* Route-transition skeleton: shown in the dashboard content slot while the next page's data
   streams in. Theme-token driven so it reads correctly in light and dark. */
@keyframes sk-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }
.sk {
  background: var(--bg-2);
  border-radius: 8px;
  animation: sk-pulse 1.1s ease-in-out infinite;
}

/* Doctor onboarding, full-screen two-column layout: compact step rail on the
   left, focused edit column on the right, with generous separation between
   them. Collapses to a single centered column on narrow viewports. */
.onboarding-grid {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  grid-gap: 88px;
  gap: 88px;
  /* Center each column independently inside a stable, viewport-tall row so the
     left step rail stays vertically centered and never shifts when the right
     column changes height between steps. The right column re-centers around the
     same axis; its content swaps are smoothed by the step transition below. */
  align-items: center;
  min-height: calc(100vh - 112px);
}
@media (max-width: 860px) {
  .onboarding-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
    align-items: start;
    min-height: 0;
  }
  .onboarding-rail {
    position: static !important;
  }
}

/* Onboarding step transition: fade plus a short horizontal slide whose direction
   follows navigation (forward slides in from the right, back from the left). The
   keyed wrapper remounts on each step change to replay the animation. */
@keyframes ob-step-fwd {
  from { opacity: 0; transform: translateX(18px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes ob-step-back {
  from { opacity: 0; transform: translateX(-18px); }
  to   { opacity: 1; transform: translateX(0); }
}
.ob-step-fwd { animation: ob-step-fwd .28s cubic-bezier(.22, .61, .36, 1); }
.ob-step-back { animation: ob-step-back .28s cubic-bezier(.22, .61, .36, 1); }
@media (prefers-reduced-motion: reduce) {
  .ob-step-fwd,
  .ob-step-back { animation: none; }
}

/* Patient intake hero -> wizard transition. Same language as the step change
   below (fade + short slide), but vertical: the incoming phase rises from below
   on the way forward and settles from above on the way back. The wrapper is
   keyed on the phase so it remounts and replays. */
@keyframes plink-phase-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes plink-phase-down {
  from { opacity: 0; transform: translateY(-16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.plink-phase-up { animation: plink-phase-up .34s cubic-bezier(.16, 1, .3, 1); }
.plink-phase-down { animation: plink-phase-down .34s cubic-bezier(.16, 1, .3, 1); }
@media (prefers-reduced-motion: reduce) {
  .plink-phase-up,
  .plink-phase-down { animation: none; }
}

/* Selectable service rows on the hero. Icon doubles as the selection indicator
   (selected = filled accent tile + accent row), so there is no radio control. */
.plink-opt {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 13px 14px;
  border-radius: var(--r-row);
  border: 1px solid var(--border-soft);
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition: background-color .14s, border-color .14s, box-shadow .14s;
}
.plink-opt:hover { background: var(--bg-2); }
.plink-opt[data-checked="true"] { background: var(--accent-bg); border-color: var(--accent); }
.plink-opt:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--accent-bg); }
.plink-opt-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--muted);
  color: var(--fg-3);
  transition: background-color .14s, color .14s;
}
.plink-opt[data-checked="true"] .plink-opt-icon { background: var(--accent); color: var(--bg); }
.plink-opt-main { min-width: 0; flex: 1 1; }
.plink-opt-title { display: block; font-size: 13.5px; font-weight: 600; color: var(--fg); letter-spacing: -0.01em; }
.plink-opt-desc { display: block; font-size: 12px; color: var(--muted-fg); margin-top: 2px; letter-spacing: 0.008em; line-height: 1.45; }
.plink-opt-price { font-family: var(--font-display); font-weight: 700; font-size: 17px; letter-spacing: -0.018em; color: var(--fg); }
.tabs {
  max-width: 100%;
  flex-wrap: wrap;
}
.analytics-patient-row .summary,
.attachment-name,
.admin-table-value {
  overflow-wrap: anywhere;
}
.analytics-patient-row .summary,
.attachment-name,
.admin-table-value {
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
}

@media (max-width: 900px) {
  .top-bar {
    align-items: flex-start !important;
    gap: 8px !important;
    flex-wrap: wrap !important;
  }
  .top-bar > div:last-child {
    flex-wrap: wrap;
    justify-content: flex-end;
    min-width: 0;
  }
  .screen-pad {
    padding: 20px 18px 36px !important;
  }
  .case-detail-grid,
  .patient-profile-layout,
  .analytics-wide-grid,
  .analytics-two-grid,
  .admin-table-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  .analytics-kpi-grid,
  .admin-metric-grid,
  .admin-action-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  .settings-screen,
  .patient-edit-screen,
  .admin-operations {
    padding: 22px 18px 36px !important;
    max-width: none !important;
  }
  .settings-tabs {
    display: flex !important;
    width: 100%;
  }
  .settings-form-row,
  .settings-price-row {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px !important;
  }
  .settings-toggle-row,
  .settings-action-row {
    align-items: flex-start !important;
    flex-direction: column !important;
  }
  .settings-toggle-row select {
    width: 100% !important;
  }
  .admin-break-glass-form {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  .patient-profile-case-row {
    grid-template-columns: minmax(0, 1fr) auto !important;
  }
  .patient-profile-case-row > .tabular {
    grid-column: 1 / -1;
    text-align: left !important;
  }
}

@media (max-width: 800px) {
  .app-sidebar {
    width: 220px !important;
  }
}

@media (max-width: 640px) {
  /* Header publico: en movil dejamos solo el logo y el boton principal. Los
     enlaces de texto se esconden (siguen disponibles en el footer / al hacer
     scroll) para que la barra quepa en una sola fila sin amontonarse. */
  .public-nav .link-soft {
    display: none !important;
  }
  .public-nav {
    gap: 0 !important;
  }
  .app-shell {
    display: block;
    height: auto;
    min-height: 100vh;
  }
  .app-main {
    overflow: visible;
    min-height: 100vh;
  }
  .app-sidebar {
    display: none !important;
  }
  .dashboard-layout {
    display: block !important;
  }
  .dashboard-sidebar {
    display: none !important;
  }
  .dashboard-content {
    width: 100%;
  }
  .screen-pad,
  .settings-screen,
  .patient-edit-screen,
  .admin-operations {
    padding: 18px 14px 32px !important;
  }
  .top-bar {
    position: relative !important;
    padding: 12px 14px !important;
  }
  .top-bar > div:first-child {
    width: 100%;
    overflow: hidden;
  }
  .top-bar > div:last-child {
    justify-content: flex-start;
  }
  .analytics-kpi-grid,
  .admin-metric-grid,
  .admin-action-grid,
  .admin-break-glass-form {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  .attachment-row {
    grid-template-columns: 24px minmax(0, 1fr) !important;
    align-items: start !important;
  }
  .attachment-row > .t-meta {
    grid-column: 2 / -1;
  }
  .patient-profile-case-row {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  .patient-profile-case-row > div:nth-child(2) {
    justify-content: flex-start !important;
  }
  .inbox-row,
  .patients-row {
    grid-template-columns: 32px minmax(0, 1fr) !important;
    align-items: start !important;
  }
  .inbox-row .summary,
  .patients-row .summary {
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
  }
  .inbox-row .chip-col,
  .inbox-row .time-col,
  .patients-row > .tabular {
    grid-column: 2 / -1;
    justify-content: flex-start !important;
    text-align: left !important;
  }
}

@media (max-width: 820px) {
  .public-header {
    gap: 12px !important;
    padding: 14px 18px !important;
  }
  .public-section {
    padding-left: 18px !important;
    padding-right: 18px !important;
  }
  .public-hero-grid,
  .public-two-grid,
  .pricing-plan-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  .public-three-grid,
  .public-stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  .public-hero-section {
    padding-top: 48px !important;
  }
}

@media (max-width: 520px) {
  .public-header {
    position: relative !important;
  }
  .public-cta-row,
  .public-proof-row {
    align-items: stretch !important;
    flex-direction: column !important;
  }
  /* Pills here render as <a> (con `to`) o <button> (con `onClick`); estiramos y
     centramos ambos para que ninguno quede a la izquierda a media anchura. */
  .public-cta-row > a,
  .public-cta-row > button,
  .public-cta-row .btn {
    width: 100%;
    justify-content: center;
  }
  .public-three-grid,
  .public-stats-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  .public-footer {
    align-items: flex-start !important;
    flex-direction: column !important;
    gap: 14px !important;
    padding: 20px 18px !important;
  }
  .public-footer-brand {
    align-items: flex-start !important;
    flex-wrap: wrap !important;
  }
  .public-footer-links {
    flex-wrap: wrap !important;
    gap: 12px !important;
  }
}

/* Trusted-by logos — real U.S. health-system marks, flattened to monochrome by
   CSS. Two identical groups so the track can scroll -50% for a seamless loop. */
.logo-marquee {
  overflow: hidden;
  width: 100%;
  /* fade both edges so logos slide in/out softly */
  -webkit-mask-image: linear-gradient(to right, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(to right, transparent, #000 8%, #000 92%, transparent);
}
.logo-marquee__track {
  display: flex;
  width: max-content;
  align-items: center;
  animation: logo-marquee 38s linear infinite;
  will-change: transform;
}
.logo-marquee:hover .logo-marquee__track {
  animation-play-state: paused;
}
.logo-marquee__group {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.logo-marquee__item {
  display: inline-flex;
  align-items: center;
  padding: 0 38px;
  /* flatten brand colours to a soft monochrome grey */
  filter: grayscale(1) opacity(0.62) contrast(0.9);
  transition: filter .25s ease;
}
.logo-marquee__item:hover {
  filter: grayscale(1) opacity(0.95) contrast(0.95);
}
.logo-marquee__item img {
  display: block;
  height: 28px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
  -webkit-user-drag: none;
}
@keyframes logo-marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .logo-marquee__track { animation: none; }
}

/* Video demo modal — opened from the hero "Watch 2-min demo" button. */
.video-modal__overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 17, 21, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: video-modal-fade 0.18s ease-out;
}
.video-modal__dialog {
  position: relative;
  width: 100%;
  max-width: 920px;
  border-radius: 18px;
  overflow: hidden;
  background: #000;
  box-shadow: var(--shadow-pop);
  animation: video-modal-pop 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.video-modal__video {
  display: block;
  width: 100%;
  height: auto;
  max-height: 80vh;
  background: #000;
}
.video-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 9999px;
  border: none;
  cursor: pointer;
  color: #fff;
  background: rgba(15, 17, 21, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: background 0.18s ease;
}
.video-modal__close:hover {
  background: rgba(15, 17, 21, 0.85);
}
@keyframes video-modal-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes video-modal-pop {
  from { opacity: 0; transform: scale(0.96); }
  to   { opacity: 1; transform: scale(1); }
}

/*!***********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** css ../../node_modules/.pnpm/next@15.5.18_@opentelemetry+api@1.9.1_@playwright+test@1.60.0_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[2]!../../node_modules/.pnpm/next@15.5.18_@opentelemetry+api@1.9.1_@playwright+test@1.60.0_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/next/dist/build/webpack/loaders/postcss-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[3]!./src/app/globals.css ***!
  \***********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/


