@font-face {
  font-family: "Mona Sans";
  src: url("../fonts/MonaSans-Regular.woff2") format("woff2"),
       url("../fonts/MonaSans-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Mona Sans";
  src: url("../fonts/MonaSans-Medium.woff2") format("woff2"),
       url("../fonts/MonaSans-Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Mona Sans";
  src: url("../fonts/MonaSans-Black.woff2") format("woff2"),
       url("../fonts/MonaSans-Black.ttf") format("truetype");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #f3efe8;
  --ink-2: #fffdfb;
  --text: #1c1916;
  --muted: #6d645c;
  --line: rgba(48, 32, 16, 0.1);
  --amber: #b85e10;
  --good: #1b7a43;
  --bad: #b42318;
  --shadow: 0 16px 40px rgba(72, 42, 12, 0.07);
  --surface: rgba(255, 252, 248, 0.94);
  --surface-2: rgba(255, 255, 255, 0.72);
  --sidebar: #fffcf8;
  --topbar: rgba(255, 252, 248, 0.9);
  --menu: #fffcf8;
  --tooltip: #1c1916;
  --tooltip-text: #f6f1ea;
  --collapse: #ffffff;
  --hover: rgba(253, 153, 39, 0.12);
  --nav-well: rgba(48, 32, 16, 0.05);
  --input: #ffffff;
  --track: rgba(48, 32, 16, 0.08);
  --pill-idle: rgba(48, 32, 16, 0.06);
  --warm: #8a4b08;
  --warm-bg: rgba(253, 153, 39, 0.16);
  --good-bg: rgba(27, 122, 67, 0.12);
  --bad-bg: rgba(180, 35, 24, 0.1);
  --link-soft: #9a4e0a;
  --banner-bg: rgba(253, 153, 39, 0.2);
  --side-shadow: 10px 0 32px rgba(72, 42, 12, 0.05);
  --badge-ring: #fffcf8;
  color-scheme: light;
}
html.theme-dark {
  --ink: #0c0e12;
  --ink-2: #14181f;
  --text: #f6f1ea;
  --muted: #b3aa9f;
  --line: rgba(255, 255, 255, 0.1);
  --amber: #fd9927;
  --good: #b7f0cb;
  --bad: #ffb1a6;
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
  --surface: rgba(20, 24, 31, 0.78);
  --surface-2: rgba(255, 255, 255, 0.04);
  --sidebar: rgba(12, 14, 18, 0.94);
  --topbar: rgba(12, 14, 18, 0.86);
  --menu: #161a21;
  --tooltip: #1b1f27;
  --tooltip-text: #f6f1ea;
  --collapse: #161a21;
  --hover: rgba(255, 255, 255, 0.05);
  --nav-well: rgba(255, 255, 255, 0.05);
  --input: rgba(255, 255, 255, 0.03);
  --track: rgba(255, 255, 255, 0.08);
  --pill-idle: rgba(255, 255, 255, 0.06);
  --warm: #ffd7a8;
  --warm-bg: rgba(253, 153, 39, 0.16);
  --good-bg: rgba(80, 180, 120, 0.16);
  --bad-bg: rgba(255, 100, 80, 0.12);
  --link-soft: #ffd7a8;
  --banner-bg: rgba(122, 46, 14, 0.55);
  --side-shadow: none;
  --badge-ring: #12141a;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: "Mona Sans", system-ui, sans-serif;
  font-weight: 400;
  color: var(--text);
  background:
    radial-gradient(1000px 520px at 0% -10%, rgba(253, 153, 39, 0.2), transparent 55%),
    radial-gradient(800px 480px at 100% 0%, rgba(226, 91, 18, 0.16), transparent 50%),
    var(--ink);
}
body.app .orb { opacity: 0.2; filter: blur(90px); }
html.theme-dark body.app .orb { opacity: 0.16; }
html:not(.theme-dark) .grain { opacity: 0.07; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
h1, h2, h3 { font-weight: 900; letter-spacing: -0.045em; margin: 0; }
h1 { font-size: clamp(1.45rem, 2.4vw, 1.9rem); line-height: 1.15; letter-spacing: -0.03em; font-weight: 900; }
.page-head h1 { max-width: 40rem; }
h2 { font-size: 1.7rem; }
p { line-height: 1.5; }

.atmosphere { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(50px);
  opacity: 0.55;
  animation: drift 22s ease-in-out infinite alternate;
}
.orb-a { width: 420px; height: 420px; background: #fd9927; top: -120px; left: -80px; }
.orb-b { width: 360px; height: 360px; background: #e25b12; right: -120px; top: 18%; animation-duration: 28s; }
.orb-c { width: 280px; height: 280px; background: #7a2e0e; left: 32%; bottom: -120px; animation-duration: 18s; }
.grain {
  position: absolute;
  inset: -20%;
  opacity: 0.18;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='.55'/></svg>");
}
@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(6%, 8%, 0) scale(1.12); }
}

.shell, .guest-frame { position: relative; z-index: 1; }
.shell {
  --side: 252px;
  --side-ease: cubic-bezier(.22, 1, .36, 1);
  display: grid;
  grid-template-columns: var(--side) minmax(0, 1fr);
  min-height: 100vh;
  transition: grid-template-columns 0.46s var(--side-ease);
}
html.sidebar-collapsed .shell { --side: 78px; }
.sidebar {
  position: sticky;
  top: 0;
  z-index: 12;
  height: 100vh;
  width: var(--side);
  display: flex;
  flex-direction: column;
  padding: 18px 12px 16px;
  background: var(--sidebar);
  border-right: 1px solid var(--line);
  box-shadow: var(--side-shadow);
  overflow: hidden;
  transition:
    width 0.46s var(--side-ease),
    padding 0.46s var(--side-ease),
    box-shadow 0.4s ease,
    border-color 0.35s ease;
}
html.sidebar-collapsed .sidebar { padding: 16px 10px 18px; }
.sidebar::before,
.sidebar::after {
  content: "";
  position: absolute;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
}
.sidebar::before {
  inset: 0;
  background:
    linear-gradient(105deg, transparent 20%, rgba(253, 153, 39, 0.16) 48%, transparent 72%);
}
.sidebar::after {
  top: 8%;
  bottom: 8%;
  right: -1px;
  width: 3px;
  border-radius: 99px;
  background: linear-gradient(180deg, transparent, #fd9927 35%, #ffd59a 50%, #fd9927 65%, transparent);
  box-shadow: 0 0 18px rgba(253, 153, 39, 0.55);
}
.sidebar > * { position: relative; z-index: 1; }
html.is-side-morphing .sidebar {
  border-color: rgba(253, 153, 39, 0.28);
  box-shadow: 8px 0 32px rgba(253, 153, 39, 0.1), var(--side-shadow);
}
html.is-side-morphing .sidebar::before {
  animation: side-wash 0.48s var(--side-ease) both;
}
html.is-side-morphing .sidebar::after {
  animation: side-edge 0.48s var(--side-ease) both;
}
html.is-side-morphing .workspace {
  animation: side-workspace 0.46s ease both;
}
html.is-side-collapsing .nav-label,
html.is-side-collapsing .brand-copy {
  transition: max-width 0.32s var(--side-ease), opacity 0.2s ease, transform 0.32s var(--side-ease);
}
html.is-side-expanding .nav-label,
html.is-side-expanding .brand-copy {
  transition: max-width 0.42s var(--side-ease) 0.04s, opacity 0.28s ease 0.06s, transform 0.36s var(--side-ease);
}
@keyframes side-wash {
  0% { opacity: 0; transform: translateX(-12%); }
  40% { opacity: 1; }
  100% { opacity: 0; transform: translateX(18%); }
}
@keyframes side-edge {
  0% { opacity: 0; transform: scaleY(0.4); }
  35% { opacity: 1; transform: scaleY(1); }
  100% { opacity: 0; transform: scaleY(0.85); }
}
@keyframes side-workspace {
  0% { filter: brightness(1); }
  40% { filter: brightness(1.03) saturate(1.04); }
  100% { filter: none; }
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  min-width: 0;
  text-decoration: none;
  padding: 6px 8px;
  transition: padding 0.55s var(--side-ease), gap 0.45s ease;
}
.brand-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 168px;
  overflow: hidden;
  white-space: nowrap;
  transition: max-width 0.5s var(--side-ease), opacity 0.32s ease, transform 0.45s var(--side-ease);
}
.brand-copy strong { font-weight: 900; letter-spacing: -0.04em; }
.brand-copy small, .sidebar-foot small, .muted, .fine { color: var(--muted); }
.brand-logo { height: 42px; width: auto; max-width: 148px; object-fit: contain; display: block; }
.guest .brand-logo { height: 72px; max-width: 240px; }
.wordmark {
  font-weight: 900;
  font-size: 1.8rem;
  letter-spacing: -0.06em;
  background: linear-gradient(110deg, #ffe1b0 0%, #fd9927 30%, #fff6ea 48%, #e25b12 70%, #ffc56a 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: sweep 5.5s linear infinite;
}
@keyframes sweep { to { background-position: 200% 50%; } }
.brand-shine { position: relative; display: inline-flex; overflow: hidden; }
.brand-shine::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.55), transparent 70%);
  transform: translateX(-130%);
  animation: sheen 4.8s ease-in-out infinite;
  pointer-events: none;
}
@keyframes sheen { 40%, 100% { transform: translateX(130%); } }

.side-brand { padding: 4px 6px 16px; margin-bottom: 8px; border-bottom: 1px solid var(--line); transition: padding 0.5s var(--side-ease), margin 0.5s var(--side-ease); }
.side-kicker {
  margin: 14px 12px 8px;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  transition: height 0.45s var(--side-ease), margin 0.45s var(--side-ease), opacity 0.28s ease;
}
html.sidebar-collapsed .side-kicker { height: 0; margin: 10px 0 0; overflow: hidden; opacity: 0; }
.nav { position: relative; display: flex; flex-direction: column; gap: 2px; transition: gap 0.45s var(--side-ease); }
.nav a {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  text-decoration: none;
  padding: 4px 8px;
  border-radius: 14px;
  color: var(--muted);
  white-space: nowrap;
  transition:
    min-height 0.5s var(--side-ease),
    padding 0.5s var(--side-ease),
    gap 0.4s ease,
    border-radius 0.45s ease,
    width 0.5s var(--side-ease),
    background 0.2s ease,
    color 0.2s ease;
}
.nav a:nth-child(2) { --nav-i: 0; }
.nav a:nth-child(3) { --nav-i: 1; }
.nav a:nth-child(4) { --nav-i: 2; }
.nav a:nth-child(5) { --nav-i: 3; }
.nav a:nth-child(6) { --nav-i: 4; }
.nav a:nth-child(7) { --nav-i: 5; }
.nav a:nth-child(8) { --nav-i: 6; }
.nav a:nth-child(9) { --nav-i: 7; }
.nav a:nth-child(10) { --nav-i: 8; }
.nav a:nth-child(11) { --nav-i: 9; }
.nav a:not(.is-active):hover { color: var(--text); background: var(--hover); }
.nav-ico {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  border-radius: 11px;
  background: var(--nav-well);
  transition:
    width 0.5s var(--side-ease),
    height 0.5s var(--side-ease),
    flex-basis 0.5s var(--side-ease),
    border-radius 0.45s ease,
    background 0.3s ease,
    box-shadow 0.3s ease,
    transform 0.45s var(--side-ease);
}
.nav a.is-active .nav-ico { background: transparent; }
.nav a.is-active { color: #2a1203; font-weight: 500; }
.nav-label {
  overflow: hidden;
  max-width: 160px;
  transition: max-width 0.5s var(--side-ease), opacity 0.28s ease, transform 0.4s var(--side-ease);
}
.nav-pill {
  position: absolute;
  left: 0;
  top: 0;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(115deg, #fff1dc 0%, #ffd59a 18%, #fd9927 46%, #c56a12 68%, #ffe7c4 100%);
  transition:
    transform 0.34s var(--side-ease),
    height 0.34s var(--side-ease),
    width 0.34s var(--side-ease),
    left 0.34s var(--side-ease),
    border-radius 0.34s var(--side-ease),
    box-shadow 0.35s ease,
    filter 0.35s ease;
  box-shadow: 0 8px 22px rgba(253, 153, 39, 0.22);
  will-change: transform, width, height, left;
  pointer-events: none;
}
html.is-side-morphing .nav-pill {
  transition: box-shadow 0.35s ease, filter 0.35s ease, border-radius 0.28s ease;
  filter: saturate(1.1);
  box-shadow: 0 10px 26px rgba(253, 153, 39, 0.3);
}
html.sidebar-collapsed .side-brand {
  display: grid;
  place-items: center;
  padding: 2px 0 14px;
  margin-bottom: 6px;
}
html.sidebar-collapsed .brand { justify-content: center; gap: 0; padding: 4px; }
html.sidebar-collapsed .brand-copy,
html.sidebar-collapsed .nav-label {
  max-width: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-8px);
}
html.sidebar-collapsed .nav { gap: 6px; align-items: center; }
html.sidebar-collapsed .nav a {
  justify-content: center;
  gap: 0;
  width: 100%;
  min-height: 54px;
  padding: 0;
  border-radius: 18px;
}
html.sidebar-collapsed .nav-ico {
  width: 48px;
  height: 48px;
  flex-basis: 48px;
  border-radius: 16px;
  background: var(--nav-well);
}
html.sidebar-collapsed .nav a.is-active .nav-ico {
  background: rgba(42, 18, 3, 0.08);
  box-shadow: inset 0 0 0 1px rgba(253, 153, 39, 0.28);
}
.nav-tip {
  position: fixed;
  z-index: 80;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px 9px 12px;
  border-radius: 14px;
  border: 1px solid rgba(253, 153, 39, 0.42);
  background:
    linear-gradient(135deg, rgba(255, 241, 220, 0.98), rgba(255, 252, 248, 0.96) 55%),
    #1c1916;
  color: #2a1203;
  font-size: 0.86rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transform: translate(-6px, -50%) scale(0.96);
  transform-origin: left center;
  box-shadow:
    0 16px 40px rgba(42, 18, 3, 0.22),
    0 0 0 1px rgba(255, 255, 255, 0.35) inset,
    0 0 24px rgba(253, 153, 39, 0.18);
  transition: opacity 0.2s ease, transform 0.28s cubic-bezier(.22, 1, .36, 1);
}
.nav-tip::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: linear-gradient(145deg, #ffd59a, #fd9927 55%, #c56a12);
  box-shadow: 0 0 10px rgba(253, 153, 39, 0.55);
  flex: 0 0 auto;
}
.nav-tip::after {
  content: "";
  position: absolute;
  left: -5px;
  top: 50%;
  width: 10px;
  height: 10px;
  margin-top: -5px;
  border-radius: 2px;
  background: linear-gradient(135deg, #fff1dc, #fffcf8);
  border-left: 1px solid rgba(253, 153, 39, 0.42);
  border-bottom: 1px solid rgba(253, 153, 39, 0.42);
  transform: rotate(45deg);
}
html.theme-dark .nav-tip {
  background:
    linear-gradient(145deg, #3a2414, #1a120c 60%);
  color: #fff6ea;
  border-color: rgba(253, 153, 39, 0.5);
  box-shadow:
    0 18px 42px rgba(0, 0, 0, 0.45),
    0 0 28px rgba(253, 153, 39, 0.16),
    inset 0 1px 0 rgba(255, 213, 154, 0.18);
}
html.theme-dark .nav-tip::after {
  background: #2a1a10;
  border-color: rgba(253, 153, 39, 0.45);
}
.nav-tip.is-on {
  opacity: 1;
  transform: translate(0, -50%) scale(1);
}
.sidebar .wordmark { animation: none; background-position: 0 50%; }
.sidebar .brand-shine::after { animation: none; }
.ico { width: 18px; height: 18px; flex: 0 0 18px; }
.sidebar .brand-logo { height: 28px; max-width: 52px; object-fit: contain; }
.sidebar .brand-copy small { font-size: 0.75rem; }
html.sidebar-collapsed .brand-logo { height: 32px; max-width: 40px; }
html.sidebar-collapsed .sidebar .wordmark { font-size: 1.35rem; }
.text-btn, .btn, .icon-btn, .side-toggle, .account-trigger, .icon-tool { cursor: pointer; }
.side-toggle {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--muted);
  transition:
    border-color 0.22s ease,
    background 0.22s ease,
    color 0.22s ease,
    transform 0.22s ease;
}
.side-toggle:hover {
  border-color: rgba(253, 153, 39, 0.45);
  background: rgba(253, 153, 39, 0.1);
  color: #9a4e0a;
}
.side-toggle:active { transform: scale(0.94); }
html.is-side-morphing .side-toggle {
  border-color: rgba(253, 153, 39, 0.55);
  color: #c56a12;
  background: rgba(253, 153, 39, 0.14);
}
.side-toggle-ico {
  width: 16px;
  height: 16px;
  transition: transform 0.45s var(--side-ease);
}
html.sidebar-collapsed .side-toggle-ico { transform: rotate(180deg); }
.text-btn { background: none; border: 0; color: var(--muted); padding: 0; }
.text-btn:hover { color: var(--text); }

.workspace { position: relative; z-index: 1; min-width: 0; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  min-height: 72px;
  padding: 12px 28px;
  background: var(--topbar);
  border-bottom: 1px solid var(--line);
  overflow: visible;
}
.topbar-lead, .topbar-tools { display: flex; align-items: center; gap: 10px; min-width: 0; overflow: visible; }
.topbar-lead { flex: 1; }
.topbar-tools { margin-left: auto; }
.topbar-context { margin: 0; color: var(--muted); font-size: 0.92rem; white-space: nowrap; }
.page-head { margin-bottom: 18px; }
.eyebrow { margin: 0 0 6px; text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.72rem; color: var(--amber); font-weight: 500; }
.page { padding: 26px 32px 48px; }
.rise > * { animation: rise 0.7s cubic-bezier(.16,1,.3,1) both; }
.rise > *:nth-child(2) { animation-delay: 0.06s; }
.rise > *:nth-child(3) { animation-delay: 0.12s; }
.rise > *:nth-child(4) { animation-delay: 0.18s; }
@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

.lede { color: var(--muted); max-width: 46rem; }
.hero-line, .detail-head, .panel-head, .form-actions, .action-row, .modal-actions {
  display: flex; justify-content: space-between; gap: 16px; align-items: center; flex-wrap: wrap;
}
.kpi-grid, .split-panels, .settings-grid { display: grid; gap: 16px; }
.kpi-grid { grid-template-columns: repeat(4, 1fr); margin: 22px 0; }
.split-panels { grid-template-columns: 1fr 1fr; }
.settings-grid { max-width: 920px; }
.kpi, .panel, .card, .auth-card, .center-card, .modal-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}
.kpi, .panel, .card, .center-card { padding: 22px; }
.kpi span, .kpi small { display: block; color: var(--muted); }
.kpi strong { display: block; margin: 10px 0 6px; font-size: 1.8rem; font-weight: 900; letter-spacing: -0.04em; }

.dash-stage {
  position: relative;
  overflow: hidden;
  margin: 0 0 8px;
  padding: 26px 26px 18px;
  border-radius: 32px;
  border: 1px solid rgba(253, 153, 39, .28);
  background:
    radial-gradient(80% 70% at 0% 0%, rgba(253, 153, 39, .22), transparent 55%),
    radial-gradient(70% 60% at 100% 100%, rgba(255, 213, 154, .14), transparent 50%),
    linear-gradient(145deg, rgba(255,255,255,.55), rgba(255,255,255,.08));
  box-shadow: 0 24px 50px rgba(42, 18, 3, .08), inset 0 1px 0 rgba(255,255,255,.55);
  animation: dash-stage-in .9s cubic-bezier(.16, 1, .3, 1) both;
}
html.theme-dark .dash-stage {
  background:
    radial-gradient(80% 70% at 0% 0%, rgba(253, 153, 39, .28), transparent 55%),
    radial-gradient(70% 60% at 100% 100%, rgba(255, 213, 154, .1), transparent 50%),
    linear-gradient(145deg, #2a1c12, #120e0b);
}
.dash-aurora { position: absolute; inset: -20%; pointer-events: none; }
.dash-aurora i {
  position: absolute; width: 42%; height: 42%; border-radius: 50%;
  filter: blur(40px); opacity: .55; animation: dash-drift 10s ease-in-out infinite alternate;
}
.dash-aurora i:nth-child(1) { left: -5%; top: -10%; background: rgba(253, 153, 39, .45); }
.dash-aurora i:nth-child(2) { right: -8%; top: 20%; background: rgba(255, 213, 154, .35); animation-delay: .8s; }
.dash-aurora i:nth-child(3) { left: 30%; bottom: -20%; background: rgba(197, 106, 18, .28); animation-delay: 1.4s; }
.dash-hero {
  position: relative; z-index: 1;
  display: flex; justify-content: space-between; gap: 18px; align-items: end; flex-wrap: wrap;
  margin-bottom: 16px;
}
.dash-hero h2 {
  margin: 4px 0 8px;
  font-size: clamp(1.8rem, 3.4vw, 2.8rem);
  letter-spacing: -.05em;
  line-height: 1.05;
}
.dash-hero .lede { margin: 0; max-width: 36rem; color: var(--muted); }
.dash-kpis { margin-top: 18px; gap: 14px; }
.fx-dock {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  z-index: 6;
}
.fx-dock .icon-tool {
  position: relative;
  z-index: 2;
  flex: 0 0 auto;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
}
.fx-ribbon {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 42px;
  padding: 0 14px;
  white-space: nowrap;
  border-radius: 999px;
  border: 1px solid rgba(253, 153, 39, .35);
  background:
    linear-gradient(120deg, rgba(255, 241, 220, .95), rgba(255, 213, 154, .45) 45%, rgba(253, 153, 39, .16)),
    var(--surface);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.65);
  transform-origin: right center;
  pointer-events: none;
  overflow: hidden;
}
html.theme-dark .fx-ribbon {
  background:
    linear-gradient(120deg, rgba(58, 36, 20, .95), rgba(253, 153, 39, .16)),
    rgba(18, 12, 8, .88);
}
.fx-ribbon[hidden] {
  display: inline-flex !important;
  width: 0;
  min-width: 0;
  padding: 0;
  border-width: 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.fx-ribbon.is-open {
  visibility: visible;
  pointer-events: auto;
  animation: fx-ribbon-in .55s cubic-bezier(.16, 1, .3, 1) both;
}
.fx-ribbon.is-closing {
  visibility: visible;
  pointer-events: none;
  animation: fx-ribbon-out .32s cubic-bezier(.4, 0, .2, 1) both;
}
.fx-pair { display: flex; flex-direction: column; gap: 1px; line-height: 1.05; }
.fx-pair small {
  font-size: .56rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}
.fx-pair strong {
  font-size: .84rem;
  letter-spacing: -.02em;
  color: var(--text);
  transition: color .35s ease, text-shadow .35s ease, transform .35s ease;
}
.fx-pair strong.is-up {
  color: #0f7a3a;
  text-shadow: 0 0 12px rgba(15, 122, 58, .25);
  animation: fx-flash-up .55s ease;
}
.fx-pair strong.is-down {
  color: #c62828;
  text-shadow: 0 0 12px rgba(198, 40, 40, .28);
  animation: fx-flash-down .55s ease;
}
@keyframes fx-ribbon-in {
  0% { opacity: 0; max-width: 0; transform: scaleX(.2); filter: blur(6px); }
  60% { opacity: 1; max-width: 240px; transform: scaleX(1.03); filter: blur(0); }
  100% { opacity: 1; max-width: 240px; transform: none; filter: none; }
}
@keyframes fx-ribbon-out {
  0% { opacity: 1; max-width: 240px; transform: none; filter: none; }
  100% { opacity: 0; max-width: 0; transform: scaleX(.2); filter: blur(6px); }
}
@keyframes fx-flash-up {
  0% { transform: translateY(4px); }
  40% { transform: translateY(-2px) scale(1.04); }
  100% { transform: none; }
}
@keyframes fx-flash-down {
  0% { transform: translateY(-4px); }
  40% { transform: translateY(2px) scale(1.04); }
  100% { transform: none; }
}
@media (max-width: 720px) {
  .fx-ribbon { height: 40px; gap: 10px; padding: 0 12px; }
  .fx-pair strong { font-size: .78rem; }
}
.dash-kpi {
  position: relative;
  overflow: hidden;
  min-height: 148px;
  padding: 20px 18px 16px;
  border-color: rgba(253, 153, 39, .22);
  background:
    linear-gradient(155deg, rgba(253, 153, 39, .12), transparent 48%),
    var(--surface);
  transform-origin: 50% 120%;
  animation: kpi-pop .85s cubic-bezier(.16, 1, .3, 1) both;
  animation-delay: calc(var(--i) * 70ms + 120ms);
  transition: transform .28s ease, border-color .28s ease, box-shadow .28s ease, background .45s ease, filter .35s ease;
}
.dash-kpi:hover {
  transform: translateY(-5px) scale(1.015);
  border-color: rgba(253, 153, 39, .55);
  box-shadow: 0 18px 36px rgba(197, 106, 18, .16);
}
.dash-kpi .kpi-label {
  position: relative;
  z-index: 1;
  font-size: .72rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #9a4e0a;
}
html.theme-dark .dash-kpi .kpi-label {
  color: #ffd59a;
  text-shadow: 0 0 18px rgba(253, 153, 39, .4);
}
.dash-kpi strong {
  position: relative;
  z-index: 1;
  margin: 14px 0 8px;
  font-size: clamp(1.55rem, 2.2vw, 2.05rem);
  background: linear-gradient(120deg, #2a1203 10%, #c56a12 45%, #fd9927 75%, #2a1203);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: metal-flow 4.5s linear infinite;
}
html.theme-dark .dash-kpi {
  border-color: rgba(253, 153, 39, .48);
  background:
    radial-gradient(120% 100% at 100% -10%, rgba(253, 153, 39, .42), transparent 52%),
    radial-gradient(90% 80% at 0% 110%, rgba(226, 91, 18, .22), transparent 55%),
    linear-gradient(165deg, #3f2614 0%, #1c130c 48%, #100d0a 100%);
  box-shadow:
    0 20px 44px rgba(0, 0, 0, .42),
    inset 0 1px 0 rgba(255, 213, 154, .28),
    0 0 0 1px rgba(253, 153, 39, .14),
    0 0 32px rgba(253, 153, 39, .08);
}
html.theme-dark .dash-kpi::after {
  content: "";
  position: absolute;
  inset: auto -20% -35% 35%;
  height: 70%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(253, 153, 39, .28), transparent 68%);
  pointer-events: none;
}
html.theme-dark .dash-kpi strong {
  background: linear-gradient(115deg, #ffffff 0%, #ffe7c4 22%, #fd9927 52%, #ffd59a 78%, #fff6ea 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  filter: drop-shadow(0 0 16px rgba(253, 153, 39, .55));
  font-size: clamp(1.65rem, 2.35vw, 2.2rem);
}
html.theme-dark .dash-kpi small {
  color: rgba(255, 241, 220, .78);
  text-shadow: 0 1px 0 rgba(0, 0, 0, .35);
}
html.theme-dark .dash-kpi:hover {
  transform: translateY(-6px) scale(1.02);
  border-color: #fd9927;
  box-shadow:
    0 26px 54px rgba(253, 153, 39, .22),
    inset 0 1px 0 rgba(255, 246, 234, .3),
    0 0 0 1px rgba(253, 153, 39, .35);
}
.dash-kpi small { position: relative; z-index: 1; }
.dash-kpi .kpi-sheen {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.35) 48%, transparent 62%);
  transform: translateX(-130%);
  animation: sheen 1.6s ease both;
  animation-delay: calc(var(--i) * 80ms + 350ms);
}
html.theme-dark .dash-kpi .kpi-sheen {
  background: linear-gradient(115deg, transparent 28%, rgba(255, 213, 154, .38) 48%, transparent 64%);
}
.dash-kpi.is-metal {
  background:
    linear-gradient(145deg, rgba(253, 153, 39, .22), transparent 42%),
    linear-gradient(180deg, #fff8ef, var(--surface));
}
html.theme-dark .dash-kpi.is-metal {
  background:
    radial-gradient(110% 90% at 100% 0%, rgba(255, 197, 106, .4), transparent 50%),
    linear-gradient(165deg, #4a2c12, #1a120c 58%);
}
.dash-kpi.is-warm { border-color: rgba(253, 153, 39, .4); }
html.theme-dark .dash-kpi.is-warm {
  border-color: rgba(253, 153, 39, .62);
  box-shadow:
    0 20px 44px rgba(0, 0, 0, .42),
    inset 0 1px 0 rgba(255, 213, 154, .32),
    0 0 36px rgba(253, 153, 39, .16);
}
.dash-kpi.is-good {
  background:
    linear-gradient(145deg, rgba(142, 215, 173, .22), transparent 45%),
    var(--surface);
}
html.theme-dark .dash-kpi.is-good {
  background:
    radial-gradient(110% 90% at 100% 0%, rgba(253, 153, 39, .3), transparent 48%),
    radial-gradient(80% 70% at 0% 100%, rgba(80, 180, 120, .18), transparent 55%),
    linear-gradient(165deg, #2a2214, #10140f 58%);
}
html.theme-dark .dash-kpi.is-soft {
  background:
    radial-gradient(110% 90% at 100% 0%, rgba(253, 153, 39, .34), transparent 50%),
    linear-gradient(165deg, #342214, #14100d 60%);
}
.dash-charts .dash-panel,
.split-panels .dash-panel {
  animation: dash-stage-in .8s cubic-bezier(.16, 1, .3, 1) both;
  animation-delay: .35s;
}
@keyframes dash-stage-in {
  from { opacity: 0; transform: translateY(24px) scale(.985); filter: blur(6px); }
  to { opacity: 1; transform: none; filter: none; }
}
@keyframes kpi-pop {
  0% { opacity: 0; transform: translateY(36px) scale(.92); filter: blur(8px); }
  70% { opacity: 1; transform: translateY(-6px) scale(1.03); filter: blur(0); }
  100% { opacity: 1; transform: none; filter: none; }
}
@keyframes dash-drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(8%, -6%, 0) scale(1.12); }
}
@keyframes metal-flow {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

/* Theme tint: radial wash from the toggle, fast & professional */
.theme-veil {
  --x: 50%;
  --y: 50%;
  position: fixed;
  inset: 0;
  z-index: 12000;
  pointer-events: none;
  clip-path: circle(0px at var(--x) var(--y));
  opacity: 1;
  transition:
    clip-path 0.42s cubic-bezier(.22, 1, .36, 1),
    opacity 0.22s ease;
  will-change: clip-path, opacity;
}
.theme-veil.to-dark {
  background:
    radial-gradient(circle at var(--x) var(--y),
      #fff1dc 0%,
      #fd9927 14%,
      #c56a12 32%,
      #2a1203 58%,
      #0c0e12 78%);
}
.theme-veil.to-light {
  background:
    radial-gradient(circle at var(--x) var(--y),
      #fd9927 0%,
      #ffd59a 18%,
      #fff1dc 42%,
      #fffcf8 72%);
}
.theme-veil.is-on {
  clip-path: circle(155vmax at var(--x) var(--y));
}
.theme-veil.is-fade {
  opacity: 0;
}
html.is-theme-burst .is-theme-source {
  position: relative;
  z-index: 12001;
  border-color: rgba(253, 153, 39, .75) !important;
  background: linear-gradient(145deg, #fff1dc, #fd9927) !important;
  color: #2a1203 !important;
  box-shadow:
    0 0 0 5px rgba(253, 153, 39, .2),
    0 10px 24px rgba(253, 153, 39, .3);
  animation: theme-source-pulse 0.42s ease both;
}
@keyframes theme-source-pulse {
  0% { transform: scale(1); }
  45% { transform: scale(1.08); }
  100% { transform: scale(1); }
}
html.is-theme-settling .dash-kpi {
  animation: kpi-theme-flare 0.48s cubic-bezier(.22, 1, .36, 1) both;
  animation-delay: calc(var(--i, 0) * 28ms);
}
@keyframes kpi-theme-flare {
  0% { filter: brightness(1.18) saturate(1.2); }
  100% { filter: none; }
}
html.is-theme-settling .dash-stage {
  animation: stage-theme-wash 0.42s ease both;
}
@keyframes stage-theme-wash {
  0% { filter: brightness(1.1) saturate(1.12); }
  100% { filter: none; }
}
html.is-theme-settling .dash-kpi .kpi-sheen {
  animation: sheen 0.55s ease both;
  animation-delay: calc(var(--i, 0) * 24ms);
}
.meter { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 18px; }
.meter div { padding: 14px 16px; border-radius: 18px; background: var(--surface-2); border: 1px solid var(--line); }
.meter strong { display: block; font-size: 1.4rem; font-weight: 900; }
.meter span { color: var(--muted); font-size: 0.85rem; }
.panel-head { margin-bottom: 8px; }
.panel-head a { color: var(--amber); text-decoration: none; }

.btn {
  position: relative;
  overflow: hidden;
  border-radius: 999px;
  padding: 0.85rem 1.2rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
}
.btn-primary {
  color: #2a1203;
  font-weight: 900;
  background: linear-gradient(120deg, #ffc56a, #fd9927 40%, #e25b12 78%, #7a2e0e);
  background-size: 180% 180%;
  border: 0;
}
.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,.45), transparent 80%);
  transform: translateX(-120%);
  animation: sheen 3.8s ease-in-out infinite;
}
.btn-ghost { background: transparent; border-color: var(--line); }
.btn-danger { background: transparent; color: var(--bad); border-color: rgba(255, 139, 122, 0.35); }
.btn-block { width: 100%; margin: 10px 0; }
.icon-btn {
  width: 42px; height: 42px; border-radius: 14px; border: 1px solid var(--line); background: transparent; align-self: end;
}

.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field span { font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.field input, .field select, .field textarea, .search input {
  width: 100%;
  background: var(--input);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.85rem 0.95rem;
  outline: none;
}
.field input:focus, .field select:focus, .field textarea:focus, .search input:focus {
  border-color: rgba(253, 153, 39, 0.8);
  box-shadow: 0 0 0 4px rgba(253, 153, 39, 0.15);
}
.stack { display: flex; flex-direction: column; gap: 14px; }
.grid-2, .grid-3 { display: grid; gap: 14px; }
.grid-2 { grid-template-columns: 1fr 1fr; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.hint { color: var(--muted); margin: 0; }
.flash { border-radius: 16px; padding: 12px 14px; border: 1px solid var(--line); margin-bottom: 14px; }
.flash-ok { border-color: rgba(183, 240, 203, 0.45); }
.flash-error { border-color: rgba(255, 177, 166, 0.5); }
.toast-host {
  position: fixed;
  top: max(16px, env(safe-area-inset-top));
  left: 50%;
  transform: translateX(-50%);
  z-index: 12000;
  width: min(420px, calc(100vw - 24px));
  pointer-events: none;
  display: grid;
  gap: 10px;
}
.toast {
  position: relative;
  overflow: hidden;
  pointer-events: auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px 14px 16px;
  border-radius: 20px;
  border: 1px solid rgba(255, 213, 154, 0.35);
  background:
    linear-gradient(145deg, rgba(42, 18, 3, 0.96), rgba(92, 46, 10, 0.92) 55%, rgba(26, 16, 10, 0.96));
  color: #fff6ea;
  box-shadow:
    0 22px 48px rgba(42, 18, 3, 0.35),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  opacity: 0;
  transform: translateY(-18px) scale(0.96);
  transition: opacity .35s ease, transform .45s cubic-bezier(.16, 1, .3, 1);
}
.toast.is-in {
  opacity: 1;
  transform: translateY(0) scale(1);
}
.toast.is-out {
  opacity: 0;
  transform: translateY(-12px) scale(0.97);
}
.toast-aura {
  position: absolute;
  inset: -40% auto auto 55%;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(253, 153, 39, 0.45), transparent 68%);
  pointer-events: none;
  animation: toast-glow 2.4s ease-in-out infinite alternate;
}
.toast-mark {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #fff6ea, #ffd59a 50%, #fd9927);
  color: #2a1203;
  box-shadow: 0 10px 22px rgba(253, 153, 39, 0.35);
}
.toast-mark::before {
  content: "✓";
  font-weight: 800;
  font-size: 1.1rem;
  line-height: 1;
}
.toast-error .toast-mark {
  background: linear-gradient(145deg, #ffe4df, #ffb1a6 55%, #e85d4c);
  box-shadow: 0 10px 22px rgba(232, 93, 76, 0.28);
}
.toast-error .toast-mark::before { content: "!"; }
.toast-info .toast-mark {
  background: linear-gradient(145deg, #eef6ff, #c9ddff 55%, #6f9dff);
  box-shadow: 0 10px 22px rgba(111, 157, 255, 0.28);
}
.toast-info .toast-mark::before { content: "i"; font-style: italic; }
.toast-copy { min-width: 0; position: relative; z-index: 1; }
.toast-copy strong {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #ffd59a;
  margin-bottom: 4px;
}
.toast-error .toast-copy strong { color: #ffb1a6; }
.toast-info .toast-copy strong { color: #c9ddff; }
.toast-copy p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.35;
  letter-spacing: -0.01em;
}
.toast-close {
  position: relative;
  z-index: 1;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff6ea;
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}
.toast-close:hover { background: rgba(255, 255, 255, 0.16); }
.toast-rail {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 8px;
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
}
.toast-rail i {
  display: block;
  height: 100%;
  width: 100%;
  transform-origin: left center;
  background: linear-gradient(90deg, #ffd59a, #fd9927);
  animation: toast-rail 4.2s linear forwards;
}
.toast-error .toast-rail i { background: linear-gradient(90deg, #ffb1a6, #e85d4c); }
.toast-info .toast-rail i { background: linear-gradient(90deg, #c9ddff, #6f9dff); }
@keyframes toast-glow {
  from { opacity: 0.55; transform: translate(-10%, -8%) scale(0.92); }
  to { opacity: 1; transform: translate(-18%, -2%) scale(1.08); }
}
@keyframes toast-rail {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}
@media (prefers-reduced-motion: reduce) {
  .toast, .toast-aura, .toast-rail i { animation: none !important; transition: none !important; }
  .toast { opacity: 1; transform: none; }
}
.banner { padding: 10px 14px; border-radius: 14px; background: var(--banner-bg); color: var(--text); letter-spacing: 0.08em; font-weight: 900; font-size: 0.78rem; }

.split { display: grid; grid-template-columns: minmax(280px, 380px) 1fr; gap: 18px; align-items: start; }
.split-list, .split-detail { min-width: 0; }
.list { display: flex; flex-direction: column; gap: 8px; }
.row-link {
  display: flex; justify-content: space-between; gap: 12px; align-items: center;
  text-decoration: none; padding: 12px 14px; border-radius: 16px;
  border: 1px solid transparent; background: var(--surface-2);
  animation: rise 0.55s cubic-bezier(.16,1,.3,1) both;
  animation-delay: calc(var(--i, 0) * 40ms);
}
.row-link small, .row-link span { display: block; }
.row-link small { color: var(--muted); }
.row-link.is-selected, .row-link:hover { border-color: rgba(253, 153, 39, 0.45); }
.empty, .empty-stage { color: var(--muted); }
.empty-stage { min-height: 420px; display: grid; align-content: center; justify-items: start; gap: 8px; padding: 20px; }
.search { margin-bottom: 8px; }
.toolbar { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; }
.toolbar .search { flex: 1; margin: 0; }
.toolbar .search input { width: 100%; }
.catalog { width: 100%; }
.catalog .row-link { width: 100%; }
.catalog .row-link > span { flex: 1; min-width: 0; }
.catalog .row-link b { font-weight: 500; white-space: nowrap; }
.back-line { margin: 0 0 14px; }
.back-line a { color: var(--muted); text-decoration: none; }
.sheet-card { width: min(980px, 100%); max-height: min(88vh, 920px); overflow: auto; }
.sheet-head { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 8px; padding-right: 52px; }
.sheet-card .doc-form { border: 0; background: transparent; padding: 0; box-shadow: none; }
button.row-link { width: 100%; text-align: left; cursor: pointer; }
body.modal-open { overflow: hidden; }

.pill { border-radius: 999px; padding: 0.35rem 0.75rem; font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; white-space: nowrap; font-weight: 500; }
.pill-borrador { background: var(--pill-idle); color: var(--muted); }
.pill-enviada, .pill-emitida { color: #2a1203; background: linear-gradient(120deg, #fff1dc, #ffd59a 40%, #fd9927); }
.pill-aprobada, .pill-aceptada, .pill-pagado { color: #06331c; background: linear-gradient(120deg, #e7f8ee, #8ed7ad); }
.pill-facturada { color: #2a1203; background: linear-gradient(115deg, #fff6e8, #fd9927 45%, #c56a12); box-shadow: inset 0 1px 0 rgba(255,255,255,.65); }
.pill-pendiente { color: #6a3b0c; background: rgba(253, 153, 39, .16); border: 1px solid rgba(253, 153, 39, .35); }
.pill-rechazada { color: var(--bad); background: var(--bad-bg); }
.pill-abierta { color: #2a1203; background: linear-gradient(120deg, #fff1dc, #ffd59a 40%, #fd9927); }
.pill-cerrada { color: var(--muted); background: var(--pill-idle); }
.pill-aceptada_condicional { color: var(--warm); background: var(--warm-bg); }
.stamp {
  display: inline-flex; border: 1.5px solid currentColor; border-radius: 12px;
  padding: 0.45rem 0.7rem; text-transform: uppercase; letter-spacing: 0.14em;
  font-weight: 900; font-size: 0.75rem; transform: rotate(-8deg);
  animation: stamp-in 0.55s cubic-bezier(.16,1,.3,1) both;
}
.stamp-aprobada, .stamp-aceptada { color: var(--good); }
.stamp-rechazada { color: var(--bad); }
.stamp-enviada, .stamp-facturada, .stamp-emitida { color: var(--warm); }
@keyframes stamp-in { from { opacity: 0; transform: rotate(-18deg) scale(1.3); } }

.pipeline { position: relative; margin: 18px 0 8px; }
.pipeline-track { height: 3px; background: var(--track); border-radius: 99px; margin: 0 8% 12px; }
.pipeline-track span {
  display: block; height: 100%; width: 0; border-radius: inherit;
  background: linear-gradient(90deg, #ffc56a, #fd9927, #e25b12);
}
.pipeline[data-step="0"] .pipeline-track span { width: 8%; animation: fill .8s cubic-bezier(.16,1,.3,1); }
.pipeline[data-step="1"] .pipeline-track span { width: 50%; animation: fill .8s cubic-bezier(.16,1,.3,1); }
.pipeline[data-step="2"] .pipeline-track span { width: 100%; animation: fill .8s cubic-bezier(.16,1,.3,1); }
.pipeline[data-step="3"] .pipeline-track span { width: 100%; animation: fill .8s cubic-bezier(.16,1,.3,1); }
@keyframes fill { from { width: 0; } }
.pipeline ol { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0; padding: 0; }
.pipeline li { display: flex; flex-direction: column; gap: 2px; color: var(--muted); font-size: 0.85rem; }
.pipeline li em { font-style: normal; letter-spacing: 0.12em; font-size: 0.68rem; }
.pipeline li.is-done, .pipeline li.is-current { color: var(--text); }
.pipeline.is-rejected li.is-current { color: var(--bad); }

.paper { background: white; color: #1c1916; border-radius: 18px; overflow: hidden; margin-top: 16px; }
.paper-bar { height: 8px; background: linear-gradient(90deg, #ffc56a, #fd9927, #e25b12, #7a2e0e); }
.paper-body { padding: 18px; }
.paper .wordmark { font-size: 1.4rem; }
.paper .brand-logo { height: 36px; }
.paper-head, .paper-total { display: flex; justify-content: space-between; gap: 12px; }
.paper-head b, .paper-total { font-weight: 900; }
.paper-head span, .paper small { display: block; color: #6d645c; font-weight: 400; }
.meta-pills { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 12px 0; list-style: none; }
.meta-pills li { background: #f6f1ea; border-radius: 999px; padding: 4px 10px; font-size: 0.82rem; }
.meta-pills span { color: #8a8178; margin-right: 4px; }
.paper-table { width: 100%; border-collapse: collapse; }
.paper-table th { text-align: left; font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: #8a8178; }
.paper-table td, .paper-table th { padding: 8px 4px; border-bottom: 1px solid #efe8df; }
.link-row a { color: var(--link-soft); }

.lines { display: flex; flex-direction: column; gap: 10px; }
.line { display: grid; grid-template-columns: 1.5fr 0.6fr 0.7fr 0.8fr auto; gap: 10px; align-items: end; }
.line-note { grid-column: 1 / -2; }
.convert { margin-top: 8px; }
.totals { display: flex; justify-content: flex-end; gap: 18px; color: var(--muted); }
.totals strong { color: var(--text); font-weight: 900; }
.logo-preview { padding: 12px 0; }
.secret {
  font-weight: 900; letter-spacing: 0.04em; font-size: 1.3rem;
  padding: 12px 14px; border-radius: 16px; background: var(--surface-2);
}

.guest { min-height: 100vh; }
.guest-frame { min-height: 100vh; display: grid; place-items: center; padding: 32px 16px; }
.auth-card, .center-card { width: min(460px, 100%); padding: 28px; animation: rise 0.8s cubic-bezier(.16,1,.3,1) both; }
.auth-card-wide { width: min(680px, 100%); }
.auth-brand { margin-bottom: 8px; }
.scrim { display: none; }
.icon-tool {
  position: relative;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  padding: 0;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--text);
}
.icon-tool svg { width: 18px; height: 18px; }
.nav-toggle.icon-tool { display: none; }
.icon-tool[aria-expanded="true"] { border-color: rgba(253, 153, 39, 0.7); background: rgba(253, 153, 39, 0.1); }
.badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 99px;
  background: #e25b12;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  box-shadow: 0 0 0 2px var(--badge-ring);
}
.menu { position: relative; }
.menu-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 30;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--menu);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(18px);
  transform-origin: top right;
  animation: pop 0.22s cubic-bezier(.16,1,.3,1);
}
.menu-panel::before {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(253, 153, 39, 0.9), transparent);
}
@keyframes pop {
  from { opacity: 0; transform: translateY(-8px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.note-panel {
  position: fixed;
  z-index: 60;
  width: min(400px, calc(100vw - 28px));
  padding: 0;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid rgba(253, 153, 39, .36);
  background:
    radial-gradient(90% 70% at 100% -10%, rgba(253, 153, 39, .28), transparent 52%),
    linear-gradient(165deg, rgba(255,248,239,.98), var(--menu) 48%);
  box-shadow:
    0 24px 60px rgba(42, 18, 3, .22),
    inset 0 1px 0 rgba(255,255,255,.55);
  backdrop-filter: none;
  transform-origin: top right;
  animation: none;
}
html.theme-dark .note-panel {
  background:
    radial-gradient(90% 70% at 100% -10%, rgba(253, 153, 39, .32), transparent 52%),
    linear-gradient(165deg, #2a1c12, #120e0b 55%);
}
.note-panel.menu-panel { animation: none; }
.note-panel.is-live {
  animation: note-panel-in .36s cubic-bezier(.16, 1, .3, 1) both;
}
.note-panel.is-live .note-sheen { animation: note-sheen .9s ease .05s both; }
.note-panel.is-live .note { animation: note-row-in .42s cubic-bezier(.16, 1, .3, 1) both; animation-delay: calc(var(--i, 0) * 40ms + 40ms); }
.note-panel::before {
  left: 0; right: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, transparent, #fff1dc 18%, #fd9927 50%, #fff1dc 82%, transparent);
}
.note-aurora, .note-sheen { position: absolute; inset: 0; pointer-events: none; overflow: hidden; border-radius: inherit; }
.note-aurora i {
  position: absolute; width: 42%; height: 42%; border-radius: 50%;
  opacity: .28;
  background: radial-gradient(circle, rgba(253, 153, 39, .5), transparent 70%);
}
.note-aurora i:nth-child(1) { top: -18%; right: -12%; }
.note-aurora i:nth-child(2) { left: -16%; bottom: 10%; opacity: .2; }
.note-aurora i:nth-child(3) { right: 18%; bottom: -22%; opacity: .18; }
.note-sheen {
  background: linear-gradient(115deg, transparent 28%, rgba(255,255,255,.22) 48%, transparent 62%);
  transform: translateX(-120%);
}
@keyframes note-panel-in {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: none; }
}
@keyframes note-sheen { to { transform: translateX(120%); } }
.account-panel { width: min(360px, calc(100vw - 32px)); padding-bottom: 8px; }
.menu-bar, .account-card, .note-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 12px;
}
.note-head {
  position: relative; z-index: 1;
  padding: 20px 18px 10px;
  align-items: flex-start;
}
.note-head .eyebrow { margin: 0 0 4px; color: #9a4e0a; letter-spacing: .2em; }
html.theme-dark .note-head .eyebrow { color: #ffd59a; }
.note-head strong {
  display: block;
  font-size: 1.35rem;
  letter-spacing: -.04em;
  background: linear-gradient(120deg, #2a1203, #c56a12 45%, #fd9927 80%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
html.theme-dark .note-head strong {
  background: linear-gradient(120deg, #fff6e8, #fd9927 55%, #ffd59a);
  -webkit-background-clip: text;
  background-clip: text;
}
.note-head-tools { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.note-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: .68rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #2a1203;
  background: linear-gradient(120deg, #fff1dc, #ffd59a 40%, #fd9927);
  box-shadow: 0 8px 18px rgba(197, 106, 18, .22);
  animation: note-pill-pop .55s cubic-bezier(.16, 1, .3, 1) both;
}
@keyframes note-pill-pop {
  from { opacity: 0; transform: scale(.7) translateY(-6px); }
  to { opacity: 1; transform: none; }
}
.menu-bar strong, .account-card strong { font-weight: 500; letter-spacing: 0; }
.account-card { justify-content: flex-start; }
.account-card strong, .account-card small, .note-copy small, .note-copy em { display: block; }
.account-card small, .note-copy small, .note-copy em { color: var(--muted); }
.note-copy em { margin-top: 6px; font-style: normal; font-size: 0.72rem; letter-spacing: .02em; }
.note-list {
  position: relative;
  z-index: 1;
  max-height: min(460px, 62vh);
  overflow: auto;
  padding: 6px 12px 14px;
  scrollbar-width: thin;
  scrollbar-color: #fd9927 rgba(253, 153, 39, .12);
}
.note-list::-webkit-scrollbar,
.modal-card::-webkit-scrollbar,
.sheet-card::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
.note-list::-webkit-scrollbar-track,
.modal-card::-webkit-scrollbar-track,
.sheet-card::-webkit-scrollbar-track {
  margin: 10px 0;
  background: linear-gradient(180deg, rgba(255, 236, 210, .1), rgba(253, 153, 39, .06));
  border-radius: 99px;
}
.note-list::-webkit-scrollbar-thumb,
.modal-card::-webkit-scrollbar-thumb,
.sheet-card::-webkit-scrollbar-thumb {
  border-radius: 99px;
  border: 2px solid transparent;
  background:
    linear-gradient(180deg, #fff6e8, #ffd59a 18%, #fd9927 52%, #c56a12 78%, #ffe7c4) padding-box;
  box-shadow: inset 0 0 0 1px rgba(255, 244, 220, .55);
}
.note, .menu-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  text-align: left;
  text-decoration: none;
  border: 0;
  border-radius: 18px;
  background: transparent;
  color: inherit;
  padding: 13px 12px;
  animation: note-row-in .62s cubic-bezier(.16, 1, .3, 1) both;
  animation-delay: calc(var(--i, 0) * 55ms + 80ms);
  transition: transform .28s ease, background .28s ease, box-shadow .28s ease;
}
@keyframes note-row-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}
.note:hover {
  transform: translateY(-2px);
  background:
    linear-gradient(120deg, rgba(253, 153, 39, .18), transparent 62%),
    rgba(255,255,255,.28);
  box-shadow: 0 12px 28px rgba(197, 106, 18, .12);
}
html.theme-dark .note:hover { background: linear-gradient(120deg, rgba(253, 153, 39, .2), rgba(255,255,255,.03) 62%); }
.note.is-unread {
  background:
    linear-gradient(125deg, rgba(253, 153, 39, .2), rgba(255,255,255,.04) 58%);
  box-shadow: inset 0 0 0 1px rgba(253, 153, 39, .22);
}
.note.is-unread::after {
  content: "";
  position: absolute;
  /* fallback if absolute needed - use border on ico instead */
}
.note { position: relative; }
.note-ico {
  position: relative;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(253, 153, 39, .12);
  border: 1px solid rgba(253, 153, 39, .22);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.35);
}
.note-ico i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #8d6a45;
  box-shadow: 0 0 12px currentColor;
}
.note-ico.is-good { background: rgba(27, 122, 67, .12); border-color: rgba(27, 122, 67, .28); }
.note-ico.is-good i { background: #1b7a43; color: #1b7a43; }
.note-ico.is-bad { background: rgba(198, 40, 40, .12); border-color: rgba(198, 40, 40, .28); }
.note-ico.is-bad i { background: #c62828; color: #c62828; }
.note-ico.is-warn { background: rgba(253, 153, 39, .18); border-color: rgba(253, 153, 39, .4); }
.note-ico.is-warn i { background: #fd9927; color: #fd9927; animation: note-pulse 1.8s ease-in-out infinite; }
.note-ico.is-idle i { background: #8d6a45; color: #8d6a45; }
@keyframes note-pulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(253, 153, 39, .45); }
  50% { transform: scale(1.12); box-shadow: 0 0 0 8px rgba(253, 153, 39, 0); }
}
.note-copy { min-width: 0; flex: 1; }
.note-copy strong {
  display: block;
  font-size: .98rem;
  font-weight: 600;
  letter-spacing: -.02em;
}
.note-copy small { margin-top: 3px; line-height: 1.4; }
.note-go {
  align-self: center;
  color: #c56a12;
  font-size: 1.2rem;
  opacity: 0;
  transform: translateX(-6px);
  transition: .25s ease;
}
.note:hover .note-go { opacity: 1; transform: none; }
.note-empty {
  position: relative;
  overflow: hidden;
  margin: 10px 4px 8px;
  padding: 36px 18px;
  text-align: center;
  border-radius: 22px;
  border: 1px dashed rgba(253, 153, 39, .32);
  color: var(--muted);
  background: rgba(253, 153, 39, .06);
}
.note-empty strong { display: block; margin-bottom: 6px; color: var(--text); font-size: 1.05rem; }
.note-empty p { margin: 0; }
.note-empty-glow {
  position: absolute; inset: auto;
  width: 120px; height: 120px; left: 50%; top: -30px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(253, 153, 39, .34), transparent 70%);
  pointer-events: none;
}
.menu-item { align-items: center; margin: 0 8px; width: calc(100% - 16px); }
.menu-item:hover { background: var(--hover); }
.menu-out { color: var(--muted); }
.menu-out:hover { color: var(--bad); }
.account-trigger {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 280px;
  padding: 5px 10px 5px 5px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: inherit;
}
.account-trigger[aria-expanded="true"] { border-color: rgba(253, 153, 39, 0.65); background: rgba(253, 153, 39, 0.08); }
.account-trigger svg { width: 16px; height: 16px; flex: 0 0 16px; color: var(--muted); transition: transform 0.2s ease; }
.account-trigger[aria-expanded="true"] svg { transform: rotate(180deg); }
.account-id { min-width: 0; text-align: left; }
.account-id strong, .account-id small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-id strong { font-size: 0.92rem; font-weight: 500; letter-spacing: 0; }
.account-id small { color: var(--muted); font-size: 0.75rem; }
.avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  border-radius: 50%;
  background: #fd9927;
  color: #2a1203;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: -0.03em;
}
.avatar-lg { width: 48px; height: 48px; flex-basis: 48px; font-size: 1rem; }
.theme-ico-sun, html.theme-dark .theme-ico-moon { display: none; }
html.theme-dark .theme-ico-sun { display: block; }
.account-head { align-items: flex-start; }
.account-head strong { font-size: 1rem; }
.account-role {
  display: inline-flex;
  margin: 4px 0 2px;
  padding: 2px 8px;
  border-radius: 99px;
  background: var(--warm-bg);
  color: var(--warm);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.account-facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 14px;
  margin: 0 14px 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface-2);
}
.account-facts div { min-width: 0; }
.account-facts dt { font-size: 0.66rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.account-facts dd { margin: 3px 0 0; font-size: 0.88rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-theme { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 14px 10px; }
.account-theme > span { color: var(--muted); font-size: 0.8rem; }
.theme-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  flex: 1;
  max-width: 210px;
  padding: 3px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface-2);
}
.theme-switch button {
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  padding: 7px 8px;
  cursor: pointer;
}
.theme-switch [data-theme-choice="light"],
html.theme-dark .theme-switch [data-theme-choice="dark"] {
  background: linear-gradient(120deg, #ffc56a, #fd9927);
  color: #2a1203;
  font-weight: 500;
}
html.theme-dark .theme-switch [data-theme-choice="light"] { background: transparent; color: var(--muted); font-weight: 400; }
.account-actions { padding-top: 4px; border-top: 1px solid var(--line); margin-top: 4px; }
.modal[hidden], .scrim[hidden], [hidden] { display: none !important; }
.modal { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; background: rgba(6,7,10,.62); backdrop-filter: blur(8px); padding: 18px; }
.modal.sheet { z-index: 70; background: rgba(10, 7, 4, .72); }
body.modal-open .shell { z-index: 1; }
body.modal-open .sidebar { z-index: 1; }
#confirm-modal { z-index: 90; }
.modal-card { width: min(460px, 100%); padding: 22px; position: relative; }
.modal .sheet-card {
  width: min(980px, calc(100vw - 36px));
  max-height: min(88vh, 920px);
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #fd9927 rgba(253, 153, 39, .12);
}
.modal .dossier-card {
  width: min(1120px, calc(100vw - 24px));
  padding: 18px 18px 22px;
  border-radius: 28px;
  background:
    radial-gradient(90% 60% at 100% 0%, rgba(253, 153, 39, 0.08), transparent 55%),
    var(--surface);
  box-shadow: 0 28px 64px rgba(20, 12, 6, 0.28), 0 0 0 1px rgba(253, 153, 39, 0.08);
}
.dossier-card .sea-copy { padding-right: 56px; }
.dossier-card .sea { margin-bottom: 12px; }
.ops-dossier {
  position: relative;
  margin: 4px 2px 0;
  padding: 18px 18px 16px;
  border-radius: 22px;
  border: 1px solid rgba(48, 32, 16, 0.1);
  background:
    linear-gradient(165deg, rgba(255, 248, 240, 0.95), rgba(255, 255, 255, 0.55)),
    var(--surface);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
}
html.theme-dark .ops-dossier {
  border-color: rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(165deg, rgba(36, 28, 22, 0.95), rgba(18, 15, 12, 0.9));
  box-shadow: inset 0 1px 0 rgba(255, 220, 170, 0.06);
}
.ops-dossier-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.ops-dossier-head h3 {
  margin: 2px 0 0;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.ops-dossier-state {
  flex: 0 0 auto;
  margin-top: 4px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--muted);
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.03);
}
.ops-dossier-state.is-live {
  color: #9a4e0a;
  border-color: rgba(253, 153, 39, 0.35);
  background: rgba(253, 153, 39, 0.12);
}
html.theme-dark .ops-dossier-state.is-live { color: #ffd59a; }
.ops-dossier .sea-meta {
  margin: 0 0 14px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}
.ops-dossier .sea-meta span {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(48, 32, 16, 0.1);
  background: rgba(255, 255, 255, 0.55);
  color: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
html.theme-dark .ops-dossier .sea-meta span {
  border-color: rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}
.ops-dossier .sea-meta em {
  font-style: normal;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.modal-card::-webkit-scrollbar { width: 11px; height: 11px; }
.modal-card::-webkit-scrollbar-track {
  margin: 14px 0;
  background: linear-gradient(180deg, rgba(255, 236, 210, .08), rgba(253, 153, 39, .05));
  border-radius: 99px;
}
.modal-card::-webkit-scrollbar-thumb {
  border-radius: 99px;
  border: 2px solid transparent;
  background:
    linear-gradient(180deg, #fff6e8, #ffd59a 18%, #fd9927 52%, #c56a12 78%, #ffe7c4) padding-box;
  box-shadow: inset 0 0 0 1px rgba(255, 244, 220, .55);
}
.sheet-x {
  position: sticky;
  top: 0;
  float: right;
  z-index: 4;
  width: 42px;
  height: 42px;
  margin: 0 0 -42px 12px;
  border: 0;
  border-radius: 50%;
  display: grid;
  place-items: center;
  cursor: pointer;
  color: #2a1203;
  background: linear-gradient(145deg, #fff8ee 0%, #ffd59a 28%, #fd9927 58%, #a85a0c 100%);
  box-shadow: 0 10px 24px rgba(168, 78, 8, .35), inset 0 1px 0 rgba(255, 255, 255, .75);
  transition: transform .35s cubic-bezier(.16,1,.3,1);
}
.sheet-x svg { width: 16px; height: 16px; }
.sheet-x:hover { transform: rotate(90deg); }
.modal.sheet:not([hidden]) .sheet-card { animation: dossier-in .5s cubic-bezier(.16,1,.3,1); }
@keyframes dossier-in {
  from { opacity: 0; transform: translateY(26px) scale(.97); }
  to { opacity: 1; transform: none; }
}
:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }

.dock { display: none; }
.mobile-brand { display: none; align-items: center; text-decoration: none; }
.mobile-brand .wordmark { font-size: 1.35rem; animation: none; }
.mobile-brand .brand-logo { height: 30px; max-width: 108px; }

@view-transition { navigation: auto; }
::view-transition-new(root) { animation: rise 0.45s cubic-bezier(.16,1,.3,1) both; }

.fx-strip, .fx-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid var(--line);
  background:
    linear-gradient(115deg, rgba(253, 153, 39, 0.18), transparent 46%),
    var(--surface);
}
.fx-strip { margin: 0 0 16px; padding: 14px 16px; border-radius: 18px; }
.fx-strip strong, .fx-card strong { display: block; letter-spacing: -0.03em; }
.fx-strip strong { font-size: 1.2rem; }
.fx-card strong { font-size: 1.45rem; }
.fx-strip small, .fx-card small, .fx-kicker { color: var(--muted); }
.fx-kicker { display: block; font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 4px; }
.fx-strip em {
  margin-left: auto;
  font-style: normal;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #9a5b12;
}
.fx-card { align-items: end; padding: 16px; border-radius: 18px; }
.fx-actions { width: min(240px, 100%); display: flex; flex-direction: column; gap: 8px; }
.fx-equiv { color: var(--muted); font-style: normal; font-weight: 400; margin-left: 8px; }
.veil {
  position: fixed; inset: 0; z-index: 80;
  display: grid; place-items: center;
  background: rgba(250, 246, 240, 0.86);
  opacity: 0; visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}
html.theme-dark .veil { background: rgba(12, 14, 18, 0.82); }
html.is-booting .veil, .veil.is-on { opacity: 1; visibility: visible; }
.veil-mark { display: grid; justify-items: center; gap: 8px; }
.veil-mark strong { font-size: 1.4rem; letter-spacing: -0.04em; }
.veil-mark small { color: var(--muted); letter-spacing: 0.16em; text-transform: uppercase; font-size: 0.68rem; }
.veil-mark i {
  width: 46px; height: 46px; border-radius: 50%;
  border: 2px solid rgba(253, 153, 39, 0.25);
  border-top-color: #fd9927;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.ledger { display: flex; flex-direction: column; align-items: stretch; gap: 14px; margin-bottom: 16px; }
.ledger article strong { display: block; font-size: 1.6rem; letter-spacing: -0.04em; }
.ledger article span, .ledger article small, .fact-row span { color: var(--muted); }
.filters { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-start; width: 100%; }
.filters + .deck { margin-top: 22px; }
.quote-card { align-items: center; }
.row-link .quote-side { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.pay-line { display: flex; align-items: center; gap: 12px; margin: 0 0 16px; }
.filters button {
  border: 1px solid var(--line); background: var(--surface); color: var(--text);
  border-radius: 999px; padding: 7px 12px; cursor: pointer;
}
.filters button b { color: var(--muted); font-weight: 500; margin-left: 4px; }
.filters button.is-on { background: linear-gradient(120deg, #ffc56a, #fd9927); color: #2a1203; border-color: transparent; }
.filters button.is-on b { color: #2a1203; }
.fact-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 14px 0; }
.fact-row article {
  padding: 12px 14px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface);
  animation: rise 0.6s cubic-bezier(.16,1,.3,1) both;
}
.fact-row strong { display: block; margin-top: 4px; }
.fact-row article:nth-child(2) { animation-delay: 60ms; }
.fact-row article:nth-child(3) { animation-delay: 120ms; }
.fact-row article:nth-child(4) { animation-delay: 180ms; }
.track-mini { margin: 8px 0 16px; }
.dossier { margin-top: 0; }
@media (prefers-reduced-motion: reduce) {
  .veil { display: none; }
}
.chart-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 16px; margin-bottom: 16px; }
.chart-card { min-height: 240px; }
.vbars { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; align-items: end; height: 190px; }
.vbar { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; gap: 6px; }
.vbar i {
  display: block;
  height: var(--h);
  border-radius: 12px 12px 4px 4px;
  background: linear-gradient(180deg, #ffe1b0, #fd9927 42%, #e25b12);
  transform: scaleY(0);
  transform-origin: bottom;
  animation: growY 0.9s cubic-bezier(.16,1,.3,1) forwards;
  animation-delay: calc(var(--i) * 70ms);
}
.vbar i.is-set { animation: none; transform: scaleY(1); transition: height 0.6s cubic-bezier(.16,1,.3,1); }
.vbar small { color: var(--muted); font-size: 0.72rem; text-align: center; }
@keyframes growY { to { transform: scaleY(1); } }
.donut-row { display: flex; gap: 18px; align-items: center; }
.donut { width: 150px; height: 150px; flex: 0 0 150px; }
.donut svg { width: 100%; height: 100%; animation: pop 0.7s cubic-bezier(.16,1,.3,1) both; }
.legend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; color: var(--muted); font-size: 0.86rem; }
.legend i { width: 8px; height: 8px; margin-right: 6px; border-radius: 50%; display: inline-block; }
.hbar { display: grid; grid-template-columns: 108px 1fr 28px; gap: 8px; align-items: center; margin: 9px 0; }
.hbar span, .hbar em { color: var(--muted); font-size: 0.82rem; font-style: normal; }
.hbar b { display: block; height: 8px; border-radius: 99px; background: var(--track); overflow: hidden; }
.hbar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #ffc56a, #e25b12);
  transform: scaleX(0);
  transform-origin: left;
  animation: growX 0.8s cubic-bezier(.16,1,.3,1) forwards;
  animation-delay: calc(var(--i) * 60ms);
}
.hbar i.is-set { animation: none; transform: scaleX(1); transition: width 0.6s cubic-bezier(.16,1,.3,1); }
@keyframes growX { to { transform: scaleX(1); } }
.live-chip { color: var(--muted); font-size: 0.75rem; }
.live-chip::before {
  content: "";
  width: 7px; height: 7px; margin-right: 6px; border-radius: 50%;
  background: #1b7a43; display: inline-block;
  animation: pulse 1.8s ease-out infinite;
}
.account-live {
  display: flex; align-items: center; gap: 10px;
  margin: 0 14px 12px; padding: 10px 12px;
  border-radius: 14px; border: 1px solid var(--line); background: var(--surface-2);
}
.account-live strong, .account-live small { display: block; }
.account-live small { color: var(--muted); }
.presence {
  width: 10px; height: 10px; flex: 0 0 10px; border-radius: 50%;
  background: #1b7a43;
  box-shadow: 0 0 0 0 rgba(27, 122, 67, 0.55);
  animation: pulse 1.8s ease-out infinite;
}
.presence.is-off { background: #b9a48f; animation: none; box-shadow: none; }
@keyframes pulse {
  70% { box-shadow: 0 0 0 8px rgba(27, 122, 67, 0); }
}
.cargo-form { display: flex; gap: 12px; align-items: end; flex-wrap: wrap; margin: 8px 0 14px; }
.cargo-form .field { min-width: min(240px, 100%); }
.team-card strong, .team-id small { display: block; }
.team-id { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.team-id small, .check { color: var(--muted); }
.team-id div { flex: 1; min-width: 0; }
.check { display: flex; gap: 8px; align-items: center; }
.voyage-list { display: flex; flex-direction: column; gap: 16px; }
.voyage {
  background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 20px;
  animation: rise 0.7s cubic-bezier(.16,1,.3,1) both;
  animation-delay: calc(var(--i) * 80ms);
}
.voyage-head, .voyage-total { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.voyage-total { margin: 8px 0 0; font-weight: 500; }
.track { list-style: none; display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin: 18px 0; padding: 0; }
.track li { display: flex; flex-direction: column; gap: 6px; color: var(--muted); font-size: 0.75rem; }
.track i { display: block; height: 8px; border-radius: 99px; background: var(--track); position: relative; overflow: hidden; }
.track .is-done i, .track .is-now i { background: linear-gradient(90deg, #ffc56a, #fd9927 60%, #e25b12); }
.track .is-now { color: var(--text); font-weight: 500; }
.track .is-now i::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent, rgba(255,255,255,.7), transparent);
  animation: sheen 1.8s ease-in-out infinite;
}

@media (max-width: 1100px) {
  .kpi-grid, .split, .split-panels, .grid-3 { grid-template-columns: 1fr 1fr; }
  .shell, html.sidebar-collapsed .shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed;
    z-index: 30;
    width: min(300px, 88vw);
    transform: translateX(-105%);
    transition: transform 0.4s cubic-bezier(.16,1,.3,1);
  }
  .sidebar.is-open { transform: none; }
  html.sidebar-collapsed .brand-copy,
  html.sidebar-collapsed .nav-label { max-width: 160px; opacity: 1; }
  html.sidebar-collapsed .brand { justify-content: flex-start; gap: 12px; padding-inline: 8px; }
  html.sidebar-collapsed .nav a { justify-content: flex-start; gap: 10px; padding-inline: 12px; }
  html.sidebar-collapsed .nav-pill { left: 0; right: 0; width: auto; margin-left: 0; }
  .nav-tip { display: none !important; }
  html.sidebar-collapsed .nav { gap: 2px; align-items: stretch; }
  html.sidebar-collapsed .nav a { min-height: 44px; width: auto; border-radius: 14px; }
  html.sidebar-collapsed .nav-ico { width: 34px; height: 34px; flex-basis: 34px; border-radius: 11px; }
  html.sidebar-collapsed .nav-pill { width: auto; height: 44px; margin-left: 0; border-radius: 14px; }
  .side-toggle { display: none; }
  .nav-toggle.icon-tool { display: grid; }
  .scrim { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 25; }
  .topbar, .page { padding-left: 18px; padding-right: 18px; }
  .line { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .sidebar { display: none; }
  .nav-toggle.icon-tool { display: none; }
  .mobile-brand { display: inline-flex; }
  .shell, html.sidebar-collapsed .shell { grid-template-columns: 1fr; }
  .topbar {
    min-height: 62px;
    padding: calc(8px + env(safe-area-inset-top)) 14px 8px;
  }
  .clients-hero { flex-direction: column; align-items: stretch; padding: 22px; }
  .clients-hero-meta { align-self: start; }
  .icon-tool { width: 40px; height: 40px; border-radius: 13px; }
  .page {
    padding: 16px 14px calc(108px + env(safe-area-inset-bottom));
  }
  .page-head { margin-bottom: 12px; }
  .page-head h1 { font-size: 1.45rem; }
  .kpi-grid, .split, .split-panels, .grid-2, .grid-3, .settings-grid { grid-template-columns: 1fr; }
  .kpi-grid, .chart-grid { grid-template-columns: 1fr; }
  .kpi-grid { grid-template-columns: 1fr 1fr; gap: 10px; margin: 14px 0; }
  .track { grid-template-columns: repeat(3, 1fr); }
  .donut-row, .fx-strip, .fx-card, .ledger { flex-direction: column; align-items: flex-start; }
  .filters { justify-content: flex-start; }
  .toolbar { flex-direction: column; align-items: stretch; }
  .ledger { align-items: stretch; }
  .fact-row { grid-template-columns: 1fr 1fr; }
  .fx-actions { width: 100%; }
  .cargo-form { align-items: stretch; }
  .dash-kpis { grid-template-columns: 1fr 1fr; }
  .dash-hero { align-items: flex-start; }
  .dash-stage { padding: 18px 16px 14px; border-radius: 24px; }
  .kpi-grid .kpi:first-child { grid-column: auto; }
  .kpi-grid .kpi:first-child strong { font-size: inherit; }
  .kpi, .panel, .card { padding: 16px; border-radius: 20px; }
  .kpi strong { font-size: 1.35rem; }
  .meter { grid-template-columns: 1fr 1fr; gap: 8px; }
  .hero-line, .detail-head, .form-actions, .action-row { align-items: stretch; }
  .hero-actions { display: flex; flex-direction: column; gap: 8px; width: 100%; }
  .hero-actions .btn, .btn-block { width: 100%; }
  .pipeline ol { grid-template-columns: repeat(4, minmax(72px, 1fr)); }
  .pipeline { overflow-x: auto; }
  .line { grid-template-columns: 1fr; }
  .paper { border-radius: 16px; }
  .paper-table { min-width: 520px; }
  .paper-body { overflow-x: auto; }
  .account-id, .account-trigger > svg { display: none; }
  .account-trigger {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 13px;
    justify-content: center;
  }
  .dock {
    position: fixed;
    z-index: 28;
    left: 12px;
    right: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom));
    display: grid;
    grid-template-columns: repeat(var(--dock-count, 5), minmax(0, 1fr));
    align-items: center;
    height: 68px;
    padding: 6px;
    border-radius: 22px;
    border: 1px solid var(--line);
    background: var(--menu);
    box-shadow: 0 18px 50px rgba(48, 28, 8, 0.18);
    backdrop-filter: blur(18px);
  }
  .dock::after {
    content: "";
    position: absolute;
    left: 18%;
    right: 18%;
    bottom: -8px;
    height: 16px;
    background: radial-gradient(closest-side, rgba(253, 153, 39, 0.45), transparent);
    filter: blur(6px);
    z-index: -1;
    pointer-events: none;
  }
  .dock-pill {
    position: absolute;
    top: 0;
    left: 0;
    border-radius: 16px;
    background: linear-gradient(160deg, #ffc56a, #fd9927 58%, #e25b12);
    box-shadow: 0 8px 18px rgba(253, 153, 39, 0.28);
    transition: transform 0.4s cubic-bezier(.16,1,.3,1), width 0.4s cubic-bezier(.16,1,.3,1);
  }
  .dock a {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
    min-height: 56px;
    border-radius: 16px;
    text-decoration: none;
    color: var(--muted);
    font-size: 0.64rem;
    letter-spacing: 0.01em;
  }
  .dock a.is-active { color: #2a1203; font-weight: 500; }
  .dock .nav-ico { width: auto; height: auto; background: transparent; }
  .dock .ico { width: 18px; height: 18px; }
  .menu-panel {
    position: fixed;
    top: auto;
    right: 12px;
    left: 12px;
    bottom: calc(92px + env(safe-area-inset-bottom));
    width: auto;
    max-height: min(68vh, 560px);
    border-radius: 24px;
    z-index: 36;
    animation: sheet 0.32s cubic-bezier(.16,1,.3,1);
  }
  .note-panel.menu-panel {
    top: auto;
    right: 12px;
    left: 12px;
    bottom: calc(92px + env(safe-area-inset-bottom));
    width: auto;
    max-height: min(68vh, 560px);
    z-index: 60;
    animation: none;
  }
  .note-panel.menu-panel.is-live { animation: sheet 0.32s cubic-bezier(.16,1,.3,1) both; }
  .account-panel { width: auto; }
  .note-list { max-height: 42vh; }
  .scrim.is-sheet { z-index: 34; background: rgba(22, 16, 10, 0.46); }
  .guest-frame { align-items: end; padding: 20px 14px calc(18px + env(safe-area-inset-bottom)); }
  .auth-card, .center-card { border-radius: 28px; }
}
@keyframes sheet {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

.sea {
  position: relative;
  margin-bottom: 18px;
  padding: 22px 22px 18px;
  border-radius: 28px;
  color: #f6efe6;
  background:
    radial-gradient(90% 80% at 0% 100%, rgba(253, 153, 39, .22), transparent 55%),
    radial-gradient(70% 60% at 100% 0%, rgba(255, 214, 160, .16), transparent 50%),
    linear-gradient(180deg, #24180f, #100e0c 70%);
  border: 1px solid rgba(255, 196, 120, .35);
  box-shadow: 0 24px 70px rgba(90, 42, 8, .18), inset 0 1px 0 rgba(255, 236, 210, .28);
  overflow: hidden;
}
.sea.is-premium {
  background:
    radial-gradient(70% 55% at 12% 0%, rgba(255, 213, 154, .2), transparent 50%),
    radial-gradient(80% 70% at 100% 100%, rgba(253, 153, 39, .28), transparent 55%),
    linear-gradient(165deg, #2a180c 0%, #17110d 48%, #0d0b0a 100%);
  box-shadow:
    0 28px 70px rgba(42, 18, 3, .28),
    inset 0 1px 0 rgba(255, 236, 210, .22);
}
.sea-fx {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.sea-sun {
  position: absolute;
  top: -40px;
  right: 8%;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 213, 154, .45), rgba(253, 153, 39, .12) 45%, transparent 70%);
  animation: sea-sun 8s ease-in-out infinite alternate;
}
.sea-haze {
  position: absolute;
  inset: auto 0 0;
  height: 42%;
  background: linear-gradient(180deg, transparent, rgba(253, 153, 39, .08));
}
.sea-wave {
  position: absolute;
  left: -10%;
  width: 120%;
  height: 90px;
  border-radius: 50%;
  border: 1px solid rgba(255, 213, 154, .12);
  opacity: .45;
}
.sea-wave.w1 { bottom: 8%; animation: sea-wave 9s linear infinite; }
.sea-wave.w2 { bottom: 2%; animation: sea-wave 12s linear infinite reverse; opacity: .28; }
.sea-wave.w3 { bottom: -4%; animation: sea-wave 15s linear infinite; opacity: .18; }
.sea-spark {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ffd59a;
  box-shadow: 0 0 12px rgba(253, 153, 39, .8);
  animation: sea-spark 4.8s ease-in-out infinite;
}
.sea-spark.s1 { top: 28%; left: 18%; }
.sea-spark.s2 { top: 46%; left: 62%; animation-delay: 1.2s; }
.sea-spark.s3 { top: 34%; left: 78%; animation-delay: 2.1s; }
@keyframes sea-sun {
  from { transform: scale(.92) translateY(0); opacity: .7; }
  to { transform: scale(1.08) translateY(8px); opacity: 1; }
}
@keyframes sea-wave {
  from { transform: translateX(-4%) scaleY(1); }
  to { transform: translateX(4%) scaleY(1.08); }
}
@keyframes sea-spark {
  0%, 100% { opacity: .15; transform: scale(.7); }
  50% { opacity: 1; transform: scale(1.2); }
}
.sea-copy { position: relative; z-index: 1; }
.sea-copy h2 {
  margin: 4px 0 6px;
  font-size: clamp(1.15rem, 2vw, 1.7rem);
  letter-spacing: -0.04em;
  background: linear-gradient(110deg, #fff6e8 0%, #ffd59a 22%, #fd9927 48%, #fff1dc 62%, #c56a12 100%);
  background-size: 180% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: sweep 7s linear infinite;
}
.sea-kicker, .sea-copy p { margin: 0; color: rgba(255, 228, 196, .78); }
.sea-progress {
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 280px;
}
.sea-progress span {
  flex: 1;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .1);
  overflow: hidden;
  position: relative;
}
.sea-progress span::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--p, 0%);
  border-radius: inherit;
  background: linear-gradient(90deg, #ffd59a, #fd9927);
  box-shadow: 0 0 12px rgba(253, 153, 39, .55);
  animation: sea-progress-in 1.1s cubic-bezier(.16,1,.3,1) both;
}
.sea-progress b {
  font-size: .78rem;
  letter-spacing: .08em;
  color: #ffd59a;
}
@keyframes sea-progress-in {
  from { transform: scaleX(0); transform-origin: left center; }
}
.sea-stage { position: relative; margin-top: 8px; z-index: 1; }
.sea-map { width: 100%; height: auto; display: block; }
.sea-swell { animation: swell-drift 10s ease-in-out infinite alternate; }
@keyframes swell-drift {
  from { transform: translateY(0); opacity: .7; }
  to { transform: translateY(-4px); opacity: 1; }
}
.sea .craft { display: none; }
.sea[data-craft="ship"] .craft-ship,
.sea[data-craft="plane"] .craft-plane,
.sea[data-craft="truck"] .craft-truck { display: inline; }
.craft-bob { transform-box: fill-box; transform-origin: center; animation: hull-bob 3.2s ease-in-out infinite; }
.craft-shadow { animation: shadow-breathe 3.2s ease-in-out infinite; }
.wake { animation: wake-flow 1.8s linear infinite; stroke-dasharray: 8 10; }
.wake.w-b { animation-duration: 2.4s; animation-direction: reverse; }
.smoke { animation: smoke-rise 2.8s ease-out infinite; }
.smoke.s-b { animation-delay: .45s; }
.smoke.s-c { animation-delay: .9s; }
.route-bed { animation: tide 18s linear infinite; }
.route-glow { animation: route-pulse 3.6s ease-in-out infinite; }
@keyframes hull-bob {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-5px) rotate(-1.8deg); }
}
@keyframes shadow-breathe {
  50% { opacity: .15; transform: scaleX(.9); }
}
@keyframes wake-flow { to { stroke-dashoffset: -36; } }
@keyframes smoke-rise {
  0% { opacity: 0; transform: translate(0, 0) scale(.6); }
  35% { opacity: .55; }
  100% { opacity: 0; transform: translate(10px, -18px) scale(1.3); }
}
@keyframes route-pulse {
  0%, 100% { opacity: .35; }
  50% { opacity: .7; }
}
@keyframes tide { to { stroke-dashoffset: -240; } }
.port-pin {
  position: absolute;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 2px;
  transform: translate(-50%, 12px);
  opacity: 0;
  pointer-events: none;
}
.port-pin.is-set {
  opacity: 1;
  transition: opacity .45s ease, transform .45s cubic-bezier(.16,1,.3,1);
  animation: pin-pop .55s cubic-bezier(.16,1,.3,1) both;
}
.port-pin.is-above { transform: translate(-50%, calc(-100% - 10px)); }
.port-pin i {
  width: 12px; height: 12px; border-radius: 50%;
  background: linear-gradient(140deg, #fff6e8, #fd9927 45%, #a85a0c);
  box-shadow: 0 0 0 6px rgba(253, 153, 39, .18), 0 0 18px rgba(253, 153, 39, .65);
}
.port-pin.is-now i, .port-pin.is-next i { animation: port-pulse 1.8s ease-in-out infinite; }
.port-pin.is-done i {
  background: linear-gradient(140deg, #ffe7c4, #fd9927 55%, #8d4d0c);
  box-shadow: 0 0 0 5px rgba(253, 153, 39, .12), 0 0 14px rgba(253, 153, 39, .4);
}
.port-pin.is-wait { opacity: .55; }
.port-pin.is-wait i { box-shadow: none; background: #8d7b68; animation: none; }
.port-pin.is-escala i {
  width: 10px; height: 10px;
  border: 1.5px solid rgba(255, 236, 210, .85);
}
.port-pin b { font-size: .78rem; letter-spacing: .04em; max-width: 120px; text-align: center; line-height: 1.15; }
.port-pin small { color: rgba(255, 220, 180, .7); font-size: .68rem; }
.sea-itinerary {
  list-style: none;
  margin: 4px 0 12px;
  padding: 14px 12px 12px;
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(var(--n, 2), minmax(0, 1fr));
  gap: 0;
  border-radius: 18px;
  border: 1px solid rgba(255, 196, 120, .18);
  background:
    linear-gradient(180deg, rgba(255, 236, 210, .06), rgba(255, 255, 255, .02));
}
.sea-itinerary::before {
  content: "";
  position: absolute;
  left: calc(100% / (var(--n, 2) * 2));
  right: calc(100% / (var(--n, 2) * 2));
  top: 27px;
  height: 2px;
  border-radius: 99px;
  background: linear-gradient(90deg, rgba(255, 213, 154, .15), rgba(253, 153, 39, .55), rgba(255, 213, 154, .15));
  pointer-events: none;
}
.sea-itinerary li {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 6px;
  text-align: center;
  padding: 0 8px;
  color: rgba(255, 220, 180, .55);
}
.sea-itinerary li i {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #6d5a48;
  box-shadow: 0 0 0 4px rgba(20, 14, 10, .55);
}
.sea-itinerary li strong {
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.2;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sea-itinerary li small {
  font-size: .66rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255, 220, 180, .45);
}
.sea-itinerary .is-done,
.sea-itinerary .is-now,
.sea-itinerary .is-next { color: #fff4e2; }
.sea-itinerary .is-done i,
.sea-itinerary .is-now i,
.sea-itinerary .is-next i {
  background: linear-gradient(140deg, #fff6e8, #fd9927 50%, #a85a0c);
  box-shadow: 0 0 0 4px rgba(253, 153, 39, .18), 0 0 16px rgba(253, 153, 39, .45);
}
.sea-itinerary .is-now i { animation: port-pulse 1.8s ease-in-out infinite; }
.sea-itinerary .is-escala i { width: 11px; height: 11px; }
@keyframes port-pulse {
  50% { box-shadow: 0 0 0 10px rgba(253, 153, 39, .08), 0 0 22px rgba(253, 153, 39, .9); }
}
@keyframes pin-pop {
  from { opacity: 0; transform: translate(-50%, 18px) scale(.85); }
  to { opacity: 1; transform: translate(-50%, 12px) scale(1); }
}
.port-pin.is-above.is-set { animation-name: pin-pop-above; }
@keyframes pin-pop-above {
  from { opacity: 0; transform: translate(-50%, calc(-100% + 8px)) scale(.85); }
  to { opacity: 1; transform: translate(-50%, calc(-100% - 10px)) scale(1); }
}
.flow {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(88px, 1fr));
  gap: 8px;
  margin: 8px 0 16px;
  padding: 0;
  position: relative;
  z-index: 1;
}
.flow li { display: flex; flex-direction: column; gap: 6px; color: rgba(255, 220, 180, .55); font-size: .78rem; }
.flow i {
  height: 3px; border-radius: 99px; background: rgba(255,255,255,.16); display: block;
  overflow: hidden; position: relative;
}
.flow .is-done { color: #ffd7a8; }
.flow .is-done i, .flow .is-now i {
  background: linear-gradient(90deg, #fff1dc, #fd9927 40%, #c56a12);
}
.flow .is-now { color: #fff6ea; font-weight: 500; }
.flow .is-now i::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent, rgba(255,255,255,.65), transparent);
  animation: sheen 1.8s ease-in-out infinite;
}
.docs { position: relative; z-index: 1; }
.docs header, .docs li { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.docs header { margin-bottom: 8px; }
.docs header span, .docs small { color: rgba(255, 220, 180, .72); }
.docs ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.docs li {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255, 196, 120, .16);
}
.docs b { display: block; }
.docs .is-recibida { border-color: rgba(253, 153, 39, .45); }
.docs .btn { color: #fff1dc; }
.sea-actions, .sea-meta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 0 0 16px; }
.sea-meta span {
  padding: 6px 10px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--muted); background: var(--surface);
}
@media (max-width: 720px) {
  .sea { padding: 16px 14px; }
  .flow { grid-template-columns: repeat(3, 1fr); }
  .docs li { align-items: stretch; flex-direction: column; }
  .port-pin small { display: none; }
  .sea-itinerary { padding: 12px 6px 10px; }
  .sea-itinerary li strong { font-size: .72rem; }
  .sea-itinerary li small { display: none; }
  .op-card-ports li small { display: none; }
  .ops-dossier { padding: 14px; }
  .ops-dossier .sea-meta { grid-template-columns: 1fr 1fr; }
}

.ops-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 16px;
  padding: 24px 26px;
  border-radius: 28px;
  border: 1px solid rgba(253, 153, 39, .32);
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(253, 153, 39, .34), transparent 48%),
    linear-gradient(150deg, #1a1008 0%, #3d220c 40%, #c56a12 82%, #fd9927 100%);
  color: #fff6ea;
  box-shadow: 0 22px 48px rgba(42, 18, 3, .18);
}
.ops-hero-glow {
  position: absolute;
  inset: auto -40px -60px auto;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.24), transparent 70%);
  pointer-events: none;
}
.ops-hero-waves {
  position: absolute;
  inset: auto 0 0;
  height: 70px;
  pointer-events: none;
  opacity: .35;
}
.ops-hero-waves span {
  position: absolute;
  left: -8%;
  width: 116%;
  height: 48px;
  border-radius: 50%;
  border: 1px solid rgba(255, 213, 154, .35);
  animation: sea-wave 10s linear infinite;
}
.ops-hero-waves span:nth-child(2) { bottom: 8px; animation-duration: 13s; animation-direction: reverse; }
.ops-hero-waves span:nth-child(3) { bottom: -6px; animation-duration: 16s; opacity: .5; }
.ops-hero-copy { position: relative; z-index: 1; max-width: 36rem; }
.ops-hero .eyebrow { color: #ffd59a; }
.ops-hero h2 {
  margin: 4px 0 8px;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  letter-spacing: -.035em;
  color: #fff;
  font-weight: 900;
}
.ops-hero p { margin: 0; color: rgba(255, 246, 234, .78); }
.ops-hero-actions { margin-top: 16px; }
.ops-hero-stats {
  position: relative; z-index: 1;
  display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end;
}
.ops-stat {
  min-width: 110px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(18, 10, 4, .55);
  border: 1px solid rgba(255, 213, 154, .45);
}
.ops-stat small {
  display: block;
  font-size: .68rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #ffd59a;
  margin-bottom: 4px;
}
.ops-stat strong {
  display: block;
  font-size: 1.35rem;
  color: #fff;
  font-weight: 900;
}
.ops-toolbar { margin-bottom: 12px; }
.ops-search { flex: 1; width: 100%; }
.ops-filters { margin-bottom: 14px; }
.ops-empty {
  text-align: center;
  padding: 48px 20px;
  border-radius: 28px;
  border: 1px dashed rgba(253, 153, 39, .35);
  background: rgba(253, 153, 39, .06);
}
.ops-empty-orb {
  display: block;
  width: 64px; height: 64px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #fff6ea, #fd9927);
  box-shadow: 0 12px 28px rgba(253, 153, 39, .35);
  animation: hull-bob 3s ease-in-out infinite;
}
.ops-empty strong { display: block; font-size: 1.15rem; margin-bottom: 6px; }
.ops-empty p { color: var(--muted); margin: 0 0 16px; }
.ops-deck {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.ops-deck .empty, .ops-deck .ops-empty { grid-column: 1 / -1; }
.deck .op-card,
.ops-deck .op-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  width: 100%;
  margin: 0;
  padding: 18px;
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
  border-radius: 24px;
  border: 1px solid rgba(48, 32, 16, 0.12);
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(253, 153, 39, 0.14), transparent 55%),
    linear-gradient(165deg, rgba(255, 252, 248, 0.98), var(--surface));
  box-shadow: 0 14px 32px rgba(42, 18, 3, 0.07);
  animation: deck-in .78s cubic-bezier(.14, .9, .18, 1) both;
  animation-delay: calc(var(--i) * 70ms);
  transition: transform .28s cubic-bezier(.22,1,.36,1), box-shadow .28s ease, border-color .28s ease;
}
html.theme-dark .ops-deck .op-card {
  border-color: rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(253, 153, 39, 0.16), transparent 55%),
    linear-gradient(165deg, #1c1612, #12100e);
}
.ops-deck .op-card.is-live {
  border-color: rgba(253, 153, 39, 0.34);
}
.ops-deck .op-card.is-done {
  opacity: 0.92;
}
.ops-deck .op-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 44px rgba(42, 18, 3, 0.12);
  border-color: rgba(253, 153, 39, 0.42);
}
.op-card-sheen {
  position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.14) 48%, transparent 62%);
  transform: translateX(-120%);
  pointer-events: none;
}
.ops-deck .op-card:hover .op-card-sheen { animation: sheen .85s ease both; }
.op-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.op-card-id {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  font-weight: 700;
  color: #9a4e0a;
}
html.theme-dark .op-card-id { color: #ffd59a; }
.op-card-state {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--muted);
}
.op-card-state.is-live {
  color: #c56a12;
}
.op-card-title {
  display: block;
  font-size: 1.12rem;
  letter-spacing: -0.03em;
  line-height: 1.25;
  margin: 0;
}
.op-card-route {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 0.9rem;
}
.op-card-route span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.op-card-route i {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(253, 153, 39, 0.55), transparent);
  position: relative;
}
.op-card-route i::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fd9927;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 4px rgba(253, 153, 39, 0.16);
}
.op-card-ports {
  list-style: none;
  margin: 2px 0 0;
  padding: 12px 8px 10px;
  position: relative;
  display: grid;
  grid-template-columns: repeat(var(--n, 2), minmax(0, 1fr));
  gap: 0;
  border-radius: 16px;
  border: 1px solid rgba(48, 32, 16, 0.08);
  background:
    linear-gradient(180deg, rgba(253, 153, 39, 0.06), rgba(255, 255, 255, 0.2));
}
html.theme-dark .op-card-ports {
  border-color: rgba(255, 255, 255, 0.07);
  background: linear-gradient(180deg, rgba(253, 153, 39, 0.08), rgba(255, 255, 255, 0.02));
}
.op-card-ports::before {
  content: "";
  position: absolute;
  left: calc(100% / (var(--n, 2) * 2));
  right: calc(100% / (var(--n, 2) * 2));
  top: 18px;
  height: 2px;
  border-radius: 99px;
  background: linear-gradient(90deg, rgba(253, 153, 39, 0.15), rgba(253, 153, 39, 0.55), rgba(253, 153, 39, 0.15));
  pointer-events: none;
}
.op-card-ports li {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 5px;
  text-align: center;
  padding: 0 4px;
  min-width: 0;
}
.op-card-ports li i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: linear-gradient(140deg, #fff6e8, #fd9927 50%, #a85a0c);
  box-shadow: 0 0 0 4px rgba(253, 153, 39, 0.14);
}
.op-card-ports li.is-escala i {
  width: 7px;
  height: 7px;
  background: #fff;
  border: 2px solid #fd9927;
  box-shadow: 0 0 0 3px rgba(253, 153, 39, 0.12);
}
.op-card-ports li span {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.2;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.op-card-ports li small {
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.ops-deck .op-card .lane {
  margin: 4px 0 0;
}
.ops-deck .op-card .lane-from,
.ops-deck .op-card .lane-to,
.ops-deck .op-card .lane-box { display: none; }
.ops-deck .op-card .lane-stop b { display: none; }
.op-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.op-card-meta span {
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(253, 153, 39, 0.1);
  border: 1px solid rgba(253, 153, 39, 0.18);
  color: #8a4a0f;
  font-size: 0.74rem;
  letter-spacing: 0.02em;
}
html.theme-dark .op-card-meta span {
  color: #ffd59a;
  background: rgba(253, 153, 39, 0.12);
}
.op-card-refs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  color: var(--muted);
  font-size: 0.78rem;
}
.op-card-refs em {
  font-style: normal;
  letter-spacing: 0.04em;
}
.op-card-go {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #c56a12;
  font-size: 0.86rem;
  font-weight: 600;
}
.op-card-go b {
  transition: transform .2s ease;
  font-weight: 700;
}
.ops-deck .op-card:hover .op-card-go b { transform: translateX(3px); }
@keyframes deck-in {
  0% { opacity: 0; transform: translateY(28px) scale(.97); }
  100% { opacity: 1; transform: none; }
}
@media (max-width: 860px) {
  .ops-deck { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .ops-hero { flex-direction: column; align-items: stretch; padding: 20px; }
  .ops-hero-stats { justify-content: flex-start; }
  .ops-hero-actions .hero-cta { width: 100%; justify-content: center; }
}
.lane {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-areas: "from rail to" "box box box";
  gap: 8px 12px;
  align-items: center;
  width: 100%;
}
.lane-from { grid-area: from; }
.lane-to { grid-area: to; text-align: right; }
.lane-box {
  grid-area: box;
  font-weight: 500;
  letter-spacing: .12em;
  font-size: .72rem;
  color: var(--warm);
}
.lane-rail { grid-area: rail; position: relative; height: 28px; }
.lane-bed, .lane-fill {
  position: absolute;
  left: 0;
  top: 50%;
  height: 3px;
  border-radius: 99px;
}
.lane-bed { right: 0; background: rgba(42, 18, 3, .16); transform: translateY(-50%); }
.lane-fill {
  width: calc(var(--p) * 100%);
  background: linear-gradient(90deg, #fff6e8, #ffd59a 20%, #fd9927 55%, #a85a0c);
  box-shadow: 0 0 12px rgba(253, 153, 39, .45);
  transform: translateY(-50%);
  transform-origin: left center;
  animation: lane-draw .85s cubic-bezier(.2, .75, .2, 1) both;
  animation-delay: calc(var(--i) * 90ms + 140ms);
}
.lane-stop {
  position: absolute;
  left: calc(var(--at) * 100%);
  top: 50%;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 4px;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.lane-stop::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: linear-gradient(140deg, #fff6e8, #fd9927 45%, #a85a0c);
  box-shadow: 0 0 0 4px rgba(253, 153, 39, 0.16), 0 2px 8px rgba(168, 78, 8, 0.25);
}
.lane-stop.is-escala::before {
  width: 8px;
  height: 8px;
  background: #fff;
  border: 2px solid #fd9927;
  box-shadow: 0 0 0 3px rgba(253, 153, 39, 0.14);
}
.lane-stop.is-origen::before,
.lane-stop.is-destino::before {
  width: 11px;
  height: 11px;
}
.lane-stop b {
  position: absolute;
  top: calc(100% + 6px);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
  color: var(--muted);
  max-width: 90px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.is-mini .lane-stop::before {
  width: 8px;
  height: 8px;
}
.is-mini .lane-stop.is-escala::before {
  width: 6px;
  height: 6px;
}
@keyframes lane-draw {
  from { transform: translateY(-50%) scaleX(0); }
  to { transform: translateY(-50%) scaleX(1); }
}
.lane-ship {
  position: absolute;
  top: 50%;
  left: 0;
  z-index: 3;
  width: 46px;
  height: 22px;
  overflow: visible;
  filter: drop-shadow(0 4px 6px rgba(168, 78, 8, .35));
  animation:
    ship-run 1.15s cubic-bezier(.12, .85, .15, 1) both,
    ship-idle 2.8s ease-in-out calc(var(--i) * 90ms + 1.35s) infinite;
  animation-delay: calc(var(--i) * 90ms + 200ms), calc(var(--i) * 90ms + 1.35s);
}
.lane-ship path, .lane-ship rect { fill: #fd9927; }
.lane-ship rect { fill: #ffd59a; }
.lane-ship path:last-child { fill: #fff6e8; }
.is-mini .lane-ship { width: 58px; height: 28px; }
.is-mini .lane-rail { height: 36px; }
.is-letter { margin: 14px 0 8px; }
.is-letter .lane-bed { background: #efe4d6; }
.is-letter .lane-from, .is-letter .lane-to, .is-letter .lane-box { color: #6a3b0c; }
.paper-link { margin: 0 0 8px; color: #6d645c; }
.paper-link a { color: #9a4e0a; font-weight: 500; }
@keyframes ship-run {
  0% { left: 0; transform: translate(0, -58%) scale(.55); }
  72% { left: calc(var(--p) * 100% + 10px); transform: translate(-50%, -58%) scale(1.08); }
  100% { left: calc(var(--p) * 100%); transform: translate(-50%, -58%) scale(1); }
}
@keyframes ship-idle {
  0%, 100% { transform: translate(-50%, -58%) rotate(0deg); }
  50% { transform: translate(-50%, calc(-58% - 3px)) rotate(-1.5deg); }
}
@media (prefers-reduced-motion: reduce) {
  .lane-ship { left: calc(var(--p) * 100%); transform: translate(-50%, -58%); animation: none; }
  .lane-fill { transform: translateY(-50%); }
}

.supply-board {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 8px;
}
.supply-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 250px;
  padding: 22px 22px 18px;
  border-radius: 28px;
  text-decoration: none;
  color: #fff6e8;
  overflow: hidden;
  border: 1px solid rgba(255, 213, 154, .35);
  background:
    radial-gradient(420px 180px at 100% 0%, rgba(253, 153, 39, .42), transparent 60%),
    linear-gradient(165deg, #3a2414 0%, #1a120c 48%, #0e0c0a 100%);
  box-shadow: 0 22px 40px rgba(42, 18, 3, .18), inset 0 1px 0 rgba(255, 246, 232, .2);
  animation: deck-in .7s cubic-bezier(.16, 1, .3, 1) both;
  animation-delay: calc(var(--i) * 80ms);
}
.supply-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, .08) 48%, transparent 62%);
  transform: translateX(-120%);
  animation: sheen 1.4s ease both;
  animation-delay: calc(var(--i) * 90ms + 200ms);
  pointer-events: none;
}
.supply-card:hover { transform: translateY(-4px); border-color: #fd9927; }
.supply-card .eyebrow { margin: 0; color: #ffd59a; letter-spacing: .22em; }
.supply-card h2 { margin: 0; font-size: 2rem; letter-spacing: -.04em; color: #fff; }
.supply-card p { margin: 0; color: rgba(255, 241, 220, .72); }
.supply-card small { margin-top: auto; color: #ffd59a; letter-spacing: .04em; }
.supply-card .lane { margin-top: 8px; }
.supply-card .lane-from, .supply-card .lane-to, .supply-card .lane-box { color: #fff1dc; }
.supply-card .lane-bed { background: rgba(255, 246, 232, .16); }
@keyframes sheen { to { transform: translateX(120%); } }
@media (max-width: 860px) {
  .supply-board { grid-template-columns: 1fr; }
  .quote-side { flex-wrap: wrap; justify-content: flex-end; }
  .house { grid-template-columns: 1fr; }
}

.house {
  display: grid;
  grid-template-columns: 1.4fr .8fr;
  gap: 16px;
  margin-bottom: 18px;
}
.house-hero, .house-side {
  border-radius: 28px;
  border: 1px solid rgba(255, 213, 154, .35);
  background:
    radial-gradient(420px 180px at 100% 0%, rgba(253, 153, 39, .38), transparent 58%),
    linear-gradient(165deg, #3a2414 0%, #1a120c 52%, #0e0c0a 100%);
  color: #fff6e8;
  box-shadow: 0 22px 40px rgba(42, 18, 3, .16), inset 0 1px 0 rgba(255, 246, 232, .18);
}
.house-hero { padding: 28px 28px 22px; }
.house-hero .eyebrow { color: #ffd59a; letter-spacing: .22em; }
.house-hero h2 { margin: 6px 0 8px; font-size: clamp(2.2rem, 4vw, 3.4rem); letter-spacing: -.05em; color: #fff; }
.house-hero p { margin: 0 0 18px; color: rgba(255, 241, 220, .74); }
.house-hero ul { list-style: none; display: flex; gap: 18px; margin: 0 0 18px; padding: 0; }
.house-hero li { display: flex; flex-direction: column; gap: 2px; }
.house-hero li span, .house-side span { color: #ffd59a; letter-spacing: .12em; text-transform: uppercase; font-size: .72rem; }
.house-hero strong { font-size: 1.8rem; letter-spacing: -.04em; }
.house-side { padding: 22px; display: flex; flex-direction: column; gap: 14px; justify-content: center; }
.house-side p { margin: 0; display: flex; flex-direction: column; gap: 3px; }
.house-fleet .house-box { align-items: stretch; }
.house .btn-ghost { color: #fff6e8; border-color: rgba(255, 213, 154, .45); }

.perm-box { display: grid; gap: 8px; margin: 8px 0 4px; padding: 12px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface-2); }
.invite-box { margin-bottom: 16px; padding: 22px; }
.invite-url, .invite-box .invite-url, .invite-panel .invite-url {
  display: block;
  word-break: break-all;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(253,153,39,.12);
  border: 1px solid rgba(253,153,39,.28);
  color: var(--text);
  font-family: inherit;
  font-size: 0.92rem;
  line-height: 1.45;
}
.clients-hero {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 18px;
  padding: 28px 30px;
  border-radius: 30px;
  border: 1px solid rgba(253, 153, 39, 0.28);
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(253, 153, 39, 0.34), transparent 48%),
    radial-gradient(60% 80% at 0% 100%, rgba(255, 213, 154, 0.18), transparent 55%),
    linear-gradient(145deg, #2a1203 0%, #7a3a0c 42%, #fd9927 100%);
  color: #fff6ea;
  box-shadow: 0 22px 48px rgba(42, 18, 3, 0.18);
  overflow: hidden;
  position: relative;
}
.clients-hero-glow {
  position: absolute;
  inset: auto -48px -70px auto;
  width: 260px; height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.28), transparent 70%);
  pointer-events: none;
  animation: clients-orb 7s ease-in-out infinite alternate;
}
@keyframes clients-orb {
  from { transform: translate(-8px, 6px) scale(1); opacity: .85; }
  to { transform: translate(-28px, -10px) scale(1.08); opacity: 1; }
}
.clients-hero-copy { position: relative; z-index: 1; max-width: 38rem; }
.clients-hero .eyebrow { color: #ffd59a; }
.clients-hero h2 {
  margin: 4px 0 8px;
  font-size: clamp(1.35rem, 2.4vw, 1.75rem);
  letter-spacing: -0.035em;
  color: #fff;
  font-weight: 900;
}
.clients-hero p { margin: 0; color: rgba(255, 246, 234, 0.78); }
.clients-hero-actions { margin-top: 18px; }
.clients-hero-meta {
  position: relative; z-index: 1;
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  flex: 0 0 auto;
  padding: 11px 16px;
  border-radius: 999px;
  background: rgba(18, 10, 4, 0.55);
  border: 1px solid rgba(255, 213, 154, 0.45);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 10px 24px rgba(18, 10, 4, 0.22);
  white-space: nowrap;
  line-height: 1;
}
.clients-hero-meta strong {
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.clients-hero-meta span {
  margin: 0;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #ffd59a;
  font-weight: 500;
}
.clients-toolbar { margin-bottom: 18px; }
.clients-search { flex: 1; width: 100%; }
.search.is-full { width: 100%; flex: 1 1 100%; }
.search.is-full input { width: 100%; }
.clients-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.client-tile {
  --tile-a: rgba(253, 153, 39, 0.22);
  --tile-b: rgba(255, 213, 154, 0.12);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 248px;
  padding: 20px;
  overflow: hidden;
  border-radius: 26px;
  border: 1px solid rgba(253, 153, 39, 0.22);
  background:
    radial-gradient(120% 90% at 100% -10%, var(--tile-a), transparent 52%),
    radial-gradient(90% 70% at 0% 100%, var(--tile-b), transparent 55%),
    linear-gradient(165deg, rgba(255,252,248,.98), var(--surface) 55%);
  text-decoration: none;
  color: inherit;
  box-shadow:
    0 18px 40px rgba(72, 42, 12, 0.08),
    inset 0 1px 0 rgba(255,255,255,.65);
  transition: transform .28s cubic-bezier(.16,1,.3,1), border-color .24s ease, box-shadow .28s ease;
  animation: client-tile-in .7s cubic-bezier(.16,1,.3,1) both;
  animation-delay: calc(var(--i, 0) * 55ms);
}
.client-tile.tone-2 {
  --tile-a: rgba(197, 106, 18, 0.24);
  --tile-b: rgba(253, 153, 39, 0.1);
}
.client-tile.tone-3 {
  --tile-a: rgba(255, 197, 106, 0.28);
  --tile-b: rgba(42, 18, 3, 0.06);
}
html.theme-dark .client-tile {
  background:
    radial-gradient(120% 90% at 100% -10%, var(--tile-a), transparent 52%),
    radial-gradient(90% 70% at 0% 100%, rgba(253,153,39,.08), transparent 55%),
    linear-gradient(165deg, #241810, #14100d 58%);
  box-shadow: 0 18px 40px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.06);
}
@keyframes client-tile-in {
  from { opacity: 0; transform: translateY(22px) scale(.97); }
  to { opacity: 1; transform: none; }
}
.client-tile-sheen {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.28) 48%, transparent 62%);
  transform: translateX(-130%);
  pointer-events: none;
}
.client-tile:hover {
  transform: translateY(-6px) scale(1.01);
  border-color: rgba(253, 153, 39, 0.55);
  box-shadow: 0 28px 54px rgba(197, 106, 18, 0.18);
}
.client-tile:hover .client-tile-sheen {
  animation: sheen .9s ease both;
}
.client-tile:hover .client-tile-go { color: #c56a12; transform: translateX(3px); }
.client-tile-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  position: relative;
  z-index: 1;
}
.client-tile-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}
.client-card-mark {
  width: 54px; height: 54px;
  display: grid; place-items: center;
  border-radius: 18px;
  background: linear-gradient(145deg, #fff1dc, #ffd59a 28%, #fd9927 62%, #c56a12);
  color: #2a1203;
  font-weight: 900;
  letter-spacing: -0.04em;
  font-size: 1.05rem;
  box-shadow:
    0 10px 22px rgba(197, 106, 18, 0.28),
    inset 0 1px 0 rgba(255,255,255,.55);
}
.client-card-mark.is-lg { width: 64px; height: 64px; border-radius: 22px; font-size: 1.2rem; }
.client-tile-body { position: relative; z-index: 1; min-width: 0; }
.client-tile-body strong {
  display: block;
  font-size: 1.28rem;
  letter-spacing: -0.04em;
  line-height: 1.15;
  margin-bottom: 6px;
}
.client-tile-legal,
.client-tile-id {
  display: block;
  color: var(--muted);
  line-height: 1.35;
}
.client-tile-legal { margin-bottom: 2px; }
.client-tile-facts {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: auto;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255,255,255,.42);
  border: 1px solid rgba(253, 153, 39, 0.14);
}
html.theme-dark .client-tile-facts {
  background: rgba(255,255,255,.04);
  border-color: rgba(253, 153, 39, 0.18);
}
.client-tile-facts span { min-width: 0; }
.client-tile-facts small {
  display: block;
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 3px;
}
.client-tile-facts b {
  display: block;
  font-weight: 500;
  font-size: 0.92rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.client-tile-foot {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 0.82rem;
}
.client-tile-foot > span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.client-tile-go {
  flex: 0 0 auto;
  color: #9a4e0a;
  font-weight: 500;
  transition: transform .24s ease, color .24s ease;
}
.client-kind {
  font-weight: 500;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(42, 18, 3, 0.06);
  color: var(--muted);
  border: 1px solid var(--line);
}
.client-link-chip {
  font-style: normal;
  font-size: 0.68rem;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(27, 122, 67, 0.12);
  color: #1b7a43;
  border: 1px solid rgba(27, 122, 67, 0.22);
}
.client-link-chip.is-wait {
  background: rgba(253, 153, 39, 0.12);
  color: #9a4e0a;
  border-color: rgba(253, 153, 39, 0.28);
}
.clients-empty {
  grid-column: 1 / -1;
  position: relative;
  overflow: hidden;
  padding: 64px 28px;
  text-align: center;
  border-radius: 28px;
  border: 1px dashed rgba(253, 153, 39, 0.4);
  background:
    radial-gradient(80% 80% at 50% 0%, rgba(253, 153, 39, 0.14), transparent 60%),
    rgba(253, 153, 39, 0.05);
  color: var(--muted);
}
.clients-empty-orb {
  display: block;
  width: 72px; height: 72px;
  margin: 0 auto 16px;
  border-radius: 24px;
  background: linear-gradient(145deg, #ffd59a, #fd9927 60%, #c56a12);
  box-shadow: 0 16px 36px rgba(197, 106, 18, 0.28);
}
.clients-empty strong { display: block; color: var(--text); margin-bottom: 6px; font-size: 1.25rem; letter-spacing: -.03em; }
.clients-empty p { margin: 0 0 18px; }
.clients-no-match { grid-column: 1 / -1; text-align: center; padding: 28px; }
.clients-composer .sheet-head { margin-bottom: 14px; }
.clients-composer .hint { margin: 6px 0 0; }
@media (max-width: 1180px) {
  .clients-board { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .clients-board { grid-template-columns: 1fr; }
  .clients-hero-actions .hero-cta { width: 100%; justify-content: center; }
}
.client-detail-head {
  display: flex; align-items: center; gap: 16px;
  margin: 0 0 18px;
  padding: 20px 22px;
  border-radius: 24px;
  border: 1px solid rgba(253, 153, 39, 0.22);
  background:
    linear-gradient(120deg, rgba(253, 153, 39, 0.08), transparent 48%),
    var(--surface);
  box-shadow: var(--shadow);
}
.client-detail-head h2 { margin: 2px 0 4px; letter-spacing: -0.04em; font-size: 1.55rem; }
.client-detail-head small { color: var(--muted); }
.invite-stage {
  position: relative;
  overflow: hidden;
  margin: 0 0 18px;
  padding: 24px;
  border-radius: 28px;
  border: 1px solid rgba(253, 153, 39, 0.38);
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(253, 153, 39, 0.28), transparent 50%),
    linear-gradient(165deg, #2a1203 0%, #5c2e0a 48%, #1a100a 100%);
  color: #fff6ea;
  box-shadow: 0 22px 48px rgba(42, 18, 3, 0.2);
}
.invite-stage.is-compact {
  background:
    radial-gradient(80% 90% at 100% 0%, rgba(253, 153, 39, 0.16), transparent 50%),
    var(--surface);
  color: var(--text);
  border-color: rgba(253, 153, 39, 0.28);
  box-shadow: var(--shadow);
}
.invite-stage-glow {
  position: absolute;
  inset: auto -50px -70px auto;
  width: 240px; height: 240px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 213, 154, 0.35), transparent 70%);
  pointer-events: none;
}
.invite-stage-top {
  position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-bottom: 14px;
}
.invite-stage-top .eyebrow { color: #ffd59a; margin: 0 0 4px; }
.invite-stage.is-compact .invite-stage-top .eyebrow { color: #9a4e0a; }
.invite-stage-top h3 {
  margin: 0;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
  color: #fff;
}
.invite-stage.is-compact .invite-stage-top h3 { color: var(--text); }
.invite-stage-body { position: relative; z-index: 1; }
.invite-expiry-line {
  margin: 0 0 12px;
  font-size: 0.84rem;
  color: rgba(255, 246, 234, 0.75);
}
.invite-stage.is-compact .invite-expiry-line { color: var(--muted); }
.invite-chip {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 999px;
}
.invite-chip.is-live {
  background: rgba(142, 215, 173, 0.22);
  color: #b7f0cb;
  border: 1px solid rgba(142, 215, 173, 0.4);
}
.invite-chip.is-dead {
  background: rgba(255, 177, 166, 0.18);
  color: #ffb1a6;
  border: 1px solid rgba(255, 177, 166, 0.35);
}
.invite-link-row {
  display: flex; gap: 10px; align-items: stretch; flex-wrap: wrap;
  margin-bottom: 8px;
}
.invite-link-row .invite-url {
  flex: 1; min-width: min(100%, 220px);
  padding: 12px 14px;
  font-size: 0.88rem;
  letter-spacing: 0.01em;
  word-break: break-all;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 213, 154, 0.28);
  color: #fff6ea;
}
.invite-stage.is-compact .invite-link-row .invite-url {
  background: rgba(253, 153, 39, 0.1);
  border-color: rgba(253, 153, 39, 0.28);
  color: var(--text);
}
.invite-link-row .btn { flex: 0 0 auto; align-self: center; }
.invite-link-row .btn.is-copied { background: #1b7a43; border-color: #1b7a43; }
.invite-mint {
  margin-top: 2px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 213, 154, 0.2);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.invite-ttl {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex: 1;
  margin: 0;
}
.invite-ttl-opt {
  cursor: pointer;
}
.invite-ttl-opt input { position: absolute; opacity: 0; pointer-events: none; }
.invite-ttl-opt span {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 213, 154, 0.28);
  background: rgba(255, 255, 255, 0.06);
  color: #fff6ea;
  font-size: 0.84rem;
  transition: background .2s ease, border-color .2s ease, transform .2s ease;
}
.invite-ttl-opt input:checked + span {
  background: linear-gradient(145deg, #fff6ea, #ffd59a 55%, #fd9927);
  color: #2a1203;
  border-color: transparent;
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(253, 153, 39, 0.28);
}
.invite-ttl-opt:hover span { transform: translateY(-1px); }
.invite-mint-btn {
  width: auto;
  min-width: 7.5rem;
  margin-left: auto;
}
@media (max-width: 720px) {
  .invite-mint { flex-direction: column; align-items: stretch; }
  .invite-mint-btn { width: 100%; margin-left: 0; }
}
.invite-mint.is-busy { opacity: 0.72; pointer-events: none; }
.invite-history {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 213, 154, 0.22);
}
.invite-history-title {
  margin: 0 0 10px;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #ffd59a;
}
.invite-history-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}
.invite-history-item {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 213, 154, 0.16);
}
.invite-history-item.is-vencido,
.invite-history-item.is-inactivo {
  opacity: 0.78;
}
.invite-history-main {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}
.invite-history-main code {
  font-size: 0.8rem;
  color: #fff6ea;
  word-break: break-all;
}
.invite-history-meta {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  font-size: 0.78rem;
  color: rgba(255, 246, 234, 0.7);
}
.client-dossier {
  margin: 0 0 16px;
  border-radius: 28px;
  border: 1px solid rgba(48, 32, 16, 0.14);
  background:
    linear-gradient(180deg, rgba(255, 252, 248, 0.98), var(--surface)),
    var(--surface);
  box-shadow: 0 18px 40px rgba(42, 18, 3, 0.08);
  overflow: hidden;
}
html.theme-dark .client-dossier {
  border-color: rgba(255, 255, 255, 0.1);
  background: linear-gradient(180deg, #1c1612, #12100e);
}
.client-dossier-head {
  padding: 20px 22px 14px;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(120deg, rgba(253, 153, 39, 0.12), transparent 55%);
}
.client-dossier-head h2 {
  margin: 4px 0 6px;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
}
.client-dossier-head .hint { margin: 0; }
.client-dossier-form {
  padding: 18px 22px 22px;
}
.client-dossier-form .field span {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}
.client-dossier-form .field input,
.client-dossier-form .field select,
.client-dossier-form .field textarea {
  border-radius: 14px;
  border-color: rgba(48, 32, 16, 0.14);
  background: var(--input);
}
.client-dossier-form .form-actions {
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.invite-hero {
  margin: 0 0 22px;
  padding: 28px 20px 8px;
  text-align: center;
}
.invite-hero .eyebrow {
  color: #c56a12;
  letter-spacing: 0.16em;
}
.invite-hero h1 {
  margin: 6px 0 8px;
  font-size: clamp(1.55rem, 4vw, 2.2rem);
  letter-spacing: -.04em;
}
.invite-hero-line {
  margin: 0 auto;
  color: var(--muted);
  white-space: nowrap;
  font-size: clamp(0.82rem, 2.1vw, 1rem);
  line-height: 1.35;
}
.invite-hero.is-expired h1 { color: var(--bad); }
.invite-card { max-width: 640px; margin: 0 auto; }
/* Solicitudes premium */
.req-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 16px;
  padding: 24px 26px;
  border-radius: 28px;
  border: 1px solid rgba(253, 153, 39, 0.3);
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(253, 153, 39, 0.34), transparent 48%),
    radial-gradient(70% 80% at 0% 100%, rgba(255, 213, 154, 0.14), transparent 55%),
    linear-gradient(150deg, #1a1008 0%, #4a2408 42%, #c56a12 82%, #fd9927 100%);
  color: #fff6ea;
  box-shadow: 0 22px 48px rgba(42, 18, 3, 0.16);
}
.req-hero-glow {
  position: absolute;
  inset: auto -40px -60px auto;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.24), transparent 70%);
  pointer-events: none;
}
.req-hero-aura {
  position: absolute;
  left: -8%;
  bottom: -40%;
  width: 46%;
  height: 120%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 213, 154, 0.16), transparent 68%);
  pointer-events: none;
  animation: req-aura 8s ease-in-out infinite alternate;
}
@keyframes req-aura {
  from { transform: translateX(0) scale(1); opacity: 0.7; }
  to { transform: translateX(6%) scale(1.08); opacity: 1; }
}
.req-hero-copy { position: relative; z-index: 1; max-width: 36rem; }
.req-hero .eyebrow { color: #ffd59a; }
.req-hero h2 {
  margin: 4px 0 8px;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  letter-spacing: -0.035em;
  color: #fff;
  font-weight: 900;
}
.req-hero p { margin: 0; color: rgba(255, 246, 234, 0.78); }
.req-hero-stats {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.req-stat {
  min-width: 112px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(18, 10, 4, 0.55);
  border: 1px solid rgba(255, 213, 154, 0.4);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 10px 24px rgba(18, 10, 4, 0.22);
}
.req-stat.is-live {
  border-color: rgba(255, 236, 210, 0.7);
  background: rgba(253, 153, 39, 0.28);
}
.req-stat small {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #ffd59a;
  margin-bottom: 4px;
}
.req-stat strong {
  display: block;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  color: #fff;
  font-weight: 900;
}
.req-toolbar { margin-bottom: 12px; }
.req-search { flex: 1; width: 100%; }
.req-filters { margin-bottom: 14px; }
.req-board {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.req-card {
  --q-a: rgba(253, 153, 39, 0.16);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(48, 32, 16, 0.12);
  background:
    radial-gradient(120% 90% at 100% 0%, var(--q-a), transparent 55%),
    linear-gradient(165deg, rgba(255, 252, 248, 0.98), var(--surface));
  box-shadow: 0 14px 32px rgba(42, 18, 3, 0.08);
  animation: deck-in 0.72s cubic-bezier(0.14, 0.9, 0.18, 1) both;
  animation-delay: calc(var(--i) * 55ms);
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.28s ease, border-color 0.28s ease;
}
.req-card.tone-live { --q-a: rgba(253, 153, 39, 0.28); border-color: rgba(253, 153, 39, 0.34); }
.req-card.tone-good { --q-a: rgba(80, 180, 120, 0.18); }
.req-card.tone-bad { --q-a: rgba(198, 40, 40, 0.12); }
html.theme-dark .req-card {
  border-color: rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(120% 90% at 100% 0%, var(--q-a), transparent 55%),
    linear-gradient(165deg, #1c1612, #12100e);
}
.req-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 44px rgba(42, 18, 3, 0.12);
  border-color: rgba(253, 153, 39, 0.4);
}
.req-card-sheen {
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.14) 48%, transparent 62%);
  transform: translateX(-120%);
  pointer-events: none;
}
.req-card:hover .req-card-sheen { animation: sheen 0.85s ease both; }
.req-card-top {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}
.req-avatar {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #2a1203;
  background: linear-gradient(140deg, #fff6e8, #ffd59a 40%, #fd9927);
  box-shadow: 0 8px 18px rgba(168, 78, 8, 0.22);
}
.req-card-who { min-width: 0; }
.req-card-who strong {
  display: block;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.req-card-who small {
  display: block;
  color: var(--muted);
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.req-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}
.req-kind {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  color: #8a4a0f;
  background: rgba(253, 153, 39, 0.12);
  border: 1px solid rgba(253, 153, 39, 0.22);
}
.req-kind.is-edit {
  color: #3d4f7a;
  background: rgba(111, 157, 255, 0.12);
  border-color: rgba(111, 157, 255, 0.28);
}
.req-kind.is-suspend {
  color: var(--bad);
  background: var(--bad-bg);
  border-color: transparent;
}
html.theme-dark .req-kind.is-join,
html.theme-dark .req-kind { color: #ffd59a; }
.req-card-body { position: relative; z-index: 1; display: grid; gap: 12px; }
.req-card-hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
}
.req-meta {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.req-meta li {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(48, 32, 16, 0.08);
  background: rgba(255, 255, 255, 0.45);
}
html.theme-dark .req-meta li {
  border-color: rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.03);
}
.req-meta em {
  font-style: normal;
  font-size: 0.64rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--muted);
}
.req-meta span,
.req-meta a {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: inherit;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.req-meta a:hover { color: #c56a12; }
.req-note {
  margin: 0;
  padding: 12px 14px;
  border-radius: 16px;
  border-left: 3px solid #fd9927;
  background: rgba(253, 153, 39, 0.08);
  color: var(--text);
  font-size: 0.9rem;
  line-height: 1.45;
}
html.theme-dark .req-note { background: rgba(253, 153, 39, 0.1); }
.req-card-actions {
  position: relative;
  z-index: 1;
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 4px;
}
.req-card-actions form { margin: 0; }
.req-card.is-pending .req-card-actions .btn-primary {
  box-shadow: 0 10px 22px rgba(168, 78, 8, 0.22);
}
.req-empty {
  grid-column: 1 / -1;
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 6px;
  padding: 48px 24px;
  border-radius: 24px;
  border: 1px dashed rgba(253, 153, 39, 0.35);
  background:
    radial-gradient(80% 80% at 50% 0%, rgba(253, 153, 39, 0.1), transparent 60%),
    var(--surface);
}
.req-empty-orb {
  width: 56px;
  height: 56px;
  margin-bottom: 8px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 30%, #fff6e8, #fd9927 55%, #8d4d0c);
  box-shadow: 0 12px 28px rgba(168, 78, 8, 0.25);
  animation: req-aura 5s ease-in-out infinite alternate;
}
.req-empty strong { display: block; font-size: 1.15rem; }
.req-empty p { margin: 0; color: var(--muted); max-width: 28rem; }
.req-catalog-empty { grid-column: 1 / -1; }
@media (max-width: 980px) {
  .req-board { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .req-hero { flex-direction: column; align-items: stretch; padding: 20px; }
  .req-hero-stats { justify-content: flex-start; }
  .req-card-top { grid-template-columns: auto minmax(0, 1fr); }
  .req-card-badges { grid-column: 1 / -1; justify-content: flex-start; }
  .req-meta { grid-template-columns: 1fr; }
}
.stats-filter { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; }
.stats-filter .field { margin: 0; min-width: 150px; }
.stats-panel h2, .stats-chart .eyebrow { margin-bottom: 8px; }
.bar-chart { display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); gap: 10px; align-items: end; min-height: 220px; padding-top: 12px; }

.stats-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 16px;
  padding: 24px 26px;
  border-radius: 28px;
  border: 1px solid rgba(253, 153, 39, 0.3);
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(253, 153, 39, 0.32), transparent 48%),
    linear-gradient(150deg, #1a1008 0%, #4a2408 42%, #c56a12 82%, #fd9927 100%);
  color: #fff6ea;
  box-shadow: 0 22px 48px rgba(42, 18, 3, 0.16);
}
.stats-hero-glow {
  position: absolute;
  inset: auto -40px -60px auto;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.22), transparent 70%);
  pointer-events: none;
}
.stats-hero-copy { position: relative; z-index: 1; max-width: 36rem; }
.stats-hero .eyebrow { color: #ffd59a; }
.stats-hero h2 {
  margin: 4px 0 8px;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  letter-spacing: -0.035em;
  color: #fff;
  font-weight: 900;
}
.stats-hero p { margin: 0; color: rgba(255, 246, 234, 0.78); }
.stats-hero-stats {
  position: relative; z-index: 1;
  display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end;
}
.stats-stat {
  min-width: 140px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(18, 10, 4, 0.55);
  border: 1px solid rgba(255, 213, 154, 0.45);
}
.stats-stat small {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #ffd59a;
  margin-bottom: 4px;
}
.stats-stat strong {
  display: block;
  font-size: 1.2rem;
  color: #fff;
  font-weight: 900;
  letter-spacing: -0.03em;
}
.stats-stat.is-soft strong { font-size: 1.45rem; }
.stats-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
  align-items: end;
  justify-content: space-between;
  margin: 0 0 16px;
}
.stats-presets { display: flex; flex-wrap: wrap; gap: 8px; }
.stats-preset {
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(253, 153, 39, 0.28);
  background: rgba(253, 153, 39, 0.08);
  color: var(--text);
  font-size: 0.86rem;
}
.stats-preset.is-on,
.stats-preset:hover {
  background: linear-gradient(145deg, #fff6ea, #ffd59a 55%, #fd9927);
  color: #2a1203;
  border-color: transparent;
  font-weight: 700;
}
.stats-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 16px;
}
.stats-kpi {
  padding: 16px;
  border-radius: 22px;
  border: 1px solid rgba(48, 32, 16, 0.12);
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(253, 153, 39, 0.14), transparent 55%),
    var(--surface);
  box-shadow: 0 14px 30px rgba(42, 18, 3, 0.06);
  animation: rise 0.55s cubic-bezier(.16,1,.3,1) both;
}
.stats-kpi.is-warn {
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(253, 153, 39, 0.22), transparent 55%),
    var(--surface);
}
html.theme-dark .stats-kpi {
  border-color: rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(253, 153, 39, 0.16), transparent 55%),
    #161210;
}
.stats-kpi span {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}
.stats-kpi strong {
  display: block;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  margin-bottom: 4px;
}
.stats-kpi small { color: var(--muted); }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 0 0 16px;
}
.stats-panel, .stats-chart {
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(48, 32, 16, 0.12);
  background: var(--surface);
  box-shadow: 0 16px 36px rgba(42, 18, 3, 0.06);
}
.stats-chart {
  margin: 0 0 16px;
}
html.theme-dark .stats-panel,
html.theme-dark .stats-chart {
  border-color: rgba(255, 255, 255, 0.08);
  background: #161210;
}
.stats-panel-head, .stats-chart-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
  margin-bottom: 14px;
}
.stats-panel-head h3, .stats-chart-head h3 {
  margin: 4px 0 0;
  font-size: 1.15rem;
  letter-spacing: -0.03em;
}
.stats-panel-head strong { color: #c56a12; font-size: 1.05rem; }
.stats-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.stats-bars-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.88rem;
  margin-bottom: 5px;
}
.stats-bars-meta span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.stats-bars-track {
  display: block;
  height: 8px;
  border-radius: 999px;
  background: rgba(253, 153, 39, 0.12);
  overflow: hidden;
}
.stats-bars-track i {
  display: block;
  height: 100%;
  width: var(--w, 0%);
  border-radius: inherit;
  background: linear-gradient(90deg, #ffd59a, #fd9927);
}
.stats-ops {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.stats-ops div {
  padding: 12px;
  border-radius: 16px;
  background: rgba(253, 153, 39, 0.08);
  border: 1px solid rgba(253, 153, 39, 0.16);
}
.stats-ops small {
  display: block;
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.stats-ops strong { font-size: 1.1rem; letter-spacing: -0.02em; }
.stats-bar-chart { min-height: 260px; }
.stats-bar-chart .bar-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: end;
  gap: 8px;
  min-width: 0;
}
.stats-bar-chart .bar-col i {
  display: block;
  width: 100%;
  max-width: 42px;
  height: var(--h);
  border-radius: 12px 12px 6px 6px;
  background: linear-gradient(180deg, #ffd59a, #fd9927 70%, #c56a12);
  box-shadow: 0 10px 20px rgba(253, 153, 39, 0.25);
}
.stats-bar-chart .bar-col.is-neg i {
  background: linear-gradient(180deg, #ffb1a6, #e85d4c);
}
.stats-bar-chart .bar-col strong {
  font-size: 0.72rem;
  color: var(--muted);
  text-align: center;
  line-height: 1.2;
}
.stats-bar-chart .bar-col span {
  font-size: 0.78rem;
  color: var(--text);
  font-weight: 600;
}
.stats-section-title { margin: 8px 0 12px; }
.stats-section-title h3 {
  margin: 4px 0 0;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
}
.stats-compare-hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr 1.1fr;
  gap: 12px;
  margin: 0 0 16px;
}
.stats-compare-card, .stats-compare-mid, .stats-triple-card {
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(48, 32, 16, 0.12);
  background: var(--surface);
  box-shadow: 0 16px 36px rgba(42, 18, 3, 0.06);
}
html.theme-dark .stats-compare-card,
html.theme-dark .stats-compare-mid,
html.theme-dark .stats-triple-card {
  border-color: rgba(255,255,255,0.08);
  background: #161210;
}
.stats-compare-card.is-now {
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(253,153,39,0.22), transparent 55%),
    var(--surface);
  border-color: rgba(253,153,39,0.28);
}
.stats-compare-card h3, .stats-triple-card h3 {
  margin: 4px 0 8px;
  font-size: 1.15rem;
  letter-spacing: -0.03em;
}
.stats-compare-card > strong {
  display: block;
  font-size: 1.55rem;
  letter-spacing: -0.04em;
  margin-bottom: 12px;
}
.stats-compare-card ul, .stats-mini-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}
.stats-compare-card li, .stats-mini-grid li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.9rem;
}
.stats-compare-card li span, .stats-mini-grid li span { color: var(--muted); }
.stats-delta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.stats-delta-grid div {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(253,153,39,0.08);
  border: 1px solid rgba(253,153,39,0.14);
}
.stats-delta-grid span {
  display: block;
  font-size: 0.72rem;
  color: var(--muted);
  margin-bottom: 4px;
}
.stats-delta-grid strong { font-size: 1.05rem; letter-spacing: -0.02em; }
.stats-delta-grid .is-up strong, .stats-delta.is-up { color: #1b7a43; }
.stats-delta-grid .is-down strong, .stats-delta.is-down { color: #c0392b; }
.stats-delta-grid .is-flat strong, .stats-delta.is-flat { color: var(--muted); }
.stats-delta { margin-left: 6px; font-style: normal; font-weight: 700; font-size: 0.78rem; }
.stats-triple {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 16px;
}
.stats-triple-card.is-current {
  border-color: rgba(253,153,39,0.35);
  box-shadow: 0 18px 40px rgba(253,153,39,0.12);
}
.stats-triple-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: start;
  margin-bottom: 10px;
}
.stats-triple-head strong { color: #c56a12; font-size: 1.15rem; }
.stats-mini-bars {
  height: 54px;
  display: flex;
  align-items: end;
  margin-bottom: 12px;
}
.stats-mini-bars i {
  display: block;
  width: 100%;
  height: var(--h);
  border-radius: 12px 12px 6px 6px;
  background: linear-gradient(180deg, #ffd59a, #fd9927);
}
.stats-mini-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stats-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stats-dual-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.stats-dual-track {
  display: grid;
  gap: 4px;
}
.stats-dual-track span {
  display: block;
  height: 8px;
  width: var(--w);
  border-radius: 999px;
  max-width: 100%;
}
.stats-dual-track .is-now, .stats-legend-inline i.is-now { background: linear-gradient(90deg, #ffd59a, #fd9927); }
.stats-dual-track .is-prev, .stats-legend-inline i.is-prev { background: linear-gradient(90deg, #cbb7a2, #8d6a45); }
.stats-legend-inline {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  display: flex;
  gap: 12px;
  align-items: center;
}
.stats-legend-inline i {
  width: 10px; height: 10px; border-radius: 50%; display: inline-block; margin-right: 4px;
}
.stats-spark {
  display: grid;
  grid-template-columns: repeat(30, minmax(0, 1fr));
  gap: 3px;
  align-items: end;
  min-height: 140px;
}
.stats-spark-col {
  height: 100%;
  display: flex;
  align-items: end;
}
.stats-spark-col i {
  display: block;
  width: 100%;
  height: var(--h);
  border-radius: 6px 6px 2px 2px;
  background: linear-gradient(180deg, rgba(255,213,154,.95), #fd9927);
}
.stats-spark-meta {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.78rem;
}
.stats-kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1180px) {
  .stats-compare-hero, .stats-triple, .stats-grid-3 { grid-template-columns: 1fr; }
  .stats-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.bar-col { display: grid; grid-template-rows: 1fr auto auto; gap: 6px; height: 220px; text-align: center; }
.bar-col i {
  align-self: end; height: var(--h); border-radius: 14px 14px 8px 8px;
  background: linear-gradient(180deg, #fff1dc, #fd9927 55%, #c56a12);
  box-shadow: 0 10px 24px rgba(197, 106, 18, .28);
  animation: rise .7s cubic-bezier(.16,1,.3,1) both;
}
.bar-col strong { font-size: .72rem; }
.bar-col span { color: var(--muted); font-size: .7rem; }
.doc-block { flex-direction: column; align-items: stretch !important; gap: 12px; }
.doc-top { display: flex; justify-content: space-between; gap: 12px; align-items: center; width: 100%; flex-wrap: wrap; }
.doc-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.upload-btn { position: relative; overflow: hidden; cursor: pointer; }
.upload-btn input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.doc-carousel { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center; width: 100%; }
.carousel-track {
  display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 4px 2px 8px; scrollbar-color: #fd9927 transparent;
}
.carousel-card {
  flex: 0 0 200px; scroll-snap-align: start; text-decoration: none; color: inherit;
  padding: 14px; border-radius: 18px; border: 1px solid rgba(253,153,39,.35);
  background: linear-gradient(145deg, rgba(253,153,39,.16), transparent 55%), var(--surface);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.35);
  transition: transform .25s ease, border-color .25s ease;
}
.carousel-card:hover { transform: translateY(-3px); border-color: #fd9927; }
.carousel-card strong, .carousel-card small { display: block; }
.carousel-card small { color: var(--muted); margin-top: 6px; }
.carousel-nav {
  width: 36px; height: 36px; border-radius: 50%; border: 1px solid rgba(253,153,39,.4);
  background: linear-gradient(140deg, #fff1dc, #fd9927); color: #2a1203; cursor: pointer; font-size: 1.2rem;
}
.soon-stage {
  position: relative; min-height: 62vh; display: grid; place-items: center; overflow: hidden;
  border-radius: 32px; border: 1px solid rgba(253,153,39,.35);
  background:
    radial-gradient(50% 40% at 50% 0%, rgba(253,153,39,.35), transparent 70%),
    linear-gradient(165deg, #3a2414, #120e0b 60%, #0a0908);
  color: #fff6e8;
}
.soon-orbit { position: absolute; inset: 10%; border-radius: 50%; border: 1px dashed rgba(255,213,154,.25); animation: spin 28s linear infinite; }
.soon-orbit i {
  position: absolute; width: 14px; height: 14px; border-radius: 50%;
  background: linear-gradient(120deg, #fff1dc, #fd9927); box-shadow: 0 0 20px rgba(253,153,39,.7);
}
.soon-orbit i:nth-child(1) { top: 0; left: 50%; }
.soon-orbit i:nth-child(2) { right: 0; top: 50%; }
.soon-orbit i:nth-child(3) { bottom: 0; left: 40%; }
.soon-orbit i:nth-child(4) { left: 8%; top: 30%; }
.soon-card {
  position: relative; z-index: 1; max-width: 560px; text-align: center; padding: 36px 28px;
  border-radius: 28px; border: 1px solid rgba(255,213,154,.35);
  background: rgba(18, 12, 8, .72); backdrop-filter: blur(10px);
  animation: deck-in .8s cubic-bezier(.16,1,.3,1) both;
}
.soon-card h2 { font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -.05em; margin: 8px 0 12px; }
.soon-pulse { height: 4px; border-radius: 99px; margin: 22px auto 14px; max-width: 180px; background: rgba(255,255,255,.12); overflow: hidden; }
.soon-pulse span {
  display: block; width: 40%; height: 100%;
  background: linear-gradient(90deg, #fff1dc, #fd9927, #c56a12);
  animation: soon-run 1.4s ease-in-out infinite;
}
@keyframes soon-run { 0% { transform: translateX(-120%); } 100% { transform: translateX(280%); } }
@media (max-width: 1100px) {
  .stats-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .stats-grid, .stats-kpis { grid-template-columns: 1fr; }
  .stats-hero, .stats-controls { flex-direction: column; align-items: stretch; }
  .stats-hero-stats { justify-content: flex-start; }
  .stats-ops { grid-template-columns: 1fr; }
  .bar-chart { grid-template-columns: repeat(auto-fit, minmax(56px, 1fr)); }
}

/* Cotizaciones premium */
.quotes-hero, .quote-detail-hero, .quote-edit-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 16px;
  padding: 24px 26px;
  border-radius: 28px;
  border: 1px solid rgba(253, 153, 39, 0.28);
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(253, 153, 39, 0.32), transparent 48%),
    radial-gradient(70% 80% at 0% 100%, rgba(255, 213, 154, 0.16), transparent 55%),
    linear-gradient(145deg, #2a1203 0%, #7a3a0c 42%, #fd9927 100%);
  color: #fff6ea;
  box-shadow: 0 20px 44px rgba(42, 18, 3, 0.16);
}
.quotes-hero-glow, .quote-detail-glow, .quote-edit-glow {
  position: absolute;
  inset: auto -40px -60px auto;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.26), transparent 70%);
  pointer-events: none;
}
.quotes-hero-copy, .quote-detail-copy, .quote-edit-copy { position: relative; z-index: 1; max-width: 36rem; }
.quotes-hero .eyebrow, .quote-detail-hero .eyebrow, .quote-edit-hero .eyebrow { color: #ffd59a; }
.quotes-hero h2, .quote-detail-hero h2, .quote-edit-hero h2 {
  margin: 4px 0 8px;
  font-size: clamp(1.35rem, 2.5vw, 1.8rem);
  letter-spacing: -0.035em;
  color: #fff;
  font-weight: 900;
}
.quotes-hero p, .quote-detail-hero p, .quote-edit-hero p { margin: 0; color: rgba(255, 246, 234, 0.78); }
.quotes-hero-actions { margin-top: 16px; }
.quote-edit-back {
  background: #fff6ea;
  color: #2a1203;
  border-color: transparent;
  box-shadow: 0 10px 24px rgba(42, 18, 3, 0.2);
}
.quotes-hero-stats {
  position: relative; z-index: 1;
  display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end;
}
.quotes-stat {
  min-width: 148px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(18, 10, 4, 0.55);
  border: 1px solid rgba(255, 213, 154, 0.45);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 10px 24px rgba(18, 10, 4, 0.22);
}
.quotes-stat small {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #ffd59a;
  margin-bottom: 4px;
  font-weight: 500;
}
.quotes-stat strong {
  display: block;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
  white-space: nowrap;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
  font-weight: 900;
}
.quotes-stat.is-soft strong { font-size: 1.4rem; }
.quotes-toolbar { margin-bottom: 12px; }
.quotes-search { flex: 1; width: 100%; }

/* Hero CTA premium */
.hero-cta {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(145deg, #ffffff 0%, #fff6ea 42%, #ffd59a 100%);
  color: #2a1203;
  font-weight: 700;
  letter-spacing: -0.01em;
  box-shadow:
    0 14px 30px rgba(42, 18, 3, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: transform .28s cubic-bezier(.22,1,.36,1), box-shadow .28s ease, filter .28s ease;
}
.hero-cta svg { width: 17px; height: 17px; position: relative; z-index: 1; }
.hero-cta-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 28%, rgba(255,255,255,.7) 48%, transparent 62%);
  transform: translateX(-120%);
  pointer-events: none;
}
.hero-cta:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow:
    0 18px 36px rgba(42, 18, 3, 0.32),
    0 0 0 1px rgba(255, 213, 154, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
  filter: saturate(1.05);
}
.hero-cta:hover .hero-cta-shine { animation: sheen .7s ease both; }
.hero-cta:active { transform: translateY(0) scale(0.98); }
.quotes-filters { margin-bottom: 16px; }
.quotes-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.quote-tile {
  --q-a: rgba(253, 153, 39, 0.2);
  --q-b: rgba(255, 213, 154, 0.1);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 188px;
  padding: 18px;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid rgba(253, 153, 39, 0.2);
  background:
    radial-gradient(120% 90% at 100% -10%, var(--q-a), transparent 52%),
    radial-gradient(90% 70% at 0% 100%, var(--q-b), transparent 55%),
    linear-gradient(165deg, rgba(255,252,248,.98), var(--surface) 55%);
  text-decoration: none;
  color: inherit;
  box-shadow: 0 16px 36px rgba(72, 42, 12, 0.08), inset 0 1px 0 rgba(255,255,255,.6);
  transition: transform .28s cubic-bezier(.16,1,.3,1), border-color .24s ease, box-shadow .28s ease;
  animation: quote-tile-in .65s cubic-bezier(.16,1,.3,1) both;
  animation-delay: calc(var(--i, 0) * 45ms);
}
.quote-tile.tone-warm { --q-a: rgba(253, 153, 39, 0.32); }
.quote-tile.tone-good { --q-a: rgba(80, 180, 120, 0.22); --q-b: rgba(253, 153, 39, 0.08); }
.quote-tile.tone-metal { --q-a: rgba(255, 197, 106, 0.34); }
.quote-tile.tone-bad { --q-a: rgba(198, 40, 40, 0.16); --q-b: rgba(253, 153, 39, 0.06); }
html.theme-dark .quote-tile {
  background:
    radial-gradient(120% 90% at 100% -10%, var(--q-a), transparent 52%),
    linear-gradient(165deg, #241810, #14100d 58%);
  box-shadow: 0 16px 36px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.06);
}
@keyframes quote-tile-in {
  from { opacity: 0; transform: translateY(18px) scale(.97); }
  to { opacity: 1; transform: none; }
}
.quote-tile-sheen {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.26) 48%, transparent 62%);
  transform: translateX(-130%);
}
.quote-tile:hover {
  transform: translateY(-5px) scale(1.01);
  border-color: rgba(253, 153, 39, 0.5);
  box-shadow: 0 24px 48px rgba(197, 106, 18, 0.16);
}
.quote-tile:hover .quote-tile-sheen { animation: sheen .85s ease both; }
.quote-tile:hover .quote-tile-go { color: #c56a12; transform: translateX(3px); }
.quote-tile-top, .quote-tile-foot {
  position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.quote-tile-id {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  font-weight: 500;
  color: #9a4e0a;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(253, 153, 39, 0.12);
  border: 1px solid rgba(253, 153, 39, 0.22);
}
html.theme-dark .quote-tile-id { color: #ffd59a; }
.quote-tile-body { position: relative; z-index: 1; min-width: 0; flex: 1; }
.quote-tile-body strong {
  display: block;
  font-size: 1.12rem;
  letter-spacing: -0.03em;
  margin-bottom: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.quote-tile-body small { color: var(--muted); line-height: 1.35; }
.quote-tile-foot { margin-top: auto; }
.quote-tile-foot b {
  font-size: 1.15rem;
  letter-spacing: -0.03em;
  background: linear-gradient(120deg, #2a1203, #c56a12 50%, #fd9927);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
html.theme-dark .quote-tile-foot b {
  background: linear-gradient(120deg, #fff6ea, #fd9927 55%, #ffd59a);
  -webkit-background-clip: text;
  background-clip: text;
}
.quote-tile-go {
  color: #9a4e0a;
  font-weight: 500;
  font-size: 0.86rem;
  transition: transform .24s ease, color .24s ease;
}
.quotes-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 56px 24px;
  border-radius: 28px;
  border: 1px dashed rgba(253, 153, 39, 0.4);
  background: radial-gradient(80% 80% at 50% 0%, rgba(253, 153, 39, 0.12), transparent 60%), rgba(253, 153, 39, 0.04);
  color: var(--muted);
}
.quotes-empty-orb {
  display: block; width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 20px;
  background: linear-gradient(145deg, #ffd59a, #fd9927 60%, #c56a12);
  box-shadow: 0 14px 30px rgba(197, 106, 18, 0.28);
}
.quotes-empty strong { display: block; color: var(--text); margin-bottom: 6px; font-size: 1.2rem; }
.quotes-empty p { margin: 0 0 16px; }
.quotes-no-match { grid-column: 1 / -1; text-align: center; padding: 24px; }
.quote-detail-stamp { position: relative; z-index: 1; }
.quote-detail-panel, .quote-edit-panel {
  margin-bottom: 16px;
  padding: 20px 22px;
  border-radius: 24px;
  border: 1px solid var(--line);
  background:
    radial-gradient(90% 80% at 100% 0%, rgba(253, 153, 39, 0.1), transparent 50%),
    var(--surface);
  box-shadow: var(--shadow);
}
.quote-facts article.is-total {
  border-color: rgba(253, 153, 39, 0.4);
  background:
    linear-gradient(145deg, rgba(253, 153, 39, 0.16), transparent 55%),
    var(--surface);
}
.quote-facts article.is-total strong {
  background: linear-gradient(120deg, #2a1203, #fd9927);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 1.15rem;
}
html.theme-dark .quote-facts article.is-total strong {
  background: linear-gradient(120deg, #fff6ea, #fd9927);
  -webkit-background-clip: text;
  background-clip: text;
}
.quote-cargo {
  display: flex; flex-wrap: wrap; gap: 12px; align-items: end;
  margin: 8px 0 14px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--surface-2);
}
.quote-cargo .field { margin: 0; min-width: 220px; flex: 1; }
.quote-actions { margin-top: 4px; }
.quote-convert {
  margin: 0 0 16px;
  padding: 22px;
  border-radius: 24px;
  border: 1px solid rgba(253, 153, 39, 0.32);
  background:
    radial-gradient(80% 90% at 100% 0%, rgba(253, 153, 39, 0.16), transparent 50%),
    var(--surface);
  box-shadow: var(--shadow);
}
.quote-convert-copy h3 {
  margin: 4px 0 8px;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
}
.quote-paper { margin-top: 4px; }
.quote-edit-back { position: relative; z-index: 1; align-self: center; }
.quote-edit-panel .doc-form.is-quote-doc {
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
}
.quote-edit-panel .fx-card {
  border: 1px solid rgba(253, 153, 39, 0.28);
  background:
    radial-gradient(90% 100% at 0% 0%, rgba(253, 153, 39, 0.16), transparent 55%),
    var(--surface-2);
}
.quote-edit-panel .lines .line {
  padding: 14px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--surface-2);
}
.quote-edit-panel .totals {
  margin-top: 8px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(253, 153, 39, 0.28);
  background:
    linear-gradient(120deg, rgba(253, 153, 39, 0.12), transparent 55%),
    var(--surface-2);
}
.quote-edit-panel .totals strong { font-size: 1.05rem; }
.quotes-composer .doc-form { border: 0; background: transparent; box-shadow: none; padding: 0; }
@media (max-width: 1180px) {
  .quotes-board { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .quotes-board { grid-template-columns: 1fr; }
  .quotes-hero, .quote-detail-hero, .quote-edit-hero { flex-direction: column; align-items: stretch; padding: 20px; }
  .quotes-hero-stats { justify-content: flex-start; }
  .quotes-hero-actions .hero-cta { width: 100%; justify-content: center; }
}

/* Facturación premium */
.invoices-hero, .invoice-detail-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 16px;
  padding: 24px 26px;
  border-radius: 28px;
  border: 1px solid rgba(253, 153, 39, 0.3);
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(253, 153, 39, 0.34), transparent 48%),
    radial-gradient(70% 80% at 0% 100%, rgba(255, 213, 154, 0.14), transparent 55%),
    linear-gradient(150deg, #1a1008 0%, #5c2a08 40%, #c56a12 78%, #fd9927 100%);
  color: #fff6ea;
  box-shadow: 0 22px 48px rgba(42, 18, 3, 0.18);
}
.invoice-detail-hero.is-draft {
  background:
    radial-gradient(90% 120% at 100% 0%, rgba(255, 213, 154, 0.28), transparent 50%),
    linear-gradient(150deg, #24160c 0%, #6b3a12 48%, #a86a2a 100%);
}
.invoices-hero-glow, .invoice-detail-glow {
  position: absolute;
  inset: auto -40px -60px auto;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.24), transparent 70%);
  pointer-events: none;
}
.invoices-hero-copy, .invoice-detail-copy { position: relative; z-index: 1; max-width: 38rem; }
.invoices-hero .eyebrow, .invoice-detail-hero .eyebrow { color: #ffd59a; }
.invoices-hero h2, .invoice-detail-hero h2 {
  margin: 4px 0 8px;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  letter-spacing: -0.035em;
  color: #fff;
  font-weight: 900;
}
.invoices-hero p, .invoice-detail-hero p { margin: 0; color: rgba(255, 246, 234, 0.78); }
.invoices-hero-actions { margin-top: 16px; }
.invoices-hero-stats {
  position: relative; z-index: 1;
  display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end;
}
.invoices-stat {
  min-width: 132px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(18, 10, 4, 0.55);
  border: 1px solid rgba(255, 213, 154, 0.45);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 10px 24px rgba(18, 10, 4, 0.22);
}
.invoices-stat small {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #ffd59a;
  margin-bottom: 4px;
}
.invoices-stat strong {
  display: block;
  font-size: 1.15rem;
  letter-spacing: -0.03em;
  color: #fff;
  font-weight: 900;
  white-space: nowrap;
}
.invoices-stat.is-soft strong { font-size: 1.35rem; }
.invoices-toolbar { margin-bottom: 12px; }
.invoices-search { flex: 1; width: 100%; }
.invoices-filters { margin-bottom: 14px; }
.invoices-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.invoice-tile {
  --q-a: rgba(253, 153, 39, 0.18);
  --q-b: rgba(255, 213, 154, 0.08);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 168px;
  padding: 16px;
  border-radius: 22px;
  text-decoration: none;
  color: inherit;
  border: 1px solid rgba(48, 32, 16, 0.12);
  background:
    radial-gradient(120% 90% at 100% 0%, var(--q-a), transparent 55%),
    linear-gradient(165deg, rgba(255, 252, 248, 0.98), var(--surface));
  box-shadow: 0 14px 32px rgba(42, 18, 3, 0.08);
  animation: rise 0.55s cubic-bezier(.16,1,.3,1) both;
  animation-delay: calc(var(--i, 0) * 35ms);
  transition: transform .28s cubic-bezier(.22,1,.36,1), box-shadow .28s ease;
}
.invoice-tile.tone-draft { --q-a: rgba(180, 140, 90, 0.22); --q-b: rgba(253, 153, 39, 0.08); }
.invoice-tile.tone-warm { --q-a: rgba(253, 153, 39, 0.32); }
.invoice-tile.tone-good { --q-a: rgba(80, 180, 120, 0.22); }
.invoice-tile.tone-bad { --q-a: rgba(198, 40, 40, 0.16); }
.invoice-tile.tone-sim { --q-a: rgba(111, 157, 255, 0.22); }
html.theme-dark .invoice-tile {
  border-color: rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(120% 90% at 100% 0%, var(--q-a), transparent 55%),
    linear-gradient(165deg, #1c1612, #12100e);
}
.invoice-tile-sheen {
  position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.18) 48%, transparent 62%);
  transform: translateX(-120%); pointer-events: none;
}
.invoice-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 40px rgba(42, 18, 3, 0.14);
}
.invoice-tile:hover .invoice-tile-sheen { animation: sheen .85s ease both; }
.invoice-tile:hover .invoice-tile-go { color: #c56a12; transform: translateX(3px); }
.invoice-tile-top, .invoice-tile-foot {
  position: relative; z-index: 1;
  display: flex; justify-content: space-between; gap: 10px; align-items: flex-start;
}
.invoice-tile-badges { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.invoice-tile-id {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  font-weight: 700;
  color: #9a4e0a;
  max-width: 58%;
  word-break: break-all;
}
html.theme-dark .invoice-tile-id { color: #ffd59a; }
.invoice-tile-body { position: relative; z-index: 1; min-width: 0; flex: 1; }
.invoice-tile-body strong {
  display: block;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}
.invoice-tile-body small { color: var(--muted); line-height: 1.35; }
.invoice-tile-foot { margin-top: auto; align-items: center; }
.invoice-tile-foot b {
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.invoice-tile-go {
  color: var(--muted);
  font-size: 0.84rem;
  transition: color .2s ease, transform .2s ease;
}
.invoices-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 48px 20px;
  border-radius: 28px;
  border: 1px dashed rgba(253, 153, 39, 0.35);
  background: rgba(253, 153, 39, 0.06);
  position: relative;
}
.invoices-empty-orb {
  display: block;
  width: 64px; height: 64px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #fff6ea, #fd9927);
  box-shadow: 0 12px 28px rgba(253, 153, 39, 0.35);
}
.invoices-empty strong { display: block; font-size: 1.15rem; margin-bottom: 6px; }
.invoices-empty p { color: var(--muted); margin: 0 0 16px; }
.invoice-detail-stamp { position: relative; z-index: 1; }
.invoice-detail-panel, .invoice-edit-panel {
  margin: 0 0 16px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(48, 32, 16, 0.12);
  background: var(--surface);
  box-shadow: 0 16px 36px rgba(42, 18, 3, 0.07);
}
html.theme-dark .invoice-detail-panel,
html.theme-dark .invoice-edit-panel {
  border-color: rgba(255, 255, 255, 0.08);
}
.invoice-facts .is-total {
  background: linear-gradient(145deg, rgba(253, 153, 39, 0.16), rgba(255, 213, 154, 0.08));
  border-color: rgba(253, 153, 39, 0.28);
}
.invoice-meta { margin: 14px 0; }
.invoice-pay { margin-bottom: 12px; }
.invoice-actions { margin-top: 8px; }
.invoice-edit-head { margin-bottom: 14px; }
.invoice-edit-head h3 {
  margin: 4px 0 6px;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
}
.invoice-edit-panel .doc-form {
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
}
.invoices-composer .doc-form { border: 0; background: transparent; box-shadow: none; padding: 0; }
.invoice-sim-banner { margin-bottom: 14px; }
.invoice-paper { margin-top: 4px; }
@media (max-width: 1180px) {
  .invoices-board { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .invoices-board { grid-template-columns: 1fr; }
  .invoices-hero, .invoice-detail-hero { flex-direction: column; align-items: stretch; padding: 20px; }
  .invoices-hero-stats { justify-content: flex-start; }
  .invoices-hero-actions .hero-cta { width: 100%; justify-content: center; }
}
