﻿:root {
  --bg: #efe8dc;
  --bg-warm: #f7f1e6;
  --ink: #10211c;
  --muted: #5a6d66;
  --brand: #0c241f;
  --brand-2: #16382f;
  --brand-3: #1f4f43;
  --accent: #c45c26;
  --accent-2: #e08a3c;
  --accent-soft: #f8e6d4;
  --gold: #c9a15b;
  --paper: #fffcf7;
  --paper-soft: #ffffff;
  --line: rgba(12, 36, 31, 0.16);
  --line-strong: rgba(12, 36, 31, 0.26);
  --danger: #9f1f1f;
  --ok: #1a6b48;
  --shadow: 0 1px 2px rgba(12, 36, 31, 0.06), 0 14px 36px rgba(12, 36, 31, 0.1);
  --shadow-lg: 0 24px 64px rgba(12, 36, 31, 0.2);
  --radius: 1.1rem;
  --radius-sm: 0.75rem;
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Outfit", "Segoe UI", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --header-h: 4.4rem;
  --nav-h: 0px;
  --page-max: 80rem;
  --gutter: 1.15rem;
  --gap: 0.75rem;
  --stack: 1.25rem;
  --pad: 1.1rem;
  --control-h: 2.85rem;
  --vv-offset-top: 0px;
  --vv-height: 100dvh;
  --select-chevron: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%235c6f68' d='M1.2 1.2 6 6l4.8-4.8'/></svg>");
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: light;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  touch-action: manipulation;
}

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg-warm);
}

body {
  min-height: 100vh;
  position: relative;
  isolation: isolate;
  overflow-x: clip;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(ellipse 70% 50% at 8% -10%, rgba(196, 92, 38, 0.2), transparent 55%),
    radial-gradient(ellipse 55% 45% at 100% 0%, rgba(12, 36, 31, 0.18), transparent 50%),
    radial-gradient(ellipse 40% 30% at 70% 100%, rgba(201, 161, 91, 0.18), transparent 50%),
    linear-gradient(180deg, #efe6d6, #e2d8c6);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.28;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='0.5'/></svg>");
}

button,
input,
select {
  font: inherit;
}

button {
  -webkit-appearance: none;
  appearance: none;
}

.view {
  min-height: 100vh;
  min-height: 100dvh;
}

[hidden] {
  display: none !important;
}

.eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.lead {
  margin: 0.4rem 0 0;
  color: var(--muted);
  line-height: 1.5;
  max-width: 42rem;
}

.muted {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.hint {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
}

.error {
  margin: 0;
  padding: 0.7rem 0.85rem;
  border-radius: 0.75rem;
  background: rgba(161, 29, 29, 0.08);
  color: var(--danger);
  font-size: 0.9rem;
  animation: shake 0.4s var(--ease);
}

/* Logo */
.logo-lockup {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

.logo-lockup.compact .logo-mark {
  width: 2.15rem;
  height: 2.15rem;
  font-size: 1rem;
}

.logo-lockup.compact .logo-word {
  font-size: 1.22rem;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 2.7rem;
  height: 2.7rem;
  border-radius: 0.85rem;
  background: linear-gradient(160deg, var(--brand-3), var(--brand));
  color: #f6faf7;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.12),
    0 8px 18px rgba(12, 36, 31, 0.22);
  animation: mark-glow 4.5s ease-in-out infinite;
}

.logo-lockup.light .logo-mark {
  background: linear-gradient(160deg, #fff8ee, #efe4d2);
  color: var(--brand);
  animation: none;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

.logo-word {
  font-family: var(--font-display);
  font-weight: 650;
  font-size: 1.7rem;
  letter-spacing: -0.04em;
}

.mobile-only {
  margin-bottom: 1.2rem;
}

/* Login */
.login-layout {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: 1fr;
}

.login-hero {
  display: none;
  position: relative;
  overflow: hidden;
  padding: 3.2rem;
  color: #f4faf7;
  background:
    radial-gradient(circle at 18% 18%, rgba(196, 92, 38, 0.38), transparent 36%),
    radial-gradient(circle at 88% 82%, rgba(201, 161, 91, 0.18), transparent 32%),
    linear-gradient(165deg, #14352d 0%, #0c241f 48%, #081814 100%);
}

.login-orbs {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.login-orbs span {
  position: absolute;
  border-radius: 50%;
  filter: blur(8px);
  opacity: 0.45;
  animation: orb-float 14s ease-in-out infinite;
}

.login-orbs span:nth-child(1) {
  width: 18rem;
  height: 18rem;
  left: -4rem;
  top: 12%;
  background: radial-gradient(circle, rgba(196, 92, 38, 0.55), transparent 70%);
}

.login-orbs span:nth-child(2) {
  width: 14rem;
  height: 14rem;
  right: -2rem;
  bottom: 18%;
  background: radial-gradient(circle, rgba(201, 161, 91, 0.4), transparent 70%);
  animation-delay: -4s;
}

.login-orbs span:nth-child(3) {
  width: 10rem;
  height: 10rem;
  left: 42%;
  top: -3rem;
  background: radial-gradient(circle, rgba(244, 250, 247, 0.18), transparent 70%);
  animation-delay: -8s;
}

.login-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      -22deg,
      transparent,
      transparent 22px,
      rgba(244, 250, 247, 0.03) 22px,
      rgba(244, 250, 247, 0.03) 23px
    );
  pointer-events: none;
}

.login-hero-inner {
  position: relative;
  z-index: 1;
  max-width: 28rem;
  animation: rise 0.8s var(--ease) both;
}

.login-hero .logo-word {
  color: #f6faf7;
}

.login-tagline {
  margin: 2rem 0 0;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 2.6vw, 2.45rem);
  font-weight: 500;
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.login-points {
  margin: 2.2rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.85rem;
  counter-reset: pts;
}

.login-points li {
  counter-increment: pts;
  display: grid;
  grid-template-columns: 2.35rem 1fr;
  column-gap: 0.85rem;
  row-gap: 0.12rem;
  padding: 1rem 1.05rem;
  border: 1px solid rgba(244, 250, 247, 0.12);
  border-radius: 1rem;
  background: rgba(244, 250, 247, 0.06);
  backdrop-filter: blur(8px);
  transition: transform 0.25s var(--ease), background 0.25s var(--ease);
}

.login-points li:hover {
  transform: translateX(4px);
  background: rgba(244, 250, 247, 0.1);
}

.login-points li::before {
  content: counter(pts);
  grid-row: 1 / span 2;
  align-self: center;
  display: grid;
  place-items: center;
  width: 2.05rem;
  height: 2.05rem;
  border-radius: 50%;
  background: linear-gradient(160deg, var(--accent-2), var(--accent));
  color: #fff8f1;
  font-size: 0.82rem;
  font-weight: 700;
  box-shadow: 0 8px 16px rgba(196, 92, 38, 0.28);
}

.login-points strong {
  grid-column: 2;
  font-size: 0.98rem;
}

.login-points span {
  grid-column: 2;
  color: rgba(244, 250, 247, 0.72);
  font-size: 0.9rem;
}

.login-panel {
  display: grid;
  place-items: center;
  padding:
    max(1.6rem, env(safe-area-inset-top))
    max(1.2rem, env(safe-area-inset-right))
    max(2.4rem, env(safe-area-inset-bottom))
    max(1.2rem, env(safe-area-inset-left));
}

.login-card {
  width: min(100%, 26rem);
  padding: 1.7rem 1.5rem 1.55rem;
  border: 1.5px solid rgba(12, 36, 31, 0.16);
  border-radius: 1.4rem;
  background: #fff;
  box-shadow: var(--shadow-lg);
  animation: rise 0.75s var(--ease) 0.08s both;
}

.login-header h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 5vw, 2.4rem);
  letter-spacing: -0.03em;
}

.login-form {
  margin-top: 1.4rem;
  display: grid;
  gap: 0.95rem;
}

.password-wrap {
  position: relative;
}

.password-wrap input {
  padding-right: 3.4rem;
}

.install-hint {
  margin: 0.75rem auto 0;
  width: min(100%, 24rem);
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.4;
  text-align: center;
}

.install-login-btn {
  margin-top: 0.85rem;
}

.app-update-btn {
  position: relative;
}

.app-update-dot {
  position: absolute;
  top: 0.35rem;
  right: 0.35rem;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 999px;
  background: #c45c26;
  box-shadow: 0 0 0 2px #fff;
}

.app-update-btn.is-busy {
  opacity: 0.7;
  pointer-events: none;
}

.app-update-overlay {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  background: rgba(12, 36, 31, 0.42);
  backdrop-filter: blur(2px);
}

.app-update-overlay[hidden] {
  display: none !important;
}

.app-update-card {
  width: min(100%, 22rem);
  padding: 1.15rem 1.2rem 1.25rem;
  border-radius: 1rem;
  background: #fffcf7;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  box-shadow: 0 22px 50px rgba(12, 36, 31, 0.22);
}

.app-update-status {
  margin: 0 0 0.85rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
  text-align: center;
}

.app-update-track {
  height: 0.55rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.1);
  overflow: hidden;
}

.app-update-bar {
  height: 100%;
  width: 8%;
  border-radius: inherit;
  background: linear-gradient(90deg, #0c241f, #c45c26);
  transition: width 0.35s ease;
}

.app-update-overlay.is-done .app-update-bar {
  background: #1a6b48;
}

.app-update-overlay.is-indeterminate .app-update-bar {
  width: 40% !important;
  animation: app-update-slide 1.1s ease-in-out infinite;
}

@keyframes app-update-slide {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(280%); }
}

.header-tools {
  position: relative;
  flex: none;
}

.header-tools-btn {
  position: relative;
  width: 2.55rem;
  height: 2.55rem;
  display: grid;
  place-items: center;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  border-radius: 999px;
  background: #fff;
  color: var(--brand);
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(12, 36, 31, 0.06);
}

.header-tools-btn svg {
  width: 1.2rem;
  height: 1.2rem;
}

.header-tools-btn:hover,
.header-tools-btn[aria-expanded="true"] {
  border-color: rgba(196, 92, 38, 0.45);
  background: #fff8f1;
}

.header-tools-badge {
  position: absolute;
  top: -0.15rem;
  right: -0.15rem;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.28rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #c45c26;
  color: #fff;
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1;
}

.header-tools-badge[hidden] {
  display: none !important;
}

.header-tools-badge.is-dot {
  min-width: 0.55rem;
  width: 0.55rem;
  height: 0.55rem;
  padding: 0;
  font-size: 0;
}

.header-tools-menu {
  position: absolute;
  top: calc(100% + 0.55rem);
  right: 0;
  z-index: 45;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem;
  border-radius: 999px;
  background: rgba(255, 252, 247, 0.96);
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  box-shadow: 0 14px 36px rgba(12, 36, 31, 0.16);
  backdrop-filter: blur(12px);
  animation: header-tools-pop 0.22s ease;
}

.header-tools-menu[hidden] {
  display: none !important;
}

@keyframes header-tools-pop {
  from {
    opacity: 0;
    transform: translateY(-6px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.header-tools-orb {
  position: relative;
  width: 3.55rem;
  min-height: 3.55rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.18rem;
  padding: 0.35rem 0.25rem;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  border-radius: 999px;
  background: #fff;
  color: var(--brand);
  cursor: pointer;
  font: inherit;
  font-size: 0.62rem;
  font-weight: 650;
  line-height: 1.1;
  box-shadow: 0 4px 12px rgba(12, 36, 31, 0.08);
}

.app-update-label {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: -0.01em;
}

.install-orb-label {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: -0.01em;
}

.header-tools-orb-icon {
  display: grid;
  place-items: center;
  width: 1.35rem;
  height: 1.35rem;
}

.header-tools-orb-icon svg {
  width: 1.15rem;
  height: 1.15rem;
}

.header-tools-orb:hover,
.header-tools-orb[aria-expanded="true"] {
  border-color: rgba(196, 92, 38, 0.4);
  background: #fff8f1;
}

.header-tools-notice {
  position: relative;
}

.header-tools-notice .notice-panel {
  top: calc(100% + 0.55rem);
  right: 50%;
  transform: translateX(50%);
}

.header-tools-notice .notice-bell-count {
  top: 0.15rem;
  right: 0.2rem;
}

#install-btn[hidden] {
  display: none !important;
}

.text-btn {
  position: absolute;
  right: 0.45rem;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: var(--brand);
  font-weight: 600;
  font-size: 0.82rem;
  padding: 0.35rem 0.5rem;
  cursor: pointer;
}

@media (min-width: 960px) {
  .login-layout {
    grid-template-columns: 1.08fr 0.92fr;
  }

  .login-hero {
    display: grid;
    align-content: center;
  }

  .mobile-only {
    display: none;
  }

  .login-panel {
    padding: 3rem;
  }

  .login-card {
    padding: 2rem 1.85rem 1.8rem;
  }
}

/* App chrome */
.app-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  column-gap: 0.75rem;
  row-gap: 0.65rem;
  padding-top: calc(env(safe-area-inset-top, 0px) + 0.75rem);
  padding-bottom: 0.7rem;
  padding-left: max(var(--gutter), env(safe-area-inset-left), calc((100% - var(--page-max)) / 2));
  padding-right: max(var(--gutter), env(safe-area-inset-right), calc((100% - var(--page-max)) / 2));
  background: rgba(255, 252, 247, 0.96);
  border-bottom: 1.5px solid rgba(12, 36, 31, 0.14);
  box-shadow: 0 10px 30px rgba(12, 36, 31, 0.08);
}

.app-header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    180deg,
    rgba(255, 252, 247, 0.98) 0%,
    rgba(255, 252, 247, 0.94) 100%
  );
  backdrop-filter: blur(18px) saturate(1.15);
  pointer-events: none;
}

.app-header > .logo-lockup {
  grid-column: 1;
  min-width: 0;
}

.header-actions {
  grid-column: 2;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem;
  min-width: 0;
  overflow: visible;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  max-width: 11.5rem;
  padding: 0.2rem 0.6rem 0.2rem 0.2rem;
  border-radius: 999px;
  background: #fff;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  box-shadow: 0 4px 12px rgba(12, 36, 31, 0.06);
}

.user-avatar {
  display: grid;
  place-items: center;
  width: 1.85rem;
  height: 1.85rem;
  border-radius: 50%;
  background: linear-gradient(160deg, var(--brand-3), var(--brand));
  color: #f6faf7;
  font-size: 0.74rem;
  font-weight: 700;
  flex: none;
}

.user-label {
  color: var(--muted);
  font-size: 0.82rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notice-bell-wrap {
  position: relative;
  flex: none;
}

.header-alert-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex: none;
}

.notice-bell-btn {
  position: relative;
  width: 2.55rem;
  height: 2.55rem;
  display: grid;
  place-items: center;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  border-radius: 999px;
  background: #fff;
  color: var(--brand);
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(12, 36, 31, 0.06);
}

.notice-bell-btn svg {
  width: 1.2rem;
  height: 1.2rem;
}

.notice-bell-btn:hover,
.notice-bell-btn[aria-expanded="true"] {
  border-color: rgba(196, 92, 38, 0.45);
  background: #fff8f1;
}

.notice-bell-count {
  position: absolute;
  top: -0.15rem;
  right: -0.15rem;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.28rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #c45c26;
  color: #fff;
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1;
}

.notice-bell-count[hidden] {
  display: none !important;
}

.notice-panel {
  position: absolute;
  top: calc(100% + 0.45rem);
  right: 0;
  z-index: 40;
  width: min(22.5rem, calc(100vw - 1.5rem));
  max-height: min(28rem, 70vh);
  display: flex;
  flex-direction: column;
  border-radius: 1rem;
  background: #fff;
  border: 1.5px solid rgba(12, 36, 31, 0.16);
  box-shadow: 0 18px 48px rgba(12, 36, 31, 0.18);
  overflow: hidden;
}

.notice-panel[hidden] {
  display: none !important;
}

.notice-panel-head,
.notice-panel-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.7rem 0.85rem;
  background: #faf7f2;
  flex: 0 0 auto;
}

.notice-panel-head {
  border-bottom: 1px solid rgba(12, 36, 31, 0.1);
}

.notice-panel-head strong {
  font-size: 0.92rem;
}

.notice-panel-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  flex: none;
}

.notice-read-all,
.notice-clear-all,
.notice-push-btn {
  border: 0;
  background: none;
  color: var(--accent);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0;
}

.notice-clear-all {
  color: #9a3518;
}

.notice-panel-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

.notice-empty {
  margin: 0;
  padding: 1.2rem 0.95rem;
  color: var(--muted);
  font-size: 0.86rem;
}

.notice-item {
  display: grid;
  gap: 0.18rem;
  width: 100%;
  text-align: left;
  border: 0;
  border-bottom: 1px solid rgba(12, 36, 31, 0.08);
  background: #fff;
  padding: 0.75rem 0.9rem;
  cursor: pointer;
  font: inherit;
}

.notice-item.is-unread {
  background: #fff8f1;
}

.notice-item strong {
  font-size: 0.84rem;
  color: var(--brand);
}

.notice-item span {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.35;
}

.notice-item time {
  font-size: 0.7rem;
  color: #8a6a4a;
}

.notice-panel-foot {
  border-top: 1px solid rgba(12, 36, 31, 0.1);
  flex-direction: column;
  align-items: stretch;
}

.notice-push-hint {
  margin: 0;
  font-size: 0.74rem;
  color: var(--muted);
  line-height: 1.35;
}

@media (max-width: 720px) {
  .notice-panel {
    position: fixed;
    top: calc(env(safe-area-inset-top, 0px) + 4.85rem);
    left: 0.7rem;
    right: 0.7rem;
    width: auto;
    max-height: calc(
      100dvh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 6rem
    );
    z-index: 80;
  }
}

.tabs {
  grid-column: 1 / -1;
  display: flex;
  gap: 0.28rem;
  padding: 0.28rem;
  border-radius: 999px;
  background: #fff;
  border: 1.5px solid rgba(12, 36, 31, 0.16);
  box-shadow: 0 6px 16px rgba(12, 36, 31, 0.07);
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tab {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: 999px;
  padding: 0.48rem 0.8rem;
  min-height: 2.75rem;
  font-weight: 600;
  font-size: 0.88rem;
  white-space: nowrap;
  cursor: pointer;
  position: relative;
  transition: background 0.22s var(--ease), color 0.22s var(--ease), box-shadow 0.22s var(--ease), transform 0.22s var(--ease);
}

.tab-icon {
  display: none;
  place-items: center;
}

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

.tab-more-wrap {
  display: none;
  position: relative;
  flex: 1 1 0;
  min-width: 0;
}

.tab-more-btn {
  width: 100%;
}

.nav-more-menu {
  position: absolute;
  right: 0.35rem;
  bottom: calc(100% + 0.55rem);
  min-width: 13.5rem;
  padding: 0.4rem;
  border-radius: 1rem;
  background: rgba(255, 252, 247, 0.98);
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  box-shadow: 0 16px 40px rgba(12, 36, 31, 0.18);
  display: grid;
  gap: 0.2rem;
  z-index: 50;
}

.nav-more-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--ink);
  border-radius: 0.75rem;
  padding: 0.72rem 0.8rem;
  font: inherit;
  font-weight: 650;
  font-size: 0.92rem;
  text-align: left;
  cursor: pointer;
}

.nav-more-item .tab-icon {
  display: grid;
  width: 1.25rem;
  height: 1.25rem;
  color: var(--brand-3);
}

.nav-more-item .tab-icon svg {
  width: 1.2rem;
  height: 1.2rem;
}

.nav-more-item:hover,
.nav-more-item:focus-visible {
  background: rgba(12, 36, 31, 0.07);
  outline: none;
}

.nav-more-item.is-active {
  background: linear-gradient(180deg, var(--brand-3), var(--brand));
  color: #f6faf7;
}

.nav-more-item.is-active .tab-icon {
  color: #f6faf7;
}

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

.tab.active {
  color: #f6faf7;
  background: linear-gradient(180deg, var(--brand-3), var(--brand));
  box-shadow: 0 8px 18px rgba(12, 36, 31, 0.22);
}

@media (min-width: 1024px) {
  .app-header {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    padding-top: calc(env(safe-area-inset-top, 0px) + 0.8rem);
    padding-bottom: 0.8rem;
  }

  .app-header > .logo-lockup {
    grid-column: 1;
    justify-self: start;
  }

  .tabs {
    grid-column: 2;
    justify-self: center;
    width: max-content;
    max-width: 100%;
    gap: 0.22rem;
    padding: 0.3rem;
  }

  .header-actions {
    grid-column: 3;
    justify-self: end;
  }

  .user-chip {
    max-width: 16rem;
  }

  .tab {
    width: 2.85rem;
    height: 2.85rem;
    min-height: 2.85rem;
    padding: 0;
    border-radius: 0.9rem;
  }

  .tab-icon {
    display: grid;
    width: 1.3rem;
    height: 1.3rem;
  }

  .tab-icon svg {
    width: 1.25rem;
    height: 1.25rem;
  }

  .tab-label,
  .tab-label-short {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }

  .tab-more-wrap {
    display: none !important;
  }

  .tab::after {
    content: attr(title);
    position: absolute;
    top: calc(100% + 0.45rem);
    left: 50%;
    transform: translateX(-50%) translateY(2px);
    padding: 0.28rem 0.55rem;
    border-radius: 0.45rem;
    background: var(--brand);
    color: #f6faf7;
    font-size: 0.7rem;
    font-weight: 650;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.16s var(--ease), transform 0.16s var(--ease);
    z-index: 20;
  }

  .tab:hover::after,
  .tab:focus-visible::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }

  .header-actions .btn-ghost {
    padding: 0.48rem 0.85rem;
    font-size: 0.86rem;
    min-height: 2.5rem;
  }
}

.content {
  width: 100%;
  padding-top: 1.2rem;
  padding-bottom: max(2.75rem, calc(1.5rem + env(safe-area-inset-bottom) + var(--nav-h)));
  padding-left: max(var(--gutter), env(safe-area-inset-left), calc((100% - var(--page-max)) / 2));
  padding-right: max(var(--gutter), env(safe-area-inset-right), calc((100% - var(--page-max)) / 2));
}

.panel {
  /* No opacity/transform entrance: on mobile, fill-mode "both" + tab re-trigger
     left panels blank until a scroll forced a repaint. */
  opacity: 1;
}

.panel-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.85rem 1rem;
  margin: 0 0 var(--stack);
}

.panel-head > div {
  flex: 1 1 17rem;
  min-width: 0;
}

.panel-head > .btn-primary,
.panel-head > .header-buttons {
  flex: none;
  margin-inline-start: auto;
}

.panel-head h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 2.6vw, 2.2rem);
  line-height: 1.15;
  letter-spacing: -0.035em;
  overflow-wrap: anywhere;
}

.section-title {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: 1.22rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

/* Forms */
label {
  display: grid;
  gap: 0.38rem;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--brand-2);
}

.inline-label {
  display: grid;
  gap: 0.32rem;
}

input,
select {
  width: 100%;
  min-height: var(--control-h);
  border: 1.5px solid rgba(12, 36, 31, 0.18);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.9rem;
  color: var(--ink);
  background-color: #fff;
}

input {
  transition:
    border-color 0.2s var(--ease),
    box-shadow 0.2s var(--ease),
    background-color 0.2s,
    transform 0.2s var(--ease);
}

/* Sin transition de background: en iPhone Safari la flecha SVG parpadea/desaparece al abrir el picker */
select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: 2.4rem;
  background-color: #fff;
  background-image: var(--select-chevron);
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  background-size: 0.75rem 0.5rem;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

input[type="checkbox"],
input[type="radio"] {
  width: auto;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
}

/* Evitar que la rueda del mouse/touchpad cambie valores numéricos */
input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}

input.money-input {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
}

input::placeholder {
  color: #8b9b95;
}

input:hover,
select:hover {
  border-color: rgba(12, 36, 31, 0.3);
}

input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(12, 36, 31, 0.1);
  background-color: #fff;
}

select:hover,
select:focus,
select:active {
  /* Reafirmar la flecha: iOS borra background-image al enfocar si se usa el shorthand `background` */
  background-image: var(--select-chevron);
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  background-size: 0.75rem 0.5rem;
}

select:focus,
select:active {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(12, 36, 31, 0.1);
  background-color: #fff;
}

.btn-primary,
.btn-ghost {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.78rem;
  padding: 0.74rem 1.15rem;
  min-height: var(--control-h);
  font-weight: 650;
  line-height: 1.2;
  cursor: pointer;
  touch-action: manipulation;
  transition: background 0.2s var(--ease), box-shadow 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease);
}

.btn-primary {
  border: 0;
  background: linear-gradient(180deg, var(--brand-3), var(--brand));
  color: #f6faf7;
  box-shadow: 0 10px 22px rgba(12, 36, 31, 0.2);
}

.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 25%, rgba(255, 255, 255, 0.2) 50%, transparent 75%);
  transform: translateX(-120%);
  pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover {
    box-shadow: 0 14px 28px rgba(12, 36, 31, 0.26);
  }

  .btn-primary:hover::after {
    animation: shine 0.7s ease;
  }

  .btn-ghost:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff8f1;
    box-shadow: 0 10px 20px rgba(196, 92, 38, 0.28);
  }
}

.btn-primary:disabled,
.btn-ghost:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-block {
  width: 100%;
}

.btn-ghost {
  background: #fff4ea;
  color: #8a3e16;
  border: 1.5px solid rgba(196, 92, 38, 0.55);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7), 0 6px 14px rgba(138, 62, 22, 0.1);
}

.btn-toolbar-icon {
  display: none;
}

.btn-primary:active,
.btn-ghost:active {
  filter: brightness(0.96);
}

.btn-icon {
  flex: none;
  width: 2.15rem;
  height: 2.15rem;
  display: grid;
  place-items: center;
  border: 1.5px solid rgba(196, 92, 38, 0.5);
  border-radius: 50%;
  background: #fff4ea;
  color: #8a3e16;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(138, 62, 22, 0.1);
  transition: background 0.15s var(--ease), color 0.15s var(--ease), transform 0.15s var(--ease), border-color 0.15s var(--ease);
}

.btn-icon:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff8f1;
  transform: rotate(90deg);
}

.summary-card,
.editor,
.catalog-block {
  border: 1.5px solid rgba(12, 36, 31, 0.16);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

.summary-card {
  display: grid;
  gap: 1rem;
  padding: var(--pad);
  margin-bottom: var(--stack);
  animation: rise 0.5s var(--ease) 0.05s both;
  border-top: 3px solid var(--accent);
}

.editor {
  display: grid;
  gap: 0.95rem;
  padding: 1.15rem 1.15rem 1.2rem;
  margin-bottom: 1.4rem;
}

.editor-head {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  align-items: start;
}

.editor-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.3rem;
  letter-spacing: -0.02em;
}

.editor-head .muted {
  margin: 0.3rem 0 0;
}

.field-group {
  margin: 0;
  padding: 0.9rem 0 0;
  border: 0;
  border-top: 1px solid var(--line);
}

.field-group legend {
  padding: 0;
  margin-bottom: 0.8rem;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand);
}

.form-grid {
  display: grid;
  gap: 0.85rem;
  grid-template-columns: 1fr;
}

@media (min-width: 740px) {
  .form-grid {
    grid-template-columns: 1fr 1fr;
  }

  .form-grid .span-2,
  .catalog-grid .span-2 {
    grid-column: span 2;
  }
}

.preview-bar {
  display: grid;
  gap: 0.45rem;
  padding: 0.95rem 1.05rem;
  border-radius: 0.95rem;
  background: linear-gradient(135deg, var(--accent-soft), #f3dcc4);
  color: var(--brand);
  font-weight: 600;
  border: 1px solid rgba(196, 92, 38, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.preview-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

.preview-metrics b {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(0.92rem, 3.2vw, 1.08rem);
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

.preview-metrics span {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #8a4a22;
}

/* â€”â€” Modal nueva reserva â€”â€” */
.modal-sheet-res {
  width: min(100%, 54rem);
  max-height: min(92vh, 58rem);
  height: auto;
  min-height: 0;
  flex: 0 1 auto;
  align-self: center;
}

.modal-sheet-res .editor.res-editor {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  grid-template-columns: minmax(0, 1fr);
  flex: 1 1 auto;
  min-height: 0;
  height: auto;
  max-height: min(92vh, 58rem);
  gap: 0;
}

.modal-sheet-res .editor-body.res-modal-body {
  min-height: 0;
  max-height: none;
  padding: 0;
  overflow: auto;
  overscroll-behavior: contain;
}

.modal-sheet-res .form-actions {
  margin-top: 0;
}

.res-modal-lead {
  max-width: none;
  line-height: 1.45;
}

.res-summary-dock {
  position: sticky;
  top: 0;
  z-index: 2;
  display: grid;
  gap: 0.55rem;
  padding: 0.65rem var(--pad) 0.7rem;
  border-bottom: 1.5px solid rgba(12, 36, 31, 0.1);
  background: linear-gradient(180deg, #faf7f2 0%, #f3eadc 100%);
  box-shadow: 0 4px 14px rgba(12, 36, 31, 0.05);
  overflow: hidden;
}

.res-summary-dock::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(196, 92, 38, 0.15) 20%,
    rgba(196, 92, 38, 0.55) 50%,
    rgba(196, 92, 38, 0.15) 80%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: res-dock-shine 4s ease-in-out infinite;
  pointer-events: none;
}

.res-summary-dock.is-live::after {
  animation: res-dock-shine 2.8s ease-in-out infinite;
}

.res-summary-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem 0.85rem;
  min-width: 0;
}

.res-summary-bar-start {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
}

.res-summary-title {
  margin: 0;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--brand);
  white-space: nowrap;
}

.res-preview {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.res-preview-empty {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 600;
  color: #7a6a5a;
  line-height: 1.4;
}

.res-live {
  display: grid;
  gap: 0.5rem;
  animation: res-strip-in 0.32s var(--ease);
}

.res-live-math {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.4rem;
}

.res-live-cell {
  display: grid;
  gap: 0.18rem;
  min-width: 0;
  padding: 0.45rem 0.5rem;
  border-radius: 0.65rem;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(12, 36, 31, 0.08);
  animation: res-chip-in 0.28s var(--ease) both;
}

.res-live-cell:nth-child(1) { animation-delay: 0.02s; }
.res-live-cell:nth-child(2) { animation-delay: 0.05s; }
.res-live-cell:nth-child(3) { animation-delay: 0.08s; }
.res-live-cell:nth-child(4) { animation-delay: 0.11s; }
.res-live-cell:nth-child(5) { animation-delay: 0.14s; }

.res-live-label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #8a6a4a;
  line-height: 1.2;
}

.res-live-value {
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  color: var(--brand);
  line-height: 1.15;
  overflow-wrap: anywhere;
  animation: res-value-pop 0.34s var(--ease);
}

.res-live-cell.is-net {
  background: rgba(196, 92, 38, 0.12);
  border-color: rgba(196, 92, 38, 0.28);
}

.res-live-cell.is-net .res-live-label {
  color: #a35422;
}

.res-live-cell.is-net .res-live-value {
  color: var(--accent);
  font-size: 0.98rem;
}

.res-live-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 0.35rem;
}

.res-live-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.55rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.05);
  border: 1px solid rgba(12, 36, 31, 0.08);
  font-size: 0.72rem;
  font-weight: 600;
  color: #5a4a3a;
  white-space: nowrap;
  animation: res-chip-in 0.28s var(--ease) both;
}

.res-live-meta .res-live-chip:nth-child(1) { animation-delay: 0.04s; }
.res-live-meta .res-live-chip:nth-child(2) { animation-delay: 0.08s; }
.res-live-meta .res-live-chip:nth-child(3) { animation-delay: 0.12s; }
.res-live-meta .res-live-chip:nth-child(4) { animation-delay: 0.16s; }

.res-channel-badge {
  flex: none;
  max-width: 11rem;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(12, 36, 31, 0.12);
  background: rgba(255, 255, 255, 0.75);
  font-size: 0.74rem;
  font-weight: 600;
  color: #7a6a5a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: border-color 0.22s var(--ease), background 0.22s var(--ease), transform 0.22s var(--ease);
}

.res-channel-badge.is-set {
  border-color: rgba(196, 92, 38, 0.28);
  background: rgba(196, 92, 38, 0.1);
  color: var(--brand);
  animation: res-badge-in 0.3s var(--ease);
}

.res-channel-badge strong {
  font-weight: 700;
  color: var(--brand);
}

.res-checklist-dots {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.res-checklist-dots li {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 999px;
  border: 1.5px solid rgba(12, 36, 31, 0.2);
  background: rgba(255, 255, 255, 0.8);
  transition:
    transform 0.22s var(--ease),
    border-color 0.22s var(--ease),
    background 0.22s var(--ease),
    box-shadow 0.22s var(--ease);
}

.res-checklist-dots li.is-done {
  border-color: var(--accent);
  background: var(--accent);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85);
  animation: res-dot-pop 0.28s var(--ease);
}

.res-preview-warn {
  margin: 0.35rem 0 0;
  padding: 0.4rem 0.55rem;
  border-radius: 0.55rem;
  background: rgba(180, 50, 40, 0.1);
  border: 1px solid rgba(180, 50, 40, 0.2);
  font-size: 0.74rem;
  font-weight: 600;
  color: #8b2e26;
}

@keyframes res-dock-shine {
  0%, 100% { background-position: 200% 0; opacity: 0.45; }
  50% { background-position: 0% 0; opacity: 1; }
}

@keyframes res-strip-in {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

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

@keyframes res-value-pop {
  0% { opacity: 0.35; transform: translateY(3px); }
  60% { transform: translateY(-1px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes res-dot-pop {
  0% { transform: scale(0.7); }
  70% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

@keyframes res-badge-in {
  from { opacity: 0; transform: scale(0.92); }
  to { opacity: 1; transform: scale(1); }
}

@media (max-width: 860px) {
  .res-live-math {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .res-live-cell.is-net {
    order: -1;
    grid-column: 1 / -1;
    grid-template-columns: auto 1fr;
    align-items: baseline;
    gap: 0.55rem 0.75rem;
    padding: 0.55rem 0.7rem;
  }

  .res-live-cell.is-net .res-live-label {
    font-size: 0.72rem;
  }

  .res-live-cell.is-net .res-live-value {
    font-size: 1.15rem;
    text-align: right;
  }
}

@media (max-width: 720px) {
  .res-summary-dock {
    gap: 0.45rem;
    padding: 0.5rem var(--pad) 0.55rem;
  }

  .res-summary-title {
    font-size: 0.64rem;
  }

  .res-channel-badge {
    max-width: 9.5rem;
    font-size: 0.7rem;
  }

  .res-live-value {
    font-size: 0.82rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .res-summary-dock::after,
  .res-live.is-ready,
  .res-live-cell,
  .res-live-chip,
  .res-live-value,
  .res-checklist-dots li.is-done,
  .res-channel-badge.is-set {
    animation: none !important;
  }
}

.res-modal-form {
  display: grid;
  gap: 0.85rem;
  min-width: 0;
  padding: 0.85rem var(--pad) 1.1rem;
}

.res-section {
  padding: 1rem 1.05rem 1.05rem;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  border-radius: 1rem;
  background: linear-gradient(180deg, #fff 0%, #faf7f2 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.res-section-notes {
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
}

.res-section-notes label {
  display: grid;
  gap: 0.38rem;
}

/* Fondos suaves por tipo de campo — modal Nueva / Editar reserva */
#reservation-form {
  --res-tint-guest: #eef5fb;
  --res-tint-guest-border: rgba(74, 122, 168, 0.28);
  --res-tint-guest-ring: rgba(74, 122, 168, 0.16);
  --res-tint-place: #eef6f1;
  --res-tint-place-border: rgba(55, 120, 95, 0.26);
  --res-tint-place-ring: rgba(55, 120, 95, 0.14);
  --res-tint-stay: #faf1e6;
  --res-tint-stay-border: rgba(180, 120, 55, 0.28);
  --res-tint-stay-ring: rgba(180, 120, 55, 0.14);
  --res-tint-cash: #f3eff8;
  --res-tint-cash-border: rgba(110, 90, 160, 0.24);
  --res-tint-cash-ring: rgba(110, 90, 160, 0.14);
  --res-tint-ota: #f7f3e6;
  --res-tint-ota-border: rgba(160, 130, 50, 0.26);
  --res-tint-ota-ring: rgba(160, 130, 50, 0.14);
  --res-tint-ops: #f8eee8;
  --res-tint-ops-border: rgba(176, 100, 70, 0.26);
  --res-tint-ops-ring: rgba(176, 100, 70, 0.14);
  --res-tint-net: #f6ebe4;
  --res-tint-net-border: rgba(196, 92, 38, 0.28);
  --res-tint-net-ring: rgba(196, 92, 38, 0.16);
  --res-tint-aseo: #eef6f3;
  --res-tint-aseo-border: rgba(45, 120, 100, 0.26);
  --res-tint-aseo-ring: rgba(45, 120, 100, 0.14);
  --res-tint-notes: #f5f2ec;
  --res-tint-notes-border: rgba(12, 36, 31, 0.16);
  --res-tint-notes-ring: rgba(12, 36, 31, 0.1);
  --res-tint-bank: #eef4f1;
  --res-tint-bank-border: rgba(45, 106, 79, 0.26);
  --res-tint-bank-ring: rgba(45, 106, 79, 0.14);
}

#reservation-form input:not([type='checkbox']):not([type='radio']):not([type='file']),
#reservation-form textarea {
  transition:
    border-color 0.2s var(--ease),
    box-shadow 0.2s var(--ease),
    background-color 0.2s var(--ease),
    transform 0.2s var(--ease);
}

#reservation-form select {
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

#reservation-form input[name='guest_name'],
#reservation-form #res-guest-document,
#reservation-form #res-guest-phone {
  background-color: var(--res-tint-guest);
  border-color: var(--res-tint-guest-border);
}

#reservation-form input[name='guest_name']:focus,
#reservation-form #res-guest-document:focus,
#reservation-form #res-guest-phone:focus {
  border-color: rgba(74, 122, 168, 0.55);
  box-shadow: 0 0 0 4px var(--res-tint-guest-ring);
  background-color: #f5f9fd;
}

#reservation-form #res-unit,
#reservation-form #res-channel,
#reservation-form select[name='status'] {
  background-color: var(--res-tint-place);
  border-color: var(--res-tint-place-border);
}

#reservation-form #res-unit:focus,
#reservation-form #res-channel:focus,
#reservation-form select[name='status']:focus {
  border-color: rgba(55, 120, 95, 0.5);
  box-shadow: 0 0 0 4px var(--res-tint-place-ring);
  background-color: #f5faf7;
}

#reservation-form #res-check-in,
#reservation-form #res-check-out {
  background-color: var(--res-tint-stay);
  border-color: var(--res-tint-stay-border);
}

#reservation-form #res-check-in:focus,
#reservation-form #res-check-out:focus {
  border-color: rgba(180, 120, 55, 0.5);
  box-shadow: 0 0 0 4px var(--res-tint-stay-ring);
  background-color: #fcf7f0;
}

#reservation-form #res-collection-date,
#reservation-form #res-available-month {
  background-color: var(--res-tint-cash);
  border-color: var(--res-tint-cash-border);
}

#reservation-form #res-collection-date:focus,
#reservation-form #res-available-month:focus {
  border-color: rgba(110, 90, 160, 0.48);
  box-shadow: 0 0 0 4px var(--res-tint-cash-ring);
  background-color: #f8f5fb;
}

#reservation-form #res-nightly-rate,
#reservation-form input[name='gross_amount'],
#reservation-form #res-commission-pct,
#reservation-form #res-commission-amount {
  background-color: var(--res-tint-ota);
  border-color: var(--res-tint-ota-border);
}

#reservation-form #res-nightly-rate:focus,
#reservation-form input[name='gross_amount']:focus,
#reservation-form #res-commission-pct:focus,
#reservation-form #res-commission-amount:focus {
  border-color: rgba(160, 130, 50, 0.5);
  box-shadow: 0 0 0 4px var(--res-tint-ota-ring);
  background-color: #fbf8ef;
}

#reservation-form #res-cleaning-amount,
#reservation-form #res-admin-pct,
#reservation-form #res-admin-amount {
  background-color: var(--res-tint-ops);
  border-color: var(--res-tint-ops-border);
}

#reservation-form #res-cleaning-amount:focus,
#reservation-form #res-admin-pct:focus,
#reservation-form #res-admin-amount:focus {
  border-color: rgba(176, 100, 70, 0.5);
  box-shadow: 0 0 0 4px var(--res-tint-ops-ring);
  background-color: #fcf5f1;
}

#reservation-form #res-net-amount {
  background-color: var(--res-tint-net);
  border-color: var(--res-tint-net-border);
}

#reservation-form #res-net-amount:focus {
  border-color: rgba(196, 92, 38, 0.55);
  box-shadow: 0 0 0 4px var(--res-tint-net-ring);
  background-color: #faf1ea;
}

#reservation-form #res-collaborator {
  background-color: var(--res-tint-aseo);
  border-color: var(--res-tint-aseo-border);
}

#reservation-form #res-collaborator:focus {
  border-color: rgba(45, 120, 100, 0.5);
  box-shadow: 0 0 0 4px var(--res-tint-aseo-ring);
  background-color: #f4faf7;
}

#reservation-form #res-deposit-amount {
  background-color: var(--res-tint-bank);
  border-color: var(--res-tint-bank-border);
}

#reservation-form #res-deposit-amount:focus {
  border-color: rgba(45, 106, 79, 0.5);
  box-shadow: 0 0 0 4px var(--res-tint-bank-ring);
  background-color: #f4f9f6;
}

#reservation-form #res-bank-account {
  background-color: var(--res-tint-bank);
  border-color: var(--res-tint-bank-border);
}

#reservation-form #res-bank-account:focus {
  border-color: rgba(45, 106, 79, 0.5);
  box-shadow: 0 0 0 4px var(--res-tint-bank-ring);
  background-color: #f4f9f6;
}

#reservation-form input[name='notes'] {
  background-color: var(--res-tint-notes);
  border-color: var(--res-tint-notes-border);
}

#reservation-form input[name='notes']:focus {
  border-color: rgba(12, 36, 31, 0.4);
  box-shadow: 0 0 0 4px var(--res-tint-notes-ring);
  background-color: #faf8f4;
}

#reservation-form input[name='guest_name']:-webkit-autofill,
#reservation-form #res-guest-document:-webkit-autofill,
#reservation-form #res-guest-phone:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px var(--res-tint-guest) inset;
  box-shadow: 0 0 0 1000px var(--res-tint-guest) inset;
  -webkit-text-fill-color: var(--ink);
}

.res-section-bank {
  border-color: rgba(45, 106, 79, 0.24);
  background:
    linear-gradient(180deg, rgba(45, 106, 79, 0.055), rgba(255, 255, 255, 0.96)),
    #fff;
}

label.res-bank-toggle {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 0.8rem;
  border: 1.5px solid rgba(12, 36, 31, 0.13);
  border-radius: 0.82rem;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

label.res-bank-toggle:has(input:checked) {
  border-color: rgba(45, 106, 79, 0.48);
  background: rgba(45, 106, 79, 0.065);
  box-shadow: 0 0 0 1px rgba(45, 106, 79, 0.08);
}

.res-bank-toggle input {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.res-bank-switch {
  position: relative;
  width: 2.35rem;
  height: 1.35rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.18);
  transition: background 0.2s ease;
}

.res-bank-switch::after {
  content: "";
  position: absolute;
  top: 0.2rem;
  left: 0.2rem;
  width: 0.95rem;
  height: 0.95rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(12, 36, 31, 0.2);
  transition: transform 0.2s var(--ease);
}

.res-bank-toggle input:checked + .res-bank-switch {
  background: #2d6a4f;
}

.res-bank-toggle input:checked + .res-bank-switch::after {
  transform: translateX(1rem);
}

.res-bank-toggle-copy {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.res-bank-toggle-copy strong {
  color: var(--brand);
  font-size: 0.88rem;
}

.res-bank-toggle-copy span {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 500;
  line-height: 1.35;
}

.res-section-split {
  border-color: rgba(154, 69, 24, 0.22);
  background:
    linear-gradient(180deg, rgba(250, 232, 210, 0.45), rgba(255, 255, 255, 0.96)),
    #fff;
}

.res-split-fields {
  display: grid;
  gap: 0.65rem;
  margin-top: 0.7rem;
  padding-top: 0.7rem;
  border-top: 1px dashed rgba(154, 69, 24, 0.22);
}

@media (min-width: 640px) {
  .res-split-fields {
    grid-template-columns: minmax(10rem, 0.7fr) minmax(0, 1.3fr);
    align-items: end;
  }
}

.res-split-preview {
  margin: 0;
  padding: 0.62rem 0.75rem;
  border-radius: 0.72rem;
  background: rgba(154, 69, 24, 0.08);
  color: #7a3514;
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.4;
}

.res-split-panel {
  display: grid;
  gap: 0.55rem;
  padding: 0.8rem 0.85rem;
  border-radius: 0.9rem;
  border: 1.5px solid rgba(154, 69, 24, 0.22);
  background: linear-gradient(180deg, #fff8f1 0%, #fff 100%);
}

.res-split-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.res-split-panel-head strong {
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #9a4518;
}

.res-split-lines {
  display: grid;
  gap: 0.28rem;
  margin: 0;
  font-size: 0.86rem;
  color: var(--brand);
}

.res-split-lines span {
  color: var(--muted);
}

.res-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.28rem;
  justify-content: flex-end;
}

.badge-due {
  background: rgba(154, 69, 24, 0.14);
  color: #9a3518;
}

.res-bank-details {
  display: grid;
  gap: 0.65rem;
  margin-top: 0.7rem;
  padding-top: 0.7rem;
  border-top: 1px dashed rgba(45, 106, 79, 0.22);
}

.res-bank-preview {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 0.55rem;
  padding: 0.62rem 0.7rem;
  border-radius: 0.72rem;
  background: rgba(45, 106, 79, 0.08);
  color: #1e4d3a;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.4;
}

.res-bank-preview-icon {
  width: 1.35rem;
  height: 1.35rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #2d6a4f;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
}

@media (min-width: 640px) {
  .res-bank-details {
    grid-template-columns: minmax(12rem, 0.9fr) minmax(0, 1.4fr);
    align-items: end;
  }
}

@media (min-width: 720px) {
  .form-grid-guest {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .form-grid-money,
  .form-grid-money-ota,
  .form-grid-money-ops {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .form-grid-money-net {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  }

  .form-grid .span-all {
    grid-column: 1 / -1;
  }
}

@media (min-width: 520px) {
  .form-grid-dates-stay,
  .form-grid-dates-cash {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 719px) {
  .form-grid-guest,
  .form-grid-money,
  .form-grid-money-ota,
  .form-grid-money-ops,
  .form-grid-money-net {
    grid-template-columns: 1fr;
  }
}

.res-money-block {
  display: grid;
  gap: 0.55rem;
  padding: 0.85rem 0 0;
  border-top: 1px solid rgba(12, 36, 31, 0.1);
}

.res-money-block:first-of-type {
  padding-top: 0.15rem;
  border-top: 0;
}

.res-money-block-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand);
}

.res-money-block-desc {
  margin: -0.15rem 0 0.15rem;
  font-size: 0.8rem;
  line-height: 1.4;
  color: #6a5a4a;
}

.res-nightly-calc {
  display: grid;
  gap: 0.65rem;
  margin: 0 0 0.75rem;
  padding: 0.75rem 0.85rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: rgba(12, 36, 31, 0.035);
}

@media (min-width: 520px) {
  .res-nightly-calc {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    align-items: end;
  }
}

.res-nightly-result {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
  padding: 0.35rem 0 0.15rem;
}

.res-nightly-result-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted, #5c6670);
}

.res-nightly-result strong {
  font-size: 1.15rem;
  font-weight: 750;
  color: var(--brand);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.res-money-block-ops {
  padding: 0.85rem 0.85rem 0.95rem;
  margin-top: 0.55rem;
  border: 1px solid rgba(45, 106, 79, 0.2);
  border-radius: 0.85rem;
  background: rgba(45, 106, 79, 0.045);
}

.res-money-block-ops .res-money-block-title {
  color: #226442;
}

.res-money-block-net {
  padding: 0.85rem 0.85rem 0.95rem;
  margin-top: 0.55rem;
  border: 1.5px solid rgba(196, 92, 38, 0.28);
  border-radius: 0.85rem;
  background: linear-gradient(180deg, rgba(196, 92, 38, 0.08), rgba(255, 252, 247, 0.95));
}

.res-money-block-net .res-money-block-title {
  color: #8a4a22;
}

.res-money-block-net #res-net-amount {
  font-weight: 700;
  font-size: 1.05rem;
}

@media (max-width: 519px) {
  .form-grid-dates-stay,
  .form-grid-dates-cash {
    grid-template-columns: 1fr;
  }
}

.res-dates-block {
  display: grid;
  gap: 0.7rem;
  padding: 0.85rem 0 0;
  border-top: 1px solid rgba(12, 36, 31, 0.1);
}

.res-dates-block:first-of-type {
  padding-top: 0;
  border-top: 0;
}

.res-dates-block-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand);
}

.res-dates-block-desc {
  margin: -0.25rem 0 0;
  font-size: 0.8rem;
  line-height: 1.4;
  color: #6a5a4a;
}

.res-stay-pill {
  display: flex;
  align-items: center;
  gap: 0.55rem 0.75rem;
  flex-wrap: wrap;
  padding: 0.6rem 0.8rem;
  border-radius: 0.75rem;
  background: rgba(12, 36, 31, 0.04);
  border: 1px dashed rgba(12, 36, 31, 0.14);
}

.res-stay-pill-label {
  font-size: 0.78rem;
  font-weight: 650;
  color: var(--brand);
}

.res-stay-pill strong {
  font-family: var(--font-display);
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
  color: var(--brand);
}

.res-stay-pill-hint {
  font-size: 0.76rem;
  color: #7a6a5a;
}

.res-section-head {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.res-section-head-copy {
  flex: 1 1 auto;
  min-width: 0;
}

.res-section-head h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: -0.01em;
  color: var(--brand);
}

.res-section-head .hint {
  margin: 0.2rem 0 0;
}

.res-guest-search-toggle {
  flex: none;
  align-self: center;
  margin-left: auto;
  white-space: nowrap;
}

.res-guest-search-toggle.is-active {
  border-color: rgba(74, 122, 168, 0.45);
  color: #2f5f8a;
  background: var(--res-tint-guest);
}

.modal-sheet-guest-search {
  width: min(100%, 26rem);
  max-height: min(82vh, 32rem);
  border-color: rgba(74, 122, 168, 0.42);
  box-shadow:
    0 0 0 1px rgba(12, 36, 31, 0.28),
    0 24px 64px rgba(8, 16, 15, 0.45);
}

.guest-search-editor {
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-height: min(82vh, 32rem);
}

.modal-sheet-guest-search .editor-head.guest-search-head {
  flex: none;
  padding: 1.15rem 1.2rem 0.95rem;
  border-bottom: 1px solid rgba(12, 36, 31, 0.08);
  background: linear-gradient(180deg, #f7fafd 0%, #fff 100%);
}

.guest-search-head .eyebrow {
  color: #4a7aa8;
}

.guest-search-head h2 {
  margin: 0.15rem 0 0;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.guest-search-lead {
  margin: 0.35rem 0 0;
  font-size: 0.84rem;
  line-height: 1.45;
  max-width: 22rem;
}

.guest-search-body {
  display: grid;
  gap: 0.75rem;
  padding: 1rem 1.2rem 1.2rem;
  min-height: 0;
  overflow: hidden;
}

.guest-search-field {
  display: block;
  margin: 0;
}

.guest-search-field .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

#modal-guest-search #res-guest-search-input {
  width: 100%;
  margin: 0;
  padding: 0.78rem 0.9rem;
  border-radius: 0.85rem;
  border: 1.5px solid rgba(74, 122, 168, 0.28);
  background: var(--res-tint-guest);
  font-size: 0.95rem;
}

#modal-guest-search #res-guest-search-input:focus {
  outline: none;
  border-color: rgba(74, 122, 168, 0.55);
  box-shadow: 0 0 0 4px var(--res-tint-guest-ring);
  background-color: #f5f9fd;
}

.res-guest-search-results {
  display: grid;
  gap: 0.4rem;
  max-height: min(42vh, 16rem);
  overflow: auto;
  padding-right: 0.15rem;
}

.res-guest-search-empty {
  margin: 0;
  font-size: 0.82rem;
}

.res-guest-pick {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.7rem;
  width: 100%;
  padding: 0.65rem 0.75rem;
  border-radius: 0.8rem;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  background: #fff;
  text-align: left;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.15s ease;
}

.res-guest-pick:hover,
.res-guest-pick:focus-visible {
  border-color: rgba(196, 92, 38, 0.45);
  box-shadow: 0 6px 18px rgba(12, 36, 31, 0.07);
  transform: translateY(-1px);
  outline: none;
}

.res-guest-pick-avatar {
  display: grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(145deg, #d46a32, #b84f1f);
  flex-shrink: 0;
}

.res-guest-pick-copy {
  min-width: 0;
  display: grid;
  gap: 0.12rem;
}

.res-guest-pick-name {
  font-weight: 700;
  color: var(--brand);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.res-guest-pick-meta {
  font-size: 0.76rem;
  color: var(--muted, #5c6670);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.res-guest-pick-stays {
  flex: none;
  font-size: 0.72rem;
  font-weight: 700;
  color: #7a5a3a;
  background: rgba(196, 92, 38, 0.1);
  border-radius: 999px;
  padding: 0.2rem 0.5rem;
  white-space: nowrap;
}

.res-step {
  flex: none;
  display: grid;
  place-items: center;
  width: 1.65rem;
  height: 1.65rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff8f1;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1;
  margin-top: 0.05rem;
}

.res-date-callout {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 0.85rem;
  padding: 0.65rem 0.75rem;
  border-radius: 0.75rem;
  background: rgba(196, 92, 38, 0.08);
  border: 1px solid rgba(196, 92, 38, 0.16);
  font-size: 0.82rem;
  line-height: 1.4;
  color: #4a3a2a;
}

.res-date-callout-inline {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  padding: 0.55rem 0.7rem;
  font-size: 0.78rem;
}

@media (max-width: 719px) {
  .res-date-callout-inline {
    grid-template-columns: 1fr;
  }
}

.res-date-callout strong {
  color: var(--brand);
}

.res-readonly {
  display: grid;
  gap: 0.15rem;
  padding: 0.65rem 0.75rem;
  border-radius: 0.75rem;
  background: rgba(12, 36, 31, 0.04);
  border: 1px dashed rgba(12, 36, 31, 0.14);
}

.res-readonly-label {
  font-size: 0.78rem;
  font-weight: 650;
  color: var(--brand);
}

.res-readonly strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-variant-numeric: tabular-nums;
}

.form-grid-money {
  gap: 0.75rem;
}

.res-modal-body > .error {
  flex: none;
  margin: 0;
  padding: 0 var(--pad) 0.65rem;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: end;
}

.toolbar .inline-label {
  flex: 1 1 11.5rem;
  min-width: 0;
  max-width: 18rem;
}

.toolbar > .btn-ghost,
.toolbar > .btn-primary {
  flex: none;
}

.month-toolbar {
  align-items: end;
}

.res-due-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  flex: none;
  min-height: var(--control-h);
  padding: 0 0.85rem 0 0.7rem;
  border: 1.5px solid rgba(154, 69, 24, 0.32);
  border-radius: 999px;
  background: #fff;
  color: #9a3518;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 1px 0 rgba(12, 36, 31, 0.04);
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.15s ease;
}

.res-due-chip:hover {
  background: rgba(154, 69, 24, 0.07);
  border-color: rgba(154, 69, 24, 0.48);
}

.res-due-chip:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(154, 69, 24, 0.22);
}

.res-due-chip-mark {
  position: relative;
  flex: none;
  width: 1rem;
  height: 1rem;
  border-radius: 999px;
  border: 1.6px solid currentColor;
  opacity: 0.55;
  transition: background 0.18s ease, opacity 0.18s ease, border-color 0.18s ease;
}

.res-due-chip-mark::after {
  content: '';
  position: absolute;
  left: 0.22rem;
  top: 0.08rem;
  width: 0.28rem;
  height: 0.5rem;
  border: solid transparent;
  border-width: 0 1.7px 1.7px 0;
  transform: rotate(45deg) scale(0.6);
  opacity: 0;
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.res-due-chip-label {
  line-height: 1.1;
}

.res-due-chip.is-active {
  background: #9a3518;
  border-color: #7e2c14;
  color: #fff8f1;
  box-shadow:
    0 0 0 3px rgba(154, 69, 24, 0.2),
    0 6px 16px rgba(154, 69, 24, 0.22);
}

.res-due-chip.is-active:hover {
  background: #872f15;
  border-color: #6f2612;
}

.res-due-chip.is-active .res-due-chip-mark {
  opacity: 1;
  background: #fff;
  border-color: #fff;
}

.res-due-chip.is-active .res-due-chip-mark::after {
  border-color: #9a3518;
  opacity: 1;
  transform: rotate(45deg) scale(1);
}

.res-due-count {
  display: inline-grid;
  place-items: center;
  min-width: 1.35rem;
  height: 1.35rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: #9a3518;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1;
}

.res-due-chip.is-active .res-due-count {
  background: #fff;
  color: #9a3518;
}

.month-filter.is-dimmed {
  opacity: 0.45;
  pointer-events: none;
}

.modal-sheet-res-due {
  width: min(100%, 40rem);
  max-height: min(90vh, 52rem);
  border-color: rgba(154, 69, 24, 0.42);
}

.modal-sheet-res-due .editor-head.res-due-head {
  border-bottom: 1px solid rgba(154, 69, 24, 0.12);
  background: linear-gradient(180deg, #fff8f3 0%, #fff 100%);
}

.res-due-head .eyebrow {
  color: #9a3518;
}

.res-due-lead {
  margin: 0.35rem 0 0;
  max-width: 32rem;
  font-size: 0.86rem;
  line-height: 1.45;
}

.res-due-body {
  display: grid;
  gap: 0.85rem;
  min-height: 0;
}

.res-due-totals {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.res-due-totals .stat-chip {
  flex: 1 1 8rem;
}

#res-due-list.res-cards-list {
  gap: 0.55rem;
}

.month-filter {
  display: grid;
  gap: 0.38rem;
  flex: 1 1 17rem;
  min-width: 0;
}

.month-filter-caption {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
}

.month-filter-bar {
  display: grid;
  grid-template-columns: 2.7rem minmax(0, 1fr) 2.7rem 2.7rem;
  align-items: stretch;
  height: var(--control-h);
  min-height: var(--control-h);
  overflow: hidden;
  border: 1.5px solid rgba(12, 36, 31, 0.16);
  border-radius: 0.9rem;
  background: #fff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.85), 0 8px 18px rgba(12, 36, 31, 0.07);
}

.month-filter-nav,
.month-filter-refresh {
  display: grid;
  place-items: center;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--brand);
  cursor: pointer;
}

.month-filter-nav {
  border-right: 1px solid rgba(12, 36, 31, 0.1);
}

.month-filter-refresh {
  border-left: 1px solid rgba(12, 36, 31, 0.1);
  background: linear-gradient(160deg, #fff8f1, #ffe8d4);
  color: #8a3e16;
}

.month-filter-nav svg,
.month-filter-refresh svg {
  width: 1.15rem;
  height: 1.15rem;
}

.month-filter-nav:active,
.month-filter-refresh:active {
  background: rgba(12, 36, 31, 0.06);
}

.month-filter-refresh:active {
  background: #f3dcc4;
}

.month-filter-refresh.is-busy svg,
.panel-refresh.is-busy svg {
  animation: panel-refresh-spin 0.7s linear infinite;
}

@keyframes panel-refresh-spin {
  to {
    transform: rotate(360deg);
  }
}

.panel-refresh {
  width: 2.7rem;
  height: 2.7rem;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  margin: 0;
  padding: 0;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  border-radius: 999px;
  background:
    linear-gradient(180deg, #ffffff 0%, #f7faf8 100%);
  color: var(--brand);
  cursor: pointer;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 6px 16px rgba(12, 36, 31, 0.08);
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease, color 0.15s ease;
}

.panel-refresh svg {
  width: 1.2rem;
  height: 1.2rem;
}

.panel-refresh:hover {
  border-color: rgba(196, 92, 38, 0.42);
  background: linear-gradient(180deg, #fffdf9 0%, #fff3e8 100%);
  color: #8a3e16;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 8px 18px rgba(12, 36, 31, 0.12);
}

.panel-refresh:active {
  transform: scale(0.96);
}

.panel-refresh:disabled {
  opacity: 0.65;
  cursor: wait;
}

.month-filter-face {
  position: relative;
  display: grid;
  place-items: center;
  margin: 0;
  gap: 0;
  min-width: 0;
  font-weight: 650;
  color: var(--brand);
}

.month-filter-text {
  max-width: 100%;
  padding: 0 0.35rem;
  font-size: 0.92rem;
  font-weight: 650;
  letter-spacing: -0.01em;
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}

.month-filter-face input[type="month"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  margin: 0;
  padding: 0;
  opacity: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  cursor: pointer;
  font-size: 16px;
  -webkit-appearance: none;
  appearance: none;
}

.month-toolbar-extra {
  flex: 1 1 14rem;
  max-width: 18rem;
}

.list-section {
  margin-top: 0;
}

.list-section + .list-section {
  margin-top: 1.5rem;
}

.pockets-total {
  margin: 0 0 0.75rem;
}

.section-lead {
  margin: -0.35rem 0 0.85rem;
  font-size: 0.9rem;
  line-height: 1.45;
}

.pocket-items-toolbar {
  margin-bottom: 0.85rem;
}

.pocket-items-search-label {
  flex: 1 1 220px;
  min-width: 0;
}

.pocket-items-more-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.85rem;
}

.pocket-items-count {
  margin: 0;
  font-size: 0.88rem;
}

.pocket-items-list .pocket-row-res {
  border-left: 3px solid var(--accent, #2d6a4f);
}

.pocket-items-list {
  gap: 0.55rem;
}

.pocket-items-list .pocket-movement-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.5rem 0.75rem;
  padding: 0.8rem 0.9rem;
  border-radius: 0.95rem;
  box-shadow: 0 4px 14px rgba(12, 36, 31, 0.05);
}

.pocket-card-top {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.pocket-card-identity {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}

.pocket-card-avatar {
  flex: 0 0 2.2rem;
  width: 2.2rem;
  height: 2.2rem;
  display: grid;
  place-items: center;
  border-radius: 0.68rem;
  background: linear-gradient(150deg, var(--brand-3), var(--brand));
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.pocket-card-avatar-in {
  background: linear-gradient(150deg, #2d6a4f, #1f4f43);
  font-size: 1rem;
}

.pocket-card-avatar-out {
  background: linear-gradient(150deg, #b0473d, #8d2721);
  font-size: 1rem;
}

.pocket-card-copy {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.pocket-card-title {
  color: var(--ink);
  font-size: 0.96rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.pocket-card-location {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.pocket-card-amount {
  flex: none;
  color: var(--brand);
  font-size: 1rem;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.pocket-card-amount.is-out {
  color: var(--danger);
}

.pocket-card-meta {
  grid-column: 1;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem 0.55rem;
  color: var(--muted);
  font-size: 0.76rem;
}

.pocket-card-tag {
  display: inline-flex;
  align-items: center;
  min-height: 1.4rem;
  padding: 0.16rem 0.48rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.07);
  color: var(--brand);
  font-size: 0.68rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.pocket-bank-line {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.65rem;
  border: 1px solid rgba(45, 106, 79, 0.14);
  border-radius: 0.7rem;
  background: rgba(45, 106, 79, 0.055);
}

.pocket-bank-icon {
  width: 1.65rem;
  height: 1.65rem;
  display: grid;
  place-items: center;
  border-radius: 0.5rem;
  background: #fff;
  color: #2d6a4f;
}

.pocket-bank-icon svg {
  width: 0.95rem;
  height: 0.95rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pocket-bank-copy {
  display: grid;
  gap: 0.08rem;
  min-width: 0;
}

.pocket-bank-copy strong {
  color: #1e4d3a;
  font-size: 0.78rem;
}

.pocket-bank-copy span {
  color: var(--muted);
  font-size: 0.72rem;
  overflow-wrap: anywhere;
}

.pocket-bank-amount {
  color: #1e4d3a;
  font-size: 0.78rem;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.pocket-row-note {
  margin: 0.35rem 0 0;
  padding: 0.45rem 0.6rem;
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--muted, #5c6670);
  background: var(--surface-2, #f4f6f8);
  border-radius: 8px;
}

.pocket-row-note-icon {
  margin-right: 0.25rem;
  opacity: 0.7;
}

.pocket-linked-movement {
  display: block;
}

.pocket-linked-movement .pocket-row-note {
  width: 100%;
}

.movement-row-actions {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.6rem;
}

.pocket-movement-card > .movement-row-actions {
  grid-column: 2;
  align-self: center;
  margin-top: 0;
}

.movement-action-btn {
  position: relative;
  flex: 0 0 2.45rem;
  width: 2.45rem;
  height: 2.45rem;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1.5px solid rgba(12, 36, 31, 0.18);
  border-radius: 0.72rem;
  background: #fff;
  color: var(--brand);
  cursor: pointer;
  box-shadow: 0 3px 10px rgba(12, 36, 31, 0.07);
  transition:
    transform 0.18s var(--ease),
    color 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}

.movement-action-btn svg {
  width: 1.12rem;
  height: 1.12rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.movement-action-btn:hover,
.movement-action-btn:focus-visible {
  transform: translateY(-2px);
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
  box-shadow: 0 8px 18px rgba(12, 36, 31, 0.2);
  outline: none;
}

.movement-action-btn::after {
  content: attr(data-tooltip);
  position: absolute;
  right: 0;
  bottom: calc(100% + 0.5rem);
  z-index: 10;
  width: max-content;
  max-width: 12rem;
  padding: 0.38rem 0.58rem;
  border-radius: 0.5rem;
  background: var(--brand);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
  box-shadow: 0 6px 16px rgba(12, 36, 31, 0.2);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(0.25rem);
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
}

.movement-action-btn:hover::after,
.movement-action-btn:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.movement-assignment-btn {
  color: #8a3e16;
  border-color: rgba(196, 92, 38, 0.38);
  background: #fff8f1;
}

.movement-assignment-btn:hover,
.movement-assignment-btn:focus-visible {
  color: #fff;
  border-color: var(--accent);
  background: var(--accent);
}

.movement-delete-btn {
  color: var(--danger);
  border-color: rgba(159, 31, 31, 0.35);
  background: rgba(159, 31, 31, 0.05);
}

.movement-delete-btn:hover {
  color: #fff;
  border-color: var(--danger);
  background: var(--danger);
}

@media (max-width: 520px) {
  .pocket-items-list .pocket-movement-card {
    grid-template-columns: 1fr;
    padding: 0.75rem;
  }

  .pocket-card-top {
    align-items: flex-start;
  }

  .pocket-card-amount {
    font-size: 0.9rem;
  }

  .pocket-card-meta,
  .pocket-movement-card > .movement-row-actions,
  .pocket-bank-line {
    grid-column: 1;
  }

  .movement-row-actions {
    width: 100%;
  }

  .pocket-movement-card > .movement-row-actions {
    justify-content: flex-end;
  }

  .movement-action-btn {
    flex: 0 0 2.45rem;
    width: 2.45rem;
  }

  .pocket-bank-line {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .pocket-bank-amount {
    grid-column: 2;
  }
}

.row-money.is-out {
  color: var(--danger, #b42318);
}

.pocket-months-list .pocket-month-row {
  cursor: pointer;
  border-radius: var(--radius, 12px);
  transition: background 0.15s ease;
}

.pocket-months-list .pocket-month-row:hover,
.pocket-months-list .pocket-month-row:focus-visible {
  background: var(--surface-2, #f4f6f8);
  outline: none;
}

.pocket-months-list .pocket-month-row.is-active {
  background: color-mix(in srgb, var(--accent, #2d6a4f) 8%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent, #2d6a4f) 25%, transparent);
}

.text-warn {
  color: var(--danger, #b42318);
  font-weight: 600;
}

/* Stats */
.stat-row,
.kpi-grid {
  display: grid;
  gap: var(--gap);
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.kpi-band {
  gap: 0.85rem;
  align-items: stretch;
}

.kpi-band > * {
  grid-column: auto !important;
}

.group-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem 0.75rem;
  margin: 0 0 0.75rem;
}

.group-head h2 {
  margin: 0;
  flex: 1 1 10rem;
  min-width: 0;
  font-family: var(--font-display);
  font-size: 1.22rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.group-head .muted {
  flex: none;
  text-align: right;
}

.exp-group + .exp-group {
  margin-top: 1.4rem;
}

.btn-tiny {
  border: 0;
  background: transparent;
  color: var(--danger);
  font-size: 0.8rem;
  font-weight: 650;
  padding: 0;
  cursor: pointer;
}

.header-buttons {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.report-kpis,
.pocket-kpis {
  margin-top: 0;
}

.alert-banner {
  margin: 0;
  padding: 0.9rem 1rem;
  border-radius: 0.95rem;
  font-weight: 600;
  animation: rise 0.4s var(--ease) both;
}

.alert-banner.danger {
  background: rgba(161, 29, 29, 0.1);
  color: var(--danger);
  border: 1px solid rgba(161, 29, 29, 0.18);
}

.alert-banner.ok {
  background: rgba(28, 106, 72, 0.1);
  color: var(--ok);
  border: 1px solid rgba(28, 106, 72, 0.16);
}

@media (min-width: 840px) {
  .kpi-band {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .kpi-grid:not(.report-kpis),
  .exp-stats,
  .pocket-kpis {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.stat-chip,
.kpi-card {
  position: relative;
  z-index: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.32rem;
  min-height: 6.7rem;
  height: 100%;
  padding: 1.05rem 0.9rem 1.1rem;
  border: 0;
  border-radius: 0.95rem;
  background: transparent;
  min-width: 0;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(12, 36, 31, 0.1);
}

.stat-chip::before,
.kpi-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 2.5px;
  background: linear-gradient(135deg, var(--brand) 0%, var(--accent) 42%, var(--gold) 100%);
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask-composite: exclude;
  pointer-events: none;
  z-index: 0;
}

.stat-chip::after,
.kpi-card::after {
  content: "";
  position: absolute;
  inset: 2.5px;
  border-radius: calc(0.95rem - 2.5px);
  background: linear-gradient(180deg, #ffffff 0%, #fff8f1 100%);
  z-index: 1;
}

.stat-chip span,
.kpi-card span,
.stat-chip strong,
.kpi-card strong {
  position: relative;
  z-index: 2;
}

.stat-chip span,
.kpi-card span {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.3;
  white-space: nowrap;
}

.stat-chip strong,
.kpi-card strong {
  display: block;
  color: var(--ink);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  font-size: clamp(0.98rem, 1.45vw, 1.22rem);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kpi-card strong {
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 1.7vw, 1.36rem);
  letter-spacing: -0.03em;
}

.kpi-card.occ-kpi {
  justify-content: flex-start;
  min-height: 7.35rem;
  padding-bottom: 0.85rem;
}

.kpi-card.occ-kpi small {
  position: relative;
  z-index: 2;
  margin-top: 0.08rem;
  font-size: 0.68rem;
  font-weight: 550;
  line-height: 1.3;
  color: var(--muted);
  letter-spacing: 0;
  text-transform: none;
  white-space: normal;
}

.occ-glossary {
  margin-top: 0.85rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  border-radius: 0.85rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 248, 241, 0.78));
  overflow: hidden;
}

.occ-glossary summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.72rem 0.9rem;
  cursor: pointer;
  list-style: none;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--brand);
  user-select: none;
}

.occ-glossary summary::-webkit-details-marker {
  display: none;
}

.occ-glossary summary::marker {
  content: "";
}

.occ-glossary-chevron {
  width: 0.48rem;
  height: 0.48rem;
  flex: none;
  border-right: 2px solid rgba(12, 36, 31, 0.4);
  border-bottom: 2px solid rgba(12, 36, 31, 0.4);
  transform: rotate(45deg);
  transition: transform 0.28s var(--ease);
}

.occ-glossary[open] .occ-glossary-chevron {
  transform: rotate(-135deg) translateY(-2px);
}

.occ-glossary-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border-top: 1px solid rgba(12, 36, 31, 0.08);
}

.occ-glossary-item {
  padding: 0.75rem 0.9rem 0.9rem;
  min-width: 0;
}

.occ-glossary-item + .occ-glossary-item {
  border-left: 1px solid rgba(12, 36, 31, 0.08);
}

.occ-glossary-item strong {
  display: block;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand);
}

.occ-glossary-item p {
  margin: 0.28rem 0 0;
  font-size: 0.8rem;
  line-height: 1.4;
  color: var(--muted);
}

@media (max-width: 720px) {
  .occ-glossary-grid {
    grid-template-columns: 1fr;
  }

  .occ-glossary-item + .occ-glossary-item {
    border-left: 0;
    border-top: 1px solid rgba(12, 36, 31, 0.08);
  }
}

/* Lists */
.data-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.7rem;
}

.data-list > li {
  padding: 1rem var(--pad);
  border-radius: var(--radius);
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  background: #fff;
  display: grid;
  gap: 0.32rem;
  min-width: 0;
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease), border-color 0.22s var(--ease);
  animation: rise 0.4s var(--ease) both;
}

.catalog-block .data-list > li,
.summary-card .data-list > li {
  background: #f6efe3;
}

.data-list > li:nth-child(1) { animation-delay: 0.03s; }
.data-list > li:nth-child(2) { animation-delay: 0.06s; }
.data-list > li:nth-child(3) { animation-delay: 0.09s; }
.data-list > li:nth-child(4) { animation-delay: 0.12s; }
.data-list > li:nth-child(5) { animation-delay: 0.15s; }
.data-list > li:nth-child(6) { animation-delay: 0.18s; }

.data-list > li:hover {
  transform: translateY(-2px);
  border-color: rgba(12, 36, 31, 0.16);
  box-shadow: var(--shadow);
}

.data-list.compact > li {
  padding: 0.8rem 0.9rem;
}

#banks-list {
  gap: 0.45rem;
}

#banks-list > li.bank-account-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
  padding: 0.55rem 0.7rem 0.55rem 0.8rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: linear-gradient(180deg, #fff 0%, #f8faf9 100%);
  box-shadow: none;
}

#banks-list > li.bank-account-row:hover {
  transform: none;
  border-color: rgba(12, 36, 31, 0.16);
  box-shadow: 0 4px 14px rgba(12, 36, 31, 0.06);
}

.bank-account-main {
  min-width: 0;
  flex: 1;
  display: grid;
  gap: 0.12rem;
}

.bank-account-line {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.35rem 0.55rem;
  min-width: 0;
}

.bank-account-name {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--brand);
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

.bank-account-bank {
  flex: none;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.02em;
  color: #2f6b58;
  background: rgba(47, 107, 88, 0.1);
  border: 1px solid rgba(47, 107, 88, 0.18);
  border-radius: 999px;
  padding: 0.12rem 0.48rem;
  line-height: 1.2;
}

.bank-account-meta {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.3;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bank-account-delete {
  flex: none;
  align-self: center;
  width: 1.85rem;
  height: 1.85rem;
  display: grid;
  place-items: center;
  padding: 0;
  border-radius: 999px;
  border: 1.5px solid rgba(159, 31, 31, 0.28);
  background: rgba(159, 31, 31, 0.05);
  color: var(--danger, #9f1f1f);
  cursor: pointer;
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease,
    transform 0.15s ease;
}

.bank-account-delete svg {
  width: 0.88rem;
  height: 0.88rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
}

.bank-account-delete:hover,
.bank-account-delete:focus-visible {
  color: #fff;
  border-color: var(--danger, #9f1f1f);
  background: var(--danger, #9f1f1f);
  transform: scale(1.05);
  outline: none;
}

.empty-state {
  padding: 1.7rem 1.1rem !important;
  text-align: center;
  color: var(--muted);
  border-style: dashed !important;
  border-color: rgba(12, 36, 31, 0.22) !important;
  background: rgba(255, 255, 255, 0.55) !important;
  box-shadow: none !important;
  transform: none !important;
}

.empty-state strong {
  display: block;
  margin-bottom: 0.25rem;
  color: var(--ink);
}

.res-list-loading {
  display: grid;
  justify-items: center;
  gap: 0.55rem;
}

.res-list-loading::before {
  content: "";
  width: 1.35rem;
  height: 1.35rem;
  border: 2px solid rgba(12, 36, 31, 0.14);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: res-spin 0.7s linear infinite;
}

@keyframes res-spin {
  to {
    transform: rotate(360deg);
  }
}

.row-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem 1rem;
}

.row-title {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  font-weight: 650;
  font-size: 1.02rem;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.row-meta {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.row-money {
  flex: none;
  margin: 0;
  font-weight: 700;
  color: var(--brand);
  white-space: nowrap;
  text-align: right;
  font-variant-numeric: tabular-nums;
  line-height: 1.3;
}

/* â€”â€” Listado reservas (tarjetas) â€”â€” */
.res-cards-list {
  gap: 0.65rem;
}

.res-cards-list > li {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  animation: none;
}

.res-cards-list > li:hover {
  transform: none;
  box-shadow: none;
  border-color: transparent;
}

.res-cards-list > li.empty-state {
  padding: 1.7rem 1.1rem !important;
  border: 1.5px dashed rgba(12, 36, 31, 0.22) !important;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.55) !important;
}

.res-card-wrap {
  display: grid;
  gap: 0;
  min-width: 0;
}

.res-card {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.95rem 1.05rem;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #fff 0%, #faf7f2 100%);
  box-shadow: 0 2px 8px rgba(12, 36, 31, 0.04);
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  transition:
    border-color 0.22s var(--ease),
    box-shadow 0.22s var(--ease),
    transform 0.22s var(--ease),
    background 0.22s var(--ease);
}

.res-card:hover {
  border-color: rgba(196, 92, 38, 0.35);
  box-shadow: 0 8px 22px rgba(12, 36, 31, 0.08);
  transform: translateY(-1px);
}

.res-card:focus-visible {
  outline: 2px solid rgba(196, 92, 38, 0.55);
  outline-offset: 2px;
}

.res-card-body {
  display: grid;
  gap: 0.3rem;
  min-width: 0;
}

.res-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.res-card-guest {
  font-weight: 650;
  font-size: 1.02rem;
  line-height: 1.3;
  color: var(--brand);
  overflow-wrap: anywhere;
}

.res-card-meta {
  font-size: 0.86rem;
  line-height: 1.4;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.res-card-foot {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 0.15rem;
}

.res-card-dates {
  font-size: 0.84rem;
  color: #5a4a3a;
}

.res-card-net {
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
  white-space: nowrap;
}

.res-card-chevron {
  flex: none;
  width: 1.65rem;
  height: 1.65rem;
  border-radius: 999px;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  background: rgba(255, 255, 255, 0.85);
  position: relative;
  transition: transform 0.22s var(--ease), border-color 0.22s var(--ease), background 0.22s var(--ease);
}

.res-card-chevron::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0.45rem;
  height: 0.45rem;
  border-right: 2px solid var(--brand);
  border-bottom: 2px solid var(--brand);
  transform: translate(-70%, -50%) rotate(-45deg);
  transition: transform 0.22s var(--ease);
}

.res-card:hover .res-card-chevron {
  border-color: rgba(196, 92, 38, 0.35);
  background: rgba(196, 92, 38, 0.1);
}

.res-card-detail {
  padding: 0.95rem 1.05rem 1.05rem;
  border: 1.5px solid rgba(196, 92, 38, 0.5);
  border-top: 0;
  border-radius: 0 0 var(--radius) var(--radius);
  background: #fff;
  box-shadow: 0 10px 24px rgba(12, 36, 31, 0.06);
}

.res-detail-grid {
  margin: 0;
  display: grid;
  gap: 0.55rem 1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .res-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 960px) {
  .res-detail-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.res-detail-item {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
  padding: 0.45rem 0.55rem;
  border-radius: 0.65rem;
  background: rgba(12, 36, 31, 0.03);
  border: 1px solid rgba(12, 36, 31, 0.06);
}

.res-detail-item dt {
  margin: 0;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #8a6a4a;
}

.res-detail-item dd {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--brand);
  overflow-wrap: anywhere;
}

.res-detail-item-wide {
  grid-column: 1 / -1;
}

.res-card-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  padding-top: 0.85rem;
  margin-top: 0.15rem;
  border-top: 1px solid rgba(12, 36, 31, 0.1);
}

.modal-sheet-res-view {
  width: min(100%, 46rem);
  max-height: min(90vh, 52rem);
}

.modal-sheet-res-view .editor {
  max-height: min(90vh, 52rem);
}

.modal-sheet .form-actions.res-view-actions {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.55rem;
}

.res-action-btn {
  position: relative;
  flex: 0 0 2.6rem;
  width: 2.6rem;
  height: 2.6rem;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1.5px solid rgba(12, 36, 31, 0.16);
  border-radius: 0.75rem;
  background: #fff;
  color: var(--brand);
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(12, 36, 31, 0.07);
  transition:
    transform 0.18s var(--ease),
    color 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.res-action-btn.res-action-whatsapp {
  color: #128c7e;
  border-color: rgba(18, 140, 126, 0.35);
  background: #f1fbf8;
}

.res-action-btn.res-action-whatsapp:hover,
.res-action-btn.res-action-whatsapp:focus-visible {
  color: #075e54;
  border-color: rgba(7, 94, 84, 0.45);
  background: #e6f7f2;
}

.res-wa-link {
  color: #128c7e;
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid rgba(18, 140, 126, 0.35);
}

.res-wa-link:hover {
  color: #075e54;
  border-bottom-color: rgba(7, 94, 84, 0.55);
}

.res-wa-panel {
  display: grid;
  gap: 0.7rem;
  padding: 0.85rem 0.9rem;
  border-radius: 0.9rem;
  background: linear-gradient(180deg, #f3fbf8 0%, #eef8f4 100%);
  border: 1.5px solid rgba(18, 140, 126, 0.22);
}

.res-wa-panel-copy {
  display: grid;
  gap: 0.35rem;
}

.res-wa-panel-copy strong {
  font-size: 0.82rem;
  letter-spacing: 0.02em;
  color: #0c4f46;
}

.res-wa-inventory-summary {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.45;
  white-space: normal;
}

.res-wa-check {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  margin: 0;
  padding: 0.55rem 0.65rem;
  border-radius: 0.7rem;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(18, 140, 126, 0.18);
  font-size: 0.86rem;
  line-height: 1.35;
  cursor: pointer;
  color: #0c2420;
}

.res-wa-check input {
  margin-top: 0.15rem;
  flex: 0 0 auto;
  width: 1.05rem;
  height: 1.05rem;
  accent-color: #128c7e;
}

.res-wa-check span {
  flex: 1 1 auto;
  min-width: 0;
}

.res-guest-contact {
  display: grid;
  gap: 0.65rem;
  grid-template-columns: 1fr;
  align-items: start;
}

.res-guest-contact label {
  display: grid;
  gap: 0.35rem;
  min-width: 0;
}

@media (min-width: 520px) {
  .res-guest-contact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.res-action-btn svg {
  width: 1.15rem;
  height: 1.15rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.res-action-btn:hover,
.res-action-btn:focus-visible {
  transform: translateY(-2px);
  color: #fff;
  background: var(--brand);
  border-color: var(--brand);
  box-shadow: 0 8px 18px rgba(12, 36, 31, 0.2);
  outline: none;
}

.res-action-copy {
  color: #005a8a;
  border-color: rgba(0, 119, 182, 0.28);
  background: rgba(0, 119, 182, 0.055);
}

.res-action-copy:hover,
.res-action-copy:focus-visible {
  background: #0077b6;
  border-color: #0077b6;
}

.res-action-delete {
  color: var(--danger);
  border-color: rgba(159, 31, 31, 0.28);
  background: rgba(159, 31, 31, 0.05);
}

.res-action-delete:hover,
.res-action-delete:focus-visible {
  background: var(--danger);
  border-color: var(--danger);
}

.res-action-edit {
  color: #fff;
  border-color: var(--brand);
  background: linear-gradient(150deg, var(--brand-3), var(--brand));
}

.res-action-close {
  color: var(--muted);
}

.res-action-btn::after {
  content: attr(data-tooltip);
  position: absolute;
  right: 0;
  bottom: calc(100% + 0.5rem);
  z-index: 10;
  width: max-content;
  padding: 0.38rem 0.58rem;
  border-radius: 0.5rem;
  background: var(--brand);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
  box-shadow: 0 6px 16px rgba(12, 36, 31, 0.2);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(0.2rem);
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
}

.res-action-btn:hover::after,
.res-action-btn:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.res-view-head {
  align-items: flex-start;
}

.res-view-head-main {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
  flex: 1 1 auto;
}

.res-view-avatar {
  flex: none;
  width: 3.1rem;
  height: 3.1rem;
  display: grid;
  place-items: center;
  border-radius: 1rem;
  background: linear-gradient(160deg, var(--brand-3), var(--brand));
  color: #f6faf7;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(12, 36, 31, 0.18);
}

.res-view-head-copy {
  min-width: 0;
}

.res-view-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem 0.55rem;
}

.res-view-head-copy h2 {
  overflow-wrap: anywhere;
}

.res-view-lead {
  margin: 0.28rem 0 0;
  overflow-wrap: anywhere;
}

.res-view-status {
  flex: none;
  align-self: center;
}

.res-view-body {
  display: grid;
  gap: 0.9rem;
  padding-top: 0.95rem;
}

.res-view-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
}

.res-view-kpi {
  display: grid;
  gap: 0.18rem;
  min-width: 0;
  padding: 0.75rem 0.8rem;
  border-radius: 0.85rem;
  background: linear-gradient(180deg, #fff 0%, #faf7f2 100%);
  border: 1.5px solid rgba(12, 36, 31, 0.1);
  box-shadow: 0 4px 12px rgba(12, 36, 31, 0.05);
}

.res-view-kpi span {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.res-view-kpi strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 650;
  line-height: 1.25;
  color: var(--brand);
  overflow-wrap: anywhere;
}

.res-view-kpi-net strong {
  color: var(--accent);
}

.res-list-more-wrap {
  display: grid;
  gap: 0.45rem;
  justify-items: center;
  padding-top: 0.85rem;
  margin-top: 0.15rem;
  border-top: 1px dashed rgba(12, 36, 31, 0.14);
}

.res-list-count {
  margin: 0;
  font-size: 0.84rem;
  text-align: center;
}

.res-list-more-wrap .btn-ghost {
  min-width: 12rem;
}

@keyframes res-detail-in {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.58rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.badge-ok {
  background: rgba(28, 106, 72, 0.12);
  color: var(--ok);
}

.badge-warn {
  background: var(--accent-soft);
  color: #9a4518;
}

.badge-muted {
  background: rgba(16, 36, 31, 0.08);
  color: var(--muted);
}

.rank-index {
  display: inline-grid;
  place-items: center;
  width: 1.7rem;
  height: 1.7rem;
  flex: none;
  border-radius: 50%;
  background: linear-gradient(160deg, var(--brand-3), var(--brand));
  color: #f6faf7;
  font-size: 0.76rem;
  font-weight: 700;
}

.progress {
  height: 0.46rem;
  border-radius: 999px;
  background: rgba(16, 36, 31, 0.08);
  overflow: hidden;
  margin-top: 0.42rem;
}

.progress > i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--brand), var(--accent-2));
  border-radius: inherit;
  transform-origin: left;
  animation: bar-fill 0.8s var(--ease) both;
}

.occ-rank-card .occ-rank-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.35rem;
  margin-top: 0.65rem;
}

.occ-rank-metrics > div {
  min-width: 0;
  padding: 0.4rem 0.35rem;
  border-radius: 8px;
  background: var(--surface-2, #f4f6f8);
  text-align: center;
}

.occ-rank-metrics span {
  display: block;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted, #5c6670);
}

.occ-rank-metrics strong {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--ink, #10241f);
  line-height: 1.2;
  word-break: break-word;
}

@media (max-width: 720px) {
  .occ-rank-card .occ-rank-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.catalog-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: minmax(0, 1fr);
}

.catalog-block {
  min-width: 0;
  padding: var(--pad);
}

#panel-catalogo .catalog-block {
  margin-bottom: 0;
}

.catalog-block h2 {
  margin: 0 0 0.8rem;
  font-family: var(--font-display);
  font-size: 1.22rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.catalog-block .group-head h2 {
  margin: 0;
}

@media (min-width: 760px) {
  .catalog-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.report-bottom-grid {
  margin-top: 2.75rem;
}

.report-month-label {
  margin: 0 0 0.75rem;
  font-size: 0.9rem;
}

.report-kpi-board {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 0.85rem 1rem;
  background: var(--surface, #fff);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: var(--radius, 12px);
}

.report-kpi-group-label {
  margin: 0 0 0.4rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted, #5c6670);
}

.report-kpi-hint {
  margin: 0.45rem 0 0;
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--muted, #5c6670);
}

.report-kpi-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.45rem;
}

.report-kpi-divider {
  height: 1px;
  background: var(--border, #e2e8f0);
  margin: 0.1rem 0;
}

.report-kpi {
  min-width: 0;
  padding: 0.5rem 0.55rem;
  background: var(--surface-2, #f4f6f8);
  border-radius: 8px;
  border: 1px solid transparent;
}

.report-kpi-label {
  display: block;
  margin-bottom: 0.2rem;
  font-size: 0.7rem;
  font-weight: 500;
  line-height: 1.2;
  color: var(--muted, #5c6670);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.report-kpi-value {
  display: block;
  font-size: clamp(0.78rem, 1.6vw, 0.92rem);
  font-weight: 700;
  line-height: 1.25;
  color: var(--text, #1a1a1a);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.report-kpi-value-income {
  color: #2d6a4f;
}

.report-kpi-value-expense {
  color: #b42318;
}

.report-kpi-value-profit {
  color: #0077b6;
}

.report-kpi-value-accent {
  color: #2d6a4f;
}

@media (max-width: 720px) {
  .report-kpi-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 721px) and (max-width: 1024px) {
  .report-kpi-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.report-charts-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 900px) {
  .report-charts-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1200px) {
  .report-charts-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.report-chart-card {
  padding: 1rem 1.1rem;
  background: var(--surface, #fff);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: var(--radius, 12px);
}

.report-chart-title {
  margin: 0 0 0.85rem;
  font-size: 0.95rem;
  font-weight: 600;
}

.bar-chart {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.bar-chart-row {
  display: grid;
  grid-template-columns: minmax(5.5rem, 32%) 1fr auto;
  gap: 0.5rem;
  align-items: center;
}

.bar-chart-label {
  font-size: 0.82rem;
  line-height: 1.3;
  color: var(--text, #1a1a1a);
}

.bar-chart-track {
  height: 0.55rem;
  background: var(--surface-2, #eef1f4);
  border-radius: 999px;
  overflow: hidden;
}

.bar-chart-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--accent, #2d6a4f);
  min-width: 0;
  transition: width 0.35s ease;
}

.bar-chart-fill-income {
  background: #2d6a4f;
}

.bar-chart-fill-expense {
  background: #c1121f;
}

.bar-chart-fill-profit {
  background: #0077b6;
}

.bar-chart-fill-withdraw {
  background: #6a4c93;
}

.bar-chart-fill-channel {
  background: #e85d04;
}

.bar-chart-fill-extra {
  background: #bc6c25;
}

.bar-chart-value {
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
  color: var(--muted, #5c6670);
}

.bar-chart-empty {
  margin: 0;
  padding: 0.75rem 0;
  font-size: 0.88rem;
  color: var(--muted, #5c6670);
  list-style: none;
}

.report-detail-grid {
  display: grid;
  gap: 0.75rem;
}

@media (min-width: 720px) {
  .report-detail-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.report-detail-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  padding: 1rem 1.1rem;
  text-align: left;
  background: var(--surface, #fff);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: var(--radius, 12px);
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.report-detail-card:hover,
.report-detail-card:focus-visible {
  border-color: color-mix(in srgb, var(--accent, #2d6a4f) 40%, var(--border, #e2e8f0));
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
  outline: none;
}

.report-detail-icon {
  font-size: 1.35rem;
  line-height: 1;
}

.report-detail-copy {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.report-detail-title {
  font-size: 0.95rem;
}

.report-detail-count {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--accent, #2d6a4f);
}

.report-detail-hint {
  font-size: 0.8rem;
  color: var(--muted, #5c6670);
  line-height: 1.35;
}

.exp-detail-card.exp-detail-retiros .report-detail-count {
  color: #6a4c93;
}

.exp-detail-card.exp-detail-zone .report-detail-count {
  color: #0077b6;
}

.report-detail-card.exp-detail-card {
  align-items: flex-start;
}

.exp-detail-card .report-detail-count {
  font-variant-numeric: tabular-nums;
}

.exp-type-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.55rem;
}

label.exp-type-option {
  display: block;
  margin: 0;
  font-weight: 400;
  color: inherit;
  cursor: pointer;
}

label.exp-type-option input[type='radio'] {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  min-height: 0;
}

.exp-type-option-inner {
  min-height: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.65rem;
  padding: 0.72rem 0.75rem;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  border-radius: 0.82rem;
  background: rgba(255, 255, 255, 0.95);
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}

label.exp-type-option:hover .exp-type-option-inner {
  border-color: rgba(196, 92, 38, 0.28);
  background: rgba(255, 252, 248, 0.98);
  transform: translateY(-1px);
}

label.exp-type-option:has(input:checked) .exp-type-option-inner {
  border-color: rgba(196, 92, 38, 0.55);
  background: rgba(196, 92, 38, 0.09);
  box-shadow:
    0 0 0 1px rgba(196, 92, 38, 0.12),
    0 7px 16px rgba(196, 92, 38, 0.09);
}

.exp-type-option-icon {
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: 0.62rem;
  background: rgba(12, 36, 31, 0.07);
  color: var(--brand);
  font-size: 1rem;
  font-weight: 800;
}

.exp-type-option:nth-child(2) .exp-type-option-icon {
  color: #1e5c45;
  background: rgba(45, 106, 79, 0.11);
}

.exp-type-option:nth-child(3) .exp-type-option-icon {
  color: #5b3d7a;
  background: rgba(106, 76, 147, 0.12);
}

.exp-type-option-copy {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.exp-type-option-check {
  width: 1.35rem;
  height: 1.35rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
  opacity: 0;
  transform: scale(0.65);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

label.exp-type-option:has(input:checked) .exp-type-option-check {
  opacity: 1;
  transform: scale(1);
}

.exp-type-option-title {
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--brand);
  line-height: 1.3;
}

.exp-type-option-desc {
  display: block;
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--muted);
  font-weight: 500;
}

.modal-sheet-exp {
  width: min(100%, 42rem);
}

.modal-sheet-exp .exp-modal-lead {
  margin: 0.35rem 0 0;
  font-size: 0.88rem;
  line-height: 1.45;
  max-width: 28rem;
}

.modal-sheet-exp .exp-modal-body {
  padding-top: 0.5rem;
}

.exp-form-block + .exp-form-block {
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(12, 36, 31, 0.1);
}

.exp-form-block-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--brand);
}

.exp-step-head {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin-bottom: 0.7rem;
}

.exp-step-number {
  flex: 0 0 1.55rem;
  width: 1.55rem;
  height: 1.55rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(150deg, var(--brand-3), var(--brand));
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  box-shadow: 0 4px 10px rgba(12, 36, 31, 0.15);
}

.exp-step-head > div {
  min-width: 0;
}

.exp-step-help {
  margin: 0.16rem 0 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.35;
}

.exp-form-grid {
  gap: 0.75rem;
}

.exp-span-full {
  grid-column: 1 / -1;
}

.exp-amount-field input {
  font-weight: 700;
  color: var(--brand);
  font-variant-numeric: tabular-nums;
}

@media (min-width: 560px) {
  .exp-classification-grid,
  .exp-payment-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 760px) {
  .exp-type-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .exp-type-option-inner {
    grid-template-columns: 1fr auto;
    align-content: start;
  }

  .exp-type-option-icon {
    grid-column: 1;
    margin-bottom: 0.15rem;
  }

  .exp-type-option-copy {
    grid-column: 1 / -1;
  }

  .exp-type-option-check {
    grid-column: 2;
    grid-row: 1;
  }
}

#expense-form.is-retiro .exp-field-category,
#expense-form.is-retiro .exp-field-zone,
#expense-form.is-retiro .exp-field-unit,
#expense-form.is-general .exp-field-zone,
#expense-form.is-general .exp-field-unit {
  display: none;
}

.exp-unit-block {
  margin: 0.65rem 0 1rem;
  padding-left: 0.35rem;
  border-left: 2px solid var(--border, #e2e8f0);
}

.exp-unit-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0 0 0.45rem;
}

.exp-unit-head h3 {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 650;
}

.hint-inline {
  font-weight: 500;
  color: var(--muted);
  font-size: 0.85em;
}

.label-optional {
  font-weight: 500;
  color: var(--muted);
  font-size: 0.8em;
}

.exp-destination-hint {
  margin: 0.55rem 0 0;
  padding: 0.6rem 0.7rem;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.4;
  border: 1px solid rgba(201, 162, 39, 0.25);
  border-radius: 0.68rem;
  background: rgba(201, 162, 39, 0.08);
  color: #715800;
}

.exp-destination-hint::before {
  content: "!";
  width: 1.35rem;
  height: 1.35rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(201, 162, 39, 0.18);
  font-size: 0.72rem;
  font-weight: 800;
}

.exp-destination-hint:empty {
  display: none;
}

.exp-destination-retiro {
  border-color: rgba(106, 76, 147, 0.2);
  background: color-mix(in srgb, #6a4c93 12%, #fff);
  color: #4a3570;
}

.exp-destination-zone {
  border-color: rgba(0, 119, 182, 0.18);
  background: color-mix(in srgb, #0077b6 10%, #fff);
  color: #005a8a;
}

.exp-destination-general {
  border-color: rgba(45, 106, 79, 0.18);
  background: color-mix(in srgb, var(--accent, #2d6a4f) 10%, #fff);
  color: #1e4d3a;
}

.exp-destination-retiro::before,
.exp-destination-zone::before,
.exp-destination-general::before {
  content: "\2713";
  color: #fff;
}

.exp-destination-retiro::before {
  background: #6a4c93;
}

.exp-destination-zone::before {
  background: #0077b6;
}

.exp-destination-general::before {
  background: #2d6a4f;
}

.report-detail-chevron {
  flex: none;
  width: 1.55rem;
  height: 1.55rem;
  position: relative;
  align-self: center;
}

.report-detail-chevron::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0.45rem;
  height: 0.45rem;
  border-right: 2px solid var(--muted, #5c6670);
  border-bottom: 2px solid var(--muted, #5c6670);
  transform: translate(-70%, -50%) rotate(-45deg);
}

.modal-sheet-report {
  max-width: 44rem;
  width: min(44rem, calc(100vw - 1.5rem));
}

.modal-sheet-report .report-modal-body {
  max-height: min(68vh, 36rem);
  overflow-y: auto;
}

.report-modal-toolbar {
  margin-bottom: 0.75rem;
}

.report-modal-search-label {
  flex: 1;
  min-width: 0;
}

.modal-sheet-exp-group {
  --group-accent: #0077b6;
  --group-soft: rgba(0, 119, 182, 0.08);
  width: min(46rem, calc(100vw - 1.5rem));
}

.modal-sheet-exp-group.is-extras {
  --group-accent: #2d6a4f;
  --group-soft: rgba(45, 106, 79, 0.09);
}

.modal-sheet-exp-group.is-retiros {
  --group-accent: #6a4c93;
  --group-soft: rgba(106, 76, 147, 0.1);
}

.modal-sheet-exp-group .editor-head.exp-group-head {
  display: flex;
  align-items: center;
  gap: 0.75rem 1rem;
  padding: 1rem var(--pad) 0.9rem;
  background:
    radial-gradient(80% 100% at 0% 0%, var(--group-soft), transparent 70%),
    #fff;
  border-bottom-color: color-mix(in srgb, var(--group-accent) 25%, transparent);
}

.exp-group-head-main {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-width: 0;
  flex: 1 1 auto;
}

.exp-group-avatar {
  flex: none;
  width: 2.7rem;
  height: 2.7rem;
  display: grid;
  place-items: center;
  border-radius: 0.85rem;
  background: var(--group-soft);
  border: 1px solid color-mix(in srgb, var(--group-accent) 25%, transparent);
  color: var(--group-accent);
  font-size: 1.2rem;
  line-height: 1;
}

.exp-group-head-copy {
  min-width: 0;
}

.exp-group-head-copy .eyebrow {
  margin-bottom: 0.15rem;
  color: var(--group-accent);
}

.exp-group-head-copy h2 {
  margin: 0;
  overflow-wrap: anywhere;
}

.exp-group-lead {
  margin: 0.2rem 0 0;
  max-width: 32rem;
}

.exp-group-body {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-top: 0.85rem;
}

.exp-group-overview {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(6rem, 0.6fr);
  gap: 0.6rem;
}

.exp-group-metric {
  min-width: 0;
  display: grid;
  gap: 0.14rem;
  align-content: center;
  padding: 0.7rem 0.8rem;
  border: 1px solid color-mix(in srgb, var(--group-accent) 18%, transparent);
  border-radius: 0.78rem;
  background: var(--group-soft);
}

.exp-group-metric span {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.exp-group-metric strong {
  color: var(--group-accent);
  font-family: var(--font-display);
  font-size: 1.15rem;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
}

.exp-group-guide {
  grid-column: 1 / -1;
  margin: 0;
  padding: 0.58rem 0.7rem;
  border-left: 3px solid var(--group-accent);
  border-radius: 0.18rem 0.65rem 0.65rem 0.18rem;
  background: color-mix(in srgb, var(--group-accent) 5%, #fff);
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.4;
}

.exp-group-search {
  display: grid;
  gap: 0.35rem;
  margin-top: 0.1rem;
  color: var(--brand);
  font-size: 0.76rem;
  font-weight: 700;
}

.exp-group-search-control {
  position: relative;
  display: block;
}

.exp-group-search-control svg {
  position: absolute;
  left: 0.8rem;
  top: 50%;
  width: 1rem;
  height: 1rem;
  transform: translateY(-50%);
  fill: none;
  stroke: var(--muted);
  stroke-width: 2;
  stroke-linecap: round;
  pointer-events: none;
}

.exp-group-search input {
  width: 100%;
  padding-left: 2.35rem;
}

.exp-group-list-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.15rem;
  padding-bottom: 0.42rem;
  border-bottom: 1px solid rgba(12, 36, 31, 0.1);
}

.exp-group-list-head h3 {
  margin: 0;
  color: var(--brand);
  font-family: var(--font-display);
  font-size: 0.98rem;
}

.exp-group-list-head span {
  color: var(--muted);
  font-size: 0.75rem;
}

.exp-pay-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.4rem;
}

.exp-pay-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.55rem 0.65rem;
  min-width: 0;
  padding: 0.75rem 0.8rem;
  border-radius: 0.9rem;
  border: 1.5px solid color-mix(in srgb, var(--group-accent) 15%, rgba(12, 36, 31, 0.08));
  background: #fff;
  box-shadow: 0 3px 12px rgba(12, 36, 31, 0.045);
}

.exp-pay-card-compact {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.55rem 0.7rem;
  border-radius: 0.7rem;
  box-shadow: none;
}

.exp-pay-compact-row {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  min-width: 0;
}

.exp-pay-card-compact .exp-pay-copy {
  flex: 1 1 auto;
  min-width: 0;
  gap: 0.12rem;
}

.exp-pay-card-compact .exp-pay-title {
  font-size: 0.88rem;
  line-height: 1.25;
  font-weight: 650;
}

.exp-pay-meta {
  display: block;
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.exp-pay-card-compact .exp-pay-amount {
  font-size: 0.9rem;
  padding-top: 0.05rem;
}

.exp-pay-compact-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  min-width: 0;
}

.exp-pay-card-compact .exp-receipt-chips,
.exp-pay-card-compact .exp-receipt-empty {
  grid-column: auto;
  margin: 0;
}

.exp-pay-card-compact .exp-receipt-chip {
  padding: 0.15rem 0.45rem;
  font-size: 0.68rem;
}

.exp-pay-card-compact .exp-pay-actions {
  grid-column: auto;
  align-self: center;
  flex: none;
}

.exp-pay-card-compact .exp-pay-edit {
  font-size: 0.72rem;
  padding: 0.28rem 0.55rem;
}

.exp-pay-main {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 0.62rem;
}

.exp-pay-avatar {
  flex: 0 0 2rem;
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: 0.62rem;
  background: var(--group-soft);
  color: var(--group-accent);
  font-size: 0.9rem;
  font-weight: 800;
}

.exp-pay-copy {
  flex: 1 1 auto;
  display: grid;
  gap: 0.08rem;
  min-width: 0;
}

.exp-pay-title {
  margin: 0;
  min-width: 0;
  flex: 1 1 auto;
  font-size: 0.95rem;
  font-weight: 650;
  line-height: 1.35;
  color: var(--brand);
  overflow-wrap: anywhere;
}

.exp-pay-subtitle {
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.25;
}

.exp-pay-amount {
  flex: none;
  margin: 0;
  font-size: 0.98rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.35;
  color: var(--group-accent);
  text-align: right;
  white-space: nowrap;
}

.exp-pay-details {
  grid-column: 1;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.4rem 0.65rem;
}

.exp-pay-details > div {
  min-width: 0;
  display: grid;
  gap: 0.08rem;
}

.exp-pay-details dt {
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.exp-pay-details dd {
  margin: 0;
  color: var(--brand);
  font-size: 0.76rem;
  font-weight: 600;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.exp-pay-actions {
  grid-column: 2;
  align-self: end;
  display: flex;
  gap: 0.4rem;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.exp-pay-edit {
  font-size: 0.78rem;
  padding: 0.35rem 0.7rem;
}

.exp-receipt-empty {
  grid-column: 2;
  margin: 0.15rem 0 0;
  font-size: 0.72rem;
  color: var(--muted, #5c6670);
}

.exp-receipt-chips {
  grid-column: 2;
  list-style: none;
  margin: 0.35rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.exp-receipt-chip {
  border: 1px solid var(--border, #e2e8f0);
  background: var(--surface-2, #f4f6f8);
  border-radius: 999px;
  padding: 0.25rem 0.65rem;
  font-size: 0.72rem;
  color: var(--ink, #10241f);
  cursor: pointer;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.exp-receipt-chip:hover,
.exp-receipt-chip:focus-visible {
  border-color: var(--brand, #1f6b57);
  outline: none;
}

.exp-receipts-field input[type='file'] {
  margin-top: 0.35rem;
  font-size: 0.85rem;
}

.exp-existing-receipts {
  grid-column: 1 / -1;
  margin-top: 0.35rem;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  background: var(--surface-2, #f4f6f8);
  border: 1px solid var(--border, #e2e8f0);
}

.exp-existing-receipts-title {
  margin: 0 0 0.4rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted, #5c6670);
}

.exp-receipt-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.35rem;
}

.exp-receipt-list li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.exp-receipt-link {
  flex: 1;
  min-width: 0;
  text-align: left;
  border: 0;
  background: transparent;
  color: var(--brand, #1f6b57);
  font-size: 0.85rem;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0;
}

.exp-receipt-remove {
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  border: 1px solid rgba(159, 31, 31, 0.25);
  background: #fff;
  color: var(--danger, #9f1f1f);
  cursor: pointer;
  line-height: 1;
}

.exp-pay-delete {
  position: relative;
  width: 2.2rem;
  height: 2.2rem;
  display: grid;
  place-items: center;
  border: 1px solid rgba(159, 31, 31, 0.25);
  border-radius: 0.65rem;
  background: rgba(159, 31, 31, 0.045);
  color: var(--danger);
  padding: 0;
  cursor: pointer;
  transition: color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.exp-pay-delete svg {
  width: 1rem;
  height: 1rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.exp-pay-delete:hover,
.exp-pay-delete:focus-visible {
  color: #fff;
  background: var(--danger);
  transform: translateY(-1px);
  outline: none;
}

.exp-pay-delete::after {
  content: attr(data-tooltip);
  position: absolute;
  right: 0;
  bottom: calc(100% + 0.45rem);
  width: max-content;
  padding: 0.35rem 0.5rem;
  border-radius: 0.45rem;
  background: var(--brand);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 650;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.exp-pay-delete:hover::after,
.exp-pay-delete:focus-visible::after {
  opacity: 1;
  visibility: visible;
}

.exp-pay-empty {
  padding: 1.35rem 1rem !important;
  text-align: center;
  border-style: dashed !important;
  background: rgba(255, 255, 255, 0.55) !important;
  box-shadow: none !important;
}

.exp-pay-list .empty-state {
  list-style: none;
}

#report-expenses-list .group-head {
  align-items: baseline;
  gap: 0.75rem 1rem;
  margin-bottom: 0.65rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid rgba(12, 36, 31, 0.1);
}

#report-expenses-list .group-head h2 {
  flex: 1 1 auto;
  font-size: 1.08rem;
}

#report-expenses-list .exp-group-total {
  font-size: 1.02rem;
}

/* ConsignaciÃ³n â€” modal caja (terracota / cÃ¡lido) */
/* Bolsillos: botones inline compactos */
.header-buttons-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
}

.header-buttons-inline .btn-compact {
  white-space: nowrap;
  flex: none;
}

.header-buttons-inline .btn-label-short {
  display: none;
}

/* Modal movimiento */
.modal-sheet-mov {
  width: min(100%, 38rem);
  border-color: rgba(196, 92, 38, 0.58);
  box-shadow:
    0 0 0 1px rgba(12, 36, 31, 0.35),
    0 28px 80px rgba(8, 16, 15, 0.5);
}

.modal-sheet-mov .editor-head {
  background:
    radial-gradient(90% 70% at 0% 0%, rgba(196, 92, 38, 0.16), transparent 55%),
    linear-gradient(180deg, rgba(248, 230, 212, 0.55), transparent 70%),
    #fff;
}

.modal-sheet-mov .editor-head .eyebrow {
  color: var(--accent, #c45c26);
}

.modal-sheet-mov .form-actions {
  background: linear-gradient(180deg, #faf3ea, #f3eadc);
}

.mov-section {
  margin: 0;
  padding: 0.75rem 0 0;
  border: 0;
  border-top: 1px solid rgba(12, 36, 31, 0.1);
}

.mov-section:first-of-type {
  padding-top: 0;
  border-top: 0;
}

.mov-section legend {
  padding: 0;
  margin-bottom: 0.65rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--brand);
}

.mov-grid-type,
.mov-grid-money {
  grid-template-columns: 1fr 1fr;
}

.mov-grid-link {
  grid-template-columns: 1fr;
}

@media (max-width: 520px) {
  .mov-grid-type,
  .mov-grid-money {
    grid-template-columns: 1fr;
  }
}

/* Selector de reserva â€” centrado (verde bosque / frÃ­o) */
.modal-stack .modal-backdrop-pick {
  background: rgba(12, 36, 31, 0.48);
}

.modal-sheet-mov-pick {
  --pick: #1f4f43;
  --pick-2: #2d6a4f;
  --pick-surface: #eef5f2;
  --pick-surface-2: #f7faf9;
  width: min(100%, 42rem);
  max-height: min(90vh, 54rem);
  border-radius: 1.25rem;
  border: 2px solid rgba(45, 106, 79, 0.52);
  box-shadow:
    0 0 0 1px rgba(12, 36, 31, 0.3),
    0 32px 90px rgba(8, 16, 15, 0.52);
  animation: modal-in 0.38s var(--ease);
}

.mov-pick-editor {
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-height: min(90vh, 54rem);
}

.mov-pick-head {
  flex: none;
  border-bottom: 0;
  padding-bottom: 1.15rem;
}

.modal-sheet-mov-pick .editor-head.mov-pick-head {
  border-bottom: 0;
  background: linear-gradient(155deg, var(--pick-2) 0%, var(--pick) 42%, #0c241f 100%);
}

.modal-sheet-mov-pick .mov-pick-eyebrow {
  color: rgba(255, 255, 255, 0.75);
  letter-spacing: 0.1em;
}

.modal-sheet-mov-pick .mov-pick-head h2 {
  color: #fff;
}

.modal-sheet-mov-pick .mov-pick-lead {
  margin: 0.4rem 0 0;
  max-width: 34rem;
  font-size: 0.86rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.85);
}

.mov-pick-close {
  color: rgba(255, 255, 255, 0.92) !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  background: rgba(255, 255, 255, 0.1) !important;
}

.mov-pick-close:hover {
  background: rgba(255, 255, 255, 0.18) !important;
}

.mov-pick-sticky {
  flex: none;
  padding: 0.85rem var(--pad) 0.65rem;
  border-bottom: 1px solid rgba(45, 106, 79, 0.14);
  background: var(--pick-surface);
}

.mov-pick-search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.mov-pick-search-icon {
  position: absolute;
  left: 0.9rem;
  display: grid;
  place-items: center;
  color: var(--pick-2);
  pointer-events: none;
}

.mov-pick-search {
  width: 100%;
  padding: 0.78rem 0.95rem 0.78rem 2.65rem;
  border-radius: 0.9rem;
  border: 1.5px solid rgba(45, 106, 79, 0.18);
  background: #fff;
  font: inherit;
  font-size: 0.95rem;
  color: var(--ink, #0c241f);
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.mov-pick-search::placeholder {
  color: rgba(92, 102, 112, 0.75);
}

.mov-pick-search:hover {
  border-color: rgba(45, 106, 79, 0.32);
}

.mov-pick-search:focus {
  outline: none;
  border-color: rgba(45, 106, 79, 0.55);
  box-shadow: 0 0 0 3px rgba(45, 106, 79, 0.14);
}

.mov-pick-filter-bar {
  display: flex;
  gap: 0.45rem;
  margin-top: 0.7rem;
  padding: 0.28rem;
  border-radius: 0.85rem;
  background: rgba(12, 36, 31, 0.07);
  border: 1px solid rgba(45, 106, 79, 0.1);
}

.mov-pick-filter {
  flex: 1;
  min-width: 0;
  padding: 0.55rem 0.75rem;
  border: 0;
  border-radius: 0.62rem;
  background: transparent;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted, #5c6670);
  cursor: pointer;
  transition:
    background 0.2s ease,
    color 0.2s ease,
    box-shadow 0.2s ease;
}

.mov-pick-filter:hover {
  color: var(--pick);
}

.mov-pick-filter.is-active {
  background: #fff;
  color: var(--pick-2);
  box-shadow: 0 2px 10px rgba(12, 36, 31, 0.08);
}

.mov-pick-count {
  margin: 0.55rem 0 0;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: rgba(31, 79, 67, 0.75);
}

.mov-pick-body {
  flex: 1 1 auto;
  min-height: 0;
  padding: 0.75rem var(--pad) 1rem;
  max-height: min(52vh, 28rem);
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--pick-surface-2);
}

.mov-pick-actions {
  flex: none;
  background: linear-gradient(180deg, var(--pick-surface), #e4ede9);
  border-top: 1px solid rgba(45, 106, 79, 0.14);
}

.mov-pick-actions .btn-ghost {
  color: var(--pick);
  border-color: rgba(45, 106, 79, 0.25);
}

.mov-pick-none {
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  padding: 0.85rem 1rem;
  border-radius: 0.95rem;
  border: 1.5px dashed rgba(45, 106, 79, 0.28);
  background: #fff;
  text-align: left;
  cursor: pointer;
  transition:
    border-color 0.22s ease,
    background 0.22s ease,
    transform 0.18s ease,
    box-shadow 0.22s ease;
}

.mov-pick-none:hover,
.mov-pick-none:focus-visible {
  border-color: rgba(45, 106, 79, 0.5);
  background: var(--pick-surface);
  box-shadow: 0 8px 22px rgba(12, 36, 31, 0.06);
  transform: translateY(-1px);
  outline: none;
}

.mov-pick-none-icon {
  display: grid;
  place-items: center;
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 999px;
  background: rgba(45, 106, 79, 0.1);
  color: var(--pick-2);
}

.mov-pick-none-copy {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.mov-pick-none-title {
  font-weight: 700;
  color: var(--ink, #0c241f);
}

.mov-pick-none-desc {
  font-size: 0.8rem;
  color: var(--muted, #5c6670);
}

.mov-pick-none-arrow {
  font-size: 1.35rem;
  color: var(--pick-2);
  line-height: 1;
}

.mov-res-picker-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.55rem;
}

.mov-pick-card {
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.8rem;
  padding: 0.9rem 1rem;
  border-radius: 1rem;
  border: 1.5px solid rgba(45, 106, 79, 0.12);
  background: #fff;
  box-shadow: 0 2px 10px rgba(12, 36, 31, 0.04);
  text-align: left;
  cursor: pointer;
  transition:
    border-color 0.22s ease,
    background 0.22s ease,
    transform 0.18s ease,
    box-shadow 0.22s ease;
}

.mov-pick-card:hover,
.mov-pick-card:focus-visible {
  border-color: rgba(45, 106, 79, 0.38);
  background: var(--pick-surface);
  box-shadow: 0 10px 28px rgba(12, 36, 31, 0.08);
  transform: translateY(-1px);
  outline: none;
}

.mov-pick-card.is-selected {
  border-color: rgba(45, 106, 79, 0.55);
  background: linear-gradient(135deg, rgba(45, 106, 79, 0.1), #fff 52%);
  box-shadow:
    0 0 0 1px rgba(45, 106, 79, 0.12),
    0 12px 30px rgba(45, 106, 79, 0.1);
}

.mov-pick-avatar {
  display: grid;
  place-items: center;
  width: 2.65rem;
  height: 2.65rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  color: var(--pick);
  background: linear-gradient(145deg, rgba(45, 106, 79, 0.16), rgba(45, 106, 79, 0.06));
  border: 1px solid rgba(45, 106, 79, 0.2);
  flex-shrink: 0;
}

.mov-pick-card.is-selected .mov-pick-avatar {
  color: #fff;
  background: linear-gradient(145deg, var(--pick-2), var(--pick));
  border-color: transparent;
  box-shadow: 0 4px 14px rgba(45, 106, 79, 0.35);
}

.mov-pick-card-body {
  display: grid;
  gap: 0.35rem;
  min-width: 0;
}

.mov-pick-card-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
}

.mov-pick-card-guest {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--ink, #0c241f);
  overflow-wrap: anywhere;
}

.mov-pick-card-money {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--pick-2);
  white-space: nowrap;
}

.mov-pick-card-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.mov-pick-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #4a5560;
  background: rgba(12, 36, 31, 0.07);
}

.mov-pick-chip-zone {
  color: #005a8a;
  background: color-mix(in srgb, #0077b6 12%, #fff);
}

.mov-pick-chip-channel {
  color: #4a3570;
  background: color-mix(in srgb, #6a4c93 12%, #fff);
}

.mov-pick-card-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--muted, #5c6670);
}

.mov-pick-dot {
  opacity: 0.45;
}

.mov-pick-pocket.is-warn {
  color: #9a6700;
  font-weight: 700;
}

.mov-pick-check {
  display: grid;
  place-items: center;
  width: 1.65rem;
  height: 1.65rem;
  border-radius: 999px;
  border: 1.5px solid rgba(45, 106, 79, 0.2);
  color: transparent;
  background: #fff;
  flex-shrink: 0;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
}

.mov-pick-card.is-selected .mov-pick-check {
  border-color: transparent;
  background: var(--pick-2);
  color: #fff;
  transform: scale(1.05);
}

.mov-pick-empty {
  display: grid;
  justify-items: center;
  gap: 0.35rem;
  padding: 2rem 1rem;
  text-align: center;
  color: var(--muted, #5c6670);
}

.mov-pick-empty-icon {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  margin-bottom: 0.25rem;
  border-radius: 999px;
  font-size: 1.1rem;
  background: rgba(45, 106, 79, 0.1);
  color: var(--pick-2);
}

.mov-pick-empty strong {
  color: var(--ink, #0c241f);
  font-size: 0.95rem;
}

.mov-pick-empty span:last-child {
  font-size: 0.84rem;
  line-height: 1.45;
  max-width: 22rem;
}

.mov-res-picker-field {
  display: grid;
  gap: 0.45rem;
}

.mov-res-picker-field .field-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--brand);
}

.mov-res-picker {
  display: flex;
  align-items: stretch;
  gap: 0.45rem;
}

.mov-res-picker-btn {
  flex: 1;
  min-width: 0;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.8rem 0.95rem;
  border-radius: 0.95rem;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  background: linear-gradient(180deg, #fff, #faf7f2);
  text-align: left;
  cursor: pointer;
  transition:
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    background 0.22s ease,
    transform 0.18s ease;
}

.mov-res-picker-btn:hover,
.mov-res-picker-btn:focus-visible {
  border-color: rgba(196, 92, 38, 0.5);
  box-shadow: 0 8px 24px rgba(12, 36, 31, 0.08);
  transform: translateY(-1px);
  outline: none;
}

.mov-res-picker-btn.has-selection {
  border-color: rgba(196, 92, 38, 0.48);
  background:
    linear-gradient(135deg, rgba(196, 92, 38, 0.08), #fff 55%),
    #fff;
}

.mov-res-picker-avatar {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--muted, #5c6670);
  background: rgba(12, 36, 31, 0.06);
  border: 1.5px dashed rgba(12, 36, 31, 0.16);
  flex-shrink: 0;
}

.mov-res-picker-avatar.has-guest {
  font-size: 0.82rem;
  color: #fff;
  border-style: solid;
  border-color: transparent;
  background: linear-gradient(145deg, #d46a32, #b84f1f);
  box-shadow: 0 4px 12px rgba(196, 92, 38, 0.28);
}

.mov-res-picker-label {
  min-width: 0;
  display: grid;
  gap: 0.12rem;
}

.mov-res-picker-empty {
  font-weight: 700;
  color: var(--ink, #0c241f);
}

.mov-res-picker-sub,
.mov-res-picker-meta {
  font-size: 0.8rem;
  color: var(--muted, #5c6670);
  line-height: 1.35;
}

.mov-res-picker-guest {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink, #0c241f);
  line-height: 1.25;
}

.mov-res-picker-action {
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--brand, #c45c26);
  background: rgba(196, 92, 38, 0.1);
  flex-shrink: 0;
}

.mov-res-picker-btn.has-selection .mov-res-picker-action {
  color: #fff;
  background: var(--brand, #c45c26);
}

.mov-res-picker-clear {
  flex: none;
  align-self: center;
}

.mov-res-picker-hint.is-ok {
  padding: 0.45rem 0.6rem;
  border-radius: 0.55rem;
  background: color-mix(in srgb, var(--accent, #2d6a4f) 10%, #fff);
  color: #1e4d3a;
  font-weight: 600;
}

.mov-res-picker-hint.is-warn {
  padding: 0.45rem 0.6rem;
  border-radius: 0.55rem;
  background: color-mix(in srgb, #c9a227 14%, #fff);
  color: #7a5a00;
  font-weight: 600;
}

@media (max-width: 520px) {
  .mov-pick-filter {
    font-size: 0.76rem;
    padding: 0.5rem 0.45rem;
  }

  .mov-pick-card {
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
  }

  .mov-pick-check {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    align-self: start;
    margin-top: 0.1rem;
  }

  .mov-pick-card-body {
    grid-column: 1 / -1;
  }

  .mov-res-picker-btn {
    grid-template-columns: auto 1fr;
  }

  .mov-res-picker-action {
    grid-column: 2;
    justify-self: start;
    margin-top: 0.25rem;
  }
}

/* Pack rapidez â€” cierre de mes y validaciones */
.form-warnings {
  margin: 0.65rem 0 0;
  padding: 0.6rem 0.75rem;
  border-radius: 0.6rem;
  font-size: 0.84rem;
  line-height: 1.45;
  background: color-mix(in srgb, #c9a227 12%, #fff);
  color: #6b5200;
  border: 1px solid rgba(201, 162, 39, 0.3);
}

.mov-type-hint {
  display: block;
  margin-top: 0.45rem;
  font-size: 0.78rem;
}

.modal-sheet-close-month {
  width: min(100%, 34rem);
}

.close-month-steps {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.65rem;
}

.close-month-step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-radius: 0.85rem;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  background: #fff;
}

.close-month-step.is-ok {
  border-color: rgba(45, 106, 79, 0.35);
  background: color-mix(in srgb, #2d6a4f 8%, #fff);
}

.close-month-step.is-pending {
  border-color: rgba(201, 162, 39, 0.35);
}

.close-month-step-icon {
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 0.85rem;
  background: rgba(12, 36, 31, 0.08);
  color: var(--muted);
}

.close-month-step.is-ok .close-month-step-icon {
  background: #2d6a4f;
  color: #fff;
}

.close-month-step-title {
  font-weight: 700;
  color: var(--ink);
}

.close-month-step-detail {
  font-size: 0.82rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

.exp-repeat-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.45rem;
}

.exp-repeat-item {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.75rem 0.85rem;
  border-radius: 0.8rem;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  background: #fff;
  cursor: pointer;
}

.exp-repeat-item:has(input:checked) {
  border-color: rgba(196, 92, 38, 0.45);
  background: rgba(196, 92, 38, 0.06);
}

.exp-repeat-copy {
  flex: 1;
  min-width: 0;
}

.exp-repeat-copy strong {
  display: block;
  font-size: 0.92rem;
}

.exp-repeat-copy span {
  font-size: 0.8rem;
  color: var(--muted);
}

.panel-head-actions {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.55rem;
}

.panel-head-actions .btn-campo-link,
.panel-head-actions .btn-ghost {
  height: 2.7rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 1rem;
  border-radius: 999px;
  font-weight: 700;
  white-space: nowrap;
}

.panel-head-actions .panel-refresh {
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 6px 16px rgba(12, 36, 31, 0.1);
}

.panel-head-actions-solo {
  width: auto;
  flex: 0 0 auto;
  display: flex;
  justify-content: flex-end;
}

.report-modal-chart {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border, #e2e8f0);
}

#report-expenses-list {
  display: grid;
  gap: 1.25rem;
}

#report-expenses-list .exp-group + .exp-group {
  margin-top: 0;
}

.catalog-block .group-head {
  margin: 0 0 0.85rem;
  align-items: center;
}

.catalog-block .group-head .btn-primary {
  padding: 0.5rem 0.9rem;
  font-size: 0.86rem;
}

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

.modal-sheet-sm {
  width: min(100%, 30rem);
}

#cfg-summary {
  margin-bottom: 1.15rem;
}

.cfg-accordion {
  display: grid;
  gap: 0.75rem;
}

.cfg-panel {
  border-radius: 1rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 246, 242, 0.92)),
    #fff;
  box-shadow: 0 8px 28px rgba(8, 16, 15, 0.05);
  overflow: hidden;
  transition:
    border-color 0.28s ease,
    box-shadow 0.28s ease,
    transform 0.28s ease;
}

.cfg-panel:hover {
  border-color: rgba(196, 92, 38, 0.22);
}

.cfg-panel.is-open {
  border-color: rgba(196, 92, 38, 0.38);
  box-shadow:
    0 12px 36px rgba(196, 92, 38, 0.1),
    0 0 0 1px rgba(196, 92, 38, 0.08);
}

.cfg-panel-trigger {
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 0.85rem;
  padding: 1rem 1.05rem;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
  transition: background 0.22s ease;
}

.cfg-panel-trigger:hover {
  background: rgba(196, 92, 38, 0.05);
}

.cfg-panel.is-open .cfg-panel-trigger {
  background: linear-gradient(180deg, rgba(196, 92, 38, 0.1), rgba(196, 92, 38, 0.03));
}

.cfg-panel-icon {
  width: 2.65rem;
  height: 2.65rem;
  display: grid;
  place-items: center;
  border-radius: 0.85rem;
  font-size: 1rem;
  font-weight: 800;
  color: var(--brand);
  background: rgba(12, 36, 31, 0.06);
  border: 1px solid rgba(12, 36, 31, 0.08);
  transition:
    transform 0.28s var(--ease),
    background 0.28s ease,
    border-color 0.28s ease;
}

.cfg-panel.is-open .cfg-panel-icon {
  transform: scale(1.05);
  background: rgba(196, 92, 38, 0.14);
  border-color: rgba(196, 92, 38, 0.28);
}

.cfg-panel-icon-channels {
  color: #8a3f12;
}

.cfg-panel-icon-zones {
  color: #1f6b4a;
}

.cfg-panel-icon-units {
  color: #1e5268;
}

.cfg-panel-icon-categories {
  color: #5c4a12;
}

.cfg-panel-icon-users {
  color: #4a2d6e;
}

.cfg-panel-icon-purge {
  background: rgba(159, 31, 31, 0.12);
  color: #9f1f1f;
}

.cfg-panel-icon-maintenance {
  color: #7a3b12;
}

.cfg-panel-copy {
  display: grid;
  gap: 0.18rem;
  min-width: 0;
}

.cfg-panel-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: var(--brand);
}

.cfg-panel-lead {
  font-size: 0.82rem;
  line-height: 1.35;
  color: var(--muted);
}

.cfg-panel-badge {
  flex: none;
  min-width: 2rem;
  padding: 0.22rem 0.55rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.08);
  color: var(--brand);
  font-size: 0.78rem;
  font-weight: 800;
  text-align: center;
}

.cfg-panel-badge-warn {
  background: rgba(196, 92, 38, 0.14);
  color: #8a3f12;
}

.cfg-panel-chevron {
  width: 0.55rem;
  height: 0.55rem;
  border-right: 2px solid rgba(12, 36, 31, 0.45);
  border-bottom: 2px solid rgba(12, 36, 31, 0.45);
  transform: rotate(45deg);
  transition: transform 0.32s var(--ease);
  margin-right: 0.15rem;
}

.cfg-panel.is-open .cfg-panel-chevron {
  transform: rotate(-135deg) translateY(-2px);
}

.cfg-panel-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.38s var(--ease);
}

.cfg-panel.is-open .cfg-panel-body {
  grid-template-rows: 1fr;
}

.cfg-panel-inner {
  overflow: hidden;
}

.cfg-panel-content {
  padding: 0 1.05rem 1.1rem;
  border-top: 1px solid rgba(12, 36, 31, 0.08);
  animation: cfg-panel-content-in 0.35s var(--ease) both;
}

.cfg-panel:not(.is-open) .cfg-panel-content {
  animation: none;
}

.cfg-panel-content .group-head {
  margin-top: 0.85rem;
}

.cfg-panel-content h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.08rem;
}

.cfg-inline-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.35rem;
  height: 1.35rem;
  margin-left: 0.35rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.08);
  font-size: 0.72rem;
  font-weight: 800;
  vertical-align: middle;
}

@keyframes cfg-panel-content-in {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.cfg-hint-top {
  margin-top: 0.85rem;
}

.cfg-hint-compact {
  margin-bottom: 0.45rem;
  font-size: 0.8rem;
}

.cfg-team-grid {
  display: grid;
  gap: 1rem;
  margin-top: 0.65rem;
}

@media (min-width: 820px) {
  .cfg-team-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.1rem;
  }
}

.cfg-team-block {
  min-width: 0;
  padding: 0.85rem;
  border-radius: 0.95rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: rgba(255, 255, 255, 0.55);
}

.cfg-team-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.65rem;
}

.cfg-team-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: -0.02em;
  color: var(--brand);
}

.cfg-team-lead {
  margin: 0.15rem 0 0;
  font-size: 0.78rem;
}

.cfg-slim-rows {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.35rem;
}

.cfg-slim-rows > li {
  margin: 0;
  padding: 0;
}

.cfg-slim-row {
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 0.65rem;
  min-height: 2.5rem;
  padding: 0.45rem 0.65rem;
  border: 1px solid rgba(12, 36, 31, 0.11);
  border-radius: 0.65rem;
  background: rgba(255, 255, 255, 0.92);
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.cfg-slim-row:hover {
  border-color: rgba(196, 92, 38, 0.32);
  background: rgba(255, 252, 248, 0.98);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(196, 92, 38, 0.08);
}

.cfg-slim-row:active {
  transform: translateY(0);
}

.cfg-slim-row-avatar {
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: 0.55rem;
  background: rgba(12, 36, 31, 0.07);
  color: var(--brand);
  font-size: 0.82rem;
  font-weight: 800;
  flex: none;
}

.cfg-slim-row-avatar-role {
  background: rgba(74, 45, 110, 0.1);
  color: #4a2d6e;
}

.cfg-slim-row-copy {
  display: grid;
  gap: 0.1rem;
  min-width: 0;
}

.cfg-slim-row-copy strong {
  font-size: 0.88rem;
  color: var(--brand);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cfg-slim-row-meta {
  font-size: 0.74rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cfg-slim-row-badges {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  flex-wrap: nowrap;
}

.cfg-slim-row-arrow {
  font-size: 1.1rem;
  line-height: 1;
  color: rgba(12, 36, 31, 0.35);
  transition: transform 0.2s ease, color 0.2s ease;
}

.cfg-slim-row:hover .cfg-slim-row-arrow {
  color: rgba(196, 92, 38, 0.75);
  transform: translateX(2px);
}

.cfg-slim-rows > .empty-state {
  padding: 0.85rem;
  border-radius: 0.65rem;
  border: 1px dashed rgba(12, 36, 31, 0.12);
  background: rgba(12, 36, 31, 0.03);
  font-size: 0.84rem;
}

.role-form-actions {
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

.role-form-actions-extra {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.role-form-actions-main {
  display: flex;
  gap: 0.55rem;
  margin-left: auto;
}

@media (max-width: 640px) {
  .role-form-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .role-form-actions-main {
    margin-left: 0;
    width: 100%;
  }

  .role-form-actions-main .btn-primary,
  .role-form-actions-main .btn-ghost {
    flex: 1;
  }

  .cfg-slim-row {
    grid-template-columns: auto 1fr auto;
  }

  .cfg-slim-row-badges {
    display: none;
  }
}

.cfg-sub-accordion {
  display: grid;
  gap: 0.55rem;
  margin-top: 0.35rem;
}

.cfg-sub-accordion-slim {
  gap: 0.4rem;
}

.cfg-sub-panel-slim {
  border: 0;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}

.cfg-sub-panel-slim.is-open {
  box-shadow: none;
  background: transparent;
}

.cfg-slim-trigger {
  width: 100%;
  min-height: 2.35rem;
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 0.55rem;
  padding: 0.42rem 0.72rem;
  border: 1px solid rgba(12, 36, 31, 0.12);
  border-radius: 0.65rem;
  background: rgba(255, 255, 255, 0.88);
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
  transition:
    border-color 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease;
}

.cfg-slim-trigger:hover {
  border-color: rgba(196, 92, 38, 0.28);
  background: rgba(255, 252, 248, 0.98);
}

.cfg-sub-panel-slim.is-open > .cfg-slim-trigger,
.cfg-item-card.is-open > .cfg-slim-trigger {
  border-color: rgba(196, 92, 38, 0.38);
  background: rgba(196, 92, 38, 0.08);
}

.cfg-slim-label {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--brand);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cfg-slim-meta {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: nowrap;
}

.cfg-slim-tag {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  max-width: 5.5rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cfg-slim-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin: 0.45rem 0 0.5rem;
  flex-wrap: wrap;
}

.cfg-slim-toolbar-hint {
  font-size: 0.78rem;
}

.cfg-sub-panel-slim .cfg-panel-body .cfg-sub-panel-content {
  padding: 0 0.1rem 0.15rem;
}

.cfg-item-list {
  display: grid;
  gap: 0.35rem;
}

.cfg-item-list.data-list.compact > li {
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  animation: none;
}

.cfg-item-list.data-list.compact > li:hover {
  transform: none;
  box-shadow: none;
  border-color: transparent;
}

.cfg-item-list.data-list.compact > li.empty-state {
  padding: 0.85rem 0.65rem;
  background: rgba(12, 36, 31, 0.04);
  border-radius: 0.65rem;
  border: 1px dashed rgba(12, 36, 31, 0.12);
}

.cfg-item-list > li {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.cfg-item-card {
  border-radius: 0.6rem;
  overflow: hidden;
}

.cfg-item-card .cfg-slim-trigger {
  min-height: 2.15rem;
  padding: 0.38rem 0.65rem;
  border-radius: 0.6rem;
}

.cfg-item-card .cfg-panel-chevron {
  width: 0.45rem;
  height: 0.45rem;
}

.cfg-item-detail {
  padding: 0.55rem 0.65rem 0.7rem;
  border-top: 1px dashed rgba(12, 36, 31, 0.1);
  animation: cfg-panel-content-in 0.28s var(--ease) both;
}

.cfg-item-detail .role-perm-summary {
  margin-top: 0.45rem;
  padding: 0.6rem 0.7rem;
}

.cfg-item-detail .row-actions {
  margin-top: 0.55rem;
}

.cfg-sub-panel {
  border-radius: 0.85rem;
  border: 1px solid rgba(12, 36, 31, 0.09);
  background: rgba(255, 255, 255, 0.72);
  overflow: hidden;
  transition:
    border-color 0.25s ease,
    background 0.25s ease,
    box-shadow 0.25s ease;
}

.cfg-sub-panel:hover {
  border-color: rgba(196, 92, 38, 0.2);
}

.cfg-sub-panel.is-open {
  border-color: rgba(196, 92, 38, 0.32);
  background: rgba(255, 252, 248, 0.95);
  box-shadow: inset 0 0 0 1px rgba(196, 92, 38, 0.06);
}

.cfg-sub-panel .cfg-panel-trigger {
  padding: 0.78rem 0.9rem;
  gap: 0.7rem;
}

.cfg-sub-panel .cfg-panel-icon {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 0.7rem;
  font-size: 0.88rem;
}

.cfg-sub-panel .cfg-panel-title {
  font-size: 0.96rem;
}

.cfg-sub-panel .cfg-panel-lead {
  font-size: 0.78rem;
}

.cfg-sub-panel .cfg-panel-badge {
  min-width: 1.75rem;
  padding: 0.18rem 0.45rem;
  font-size: 0.72rem;
}

.cfg-sub-panel .cfg-panel-content {
  padding: 0 0.9rem 0.95rem;
}

.cfg-sub-panel-content .group-head {
  margin-top: 0.65rem;
}

.cfg-sub-panel-content h2 {
  font-size: 0.98rem;
}

.cfg-panel-icon-roles {
  color: #4a2d6e;
}

@media (max-width: 640px) {
  .cfg-panel-trigger {
    grid-template-columns: auto 1fr auto;
    gap: 0.7rem;
  }

  .cfg-panel-badge {
    grid-column: 2;
    grid-row: 2;
    justify-self: start;
    margin-top: -0.15rem;
  }

  .cfg-panel-chevron {
    grid-row: 1 / span 2;
    grid-column: 3;
    align-self: center;
  }
}

.cfg-hint {
  margin: 0 0 0.85rem;
}

.maintenance-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 0.5rem;
}

.maintenance-actions a.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  padding: 0.65rem 1rem;
  min-height: 2.5rem;
}

#cfg-reset-db,
.cfg-purge-danger {
  border-color: rgba(159, 31, 31, 0.45);
  color: var(--danger);
}

#cfg-reset-db:hover,
.cfg-purge-danger:hover {
  background: var(--danger);
  border-color: var(--danger);
  color: #fff8f1;
}

.config-form {
  display: grid;
  gap: 0.55rem;
  margin: 0 0 1rem;
}

.config-form .btn-primary {
  align-self: end;
  white-space: nowrap;
}

@media (min-width: 720px) {
  .config-form {
    grid-template-columns: 1fr auto;
  }

  .config-form.cols-3 {
    grid-template-columns: 1.3fr 7.5rem auto;
  }

  .config-form.cols-4 {
    grid-template-columns: 1.1fr 1fr 6.5rem auto;
  }
}

.config-pct-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: end;
  margin-top: 0.35rem;
}

.config-pct {
  width: 6.2rem;
}

.btn-compact {
  padding: 0.42rem 0.75rem;
  min-height: 2.25rem;
  font-size: 0.85rem;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes shine {
  to { transform: translateX(120%); }
}

@keyframes mark-glow {
  0%, 100% { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12), 0 8px 18px rgba(12, 36, 31, 0.22); }
  50% { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2), 0 10px 26px rgba(196, 92, 38, 0.28); }
}

@keyframes orb-float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(18px, -22px) scale(1.08); }
}

@keyframes bar-fill {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

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

body.modal-open {
  overflow: hidden;
}

.modal {
  position: fixed;
  top: var(--vv-offset-top, 0px);
  left: 0;
  right: 0;
  bottom: auto;
  height: var(--vv-height, 100dvh);
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(1rem, env(safe-area-inset-top)) 1rem max(1.1rem, env(safe-area-inset-bottom));
}

.modal.modal-stack {
  z-index: 85;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 14, 12, 0.62);
  cursor: pointer;
  animation: fade-in 0.28s ease;
}

.modal-sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 42rem);
  max-height: min(90vh, 54rem);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 1.25rem;
  background: #fff;
  border: 2px solid rgba(196, 92, 38, 0.55);
  box-shadow:
    0 0 0 1px rgba(12, 36, 31, 0.4),
    0 28px 80px rgba(8, 16, 15, 0.5);
  animation: modal-in 0.38s var(--ease);
}

.modal-sheet .editor {
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-height: min(90vh, 54rem);
  margin: 0;
  padding: 0;
  gap: 0;
  border: 0;
  border-radius: 1.25rem;
  background: transparent;
  box-shadow: none;
}

.modal-sheet .editor-head {
  flex: none;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1.15rem var(--pad) 1rem;
  border-bottom: 1.5px solid rgba(12, 36, 31, 0.14);
  background:
    linear-gradient(180deg, rgba(196, 92, 38, 0.12), transparent 72%),
    #fff;
}

.modal-sheet .editor-head .eyebrow {
  margin-bottom: 0.2rem;
}

.modal-sheet .editor-head h2 {
  font-size: 1.4rem;
}

.modal-sheet-mov-pick .editor-head.mov-pick-head {
  background: linear-gradient(155deg, #2d6a4f 0%, #1f4f43 42%, #0c241f 100%);
}

.modal-sheet-mov-pick .editor-head.mov-pick-head .eyebrow {
  color: rgba(255, 255, 255, 0.75);
}

.modal-sheet-mov-pick .editor-head.mov-pick-head h2 {
  color: #fff;
}

.modal-sheet-mov-pick .editor-head.mov-pick-head .mov-pick-lead {
  color: rgba(255, 255, 255, 0.85);
}

.editor-head > div {
  min-width: 0;
  flex: 1 1 auto;
}

.editor-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 0.35rem var(--pad) 1.1rem;
}

.editor-body > .form-grid {
  padding-top: 0.9rem;
}

.modal-sheet .field-group:first-child {
  border-top: 0;
  padding-top: 0.85rem;
}

.modal-sheet .form-actions {
  position: relative;
  z-index: 4;
  flex: none;
  padding: 0.95rem var(--pad) 1.15rem;
  border-top: 1.5px solid rgba(12, 36, 31, 0.14);
  background: #f3eadc;
}

.modal-sheet .form-actions .btn-primary {
  min-width: 10.5rem;
}

@keyframes modal-in {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.success-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  background: rgba(6, 14, 12, 0.62);
}

.success-card {
  display: grid;
  justify-items: center;
  gap: 0.8rem;
  padding: 2.1rem 1.9rem 1.8rem;
  border-radius: 1.4rem;
  background: #fff;
  border: 2px solid rgba(196, 92, 38, 0.45);
  box-shadow: var(--shadow-lg);
  min-width: 16.5rem;
  text-align: center;
  animation: modal-in 0.32s var(--ease);
}

.success-ring {
  position: relative;
  width: 7.2rem;
  height: 7.2rem;
  filter: drop-shadow(0 8px 16px rgba(32, 201, 151, 0.25));
}

.success-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ring-track,
.ring-progress {
  fill: none;
  stroke-width: 7;
}

.ring-track {
  stroke: #e6eee9;
}

.ring-progress {
  stroke: #20c997;
  stroke-linecap: round;
  stroke-dasharray: 251.2;
  stroke-dashoffset: 251.2;
}

.success-overlay.is-on .ring-progress {
  animation: ring-fill 0.85s var(--ease) forwards;
}

.success-check {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 2rem;
  font-weight: 700;
  color: #20c997;
  opacity: 0;
  transform: scale(0.6);
}

.success-overlay.is-on .success-check {
  animation: check-pop 0.35s var(--ease) 0.7s forwards;
}

.success-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.55rem;
  letter-spacing: -0.03em;
}

.success-sub {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

@keyframes ring-fill {
  to { stroke-dashoffset: 0; }
}

@keyframes check-pop {
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@media (max-width: 420px) {
  .user-label {
    display: none;
  }

  .user-chip {
    max-width: none;
    padding-right: 0.2rem;
  }

  .row-money {
    white-space: normal;
    text-align: right;
  }
}

@media (max-width: 520px) {
  .preview-metrics {
    grid-template-columns: 1fr;
  }

  .res-date-callout {
    font-size: 0.78rem;
  }

  .panel-head > .btn-primary {
    width: 100%;
  }

  .panel-head > .header-buttons {
    width: 100%;
  }

  .panel-head > .header-buttons .btn-primary,
  .panel-head > .header-buttons .btn-ghost {
    flex: 1 1 auto;
  }
}

@media (max-height: 800px) and (min-width: 900px) {
  .app-header {
    padding-top: calc(env(safe-area-inset-top, 0px) + 0.55rem);
    padding-bottom: 0.55rem;
  }

  .content {
    padding-top: 1rem;
  }

  .tab {
    min-height: 2.4rem;
  }
}

@media (min-width: 1600px) {
  :root {
    --page-max: 88rem;
    --gutter: 1.5rem;
    --pad: 1.2rem;
  }
}

@media (min-width: 2200px) {
  :root {
    --page-max: 96rem;
    --gutter: 1.75rem;
  }
}

.users-roles-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--pad);
}

@media (max-width: 720px) {
  .users-roles-grid {
    grid-template-columns: 1fr;
  }
}

.cfg-subtitle {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 0.65rem;
}

.perm-full-access {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  margin: 1rem 0;
  padding: 0.85rem 1rem;
  border-radius: var(--radius);
  background: var(--surface-2);
  font-weight: 500;
}

.modal-sheet-role {
  width: min(100%, 44rem);
}

.role-editor-head {
  position: relative;
  align-items: flex-start;
}

.role-head-main {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  min-width: 0;
}

.role-icon-preview {
  flex: none;
  width: 3.4rem;
  height: 3.4rem;
  display: grid;
  place-items: center;
  border-radius: 1rem;
  background:
    linear-gradient(145deg, rgba(12, 36, 31, 0.14), rgba(196, 92, 38, 0.18)),
    #fff;
  border: 2px solid rgba(12, 36, 31, 0.18);
  color: var(--brand);
  font-size: 1.35rem;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(12, 36, 31, 0.1);
  transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease);
}

.modal-sheet-role.is-entering .role-icon-preview {
  animation: user-avatar-pop 0.5s var(--ease) both;
}

.role-mode-badge {
  position: absolute;
  top: 1.15rem;
  right: 3.6rem;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.08);
  color: var(--brand);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.role-mode-badge.is-edit {
  background: rgba(196, 92, 38, 0.14);
  color: #8a3f12;
}

.role-mode-badge.is-duplicate {
  background: rgba(34, 90, 120, 0.12);
  color: #1e5268;
}

.role-editor-body {
  padding-top: 0.15rem;
}

.role-field-group {
  animation: user-field-in 0.42s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 0.07s + 0.06s);
}

.modal-sheet-role.is-entering .role-field-group {
  animation-name: user-field-in;
}

.role-form-grid {
  gap: 0.95rem;
}

.cfg-role-field {
  display: grid;
  gap: 0.42rem;
}

.cfg-role-field .field-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--brand);
}

.cfg-role-field input {
  transition:
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    transform 0.22s ease;
}

.cfg-role-field input:focus {
  border-color: rgba(196, 92, 38, 0.65);
  box-shadow: 0 0 0 3px rgba(196, 92, 38, 0.12);
  transform: translateY(-1px);
}

.role-access-card {
  padding: 0.9rem 1rem;
  border-radius: 0.95rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(12, 36, 31, 0.03));
  transition:
    border-color 0.28s ease,
    background 0.28s ease,
    box-shadow 0.28s ease;
}

.role-access-card.is-active {
  border-color: rgba(196, 92, 38, 0.45);
  background: linear-gradient(135deg, rgba(196, 92, 38, 0.12), rgba(255, 248, 241, 0.95));
  box-shadow: 0 8px 24px rgba(196, 92, 38, 0.1);
}

.role-full-toggle {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
}

.role-full-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.role-full-switch {
  width: 2.6rem;
  height: 1.45rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.16);
  position: relative;
  transition: background 0.25s ease;
}

.role-full-switch::after {
  content: '';
  position: absolute;
  top: 0.16rem;
  left: 0.16rem;
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
  transition: transform 0.25s var(--ease);
}

.role-full-toggle input:checked + .role-full-switch {
  background: rgba(196, 92, 38, 0.85);
}

.role-full-toggle input:checked + .role-full-switch::after {
  transform: translateX(1.05rem);
}

.role-full-copy {
  display: grid;
  gap: 0.15rem;
}

.role-perm-fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  transition:
    opacity 0.28s ease,
    transform 0.28s ease;
}

.role-perm-fieldset.is-disabled {
  opacity: 0.45;
  pointer-events: none;
  transform: scale(0.985);
}

.role-perm-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}

.role-perm-head legend {
  padding: 0;
  margin: 0;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand);
}

.role-perm-count {
  flex: none;
  padding: 0.22rem 0.6rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.08);
  color: var(--brand);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  transition: background 0.25s ease, color 0.25s ease;
}

.role-perm-count.is-complete {
  background: rgba(34, 120, 84, 0.14);
  color: #1f6b4a;
}

.role-perm-count.is-empty {
  background: rgba(12, 36, 31, 0.06);
  color: var(--muted);
}

.role-perm-groups {
  display: grid;
  gap: 0.85rem;
}

.perm-group {
  padding: 0.85rem 0.95rem;
  border-radius: 0.95rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: rgba(255, 255, 255, 0.72);
  transition:
    border-color 0.25s ease,
    background 0.25s ease,
    box-shadow 0.25s ease;
}

.perm-group.is-partial {
  border-color: rgba(196, 92, 38, 0.28);
  background: rgba(255, 248, 241, 0.65);
}

.perm-group.is-complete {
  border-color: rgba(34, 120, 84, 0.28);
  background: rgba(240, 252, 246, 0.75);
  box-shadow: inset 0 0 0 1px rgba(34, 120, 84, 0.08);
}

.perm-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.65rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid rgba(12, 36, 31, 0.08);
}

.perm-group-title {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--brand);
  margin: 0;
}

.perm-group-count {
  flex: none;
  min-width: 2.4rem;
  text-align: center;
  padding: 0.18rem 0.45rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.07);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  transition: background 0.25s ease, color 0.25s ease;
}

.perm-group.is-complete .perm-group-count {
  background: rgba(34, 120, 84, 0.14);
  color: #1f6b4a;
}

.perm-group.is-partial .perm-group-count {
  background: rgba(196, 92, 38, 0.14);
  color: #8a3f12;
}

.perm-checks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}

.perm-check-item {
  animation: perm-item-in 0.35s var(--ease) both;
  animation-delay: calc(var(--j, 0) * 0.04s + 0.05s);
}

.modal-sheet-role.is-entering .perm-check-item {
  animation-name: perm-item-in;
}

.perm-check-card {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: start;
  gap: 0.65rem;
  padding: 0.72rem 0.85rem;
  border-radius: 0.8rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  transition:
    border-color 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease,
    transform 0.22s ease;
}

.perm-check-card:hover:not(.is-disabled) {
  border-color: rgba(196, 92, 38, 0.28);
  background: rgba(255, 252, 248, 0.95);
  transform: translateY(-1px);
}

.perm-check-card.is-checked {
  border-color: rgba(34, 120, 84, 0.42);
  background: linear-gradient(135deg, rgba(34, 120, 84, 0.1), rgba(255, 255, 255, 0.95));
  box-shadow: 0 6px 18px rgba(34, 120, 84, 0.08);
}

.perm-check-card.is-pulse {
  animation: perm-check-pop 0.38s var(--ease);
}

.perm-check-card.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.perm-check-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.perm-check-order {
  flex: none;
  min-width: 1.65rem;
  margin-top: 0.12rem;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--muted);
  opacity: 0.75;
  transition: color 0.22s ease, opacity 0.22s ease;
}

.perm-check-card.is-checked .perm-check-order {
  color: #1f6b4a;
  opacity: 1;
}

.perm-check-box {
  width: 1.35rem;
  height: 1.35rem;
  margin-top: 0.1rem;
  border-radius: 0.38rem;
  border: 2px solid rgba(12, 36, 31, 0.22);
  background: #fff;
  display: grid;
  place-items: center;
  color: #fff;
  transition:
    border-color 0.22s ease,
    background 0.22s ease,
    transform 0.22s cubic-bezier(0.34, 1.4, 0.64, 1);
}

.perm-check-card.is-checked .perm-check-box {
  background: rgba(34, 120, 84, 0.92);
  border-color: rgba(34, 120, 84, 0.92);
  transform: scale(1.05);
}

.perm-check-icon {
  width: 0.72rem;
  height: 0.6rem;
  opacity: 0;
  transform: scale(0.4) rotate(-12deg);
  transition:
    opacity 0.2s ease,
    transform 0.25s cubic-bezier(0.34, 1.4, 0.64, 1);
}

.perm-check-card.is-checked .perm-check-icon {
  opacity: 1;
  transform: scale(1) rotate(0deg);
}

.perm-check-text {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.perm-check-text strong {
  font-size: 0.92rem;
  line-height: 1.3;
  color: var(--brand);
}

.perm-check-text .hint {
  font-size: 0.78rem;
  line-height: 1.35;
}

@keyframes perm-item-in {
  from {
    opacity: 0;
    transform: translateX(-8px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes perm-check-pop {
  0% {
    transform: scale(1);
  }
  45% {
    transform: scale(1.015);
  }
  100% {
    transform: scale(1);
  }
}

@media (min-width: 720px) {
  .role-perm-groups .perm-checks {
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem 0.65rem;
  }

  .perm-group[data-group='admin'] .perm-checks,
  .perm-group[data-group='occupancy'] .perm-checks {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .role-mode-badge {
    position: static;
    order: -1;
    margin-bottom: 0.35rem;
  }

  .role-editor-head {
    flex-wrap: wrap;
  }

  .role-perm-head {
    flex-direction: column;
    align-items: flex-start;
  }
}

.role-card,
.user-card {
  padding-bottom: 0.15rem;
}

.role-perm-summary {
  display: grid;
  gap: 0.55rem;
  margin: 0.55rem 0 0.15rem;
  padding: 0.75rem 0.85rem;
  border-radius: 0.85rem;
  background: linear-gradient(135deg, rgba(196, 92, 38, 0.06), rgba(12, 36, 31, 0.04));
  border: 1px solid rgba(12, 36, 31, 0.08);
}

.role-perm-group {
  display: grid;
  gap: 0.35rem;
}

.role-perm-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.role-perm-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.perm-pill {
  display: inline-flex;
  align-items: center;
  min-height: 1.55rem;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.08);
  color: var(--brand);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.perm-pill-all {
  background: rgba(196, 92, 38, 0.16);
  color: #8a3f12;
}

.role-perm-note,
.role-perm-empty,
.user-role-preview-empty {
  margin: 0;
  font-size: 0.84rem;
}

.btn-danger-link {
  color: var(--danger);
  border-color: rgba(159, 31, 31, 0.25);
}

.btn-danger-link:hover {
  background: rgba(159, 31, 31, 0.08);
  border-color: rgba(159, 31, 31, 0.45);
  color: var(--danger);
}

.modal-sheet-user {
  width: min(100%, 38rem);
}

.user-editor-head {
  position: relative;
  align-items: flex-start;
}

.user-head-main {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  min-width: 0;
}

.user-avatar-preview {
  flex: none;
  width: 3.4rem;
  height: 3.4rem;
  display: grid;
  place-items: center;
  border-radius: 1rem;
  background:
    linear-gradient(145deg, rgba(196, 92, 38, 0.22), rgba(12, 36, 31, 0.12)),
    #fff;
  border: 2px solid rgba(196, 92, 38, 0.35);
  color: var(--brand);
  font-size: 1.35rem;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(196, 92, 38, 0.12);
  transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease);
}

.modal-sheet-user.is-entering .user-avatar-preview {
  animation: user-avatar-pop 0.5s var(--ease) both;
}

.user-mode-badge {
  position: absolute;
  top: 1.15rem;
  right: 3.6rem;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.08);
  color: var(--brand);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.user-mode-badge.is-edit {
  background: rgba(196, 92, 38, 0.14);
  color: #8a3f12;
}

.user-editor-body {
  padding-top: 0.15rem;
}

.user-field-group {
  animation: user-field-in 0.42s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 0.07s + 0.06s);
}

.modal-sheet-user.is-entering .user-field-group {
  animation-name: user-field-in;
}

.user-form-grid {
  gap: 0.95rem;
}

.cfg-user-field {
  display: grid;
  gap: 0.42rem;
}

.cfg-user-field .field-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--brand);
}

.cfg-user-field input,
.cfg-user-field select {
  transition:
    border-color 0.22s ease,
    box-shadow 0.22s ease;
}

.cfg-user-field input:focus {
  border-color: rgba(196, 92, 38, 0.65);
  box-shadow: 0 0 0 3px rgba(196, 92, 38, 0.12);
  transform: translateY(-1px);
  transition:
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    transform 0.22s ease;
}

.cfg-user-field select:focus {
  border-color: rgba(196, 92, 38, 0.65);
  box-shadow: 0 0 0 3px rgba(196, 92, 38, 0.12);
  background-image: var(--select-chevron);
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  background-size: 0.75rem 0.5rem;
}

.password-field {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.45rem;
  align-items: center;
}

.btn-pass-toggle {
  min-height: 2.65rem;
  padding: 0.45rem 0.8rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(12, 36, 31, 0.14);
  background: rgba(12, 36, 31, 0.04);
  color: var(--brand);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.btn-pass-toggle:hover {
  background: rgba(196, 92, 38, 0.08);
  border-color: rgba(196, 92, 38, 0.35);
}

.user-role-preview {
  margin-top: 0.55rem;
  padding: 0.85rem 0.95rem;
  border-radius: 0.95rem;
  background: rgba(12, 36, 31, 0.03);
  border: 1px dashed rgba(12, 36, 31, 0.12);
  transition: border-color 0.25s ease, background 0.25s ease;
}

.user-role-preview:not(:empty) {
  border-style: solid;
  background: rgba(255, 255, 255, 0.72);
}

.user-status-card {
  padding: 0.85rem 1rem;
  border-radius: 0.95rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(12, 36, 31, 0.03));
  transition: border-color 0.25s ease, background 0.25s ease;
}

.user-status-card.is-inactive {
  border-color: rgba(159, 31, 31, 0.18);
  background: linear-gradient(180deg, rgba(255, 248, 241, 0.95), rgba(159, 31, 31, 0.04));
}

.user-status-toggle {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
}

.user-status-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.user-status-switch {
  width: 2.6rem;
  height: 1.45rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.16);
  position: relative;
  transition: background 0.25s ease;
}

.user-status-switch::after {
  content: '';
  position: absolute;
  top: 0.16rem;
  left: 0.16rem;
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
  transition: transform 0.25s var(--ease);
}

.user-status-toggle input:checked + .user-status-switch {
  background: rgba(34, 120, 84, 0.85);
}

.user-status-toggle input:checked + .user-status-switch::after {
  transform: translateX(1.05rem);
}

.user-status-copy {
  display: grid;
  gap: 0.15rem;
}

.user-form-actions {
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

.user-form-actions-main {
  display: flex;
  gap: 0.55rem;
  margin-left: auto;
}

@keyframes user-field-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes user-avatar-pop {
  0% {
    opacity: 0;
    transform: scale(0.82);
  }
  70% {
    transform: scale(1.05);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@media (max-width: 640px) {
  .user-mode-badge {
    position: static;
    order: -1;
    margin-bottom: 0.35rem;
  }

  .user-editor-head {
    flex-wrap: wrap;
  }

  .user-form-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .user-form-actions-main {
    margin-left: 0;
    width: 100%;
  }

  .user-form-actions-main .btn-primary,
  .user-form-actions-main .btn-ghost {
    flex: 1;
  }
}

/* â€”â€” Mobile & tablet (touch) â€”â€” */
@media (max-width: 1023px) {
  :root {
    --gutter: 1rem;
    --gap: 0.85rem;
    --stack: 1.35rem;
    --pad: 1rem;
    --touch-gap: 0.7rem;
    --nav-h: 4.35rem;
    --control-h: 2.95rem;
  }

  html,
  body {
    touch-action: pan-y;
    overscroll-behavior-x: none;
  }

  button,
  a,
  .tab,
  .btn-primary,
  .btn-ghost {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }

  input,
  select,
  textarea {
    font-size: 16px;
    max-width: 100%;
  }

  input[type="date"],
  input[type="month"] {
    -webkit-appearance: none;
    appearance: none;
    position: relative;
    display: block;
    width: 100%;
    min-width: 0;
    height: var(--control-h);
    min-height: var(--control-h);
    box-sizing: border-box;
    padding: 0 2.35rem 0 2.55rem;
    border: 1.5px solid rgba(12, 36, 31, 0.16);
    border-radius: 0.9rem;
    color: var(--brand);
    font-size: 16px;
    font-weight: 650;
    letter-spacing: -0.01em;
    line-height: normal;
    background-color: #fff;
    background-image:
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none' stroke='%230c241f' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'><rect x='3' y='5' width='14' height='12' rx='2'/><path d='M3 9h14M7 3v4M13 3v4'/></svg>"),
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%235c6f68' d='M1.2 1.2 6 6l4.8-4.8'/></svg>");
    background-repeat: no-repeat;
    background-position: left 0.85rem center, right 0.85rem center;
    background-size: 1.1rem 1.1rem, 0.7rem 0.45rem;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.85), 0 8px 18px rgba(12, 36, 31, 0.07);
    /* Evitar fade de iconos en iOS al abrir el date picker */
    transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  }

  input[type="date"]:hover,
  input[type="month"]:hover,
  input[type="date"]:focus,
  input[type="month"]:focus,
  input[type="date"]:active,
  input[type="month"]:active {
    background-image:
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none' stroke='%230c241f' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'><rect x='3' y='5' width='14' height='12' rx='2'/><path d='M3 9h14M7 3v4M13 3v4'/></svg>"),
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%235c6f68' d='M1.2 1.2 6 6l4.8-4.8'/></svg>");
    background-repeat: no-repeat;
    background-position: left 0.85rem center, right 0.85rem center;
    background-size: 1.1rem 1.1rem, 0.7rem 0.45rem;
  }

  input[type="date"]::-webkit-datetime-edit,
  input[type="month"]::-webkit-datetime-edit {
    display: flex;
    align-items: center;
    height: 100%;
    min-height: 100%;
    padding: 0;
    line-height: 1.2;
  }

  input[type="date"]::-webkit-datetime-edit-fields-wrapper,
  input[type="month"]::-webkit-datetime-edit-fields-wrapper {
    display: flex;
    align-items: center;
    padding: 0;
  }

  input[type="date"]::-webkit-datetime-edit-text,
  input[type="date"]::-webkit-datetime-edit-month-field,
  input[type="date"]::-webkit-datetime-edit-day-field,
  input[type="date"]::-webkit-datetime-edit-year-field,
  input[type="month"]::-webkit-datetime-edit-text,
  input[type="month"]::-webkit-datetime-edit-month-field,
  input[type="month"]::-webkit-datetime-edit-year-field {
    padding: 0;
    line-height: 1.2;
  }

  input[type="date"]::-webkit-date-and-time-value,
  input[type="month"]::-webkit-date-and-time-value {
    display: flex;
    align-items: center;
    text-align: left;
    margin: 0;
    padding: 0;
    min-height: 100%;
    height: 100%;
    line-height: 1.2;
  }

  input[type="date"]::-webkit-calendar-picker-indicator,
  input[type="month"]::-webkit-calendar-picker-indicator {
    position: absolute;
    inset: 0;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0;
    opacity: 0;
    cursor: pointer;
  }

  input[type="date"]::-webkit-inner-spin-button,
  input[type="date"]::-webkit-clear-button,
  input[type="month"]::-webkit-inner-spin-button,
  input[type="month"]::-webkit-clear-button {
    display: none;
    -webkit-appearance: none;
  }

  .toolbar select {
    height: var(--control-h);
    min-height: var(--control-h);
    border-radius: 0.9rem;
    font-weight: 650;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.85), 0 8px 18px rgba(12, 36, 31, 0.07);
  }

  .toolbar {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: end;
    gap: 0.55rem;
  }

  .toolbar .inline-label {
    flex: 1 1 11rem;
    max-width: none;
    width: auto;
    min-width: 0;
  }

  .month-toolbar {
    width: 100%;
    align-items: stretch;
  }

  .month-filter {
    flex: 1 1 100%;
  }

  .month-filter-bar {
    height: var(--control-h);
    border-radius: 0.95rem;
    grid-template-columns: var(--control-h) minmax(0, 1fr) var(--control-h) var(--control-h);
  }

  .month-filter-text {
    font-size: 0.95rem;
  }

  .month-filter-face input[type="month"] {
    padding: 0;
    background: none !important;
    background-image: none !important;
    box-shadow: none !important;
    border: 0;
    min-height: 0;
    height: 100%;
  }

  .month-toolbar-extra {
    flex: 1 1 100%;
    max-width: none;
    width: 100%;
  }

  .toolbar > .btn-toolbar,
  .toolbar > .btn-ghost,
  .toolbar > .btn-primary {
    flex: 0 0 auto;
    width: auto;
    min-width: var(--control-h);
    height: var(--control-h);
    min-height: var(--control-h);
    padding: 0 0.9rem;
    gap: 0.4rem;
    border-radius: 0.9rem;
    overflow: visible;
    line-height: 1;
    font-size: 0.86rem;
    white-space: nowrap;
  }

  .btn-toolbar-icon {
    display: block;
    width: 1.1rem;
    height: 1.1rem;
    flex: none;
  }

  .toolbar > .btn-toolbar span {
    line-height: 1;
  }

  @media (max-width: 360px) {
    .toolbar > .btn-toolbar {
      width: var(--control-h);
      padding: 0;
    }

    .toolbar > .btn-toolbar span {
      display: none;
    }
  }

  .app-header {
    grid-template-columns: minmax(0, 1fr) auto;
    row-gap: 0;
    padding-top: calc(env(safe-area-inset-top, 0px) + 0.7rem);
    padding-bottom: 0.55rem;
  }

  .header-tools-btn {
    width: 2.65rem;
    height: 2.65rem;
  }

  .header-tools-menu {
    right: -0.25rem;
    gap: 0.4rem;
    padding: 0.45rem;
  }

  .header-tools-orb {
    width: 3.35rem;
    min-height: 3.35rem;
    font-size: 0.58rem;
  }

  .header-alert-actions {
    gap: 0.45rem;
  }

  .notice-bell-btn {
    width: 2.65rem;
    height: 2.65rem;
    background: #fff;
    box-shadow: 0 4px 14px rgba(12, 36, 31, 0.1);
  }

  .app-header > .logo-lockup {
    grid-column: 1;
  }

  .logo-lockup.compact .logo-mark {
    width: 1.95rem;
    height: 1.95rem;
    font-size: 0.9rem;
  }

  .logo-lockup.compact .logo-word {
    font-size: 1.12rem;
  }

  .header-actions {
    grid-column: 2;
    width: auto;
    display: flex;
    align-items: center;
    gap: 0.4rem;
  }

  .header-actions .user-chip {
    max-width: 10.5rem;
  }

  #install-btn[hidden] {
    display: none !important;
  }

  #logout-btn {
    padding: 0.42rem 0.7rem;
    min-height: 2.35rem;
    font-size: 0.82rem;
    white-space: nowrap;
  }

  .tabs {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
    display: flex;
    align-items: stretch;
    justify-content: space-around;
    gap: 0.1rem;
    width: 100%;
    max-width: none;
    margin: 0;
    padding:
      0.28rem
      max(0.2rem, env(safe-area-inset-right))
      max(0.28rem, env(safe-area-inset-bottom))
      max(0.2rem, env(safe-area-inset-left));
    border-radius: 0;
    border: 0;
    border-top: 1.5px solid rgba(12, 36, 31, 0.14);
    background: rgba(255, 252, 247, 0.96);
    backdrop-filter: blur(18px) saturate(1.2);
    box-shadow: 0 -10px 28px rgba(12, 36, 31, 0.1);
    overflow: visible;
  }

  .tab {
    flex: 1 1 0;
    min-width: 0;
    flex-direction: column;
    gap: 0.12rem;
    min-height: 3.05rem;
    padding: 0.28rem 0.15rem 0.2rem;
    border-radius: 0.7rem;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.1;
  }

  .tab-overflow {
    display: none !important;
  }

  .tab-more-wrap {
    display: block;
  }

  .tab-icon {
    display: grid;
    place-items: center;
    width: 1.25rem;
    height: 1.25rem;
    color: inherit;
  }

  .tab-icon svg {
    width: 1.2rem;
    height: 1.2rem;
  }

  .tab:has(.tab-label-short) .tab-label {
    display: none;
  }

  .tab-label,
  .tab-label-short {
    display: block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .tab:hover {
    color: var(--brand);
    background: transparent;
  }

  .tab.active,
  .tab-more-btn.is-active {
    color: var(--brand);
    background: rgba(12, 36, 31, 0.08);
    box-shadow: none;
  }

  .tab-more-btn.is-open {
    color: var(--brand);
    background: rgba(12, 36, 31, 0.08);
  }

  .panel-head {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
  }

  .panel-head:has(> .panel-head-actions-solo) {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 0.75rem 1rem;
  }

  .panel-head > div {
    flex: none;
    width: 100%;
  }

  .panel-head:has(> .panel-head-actions-solo) > div {
    flex: 1 1 auto;
    width: auto;
    min-width: 0;
  }

  .panel-head > .btn-primary,
  .panel-head > .header-buttons {
    width: 100%;
    margin-inline-start: 0;
  }

  .panel-head > .panel-head-actions-solo {
    display: flex;
    width: auto;
    margin-inline-start: 0;
    margin-top: 0.15rem;
  }

  .panel-head h1 {
    font-size: clamp(1.4rem, 6vw, 1.75rem);
  }

  .header-buttons:not(.header-buttons-inline) {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--touch-gap);
    width: 100%;
  }

  .header-buttons:not(.header-buttons-inline) .btn-primary,
  .header-buttons:not(.header-buttons-inline) .btn-ghost {
    width: 100%;
    justify-content: center;
  }

  .header-buttons-inline {
    width: 100%;
    flex-wrap: nowrap;
    justify-content: stretch;
  }

  .header-buttons-inline .btn-compact {
    flex: 1 1 0;
    min-width: 0;
    text-align: center;
    justify-content: center;
  }

  .header-buttons-inline .btn-label-full {
    display: none;
  }

  .header-buttons-inline .btn-label-short {
    display: inline;
  }

  .toolbar {
    gap: var(--touch-gap);
    align-items: end;
  }

  .form-actions {
    gap: var(--touch-gap);
  }

  .group-head {
    flex-direction: column;
    align-items: stretch;
    gap: 0.65rem;
  }

  .group-head .muted {
    text-align: left;
  }

  #report-expenses-list .group-head {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: baseline;
    gap: 0.75rem;
  }

  #report-expenses-list .group-head .muted,
  #report-expenses-list .exp-group-total {
    text-align: right;
  }

  .catalog-block .group-head .btn-primary {
    width: 100%;
    justify-content: center;
  }

  .res-card-actions {
    flex-direction: column;
    align-items: stretch;
    gap: var(--touch-gap);
  }

  .res-card-actions .btn-ghost,
  .res-card-actions .btn-primary {
    width: 100%;
    justify-content: center;
  }

  .row-actions {
    gap: var(--touch-gap);
  }

  .row-actions .btn-ghost {
    flex: 1 1 calc(50% - 0.35rem);
    justify-content: center;
    min-height: var(--control-h);
    padding: 0.55rem 0.75rem;
  }

  .res-list-more-wrap .btn-ghost,
  .pocket-items-more-wrap .btn-ghost {
    width: 100%;
    min-width: 0;
  }

  .modal-sheet .editor-head h2 {
    font-size: 1.25rem;
    line-height: 1.25;
  }

  .modal-sheet .form-actions .btn-primary {
    min-width: 0;
  }

  .report-modal-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: var(--touch-gap);
  }

  .report-modal-toolbar .inline-label {
    max-width: none;
    width: 100%;
  }

  .cfg-panel-trigger {
    grid-template-columns: auto 1fr auto;
    gap: 0.65rem;
    padding: 0.9rem 0.95rem;
  }

  .cfg-slim-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: var(--touch-gap);
  }

  .cfg-slim-toolbar .btn-ghost,
  .cfg-slim-toolbar .btn-primary {
    width: 100%;
    justify-content: center;
  }

  .cfg-catalog-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .cfg-catalog-admin {
    margin: 0;
    width: 100%;
    justify-content: space-between;
  }

  .cfg-catalog-toolbar .btn-ghost,
  .cfg-catalog-toolbar .btn-primary {
    width: 100%;
    justify-content: center;
  }

  .stat-chip,
  .kpi-card {
    min-height: 5.35rem;
    padding: 0.85rem 0.7rem 0.9rem;
  }

  .kpi-card.occ-kpi {
    min-height: 6.15rem;
  }

  .occ-glossary summary {
    min-height: 2.75rem;
    padding: 0.8rem 0.85rem;
  }

  .occ-glossary-item {
    padding: 0.7rem 0.85rem 0.85rem;
  }

  .stat-chip span,
  .kpi-card span {
    white-space: normal;
    font-size: 0.64rem;
  }

  .stat-chip strong,
  .kpi-card strong {
    font-size: 0.98rem;
  }

  .report-kpi-label,
  .report-kpi-value {
    white-space: normal;
  }

  .cfg-panel-lead,
  .cfg-panel-title {
    overflow-wrap: anywhere;
  }

  .bar-chart-row {
    grid-template-columns: minmax(4.2rem, 30%) 1fr auto;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .header-buttons:not(.header-buttons-inline) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .header-buttons:not(.header-buttons-inline):has(> :nth-child(3):last-child) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .header-buttons:not(.header-buttons-inline) .btn-primary:only-of-type,
  .header-buttons:not(.header-buttons-inline) .btn-ghost:only-of-type {
    grid-column: 1 / -1;
  }

  .toolbar {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: end;
  }

  .toolbar > .btn-ghost:not(.btn-toolbar),
  .toolbar > .btn-primary {
    flex: 0 1 auto;
    width: auto;
    min-width: 9rem;
  }

  .modal-sheet .form-actions {
    flex-direction: row;
    justify-content: flex-end;
  }

  .modal-sheet .form-actions .btn-primary,
  .modal-sheet .form-actions .btn-ghost {
    width: auto;
    min-width: 9rem;
  }

  .res-card-actions {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .res-card-actions .btn-ghost,
  .res-card-actions .btn-primary {
    width: auto;
    flex: 0 1 auto;
    min-width: 9rem;
  }
}

@media (max-width: 767px) {
  .content {
    padding-top: 0.9rem;
  }

  .user-label {
    display: none;
  }

  .user-chip {
    padding-right: 0.18rem;
    max-width: none;
  }

  .panel-head .lead {
    font-size: 0.9rem;
  }

  .toolbar {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: end;
  }

  .month-toolbar {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.7rem;
  }

  .form-actions,
  .modal-sheet .form-actions,
  .mov-pick-actions {
    flex-direction: column-reverse;
    align-items: stretch;
  }

  .form-actions .btn-primary,
  .form-actions .btn-ghost,
  .modal-sheet .form-actions .btn-primary,
  .modal-sheet .form-actions .btn-ghost,
  .mov-pick-actions .btn-ghost {
    width: 100%;
    min-width: 0;
  }

  .modal {
    --sheet-top-gap: calc(env(safe-area-inset-top, 0px) + 0.7rem);
    --sheet-max-h: calc(var(--vv-height, 100dvh) - var(--sheet-top-gap));
    align-items: flex-end;
    justify-content: flex-end;
    overflow: hidden;
    padding:
      var(--sheet-top-gap)
      env(safe-area-inset-right, 0px)
      0
      env(safe-area-inset-left, 0px);
  }

  .modal-sheet {
    width: 100%;
    max-height: var(--sheet-max-h);
    min-height: 0;
    border-radius: 1.2rem 1.2rem 0 0;
    border-bottom: 0;
  }

  .modal-sheet::before {
    content: "";
    display: block;
    width: 2.55rem;
    height: 0.28rem;
    margin: 0.45rem auto 0;
    border-radius: 999px;
    background: rgba(12, 36, 31, 0.2);
    flex: none;
  }

  .modal-sheet .editor {
    border-radius: 1.2rem 1.2rem 0 0;
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    overflow: hidden;
  }

  .modal-sheet-res,
  .modal-sheet-res-view,
  .modal-sheet-res-due {
    height: var(--sheet-max-h) !important;
    max-height: var(--sheet-max-h);
    min-height: 0 !important;
    flex: 1 1 auto;
    align-self: stretch;
  }

  .modal-sheet-res .editor.res-editor,
  .modal-sheet-res-view .editor,
  .modal-sheet-res-due .editor {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto !important;
    height: 100% !important;
    max-height: none !important;
    min-height: 0 !important;
  }

  .modal-sheet-res .editor-body.res-modal-body {
    flex: 1 1 auto !important;
    height: auto !important;
    max-height: none !important;
    min-height: 0 !important;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }

  .modal-sheet-res .form-actions,
  #modal-reservation .form-actions {
    position: relative;
    bottom: auto;
    flex: 0 0 auto;
    margin-top: auto;
  }

  .modal-sheet-mov-pick {
    border-radius: 1.2rem 1.2rem 0 0;
  }

  .modal-sheet .form-actions {
    padding-bottom: max(0.95rem, env(safe-area-inset-bottom));
  }

  .modal-sheet-res .editor-head.res-editor-head {
    padding: 0.2rem var(--pad) 0.7rem;
    gap: 0.5rem;
  }

  .modal-sheet-res .editor-head .eyebrow,
  .modal-sheet-res .res-modal-lead {
    display: none;
  }

  .modal-sheet-res .editor-head h2 {
    font-size: 1.12rem;
  }

  .modal-sheet-res .res-summary-dock {
    padding: 0.45rem var(--pad) 0.5rem;
    gap: 0.4rem;
  }

  .modal-sheet-res .res-summary-title {
    display: none;
  }

  .modal-sheet-res .res-section {
    padding: 0.8rem 0.85rem 0.85rem;
  }

  .modal-sheet-res .res-section-head {
    margin-bottom: 0.65rem;
    gap: 0.55rem;
    flex-wrap: wrap;
  }

  .modal-sheet-res .res-guest-search-toggle {
    margin-left: 2.4rem;
  }

  .modal-sheet-res .res-modal-form {
    gap: 0.7rem;
    padding: 0.7rem var(--pad) 0.9rem;
  }

  .modal-sheet-res .form-grid-dates-stay,
  .modal-sheet-res .form-grid-dates-cash {
    grid-template-columns: 1fr;
    gap: 0.65rem;
  }

  .modal-sheet-res .form-grid-money,
  .modal-sheet-res .form-grid-money-ota,
  .modal-sheet-res .form-grid-money-ops,
  .modal-sheet-res .form-grid-money-net {
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem;
  }

  .modal-sheet-res .form-grid-money-ota label:first-child,
  .modal-sheet-res .form-grid-money-net label {
    grid-column: 1 / -1;
  }

  .modal-sheet-res .res-money-block-ops,
  .modal-sheet-res .res-money-block-net {
    padding: 0.75rem;
  }

  .modal-sheet-res .form-grid-guest {
    grid-template-columns: 1fr 1fr;
  }

  .modal-sheet-res .form-grid-guest .span-all,
  .modal-sheet-res .form-grid-guest .res-guest-contact {
    grid-column: 1 / -1;
  }

  .modal-sheet-res .form-grid-guest > label:last-of-type {
    grid-column: 1 / -1;
  }

  .modal-sheet-report,
  .modal-sheet-exp-group {
    width: 100%;
    height: var(--sheet-max-h);
    max-height: var(--sheet-max-h);
  }

  .modal-sheet-report .report-modal-body {
    max-height: none;
  }

  .modal-sheet-exp-group .editor-head.exp-group-head {
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.55rem 0.65rem;
    padding: 0.2rem var(--pad) 0.75rem;
  }

  .exp-group-head-main {
    flex: 1 1 calc(100% - 3rem);
    min-width: 0;
  }

  .exp-group-avatar {
    width: 2.4rem;
    height: 2.4rem;
    font-size: 1.05rem;
    border-radius: 0.75rem;
  }

  .exp-group-head-copy h2 {
    font-size: 1.12rem;
  }

  .exp-group-body {
    gap: 0.7rem;
    padding-top: 0.7rem;
  }

  .exp-group-overview {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .exp-group-metric {
    padding: 0.62rem 0.7rem;
  }

  .exp-group-metric strong {
    font-size: 1rem;
  }

  .exp-pay-card:not(.exp-pay-card-compact) {
    padding: 0.8rem 0.85rem;
    gap: 0.4rem;
  }

  .exp-pay-card-compact {
    padding: 0.5rem 0.65rem;
  }

  .exp-pay-title {
    font-size: 0.9rem;
  }

  .exp-pay-amount {
    font-size: 0.9rem;
  }

  .exp-pay-details {
    gap: 0.35rem 0.5rem;
  }

  .exp-pay-actions {
    align-self: end;
  }

  .modal-sheet .form-actions.exp-group-actions {
    flex-direction: column;
  }

  #report-expenses-list .group-head {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: baseline;
  }

  #report-expenses-list .group-head h2 {
    font-size: 1rem;
  }

  #report-expenses-list .exp-group-total {
    width: auto;
    order: 0;
    padding: 0;
    background: transparent;
    font-size: 0.95rem;
  }

  .modal-sheet .editor-head.res-view-head {
    display: flex;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.15rem var(--pad) 0.75rem;
    row-gap: 0;
  }

  .modal-sheet .editor-head .btn-icon {
    flex: none;
  }

  .res-view-head-main {
    flex: 1 1 auto;
    min-width: 0;
    gap: 0.7rem;
  }

  .res-view-avatar {
    width: 2.55rem;
    height: 2.55rem;
    font-size: 1.1rem;
    border-radius: 0.8rem;
  }

  .res-view-lead {
    margin-top: 0.18rem;
    font-size: 0.8rem;
    line-height: 1.35;
  }

  .res-view-status {
    width: auto;
    align-self: center;
  }

  .res-view-body {
    gap: 0.7rem;
    padding-top: 0.75rem;
  }

  .res-view-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.4rem;
  }

  .res-view-kpi {
    padding: 0.55rem 0.5rem;
  }

  .res-view-kpi span {
    font-size: 0.6rem;
  }

  .res-view-kpi strong {
    font-size: 0.88rem;
  }

  .res-view-kpi:last-child {
    grid-column: auto;
  }

  .res-view-body .res-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.4rem;
  }

  .res-view-body .res-detail-item {
    padding: 0.4rem 0.5rem;
  }

  .modal-sheet .form-actions.res-view-actions {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
  }

  .modal-sheet .form-actions.res-view-actions [data-close="res-view"] {
    display: grid;
  }

  .modal-sheet .form-actions.res-view-actions .res-action-btn {
    flex: 1 1 0;
    width: auto;
    max-width: 3.4rem;
  }

  .row-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }

  .row-money {
    align-self: flex-end;
  }

  .row-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .row-actions .btn-ghost {
    width: 100%;
    flex: none;
  }

  .res-date-callout-inline {
    grid-template-columns: 1fr;
  }

  .preview-metrics {
    grid-template-columns: 1fr;
  }

  .stat-row,
  .kpi-grid {
    gap: 0.75rem;
  }

  .login-card {
    padding: 1.45rem 1.2rem 1.3rem;
  }

  .login-header h1 {
    font-size: clamp(1.7rem, 8vw, 2.1rem);
  }

  .success-card {
    width: min(100%, 20rem);
    margin: 1rem;
    padding: 1.75rem 1.35rem 1.5rem;
  }
}

@media (max-width: 767px) and (display-mode: standalone),
  (max-width: 767px) and (display-mode: fullscreen) {
  .modal {
    --sheet-top-gap: max(2.75rem, calc(env(safe-area-inset-top, 0px) + 0.55rem));
  }
}

@media (max-width: 1023px) and (max-height: 500px) {
  :root {
    --nav-h: 3.15rem;
  }

  .tab-label,
  .tab-label-short {
    display: none !important;
  }

  .tab {
    min-height: 2.55rem;
    padding: 0.35rem 0.1rem;
  }

  .tabs {
    padding-top: 0.2rem;
    padding-bottom: max(0.2rem, env(safe-area-inset-bottom));
  }
}

@media (max-width: 1023px) {
  body:has(.modal:not([hidden])) .tabs,
  body:has(.success-overlay:not([hidden])) .tabs {
    visibility: hidden;
    pointer-events: none;
  }
}

@media (hover: none) {
  .btn-primary:hover,
  .btn-ghost:hover,
  .tab:hover,
  .stat-chip:hover,
  .kpi-card:hover,
  .data-list > li:hover,
  .res-card:hover,
  .linen-row:hover,
  .login-points li:hover {
    transform: none;
  }

  .btn-ghost:hover {
    background: #fff4ea;
    color: #8a3e16;
    border-color: rgba(196, 92, 38, 0.55);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7), 0 6px 14px rgba(138, 62, 22, 0.1);
  }
}

/* Instalar PWA */
.install-steps {
  margin: 0;
  padding: 0 0 0 1.15rem;
  display: grid;
  gap: 0.75rem;
  font-size: 0.92rem;
  line-height: 1.5;
}

.install-steps li {
  padding-left: 0.15rem;
}

.install-modal-body {
  display: grid;
  gap: 1rem;
}

.install-preview {
  margin: 0;
  overflow: hidden;
  border-radius: 1.15rem;
  border: 1.5px solid rgba(12, 36, 31, 0.16);
  background: #0c241f;
  box-shadow: 0 16px 36px rgba(12, 36, 31, 0.18);
}

.install-preview img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 18rem;
  object-fit: cover;
  object-position: center top;
}

@media (max-width: 767px) {
  .install-preview img {
    max-height: 14.5rem;
  }
}

.install-home-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.7rem 0.8rem;
  border-radius: 0.95rem;
  background: rgba(12, 36, 31, 0.05);
  border: 1px solid rgba(12, 36, 31, 0.08);
}

.install-home-icon {
  flex: none;
  width: 3.1rem;
  height: 3.1rem;
  border-radius: 0.85rem;
  object-fit: cover;
  box-shadow: 0 8px 16px rgba(12, 36, 31, 0.18);
}

.install-home-row strong {
  display: block;
  font-size: 0.98rem;
  color: var(--brand);
}

.install-home-row span {
  display: block;
  margin-top: 0.12rem;
  font-size: 0.8rem;
  line-height: 1.35;
  color: var(--muted);
}

.install-note {
  margin: 0;
  padding: 0.75rem 0.85rem;
  border-radius: 0.75rem;
  background: rgba(12, 36, 31, 0.05);
  font-size: 0.84rem;
  line-height: 1.45;
}

.install-ready-panel {
  margin: 0.85rem 0 0;
  padding: 0.75rem 0.85rem;
  border-radius: 0.85rem;
  border: 1.5px solid rgba(31, 107, 87, 0.28);
  background: linear-gradient(180deg, #f3faf7 0%, #fff 100%);
}

.install-ready-copy {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--brand);
  font-weight: 600;
}

.modal-sheet-install .form-actions {
  padding-top: 0.75rem;
}

.modal-sheet-install .form-actions.install-actions {
  display: flex;
  gap: 0.55rem;
}

.modal-sheet-install .form-actions.install-actions .btn-ghost,
.modal-sheet-install .form-actions.install-actions .btn-primary {
  flex: 1;
}

#install-btn:not([hidden]) {
  font-weight: 700;
}

.panel-head > .report-header-actions {
  position: relative;
  z-index: 4;
  display: grid;
  grid-template-columns: repeat(3, 3.15rem);
  gap: 0.45rem;
  width: auto;
  padding: 0.38rem;
  border: 1px solid rgba(12, 36, 31, 0.12);
  border-radius: 1rem;
  background: rgba(255, 252, 247, 0.78);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 10px 28px rgba(12, 36, 31, 0.09);
  backdrop-filter: blur(10px);
}

.report-header-actions .report-action-btn {
  width: 3.15rem;
  min-width: 0;
  min-height: 3.15rem;
  padding: 0;
  overflow: visible;
  border-radius: 0.75rem;
  box-shadow: none;
}

.report-action-btn .report-action-label {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.report-action-icon {
  width: 1.38rem;
  height: 1.38rem;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.2s var(--ease);
}

#report-close-wizard {
  color: #8a4a22;
  border-color: rgba(196, 92, 38, 0.3);
  background: linear-gradient(180deg, #fffaf5, #f9e8d7);
}

#report-xlsx {
  color: #226442;
  border-color: rgba(34, 100, 66, 0.28);
  background: linear-gradient(180deg, #f8fff9, #e3f2e8);
}

#report-pdf {
  color: #fff;
  border: 1px solid rgba(105, 27, 27, 0.18);
  background: linear-gradient(155deg, #ba4b42, #8f2f2a);
  box-shadow: 0 7px 16px rgba(143, 47, 42, 0.2);
}

.report-action-btn:hover {
  transform: translateY(-2px);
}

.report-action-btn:hover .report-action-icon {
  transform: scale(1.08);
}

#report-close-wizard:hover {
  color: #fff;
  border-color: #b55225;
  background: linear-gradient(155deg, #d8773f, #a8441d);
}

#report-xlsx:hover {
  color: #fff;
  border-color: #27704b;
  background: linear-gradient(155deg, #3c8a61, #21613f);
}

#report-pdf:hover {
  background: linear-gradient(155deg, #c95a50, #862824);
  box-shadow: 0 10px 22px rgba(143, 47, 42, 0.28);
}

.report-action-btn::before {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  top: calc(100% + 0.55rem);
  z-index: 10;
  padding: 0.48rem 0.68rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.58rem;
  background: #102c25;
  color: #fff;
  box-shadow: 0 10px 24px rgba(12, 36, 31, 0.24);
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, -0.25rem);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.report-action-btn:hover::before,
.report-action-btn:focus-visible::before,
.report-action-btn:active::before {
  opacity: 1;
  transform: translate(-50%, 0);
}

@media (max-width: 767px) {
  .panel-head > .report-header-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: 100%;
  }

  .report-header-actions .report-action-btn {
    width: 100%;
  }
}

/* Nueva reserva: la hoja mide el contenido; el pie no puede quedar a media altura. */
#modal-reservation.modal {
  align-items: center;
  justify-content: center;
}

#modal-reservation .modal-sheet-res {
  display: block !important;
  height: max-content !important;
  max-height: min(90vh, 56rem) !important;
  min-height: 0 !important;
  flex: none !important;
  align-self: center !important;
  overflow: auto !important;
}

#modal-reservation #reservation-form.editor {
  display: block !important;
  height: auto !important;
  max-height: none !important;
  min-height: 0 !important;
  flex: none !important;
  margin: 0 !important;
  overflow: visible !important;
}

#modal-reservation .res-modal-body {
  display: block !important;
  height: auto !important;
  max-height: none !important;
  min-height: 0 !important;
  overflow: visible !important;
  flex: none !important;
}

#modal-reservation .res-editor-head {
  position: sticky;
  top: 0;
  z-index: 3;
}

#modal-reservation .form-actions {
  position: sticky;
  bottom: 0;
  z-index: 4;
  margin-top: 0 !important;
}

.res-cross-month-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 0.85rem 0 0.2rem;
  padding: 0.85rem 0.95rem;
  border: 1.5px solid rgba(196, 92, 38, 0.4);
  border-radius: 0.9rem;
  background:
    linear-gradient(180deg, rgba(196, 92, 38, 0.1), rgba(255, 252, 247, 0.96)),
    #fff;
}

.res-cross-month-banner.is-accepted {
  border-color: rgba(45, 106, 79, 0.4);
  background:
    linear-gradient(180deg, rgba(45, 106, 79, 0.08), rgba(255, 252, 247, 0.96)),
    #fff;
}

.res-cross-month-banner-copy {
  min-width: 0;
  flex: 1 1 12rem;
}

.res-cross-month-banner-copy strong {
  display: block;
  color: var(--brand);
  margin-bottom: 0.15rem;
}

.res-cross-month-banner .btn-ghost {
  flex: none;
}

.modal-sheet-cross-month {
  width: min(100%, 36rem);
}

.res-cross-month-rules {
  margin: 0.85rem 0 0;
  font-size: 0.82rem;
  line-height: 1.45;
}

.res-cross-month-alert {
  margin: 0.85rem var(--pad) 0.35rem;
  padding: 0.95rem 1rem 1rem;
  border: 1.5px solid rgba(196, 92, 38, 0.45);
  border-radius: 1rem;
  background:
    linear-gradient(180deg, rgba(196, 92, 38, 0.1), rgba(255, 252, 247, 0.96)),
    #fff;
  display: grid;
  gap: 0.75rem;
}

.res-cross-month-alert.is-accepted {
  border-color: rgba(45, 106, 79, 0.4);
  background:
    linear-gradient(180deg, rgba(45, 106, 79, 0.08), rgba(255, 252, 247, 0.96)),
    #fff;
}

.res-cross-month-head strong {
  display: block;
  color: var(--brand);
  margin-bottom: 0.2rem;
}

.res-cross-month-body {
  display: grid;
  gap: 0.65rem;
}

@media (min-width: 720px) {
  .res-cross-month-body {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.res-cross-month-card {
  padding: 0.7rem 0.8rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(12, 36, 31, 0.12);
  background: #fff;
  display: grid;
  gap: 0.25rem;
}

.res-cross-month-card ul {
  margin: 0.35rem 0 0;
  padding-left: 1.1rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.cfg-catalog-content {
  padding-top: 0.75rem;
}

.cfg-catalog-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-bottom: 0.55rem;
}

.cfg-catalog-admin {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0 auto 0 0;
  min-height: 2.25rem;
  padding: 0.18rem 0.45rem 0.18rem 0.65rem;
  border-radius: 0.65rem;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: rgba(255, 255, 255, 0.78);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.cfg-catalog-admin input {
  width: 3.6rem;
  min-height: 0;
  height: 1.7rem;
  margin: 0;
  padding: 0.12rem 0.2rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  color: var(--brand);
  font-variant-numeric: tabular-nums;
}

.cfg-catalog-admin input:hover,
.cfg-catalog-admin input:focus {
  border: 0;
  box-shadow: none;
  transform: none;
  background: transparent;
  outline: none;
}

.cfg-catalog-admin input::-webkit-outer-spin-button,
.cfg-catalog-admin input::-webkit-inner-spin-button {
  appearance: none;
  margin: 0;
}

.cfg-catalog-admin input[type="number"] {
  appearance: textfield;
}

.cfg-catalog-admin-suffix {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: none;
  color: var(--brand);
}

.cfg-slim-row-avatar-channel {
  background: rgba(138, 63, 18, 0.12);
  color: #8a3f12;
}

.cfg-slim-row-avatar-zone {
  background: rgba(31, 107, 74, 0.12);
  color: #1f6b4a;
}

.cfg-slim-row-avatar-unit {
  background: rgba(30, 82, 104, 0.12);
  color: #1e5268;
}

.cfg-slim-row-avatar-category {
  background: rgba(92, 74, 18, 0.12);
  color: #5c4a12;
}

.cfg-slim-row-avatar-collab {
  background: rgba(31, 79, 67, 0.12);
  color: #1f4f43;
}

.cfg-slim-row.is-inactive {
  opacity: 0.62;
}

.cfg-slim-row-static {
  cursor: default;
}

.cfg-slim-row-static:hover {
  transform: none;
  box-shadow: none;
  border-color: rgba(12, 36, 31, 0.11);
  background: rgba(255, 255, 255, 0.92);
}

.cfg-catalog-status {
  margin-top: 0.15rem;
}

.cfg-panel-icon-inventory {
  background: linear-gradient(155deg, #d08a3c, #9a3518);
  color: #fff;
}

.cfg-slim-row-avatar-inventory {
  background: rgba(154, 53, 24, 0.12);
  color: #9a3518;
}

.cfg-panel-icon-collaborators {
  background: linear-gradient(155deg, #3d7a5c, #1f4f43);
  color: #fff;
}

/* Cronograma de aseo â€” tablero de decisiones */
.aseo-summary {
  display: grid;
  gap: 0.85rem;
}

.schedule-week-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.schedule-week-label {
  display: grid;
  gap: 0.08rem;
  min-width: 11rem;
}

.schedule-week-label strong {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--brand);
}

.aseo-kpi-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
}

.aseo-kpi {
  padding: 0.75rem 0.85rem;
  border-radius: var(--radius-sm);
  background:
    linear-gradient(165deg, rgba(255, 252, 247, 0.95), rgba(247, 241, 230, 0.88));
  border: 1px solid var(--line);
  display: grid;
  gap: 0.15rem;
}

.aseo-kpi span {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.aseo-kpi strong {
  font-family: var(--font-display);
  font-size: 1.45rem;
  line-height: 1.1;
  color: var(--brand);
}

.aseo-kpi small {
  font-size: 0.72rem;
  color: var(--muted);
}

.aseo-kpi.is-warn {
  border-color: rgba(159, 31, 31, 0.28);
  background: linear-gradient(165deg, #fff8f6, #f8ece8);
}

.aseo-kpi.is-warn strong { color: var(--danger); }

.aseo-kpi.is-ok strong { color: var(--ok); }

.aseo-insight {
  margin: 0;
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: rgba(255, 252, 247, 0.9);
  font-size: 0.9rem;
  line-height: 1.4;
  color: var(--ink);
  animation: rise 0.45s var(--ease) both;
}

.aseo-insight[data-tone='warn'],
.aseo-insight[data-tone='alert'] {
  border-color: rgba(196, 92, 38, 0.35);
  background: linear-gradient(90deg, rgba(248, 230, 212, 0.75), rgba(255, 252, 247, 0.95));
}

.aseo-insight[data-tone='ok'] {
  border-color: rgba(26, 107, 72, 0.25);
  background: linear-gradient(90deg, rgba(26, 107, 72, 0.08), rgba(255, 252, 247, 0.95));
}

.aseo-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1rem;
  font-size: 0.72rem;
  color: var(--muted);
}

.aseo-legend span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.aseo-dot {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  display: inline-block;
}

.aseo-dot.is-free { background: rgba(12, 36, 31, 0.12); }
.aseo-dot.is-light { background: #3d8f6e; }
.aseo-dot.is-mid { background: #d0892e; }
.aseo-dot.is-heavy { background: #c45c26; }
.aseo-dot.is-warn { background: var(--danger); }

.aseo-section-head {
  display: grid;
  gap: 0.2rem;
  margin-bottom: 0.75rem;
}

.aseo-section-hint {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

.aseo-board {
  overflow-x: auto;
  padding-bottom: 0.35rem;
  border-radius: var(--radius);
}

.aseo-grid {
  display: grid;
  grid-template-columns: minmax(10rem, 12.5rem) repeat(var(--aseo-cols, 7), minmax(8.2rem, 1fr));
  gap: 0.4rem;
  min-width: 58rem;
}

.aseo-corner,
.aseo-day-head,
.aseo-person,
.aseo-cell {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
}

.aseo-corner {
  position: sticky;
  left: 0;
  z-index: 3;
  padding: 0.7rem 0.8rem;
  background: linear-gradient(160deg, var(--brand-3), var(--brand));
  color: #f6faf7;
  display: grid;
  gap: 0.15rem;
  align-content: center;
}

.aseo-corner span {
  font-family: var(--font-display);
  font-size: 1rem;
}

.aseo-corner small {
  font-size: 0.68rem;
  opacity: 0.75;
}

.aseo-day-head {
  padding: 0.55rem 0.5rem 0.6rem;
  text-align: center;
  display: grid;
  gap: 0.1rem;
  background: rgba(255, 252, 247, 0.92);
  transition: transform 0.2s var(--ease), border-color 0.2s var(--ease);
}

.aseo-day-name {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}

.aseo-day-num {
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--brand);
  line-height: 1;
}

.aseo-day-count {
  font-size: 0.68rem;
  color: var(--muted);
}

.aseo-day-head.is-today {
  border-color: rgba(196, 92, 38, 0.45);
  box-shadow: inset 0 -3px 0 var(--accent);
}

.aseo-day-head.is-mid { background: rgba(208, 137, 46, 0.1); }
.aseo-day-head.is-heavy { background: rgba(196, 92, 38, 0.14); }

.aseo-person {
  position: sticky;
  left: 0;
  z-index: 2;
  padding: 0.7rem 0.75rem;
  display: grid;
  gap: 0.45rem;
  align-content: start;
  background: rgba(255, 252, 247, 0.97);
  box-shadow: 4px 0 12px rgba(12, 36, 31, 0.04);
}

.aseo-person-top {
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
}

.aseo-person-rank {
  flex: none;
  width: 1.45rem;
  height: 1.45rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.7rem;
  font-weight: 700;
  background: linear-gradient(160deg, var(--brand-3), var(--brand));
  color: #f6faf7;
}

.aseo-person strong {
  display: block;
  font-size: 0.88rem;
  line-height: 1.2;
}

.aseo-person.is-unassigned {
  background: rgba(159, 31, 31, 0.06);
  border-style: dashed;
  border-color: rgba(159, 31, 31, 0.35);
}

.aseo-person.is-unassigned .aseo-person-rank {
  background: var(--danger);
}

.aseo-load {
  display: inline-block;
  margin-top: 0.2rem;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.12rem 0.42rem;
  border-radius: 999px;
}

.aseo-load.is-free,
.aseo-load.is-light { background: rgba(26, 107, 72, 0.12); color: var(--ok); }
.aseo-load.is-mid { background: rgba(208, 137, 46, 0.16); color: #8a5a00; }
.aseo-load.is-heavy { background: rgba(196, 92, 38, 0.16); color: #9a3f12; }
.aseo-load.is-warn { background: rgba(159, 31, 31, 0.14); color: var(--danger); }

.aseo-load-bar {
  height: 0.35rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.08);
  overflow: hidden;
}

.aseo-load-bar > i {
  display: block;
  height: 100%;
  width: var(--load-pct, 0%);
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand-3), var(--accent));
  transition: width 0.55s var(--ease);
}

.aseo-cell {
  min-height: 5.4rem;
  padding: 0.4rem;
  display: grid;
  gap: 0.35rem;
  align-content: start;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease);
}

.aseo-cell.is-free { background: rgba(12, 36, 31, 0.02); }
.aseo-cell.is-light { background: rgba(26, 107, 72, 0.06); }
.aseo-cell.is-mid { background: rgba(208, 137, 46, 0.1); }
.aseo-cell.is-heavy {
  background: rgba(196, 92, 38, 0.12);
  border-color: rgba(196, 92, 38, 0.28);
}
.aseo-cell.is-warn {
  background: rgba(159, 31, 31, 0.07);
  border-style: dashed;
  border-color: rgba(159, 31, 31, 0.3);
}
.aseo-cell.is-today {
  box-shadow: inset 0 0 0 1px rgba(196, 92, 38, 0.28);
}

.aseo-cell-empty {
  color: var(--muted);
  font-size: 0.72rem;
  text-align: center;
  padding: 1.1rem 0.2rem;
  opacity: 0.7;
}

.aseo-job-card {
  display: grid;
  gap: 0.18rem;
  text-align: left;
  width: 100%;
  border: 1px solid rgba(12, 36, 31, 0.1);
  background: rgba(255, 252, 247, 0.96);
  border-radius: 10px;
  padding: 0.42rem 0.48rem;
  cursor: pointer;
  transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease), border-color 0.18s var(--ease);
  border-left-width: 3px;
}

.aseo-job-card.tone-bota { border-left-color: #1f4f43; }
.aseo-job-card.tone-acacias { border-left-color: #3d7a5c; }
.aseo-job-card.tone-conquistador { border-left-color: var(--accent); }
.aseo-job-card.tone-default { border-left-color: var(--gold); }
.aseo-job-card.is-done { opacity: 0.58; }

.aseo-job-top {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.aseo-job-avatar {
  flex: none;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.58rem;
  font-weight: 700;
  background: rgba(12, 36, 31, 0.08);
  color: var(--brand);
}

.aseo-job-unit {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--ink);
}

.aseo-job-zone {
  font-size: 0.66rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.aseo-job-guest {
  font-size: 0.72rem;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.aseo-job-meta {
  display: flex;
  justify-content: space-between;
  gap: 0.25rem;
  font-size: 0.64rem;
  color: var(--muted);
  border-top: 1px solid rgba(12, 36, 31, 0.06);
  padding-top: 0.2rem;
  margin-top: 0.1rem;
}

.aseo-job-meta strong {
  color: var(--brand);
  font-size: 0.64rem;
}

.aseo-job-card:hover,
.aseo-job-card:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(12, 36, 31, 0.22);
  box-shadow: 0 8px 18px rgba(12, 36, 31, 0.1);
  outline: none;
}

.aseo-empty {
  padding: 1.5rem;
  border-radius: var(--radius);
  border: 1px dashed var(--line-strong);
  background: rgba(255, 252, 247, 0.8);
  text-align: center;
}

.aseo-empty strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin-bottom: 0.35rem;
}

.aseo-empty p {
  margin: 0;
  color: var(--muted);
}

.aseo-mobile-list {
  display: none;
  gap: 0.85rem;
}

.aseo-mobile-people {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
}

.aseo-mobile-person-card {
  padding: 0.65rem 0.7rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--paper);
  display: grid;
  gap: 0.4rem;
}

.aseo-mobile-person-card header {
  display: flex;
  justify-content: space-between;
  gap: 0.4rem;
  align-items: center;
}

.aseo-mobile-day {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.85rem;
  background: var(--paper);
}

.aseo-mobile-day.is-today {
  border-color: rgba(196, 92, 38, 0.4);
  box-shadow: inset 0 0 0 1px rgba(196, 92, 38, 0.12);
}

.aseo-mobile-day.is-heavy {
  background: linear-gradient(180deg, rgba(196, 92, 38, 0.08), var(--paper));
}

.aseo-mobile-day header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.65rem;
  gap: 0.5rem;
}

.aseo-mobile-day header > div {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.aseo-today-pill {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.15rem 0.4rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: #9a3f12;
}

.aseo-mobile-day ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}

.aseo-mobile-day li.is-unassigned .aseo-job-card {
  border-color: rgba(159, 31, 31, 0.28);
}

.aseo-mobile-person {
  margin: 0.25rem 0 0;
  font-size: 0.72rem;
  color: var(--muted);
}

.aseo-mobile-empty {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}

@media (max-width: 1100px) {
  .aseo-kpi-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .aseo-board { display: none; }
  .aseo-mobile-list { display: grid; }
  .schedule-week-label strong { font-size: 1rem; }
}

@media (max-width: 520px) {
  .aseo-mobile-people {
    grid-template-columns: 1fr;
  }
  .aseo-kpi-strip {
    grid-template-columns: 1fr 1fr;
  }
}

.login-campo-link {
  margin: 0.75rem 0 0;
  font-size: 0.92rem;
  color: var(--muted);
}
.login-campo-link a {
  color: var(--accent);
  font-weight: 600;
}

.linen-board {
  display: grid;
  gap: 1.15rem;
}

.linen-legend .linen-dot {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  display: inline-block;
}

.linen-dot.is-puesto { background: var(--ok); }
.linen-dot.is-lavando { background: var(--accent); }
.linen-dot.is-bodega { background: var(--gold); }

.linen-zone-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0 0 0.55rem;
}

.linen-zone-head h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.12rem;
  letter-spacing: -0.02em;
  color: var(--brand);
}

.linen-zone-head span {
  font-size: 0.78rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.linen-zone-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.linen-row {
  appearance: none;
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 0.95rem;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #fff 0%, #faf7f2 100%);
  box-shadow: 0 2px 8px rgba(12, 36, 31, 0.04);
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  transition:
    border-color 0.22s var(--ease),
    box-shadow 0.22s var(--ease),
    transform 0.22s var(--ease);
}

.linen-row:hover {
  border-color: rgba(196, 92, 38, 0.35);
  box-shadow: 0 8px 22px rgba(12, 36, 31, 0.08);
  transform: translateY(-1px);
}

.linen-row:focus-visible {
  outline: 2px solid rgba(196, 92, 38, 0.55);
  outline-offset: 2px;
}

.linen-row.has-alert {
  border-color: rgba(196, 92, 38, 0.42);
  background: linear-gradient(180deg, #fff8f1 0%, #f7efe6 100%);
}

.linen-row-mark {
  flex: none;
  min-width: 2.7rem;
  height: 2.7rem;
  padding: 0 0.45rem;
  display: grid;
  place-items: center;
  border-radius: 0.8rem;
  background: linear-gradient(155deg, #1f4f43, #0c241f);
  color: #fff8f1;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.linen-row-body {
  display: grid;
  gap: 0.32rem;
  min-width: 0;
}

.linen-row-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 0.75rem;
  flex-wrap: wrap;
}

.linen-row-head strong {
  font-size: 1.02rem;
  font-weight: 650;
  color: var(--brand);
}

.linen-row-flags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.linen-row-meta,
.linen-row-next {
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.4;
}

.linen-row-next { color: #5a4a3a; }

.linen-flag {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  background: rgba(196, 92, 38, 0.12);
  color: var(--accent);
}

.linen-flag.is-loc {
  background: rgba(12, 36, 31, 0.1);
  color: #0c241f;
}
.linen-flag.is-warn {
  background: rgba(159, 31, 31, 0.1);
  color: var(--danger);
}

.linen-flag.is-alert {
  background: var(--accent-soft);
  color: #8a3f12;
}

.linen-roster {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}
.linen-roster li {
  display: grid;
  grid-template-columns: 4.4rem 1fr;
  grid-template-rows: auto auto;
  column-gap: 0.65rem;
  row-gap: 0.05rem;
  padding: 0.55rem 0.7rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(12, 36, 31, 0.12);
  background: #fff;
}
.linen-roster em {
  grid-row: 1 / 3;
  align-self: center;
  font-style: normal;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.linen-roster strong {
  font-size: 0.95rem;
  color: var(--brand);
}
.linen-roster span {
  font-size: 0.78rem;
  color: var(--muted);
}
.linen-roster.is-compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.3rem;
}
.linen-roster.is-compact li {
  grid-template-columns: 1fr;
  grid-template-rows: auto auto;
  padding: 0.4rem 0.4rem 0.45rem;
  text-align: center;
}
.linen-roster.is-compact em {
  grid-row: auto;
  font-size: 0.62rem;
}
.linen-roster.is-compact strong {
  font-size: 0.78rem;
  line-height: 1.2;
}
.linen-roster .is-puesto {
  background: rgba(26, 107, 72, 0.08);
  border-color: rgba(26, 107, 72, 0.22);
}
.linen-roster .is-lavando {
  background: var(--accent-soft);
  border-color: rgba(196, 92, 38, 0.28);
}
.linen-roster .is-bodega {
  background: rgba(201, 161, 91, 0.16);
  border-color: rgba(201, 161, 91, 0.4);
}
.linen-set-place {
  margin: 0.15rem 0 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.linen-cycle.is-compact {
  margin-top: 0.15rem;
}

.linen-stop {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.22rem 0.55rem 0.22rem 0.28rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.74rem;
  font-weight: 650;
  line-height: 1;
}

.linen-stop em {
  min-width: 1.15rem;
  height: 1.15rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  font-style: normal;
  font-size: 0.72rem;
  font-weight: 800;
  background: currentColor;
  color: #fff;
}

.linen-stop.is-puesto {
  background: rgba(26, 107, 72, 0.1);
  color: var(--ok);
  border-color: rgba(26, 107, 72, 0.18);
}
.linen-stop.is-puesto em { background: var(--ok); color: #fff; }

.linen-stop.is-lavando {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: rgba(196, 92, 38, 0.2);
}
.linen-stop.is-lavando em { background: var(--accent); color: #fff; }

.linen-stop.is-bodega {
  background: rgba(201, 161, 91, 0.16);
  color: #7a5a22;
  border-color: rgba(201, 161, 91, 0.35);
}
.linen-stop.is-bodega em { background: var(--gold); color: #fff; }

.linen-stop.is-empty {
  opacity: 0.45;
}

.linen-cycle-arrow {
  width: 0.7rem;
  align-self: center;
  height: 0.7rem;
  border-right: 2px solid rgba(12, 36, 31, 0.22);
  border-bottom: 2px solid rgba(12, 36, 31, 0.22);
  transform: rotate(-45deg);
  margin: 0 0.05rem;
}

.modal-sheet-linen {
  width: min(100%, 40rem);
}
.modal-sheet-linen .editor-head {
  padding-bottom: 0.65rem;
}
.modal-sheet-linen .editor-body {
  padding: 0.5rem var(--pad) 0.65rem;
}
.modal-sheet-linen .form-actions {
  padding: 0.65rem var(--pad) 0.8rem;
}
.linen-sheet {
  display: grid;
  gap: 0.55rem;
}

.inv-open-btn {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  margin: 0;
  padding: 0.85rem 0.95rem;
  border: 1.5px solid rgba(154, 69, 24, 0.28);
  border-radius: 1rem;
  background:
    linear-gradient(135deg, rgba(196, 92, 38, 0.14), rgba(255, 252, 247, 0.96) 42%),
    #fff;
  box-shadow: 0 8px 22px rgba(154, 69, 24, 0.1);
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
}

.inv-open-btn:hover,
.inv-open-btn:focus-visible {
  border-color: rgba(154, 69, 24, 0.5);
  transform: none;
  outline: none;
}

.inv-open-ico {
  width: 2.55rem;
  height: 2.55rem;
  display: grid;
  place-items: center;
  border-radius: 0.85rem;
  background: linear-gradient(160deg, #c45c26, #9a3518);
  color: #fff;
  flex: none;
}

.inv-open-ico svg {
  width: 1.25rem;
  height: 1.25rem;
}

.inv-open-copy {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.inv-open-copy strong {
  font-size: 0.98rem;
  color: var(--brand);
}

.inv-open-copy em {
  font-style: normal;
  font-size: 0.78rem;
  color: var(--muted);
}

.inv-open-arrow {
  color: #9a3518;
  font-size: 1.35rem;
  font-weight: 500;
}

.modal-sheet-inventory {
  width: min(100%, 36rem);
  max-height: min(90vh, 52rem);
}

.modal-sheet-inventory .editor-body {
  padding: 0.45rem var(--pad) 0.7rem;
}

.inv-board {
  display: grid;
  gap: 0.55rem;
}

.inv-empty-copy {
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.4;
}

.inv-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.inv-count {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.inv-filter-wrap {
  flex: 1 1 10rem;
  min-width: 0;
  max-width: 16rem;
  margin: 0;
}

.inv-filter {
  width: 100%;
  min-height: 2.15rem;
  padding: 0.35rem 0.7rem;
  font-size: 0.84rem;
}

.inv-item-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  overflow: visible;
}

.inv-groups {
  display: grid;
  gap: 0.45rem;
}

.inv-group {
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  border-radius: 0.9rem;
  background: #fff;
  overflow: hidden;
}

.inv-group[hidden] {
  display: none !important;
}

.inv-group > summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  min-height: 2.4rem;
  padding: 0.45rem 0.75rem;
  cursor: pointer;
  background: rgba(12, 36, 31, 0.03);
  font-size: 0.84rem;
  font-weight: 750;
  color: var(--ink);
}

.inv-group > summary::-webkit-details-marker {
  display: none;
}

.inv-group-name {
  min-width: 0;
}

.inv-group-count {
  flex: none;
  min-width: 1.5rem;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.08);
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.inv-group .inv-item-list {
  border-top: 1px solid rgba(12, 36, 31, 0.08);
}

.inv-item-row {
  display: grid;
  grid-template-columns: 1.7rem minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 0.45rem;
  min-height: 2.2rem;
  padding: 0.28rem 0.45rem 0.28rem 0.65rem;
  border: 0;
  border-bottom: 1px solid rgba(12, 36, 31, 0.08);
  border-radius: 0;
  background: transparent;
}

.inv-item-row:nth-child(even) {
  background: rgba(12, 36, 31, 0.025);
}

.inv-item-row:last-child {
  border-bottom: 0;
}

.inv-item-row[hidden] {
  display: none !important;
}

.inv-item-n {
  font-size: 0.68rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  color: #8a6a4a;
  font-variant-numeric: tabular-nums;
}

.inv-item-row strong {
  font-size: 0.86rem;
  font-weight: 650;
  line-height: 1.25;
}

.inv-item-qty {
  flex: none;
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.inv-item-del {
  border: 0;
  background: none;
  color: var(--muted);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0.28rem 0.45rem;
  border-radius: 0.45rem;
}

.inv-item-del:hover,
.inv-item-del:focus-visible {
  color: var(--danger);
  background: rgba(159, 31, 31, 0.08);
  outline: none;
}

.inv-filter-empty {
  margin: 0;
  padding: 0.2rem 0.1rem 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.inv-last-check {
  margin: 0;
  padding: 0.55rem 0.7rem;
  border-radius: 0.75rem;
  border: 1.5px solid rgba(12, 36, 31, 0.1);
  background: #f6f1e8;
}

.inv-last-check.is-issues {
  border-color: rgba(159, 31, 31, 0.28);
  background: #f8ece8;
}

.inv-last-check p {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.35;
}

.inv-last-check strong {
  display: block;
  margin-bottom: 0.12rem;
  font-size: 0.74rem;
}

.inv-add-bar {
  display: grid;
  gap: 0.55rem;
  padding: 0.75rem var(--pad) 0.85rem;
  border-top: 1.5px solid rgba(12, 36, 31, 0.1);
  background: #faf7f2;
}

.inv-add-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) 4.2rem;
  gap: 0.45rem;
}

@media (max-width: 520px) {
  .inv-add-grid {
    grid-template-columns: 1fr 4.2rem;
  }
  .inv-add-grid #inv-add-name {
    grid-column: 1 / -1;
  }
}

.inv-add-bar input[type="text"],
.inv-add-bar input:not([type="checkbox"]) {
  width: 100%;
}

.inv-add-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.inv-add-all {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0;
  font-size: 0.78rem;
  font-weight: 650;
  color: var(--muted);
  cursor: pointer;
  user-select: none;
}

.inv-add-all input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

.inv-add-switch {
  width: 1.85rem;
  height: 1.05rem;
  flex: none;
  border-radius: 999px;
  background: rgba(12, 36, 31, 0.16);
  position: relative;
  transition: background 0.2s ease;
}

.inv-add-switch::after {
  content: "";
  position: absolute;
  top: 0.12rem;
  left: 0.12rem;
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px rgba(12, 36, 31, 0.2);
  transition: transform 0.2s var(--ease);
}

.inv-add-all input:checked + .inv-add-switch {
  background: var(--ok);
}

.inv-add-all input:checked + .inv-add-switch::after {
  transform: translateX(0.78rem);
}

.inv-add-all input:focus-visible + .inv-add-switch {
  box-shadow: 0 0 0 3px rgba(12, 36, 31, 0.12);
}

.inv-add-submit {
  min-width: 7.5rem;
  min-height: 2.35rem;
  padding: 0.45rem 0.9rem;
  width: auto;
}

.linen-block {
  display: grid;
  gap: 0.3rem;
}
.linen-block.is-valija {
  padding: 0.7rem 0.75rem 0.8rem;
  border-radius: 0.95rem;
  border: 1px dashed rgba(12, 36, 31, 0.2);
  background: rgba(12, 36, 31, 0.035);
}
.linen-block.is-valija .linen-ops-note {
  margin: 0 0 0.5rem;
}
.linen-sheet .linen-ops-label {
  margin: 0;
}
.linen-sheet-next {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.35;
}
.linen-sheet .linen-alert {
  margin: 0;
  padding: 0.5rem 0.7rem;
  font-size: 0.8rem;
}
.linen-set.is-tight {
  margin: 0 0 0.45rem;
  padding: 0.6rem 0.7rem 0.65rem;
}
.linen-set.is-tight:last-child {
  margin-bottom: 0;
}
.linen-set.is-tight header {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "kicker flag"
    "title flag"
    "place flag";
  gap: 0.05rem 0.5rem;
  margin: 0 0 0.4rem;
  align-items: start;
}
.linen-set.is-tight .linen-set-kicker { grid-area: kicker; margin: 0; }
.linen-set.is-tight header h3 {
  grid-area: title;
  font-size: 1rem;
}
.linen-set.is-tight .linen-set-place {
  grid-area: place;
  margin: 0;
  font-size: 0.78rem;
}
.linen-set.is-tight .linen-flag { grid-area: flag; }
.linen-set.is-tight .linen-ops {
  margin: 0 0 0.4rem;
}
.linen-set.is-tight .linen-op {
  min-height: 2.2rem;
  padding: 0.35rem 0.3rem;
}
.linen-set.is-tight .linen-op span { display: none; }
.linen-set.is-tight .linen-pieces { gap: 0.28rem; }
.linen-sheet .linen-history { margin: 0; }

.linen-modal-guide {
  flex: none;
  padding: 0.9rem var(--pad) 1rem;
  border-bottom: 1.5px solid rgba(12, 36, 31, 0.1);
  background:
    linear-gradient(180deg, rgba(248, 230, 212, 0.55), rgba(255, 252, 247, 0.96));
}

.linen-cycle-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.5rem;
  grid-template-columns: 1fr;
}

.linen-cycle-steps li {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 0.55rem;
  align-items: start;
}

.linen-cycle-num {
  grid-row: 1 / span 2;
  width: 1.45rem;
  height: 1.45rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--brand);
  color: #fff8f1;
  font-size: 0.75rem;
  font-weight: 800;
}

.linen-cycle-steps strong {
  font-size: 0.82rem;
  color: var(--brand);
}

.linen-cycle-steps span:last-child {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.35;
}

.linen-modal-guide-note {
  margin: 0.75rem 0 0;
  font-size: 0.8rem;
  line-height: 1.4;
  color: #5a4a3a;
}

.linen-bag-here {
  margin: 0;
  padding: 0.7rem 0.85rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(12, 36, 31, 0.12);
  font-size: 0.95rem;
  line-height: 1.35;
}
.linen-bag-here.is-loc-apto {
  background: rgba(26, 107, 72, 0.08);
  border-color: rgba(26, 107, 72, 0.22);
}
.linen-bag-here.is-loc-camino {
  background: var(--accent-soft);
  border-color: rgba(196, 92, 38, 0.28);
}
.linen-bag-here.is-loc-laundry {
  background: rgba(201, 161, 91, 0.16);
  border-color: rgba(201, 161, 91, 0.4);
}
.linen-loc-fix {
  margin: 0.75rem 0 1rem;
}

.linen-modal-status {
  display: grid;
  gap: 0.75rem;
  margin: 0.85rem 0 1rem;
}

.linen-next-card {
  padding: 0.85rem 0.95rem;
  border-radius: var(--radius-sm);
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  background: #fff;
}

.linen-next-card span {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.linen-next-card strong {
  display: block;
  margin: 0.2rem 0 0.25rem;
  font-size: 1rem;
  color: var(--brand);
}

.linen-next-card p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.linen-next-card.is-idle {
  background: rgba(12, 36, 31, 0.03);
}

.linen-alert {
  margin: 0.75rem 0 0;
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(196, 92, 38, 0.28);
  background: var(--accent-soft);
  font-size: 0.88rem;
  line-height: 1.4;
}

.linen-alert.is-warn {
  border-color: rgba(159, 31, 31, 0.28);
  background: #f8ece8;
}

.linen-set {
  margin: 0 0 0.85rem;
  padding: 0.95rem 1rem 1rem;
  border-radius: 1rem;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  background: #fff;
}

.linen-set.is-puesto { border-color: rgba(26, 107, 72, 0.28); }
.linen-set.is-lavando { border-color: rgba(196, 92, 38, 0.32); }
.linen-set.is-bodega { border-color: rgba(201, 161, 91, 0.4); }

.linen-set header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.65rem;
  margin-bottom: 0.4rem;
}

.linen-set-kicker {
  margin: 0 0 0.15rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.linen-set header h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: -0.02em;
  color: var(--brand);
}

.linen-set-help {
  margin: 0 0 0.85rem;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--ink);
}

.linen-ops-label {
  margin: 0 0 0.4rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.linen-ops {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.4rem;
}

.linen-ops.is-row {
  margin: 0;
}
.linen-set-movers {
  display: grid;
  gap: 0.55rem;
}
.linen-set-move .linen-ops-label {
  margin-bottom: 0.3rem;
}
.linen-set-move .linen-op {
  min-height: 2.35rem;
  padding: 0.35rem 0.3rem;
}
.linen-row-move .linen-op {
  min-height: 2.4rem;
  padding: 0.4rem 0.3rem;
}
.linen-row-move .linen-op span {
  display: none;
}

.linen-op {
  appearance: none;
  display: grid;
  gap: 0.12rem;
  padding: 0.55rem 0.45rem 0.6rem;
  border-radius: 0.75rem;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  background: #fff;
  color: inherit;
  font: inherit;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s var(--ease);
}

.linen-op strong {
  font-size: 0.8rem;
  color: var(--brand);
}
.linen-op.is-on strong {
  color: inherit;
}

.linen-op span {
  font-size: 0.68rem;
  color: var(--muted);
  line-height: 1.25;
}

.linen-op:hover {
  transform: translateY(-1px);
  border-color: rgba(12, 36, 31, 0.28);
}

.linen-op.is-on {
  font-weight: 700;
  box-shadow: inset 0 0 0 1px currentColor;
}
.linen-op.is-on.is-loc-apto {
  background: rgba(26, 107, 72, 0.12);
  border-color: var(--ok);
  color: var(--ok);
}
.linen-op.is-on.is-loc-camino {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}
.linen-op.is-on.is-loc-laundry {
  background: rgba(201, 161, 91, 0.22);
  border-color: var(--gold);
  color: #7a5a18;
}
.linen-op.is-on.is-puesto {
  background: rgba(26, 107, 72, 0.12);
  border-color: var(--ok);
}
.linen-op.is-on.is-lavando {
  background: var(--accent-soft);
  border-color: var(--accent);
}
.linen-op.is-on.is-bodega {
  background: rgba(201, 161, 91, 0.2);
  border-color: var(--gold);
}

.linen-ops-note {
  margin: 0.4rem 0 0.85rem;
  font-size: 0.76rem;
  line-height: 1.4;
  color: var(--muted);
}

.linen-pieces {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.linen-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  padding: 0.38rem 0.7rem;
  border-radius: 999px;
  border: 1.5px solid rgba(12, 36, 31, 0.14);
  background: #fff;
  font-size: 0.78rem;
  font-weight: 650;
  color: var(--muted);
  cursor: pointer;
}

.linen-chip input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.linen-chip.is-on {
  border-color: rgba(26, 107, 72, 0.35);
  background: rgba(26, 107, 72, 0.1);
  color: var(--ok);
}

.linen-chip.is-on span::before {
  content: "\2713\00a0";
}

.linen-history {
  margin: 1.1rem 0 0.4rem;
  border: 1.5px solid rgba(12, 36, 31, 0.12);
  border-radius: var(--radius-sm);
  background: #fff;
  overflow: hidden;
}

.linen-history-toggle {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  width: 100%;
  padding: 0.8rem 0.95rem;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 650;
  color: var(--brand);
}

.linen-history-toggle:hover {
  background: rgba(12, 36, 31, 0.03);
}

.linen-history-toggle::-webkit-details-marker {
  display: none;
}

.linen-history-toggle::after {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  border-right: 2px solid var(--brand);
  border-bottom: 2px solid var(--brand);
  transform: rotate(45deg);
  transition: transform 0.2s var(--ease);
  flex: none;
}

.linen-history[open] .linen-history-toggle::after {
  transform: rotate(-135deg);
  margin-top: 0.25rem;
}

.linen-history-meta {
  margin-left: auto;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.linen-history .linen-timeline {
  padding: 0 0.95rem 0.75rem;
  border-top: 1px solid rgba(12, 36, 31, 0.08);
}

.linen-timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
}

.linen-timeline li {
  display: grid;
  grid-template-columns: 7.2rem 1fr;
  gap: 0.65rem;
  padding: 0.55rem 0.15rem 0.55rem 0;
  border-bottom: 1px solid rgba(12, 36, 31, 0.08);
  font-size: 0.84rem;
}

.linen-timeline time {
  color: var(--muted);
  font-size: 0.75rem;
}

.linen-timeline strong {
  display: block;
  color: var(--brand);
}

.linen-timeline span {
  color: var(--muted);
}

.linen-timeline .is-empty {
  display: block;
  color: var(--muted);
  border: 0;
}

.linen-board > .empty-state {
  padding: 1.7rem 1.1rem;
  text-align: center;
  color: var(--muted);
  border: 1.5px dashed rgba(12, 36, 31, 0.22);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.55);
}

@media (min-width: 720px) {
  .linen-cycle-steps {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.65rem;
  }

  .linen-cycle-steps li {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .linen-cycle-num {
    grid-row: auto;
    margin-bottom: 0.2rem;
  }

  .linen-modal-status {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

@media (max-width: 640px) {
  .linen-row {
    grid-template-columns: auto minmax(0, 1fr);
    padding: 0.85rem 0.85rem;
  }

  .linen-row .res-card-chevron {
    display: none;
  }

  .linen-ops {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .linen-timeline li {
    grid-template-columns: 1fr;
    gap: 0.15rem;
  }
}

