:root {
  --bg: #edf4f7;
  --bg-deep: #0c1c28;
  --ink: #173042;
  --muted: #5f7688;
  --line: rgba(23, 48, 66, 0.1);
  --panel: rgba(255, 255, 255, 0.8);
  --panel-strong: #ffffff;
  --sidebar: linear-gradient(180deg, #0f2231 0%, #17364a 100%);
  --sidebar-2: rgba(255, 255, 255, 0.06);
  --accent: #0f9d94;
  --accent-strong: #0b7d76;
  --gold: #e0b43b;
  --green: #1d8d72;
  --red: #d04f4f;
  --shadow-xl: 0 30px 80px rgba(17, 42, 61, 0.14);
  --shadow-lg: 0 18px 48px rgba(17, 42, 61, 0.1);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
}

* { box-sizing: border-box; }

html, body { min-height: 100%; }

body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 0% 0%, rgba(15, 157, 148, 0.12), transparent 22%),
    radial-gradient(circle at 100% 0%, rgba(14, 93, 161, 0.12), transparent 24%),
    linear-gradient(180deg, #f6fbfc 0%, #e9f1f5 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    linear-gradient(rgba(15, 23, 32, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 23, 32, 0.025) 1px, transparent 1px);
  background-size: 84px 84px;
  mask-image: radial-gradient(circle at center, black 35%, transparent 95%);
  pointer-events: none;
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }

.loading-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(9, 22, 31, 0.42);
  backdrop-filter: blur(10px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
  z-index: 9999;
}

.loading-overlay.is-visible {
  opacity: 1;
  visibility: visible;
}

.loading-card {
  min-width: 280px;
  padding: 28px 30px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 28px 60px rgba(9, 22, 31, 0.22);
  display: grid;
  justify-items: center;
  gap: 10px;
  text-align: center;
}

.loading-card strong {
  font-family: "Sora", sans-serif;
  color: var(--ink);
}

.loading-card span {
  color: var(--muted);
}

.loading-spinner {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 4px solid rgba(15, 157, 148, 0.18);
  border-top-color: var(--accent);
  animation: spinLoading 0.8s linear infinite;
}

@keyframes spinLoading {
  to {
    transform: rotate(360deg);
  }
}

.portal-screen,
.login-screen,
.field-layout {
  min-height: 100vh;
  padding: 22px;
}

.portal-screen.active-screen {
  display: grid;
  grid-template-columns: 310px 1fr;
  gap: 22px;
}

.sidebar-shell {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.login-panel {
    min-height: calc(100vh - 44px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 28px;
    width: 100%;
}

.brand-block,
.login-card,
.hero-panel,
.stat-card,
.list-panel,
.details-panel,
.table-panel,
.single-form-panel,
.review-hero,
.field-form-shell,
.field-card-preview {
  background: var(--panel);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow-xl);
}

.sidebar {
  background: var(--sidebar);
  color: #eaf1f6;
  border-radius: 34px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: 0 30px 70px rgba(12, 18, 27, 0.34);
}

.sidebar-brand {
  padding: 8px 8px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.brand-tag {
  display: inline-flex;
  width: fit-content;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  color: #d4e5ef;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-weight: 800;
}

.sidebar-brand p {
  margin: 14px 0 0;
  color: #9db1c2;
  line-height: 1.6;
}

.nav-menu {
  display: grid;
  gap: 10px;
}

.nav-item {
  display: block;
  padding: 14px 16px;
  border-radius: 18px;
  color: #dbe7f0;
  font-weight: 800;
  border: 1px solid transparent;
  transition: 0.2s ease;
}

.nav-item:hover,
.nav-item.active {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.08);
}

.nav-item-highlight {
  background: linear-gradient(135deg, rgba(15, 157, 148, 0.28), rgba(52, 211, 153, 0.12));
}

.sidebar-metric {
  padding: 18px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
}

.sidebar-metric span,
.sidebar-metric small {
  display: block;
  color: #9eb0be;
}

.sidebar-metric strong {
  display: block;
  margin: 10px 0 6px;
  font-family: "Sora", sans-serif;
  font-size: 2.6rem;
  color: #fff7e9;
}

.profile-card {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.08);
}

.profile-avatar {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent), #46b8c9);
  color: white;
  font-weight: 800;
}

.profile-card strong,
.profile-card span {
  display: block;
}

.profile-card span {
  color: #9fb1c0;
  font-size: 0.9rem;
}

.main-content {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.message-stack {
  display: grid;
  gap: 10px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.topbar h1,
.login-card h2,
.brand-block h1,
.hero-panel h2,
.review-hero h2,
.field-hero h1,
.field-section-title h2,
.checklist-header h2,
.list-panel h3,
.details-panel h3,
.table-panel h3,
.upload-card h3 {
  font-family: "Sora", sans-serif;
}

.topbar h1 {
  font-size: clamp(2rem, 3vw, 3.2rem);
  margin: 6px 0 0;
}

.eyebrow,
.brand-kicker {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  font-weight: 800;
  color: #0f7c96;
}

.topbar-actions,
.filter-pill,
.login-form,
.action-row,
.form-row,
.checklist-header,
.field-topbar {
  display: flex;
}

.topbar-actions {
  align-items: center;
  gap: 12px;
}

.filter-pill {
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.78);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-lg);
}

.filter-form {
  margin: 0;
}

.filter-pill-form {
  min-width: 320px;
}

.filter-pill span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.filter-pill select {
  border: 0;
  background: transparent;
  padding: 0;
  min-width: 150px;
  font-weight: 800;
  color: var(--ink);
}

.logo-mark {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: "Sora", sans-serif;
  font-weight: 800;
  font-size: 1.9rem;
}

.logo-mark.small { font-size: 1.45rem; }

.logo-ring {
  width: 56px;
  height: 34px;
  border: 4px solid currentColor;
  border-radius: 50%;
  transform: skewX(-18deg);
  position: relative;
}

.logo-ring::after {
  content: "";
  position: absolute;
  inset: 6px -10px 6px 18px;
  border-top: 3px solid currentColor;
  border-bottom: 3px solid currentColor;
  border-radius: 50%;
}

.sidebar .logo-mark { color: #fff; }
.login-card .logo-mark,
.field-topbar .logo-mark { color: var(--ink); }

.brand-block {
  border-radius: 40px;
  padding: 56px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.brand-block::after {
  content: "";
  position: absolute;
  right: -80px;
  top: 50%;
  transform: translateY(-50%);
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(15, 157, 148, 0.3), rgba(15, 157, 148, 0));
}

.brand-block h1,
.field-hero h1 {
  font-size: clamp(2.3rem, 4vw, 4.6rem);
  line-height: 1.02;
  margin: 16px 0;
  max-width: 12ch;
}

.brand-block p,
.hero-panel p,
.review-hero p,
.field-hero p,
.login-copy,
.demo-access {
  color: var(--muted);
  line-height: 1.75;
  max-width: 62ch;
}

.story-points {
  margin-top: 18px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.story-chip {
  padding: 12px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.64);
  border: 1px solid rgba(255, 255, 255, 0.8);
  font-weight: 800;
}

.login-card {
  border-radius: 34px;
  padding: 42px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
  width: min(100%, 560px);
}

.login-scene {
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: center;
}

.login-brand-top {
  display: flex;
  justify-content: center;
  margin-bottom: 2px;
}

.login-brand-top .app-brand-header {
  padding: 0;
}

.login-scene .site-footer {
  padding-top: 0;
}

.login-elevated {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.92), rgba(255,255,255,0.72)),
    var(--panel);
}

.login-card h2 { margin: 0; font-size: 2rem; }
.login-form { flex-direction: column; gap: 16px; }

label {
  display: flex;
  flex-direction: column;
  gap: 10px;
  color: var(--muted);
  font-weight: 700;
}

input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--ink);
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: rgba(166, 82, 36, 0.35);
  box-shadow: 0 0 0 4px rgba(201, 111, 61, 0.12);
}

.btn {
  border: 0;
  border-radius: 16px;
  padding: 15px 22px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
  color: white;
  box-shadow: 0 16px 34px rgba(11, 125, 118, 0.22);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  border: 1px solid rgba(31, 41, 51, 0.08);
}

.btn-login-muted {
  background: #f6f8fb;
  color: #43576a;
  border: 1px solid rgba(67, 87, 106, 0.12);
  box-shadow: none;
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid rgba(31, 41, 51, 0.12);
}

.sidebar .btn-ghost {
  color: #e7edf4;
  border-color: rgba(255, 255, 255, 0.1);
}

.btn-wide { text-align: center; }

.message-box {
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(198, 80, 80, 0.12);
  color: #8d3131;
  font-weight: 700;
}

.hero-panel,
.review-hero {
  border-radius: var(--radius-xl);
  padding: 34px;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
}

.hero-panel {
  background:
    linear-gradient(135deg, rgba(12, 28, 40, 0.97) 0%, rgba(22, 56, 76, 0.93) 100%);
  color: #f3f7fa;
}

.hero-panel .eyebrow,
.hero-panel p,
.hero-panel .hero-badge {
  color: inherit;
}

.hero-panel p { color: #b7c6d2; }

.hero-badge,
.status-chip,
.review-badge {
  display: inline-flex;
  align-items: center;
  padding: 9px 13px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
}

.hero-badge {
  background: rgba(255, 255, 255, 0.12);
  color: #f6e7cf;
}

.hero-art {
  position: relative;
  min-height: 250px;
  display: grid;
  place-items: center;
}

.art-circle {
  width: 280px;
  height: 280px;
  border-radius: 32% 68% 70% 30% / 30% 30% 70% 70%;
  background:
    radial-gradient(circle at 30% 30%, rgba(255,255,255,0.28), transparent 28%),
    linear-gradient(180deg, rgba(15,157,148,0.74), rgba(70,184,201,0.24));
}

.art-card {
  position: absolute;
  right: 0;
  bottom: 10px;
  padding: 18px 20px;
  border-radius: 22px;
  background: rgba(255,255,255,0.96);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
}

.art-card span,
.art-card strong { display: block; }
.art-card strong {
  margin-top: 8px;
  font-family: "Sora", sans-serif;
  font-size: 2rem;
}

.stats-grid,
.panel-grid,
.upload-grid,
.checklist-grid,
.review-check-grid,
.field-checklist {
  display: grid;
  gap: 18px;
}

.stats-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.panel-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.panel-grid-2,
.upload-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.stat-card,
.list-panel,
.details-panel,
.table-panel,
.single-form-panel {
  border-radius: 28px;
  padding: 24px;
}

.stat-card {
  min-height: 190px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(255,255,255,0.68));
}

.stat-card::after {
  content: "";
  position: absolute;
  top: -50px;
  right: -50px;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(15,157,148,0.14), transparent 65%);
}

.stat-card span,
.stat-card small {
  display: block;
  color: var(--muted);
  font-weight: 800;
}

.stat-card strong {
  display: block;
  margin: 18px 0 10px;
  font-family: "Sora", sans-serif;
  font-size: clamp(2.8rem, 5vw, 4.6rem);
}

.stat-card.warning { border-top: 4px solid var(--gold); }
.stat-card.danger { border-top: 4px solid var(--red); }
.stat-card.accent { border-top: 4px solid var(--accent); }

.list-panel,
.details-panel,
.table-panel,
.single-form-panel,
.review-panel-span {
  background: rgba(255, 255, 255, 0.78);
}

.review-panel-span { grid-column: span 2; }

.list-panel h3,
.details-panel h3,
.table-panel h3 {
  margin: 0 0 18px;
  font-size: 1.2rem;
}

.list-items,
.simple-table {
  display: grid;
  gap: 12px;
  max-height: 560px;
  overflow: auto;
}

.vehicle-item,
.review-item,
.simple-row {
  padding: 16px 18px;
  border-radius: 20px;
  background: var(--panel-strong);
  border: 1px solid rgba(31, 41, 51, 0.06);
  box-shadow: 0 8px 20px rgba(15, 23, 32, 0.05);
}

.vehicle-item strong,
.vehicle-item span,
.simple-row strong {
  display: block;
}

.vehicle-item span {
  margin-top: 4px;
  color: var(--muted);
}

.vehicle-item {
  border-left: 4px solid transparent;
}

.vehicle-item:hover {
  border-left-color: var(--accent);
}

.vehicle-detail,
.review-focus {
  display: grid;
  gap: 16px;
}

.detail-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.detail-box {
  padding: 16px;
  border-radius: 18px;
  background: #ffffff;
  border: 1px solid rgba(31, 41, 51, 0.06);
}

.detail-box-accent {
  background: linear-gradient(180deg, rgba(15, 157, 148, 0.08), rgba(255, 255, 255, 0.96));
  border-color: rgba(15, 157, 148, 0.22);
}

.ticketlog-check {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 800;
}

.ticketlog-check-neutral {
  background: rgba(23, 48, 66, 0.08);
  color: var(--ink);
}

.ticketlog-check-success {
  background: rgba(28, 140, 105, 0.14);
  color: #17694f;
}

.ticketlog-check-empty {
  background: rgba(214, 164, 76, 0.18);
  color: #8b6416;
}

.ticketlog-check-error {
  background: rgba(198, 80, 80, 0.14);
  color: #8d3131;
}

.detail-box span,
.detail-box strong {
  display: block;
}

.detail-box span {
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
}

.action-row {
  gap: 12px;
  flex-wrap: wrap;
}

.simple-row {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 14px;
}

.simple-row strong {
  font-family: "Sora", sans-serif;
}

.cadastro-row {
  grid-template-columns: 1fr;
  gap: 8px;
}

.cadastro-row span {
  color: var(--muted);
  line-height: 1.5;
}

.load-more-actions {
  margin-top: 14px;
  display: flex;
  justify-content: center;
}

.data-table-wrap { overflow: auto; }

.data-table {
  width: 100%;
  min-width: 980px;
  border-collapse: separate;
  border-spacing: 0;
}

.data-table thead th {
  position: sticky;
  top: 0;
  background: #f6efe7;
  z-index: 1;
}

.data-table th,
.data-table td {
  padding: 16px;
  text-align: left;
  border-bottom: 1px solid rgba(31, 41, 51, 0.06);
}

.data-table th {
  color: var(--muted);
  font-size: 0.83rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.data-table tbody tr {
  background: rgba(255, 255, 255, 0.66);
}

.preventivas-shell {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.preventivas-columns {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.stage-column {
  padding: 18px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(31, 41, 51, 0.07);
  box-shadow: var(--shadow-lg);
  min-height: 520px;
  display: flex;
  flex-direction: column;
}

.stage-column-soft {
  background: linear-gradient(180deg, rgba(255,255,255,0.88), rgba(247,241,234,0.9));
}

.stage-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 16px;
}

.stage-header h4 {
  margin: 8px 0 0;
  font-family: "Sora", sans-serif;
  font-size: 1.05rem;
}

.stage-header strong {
  font-family: "Sora", sans-serif;
  font-size: 1.8rem;
}

.stage-kicker {
  color: var(--muted);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 800;
}

.stage-list {
  display: grid;
  gap: 12px;
  align-content: start;
}

.column-filter {
  margin-bottom: 14px;
}

.column-filter input {
  padding: 13px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
}

.vehicle-flow-card {
  position: relative;
  padding: 16px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid rgba(31, 41, 51, 0.06);
  box-shadow: 0 10px 24px rgba(15, 23, 32, 0.05);
}

.vehicle-flow-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 5px;
  border-radius: 999px;
  background: rgba(31, 41, 51, 0.08);
}

.status-side-a-vencer::before {
  background: var(--gold);
}

.status-side-vencido::before {
  background: var(--red);
}

.vehicle-flow-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.vehicle-flow-top strong {
  font-family: "Sora", sans-serif;
  font-size: 0.95rem;
}

.vehicle-flow-meta {
  display: grid;
  gap: 4px;
  margin-top: 10px;
}

.vehicle-flow-meta span {
  color: var(--muted);
  font-size: 0.9rem;
}

.vehicle-flow-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.wide {
  width: 100%;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 18px;
}

.section-head h3 {
  margin: 8px 0 0;
  font-family: "Sora", sans-serif;
}

.section-copy {
  max-width: 48ch;
  color: var(--muted);
  line-height: 1.7;
}

.status-inline-legend {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.legend-chip,
.table-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 800;
}

.legend-chip.ok,
.table-status.status-ok {
  background: rgba(28, 140, 105, 0.12);
  color: #17694f;
}

.legend-chip.warning,
.table-status.status-a-vencer {
  background: rgba(214, 164, 76, 0.18);
  color: #8b6416;
}

.legend-chip.danger,
.table-status.status-vencido {
  background: rgba(198, 80, 80, 0.12);
  color: #8d3131;
}

.table-actions {
  display: flex;
  gap: 8px;
}

.table-action-btn {
  border: 1px solid rgba(31, 41, 51, 0.08);
  background: #fff;
  color: var(--ink);
  padding: 8px 11px;
  border-radius: 12px;
  font-weight: 800;
  cursor: pointer;
}

.table-action-btn.secondary {
  background: #eaf7f6;
  color: var(--accent-strong);
}

.table-action-btn.highlight {
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: white;
  border-color: transparent;
}

.droppable-column.is-over {
  border-color: rgba(15, 157, 148, 0.45);
  background: rgba(239, 252, 250, 0.98);
}

.pipeline-card {
  cursor: grab;
}

.pipeline-card.is-dragging {
  opacity: 0.6;
}

.pipeline-empty {
  min-height: 140px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.44);
  color: var(--muted);
  text-align: center;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(9, 16, 24, 0.42);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 50;
}

.modal-backdrop.is-open {
  display: flex;
}

.modal-card {
  width: min(100%, 560px);
  max-height: 90vh;
  overflow: auto;
  border-radius: 28px;
  background: #fff;
  padding: 24px;
  box-shadow: 0 32px 70px rgba(12, 18, 27, 0.28);
}

.modal-large {
  width: min(96vw, 1800px);
  max-width: 96vw;
  max-height: 96vh;
}

.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 18px;
}

.modal-head h3 {
  margin: 8px 0 0;
  font-family: "Sora", sans-serif;
}

.modal-close {
  border: 0;
  background: #eef6f8;
  color: var(--ink);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-size: 1.4rem;
  cursor: pointer;
}

.modal-form {
  display: grid;
  gap: 16px;
}

.completion-fields {
  display: none;
  gap: 16px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.single-form-panel {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.form-row { gap: 16px; }
.form-row-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-row-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }

.upload-card {
  padding: 22px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,0.84), rgba(255,255,255,0.64));
  border: 1px dashed rgba(166, 82, 36, 0.18);
}

.upload-card p { color: var(--muted); }

.search-select {
  position: relative;
}

.search-select-input {
  padding-right: 54px;
  text-transform: uppercase;
}

.search-select-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(15, 157, 148, 0.14), rgba(70, 184, 201, 0.16));
  color: var(--accent-strong);
  cursor: pointer;
  font-size: 0.92rem;
}

.search-select-menu {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 10px);
  z-index: 12;
  display: none;
  max-height: 280px;
  overflow: auto;
  padding: 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(23, 48, 66, 0.08);
  box-shadow: 0 22px 46px rgba(17, 42, 61, 0.16);
}

.search-select.is-open .search-select-menu {
  display: grid;
  gap: 6px;
}

.search-select-option {
  width: 100%;
  border: 0;
  border-radius: 14px;
  padding: 12px 14px;
  background: transparent;
  color: var(--ink);
  text-align: left;
  font-weight: 800;
  cursor: pointer;
}

.search-select-option:hover,
.search-select-option.is-active {
  background: linear-gradient(135deg, rgba(15, 157, 148, 0.12), rgba(14, 93, 161, 0.08));
}

.search-select-option.is-hidden {
  display: none;
}

.search-select-empty {
  display: none;
  padding: 14px;
  color: var(--muted);
  text-align: center;
}

.search-select-empty.is-visible {
  display: block;
}

.review-shell {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.review-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.summary-tile {
  padding: 20px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.88);
}

.summary-tile span {
  display: block;
  color: var(--muted);
  font-weight: 800;
}

.summary-tile strong {
  display: block;
  margin-top: 10px;
  font-family: "Sora", sans-serif;
  font-size: 2.3rem;
}

.review-item-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.review-item span,
.review-item small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
}

.active-review {
  border: 1px solid rgba(166, 82, 36, 0.24);
  box-shadow: 0 14px 34px rgba(166, 82, 36, 0.12);
}

.review-badge,
.status-chip {
  background: rgba(214, 164, 76, 0.16);
  color: #8b5b16;
}

.focus-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.focus-label {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
}

.focus-head strong {
  font-family: "Sora", sans-serif;
  font-size: 1.9rem;
}

.review-check-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.review-check {
  padding: 16px 18px;
  border-radius: 18px;
  font-weight: 800;
}

.review-check.ok {
  background: rgba(28, 140, 105, 0.1);
  color: #17694f;
}

.review-check.alert {
  background: rgba(198, 80, 80, 0.11);
  color: #8d3131;
}

.review-photo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.review-photo-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 20px;
  background: #ffffff;
  border: 1px solid rgba(23, 48, 66, 0.08);
  box-shadow: 0 10px 24px rgba(17, 42, 61, 0.06);
}

.review-photo-preview {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  border-radius: 16px;
  overflow: hidden;
}

.review-photo-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 16px;
  display: block;
}

.review-photo-content {
  display: grid;
  gap: 10px;
}

.review-photo-title {
  color: var(--ink);
  font-family: "Sora", sans-serif;
  font-size: 1rem;
  line-height: 1.3;
}

.review-photo-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.review-photo-note {
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 800;
}

.review-modal-card {
  display: grid;
  gap: 18px;
  width: 96vw;
  max-width: 96vw;
  max-height: 96vh;
  height: 96vh;
}

.review-modal-image-wrap {
  border-radius: 24px;
  overflow: hidden;
  background: #f3f7f9;
  border: 1px solid rgba(23, 48, 66, 0.08);
  min-height: 0;
}

.review-modal-image-wrap img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 78vh;
  object-fit: contain;
  background: #f3f7f9;
}

.comparison-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  min-height: 0;
}

.comparison-card {
  display: grid;
  gap: 10px;
  min-height: 0;
}

.comparison-label {
  display: block;
  color: var(--ink);
  font-family: "Sora", sans-serif;
  font-size: 1.1rem;
  line-height: 1.3;
}

.comparison-card small {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.4;
}

.review-modal-card .eyebrow {
  font-size: 0.82rem;
}

.review-modal-card .modal-head h3 {
  font-size: clamp(1.6rem, 2vw, 2.4rem);
  line-height: 1.15;
}

.field-body {
  background:
    radial-gradient(circle at top left, rgba(15,157,148,0.14), transparent 24%),
    linear-gradient(180deg, #f8fcfd 0%, #edf4f7 100%);
}

.field-layout {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.field-topbar {
  justify-content: space-between;
  align-items: center;
}

.field-hero {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 22px;
  align-items: stretch;
}

.field-card-preview {
  border-radius: 30px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    linear-gradient(135deg, rgba(12, 28, 40, 0.97), rgba(18, 73, 86, 0.92));
  color: white;
}

.field-card-preview span {
  color: #cbd6df;
  font-weight: 800;
}

.field-card-preview strong {
  font-family: "Sora", sans-serif;
  font-size: 4rem;
}

.field-form-shell {
  border-radius: 32px;
  padding: 30px;
  background: rgba(255,255,255,0.82);
}

.field-section-title {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 20px;
}

.field-section-title h2 {
  margin: 8px 0 0;
  font-size: clamp(1.7rem, 2.8vw, 2.8rem);
}

.field-checklist {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field-check-card {
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 18px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid rgba(31, 41, 51, 0.06);
  color: var(--ink);
  box-shadow: 0 10px 24px rgba(15, 23, 32, 0.05);
}

.field-check-card input,
.check-item input {
  width: 18px;
  height: 18px;
}

.field-upload-box {
  padding: 22px;
  border-radius: 22px;
  background: linear-gradient(180deg, #eef8f8, #fff);
  border: 1px dashed rgba(11, 125, 118, 0.18);
}

.field-upload-box h3 {
  margin-top: 0;
  font-family: "Sora", sans-serif;
}

.field-upload-box p {
  color: var(--muted);
  line-height: 1.7;
}

.field-actionbar {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

.field-label {
  display: block;
  margin-bottom: 12px;
  color: var(--muted);
  font-weight: 800;
}

.admin-shell {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.admin-hero {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 18px;
  padding: 28px;
  border-radius: 30px;
  background:
    linear-gradient(135deg, rgba(12, 28, 40, 0.98), rgba(14, 93, 161, 0.84));
  color: white;
  box-shadow: var(--shadow-xl);
}

.admin-hero .eyebrow,
.admin-hero p {
  color: inherit;
}

.admin-hero p {
  color: #d6e6f0;
  line-height: 1.7;
  max-width: 56ch;
}

.admin-hero h2 {
  margin: 10px 0;
  font-family: "Sora", sans-serif;
  font-size: clamp(1.8rem, 2.8vw, 3rem);
  line-height: 1.08;
  max-width: 14ch;
}

.admin-hero-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.admin-target-card {
  align-self: start;
  padding: 22px;
  border-radius: 24px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.14);
}

.admin-target-card span,
.admin-target-card strong,
.admin-target-card small {
  display: block;
}

.admin-target-card span,
.admin-target-card small {
  color: #d6e6f0;
}

.admin-target-card strong {
  margin: 10px 0 6px;
  font-family: "Sora", sans-serif;
  font-size: 1.8rem;
}

.admin-form-card,
.admin-list-card {
  padding: 24px;
  border-radius: 28px;
  background: rgba(255,255,255,0.8);
  box-shadow: var(--shadow-lg);
}

.admin-form-layout {
  display: grid;
  gap: 18px;
}

.admin-form-section {
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(241,248,250,0.84));
  border: 1px solid rgba(23, 48, 66, 0.06);
}

.admin-section-head {
  margin-bottom: 14px;
}

.admin-section-head strong,
.admin-section-head span {
  display: block;
}

.admin-section-head strong {
  font-family: "Sora", sans-serif;
  margin-bottom: 5px;
}

.admin-section-head span {
  color: var(--muted);
  line-height: 1.6;
}

.section-head.compact {
  margin-bottom: 14px;
}

.fancy-checks ul {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.fancy-checks li label {
  height: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(23, 48, 66, 0.06);
  box-shadow: 0 10px 24px rgba(17, 42, 61, 0.05);
}

.admin-users-list {
  display: grid;
  gap: 14px;
}

.admin-user-card {
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(243,248,250,0.9));
  border: 1px solid rgba(23, 48, 66, 0.06);
  box-shadow: 0 12px 26px rgba(17, 42, 61, 0.05);
}

.admin-user-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.admin-user-top strong,
.admin-user-top span {
  display: block;
}

.admin-user-top strong {
  font-family: "Sora", sans-serif;
  font-size: 1rem;
}

.admin-user-top span {
  color: var(--muted);
}

.status-admin {
  background: rgba(14, 93, 161, 0.12);
  color: #0e5da1;
}

.admin-user-mail {
  margin: 12px 0;
  color: var(--muted);
}

.admin-branch-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.admin-branch-tags span {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: #edf7f6;
  color: #0b7d76;
  font-size: 0.82rem;
  font-weight: 700;
}

.admin-user-actions {
  margin-top: 14px;
}

.history-print-shell {
  padding: 0;
}

.history-print-wrap {
  overflow: auto;
  background: #ffffff;
  border: 1px solid #b8c6de;
}

.history-print-table {
  width: 100%;
  min-width: 1500px;
  border-collapse: collapse;
  background: #ffffff;
  font-size: 0.84rem;
}

.history-print-table thead th {
  position: sticky;
  top: 0;
  background: #4f81bd;
  color: #ffffff;
  font-weight: 700;
  text-align: center;
  padding: 8px 10px;
  border: 1px solid #93a9c6;
  white-space: nowrap;
}

.history-print-table td {
  padding: 7px 10px;
  border: 1px solid #c9d4e5;
  color: #111111;
  white-space: nowrap;
  vertical-align: middle;
}

.history-print-table tbody tr:nth-child(even) {
  background: #f7fbff;
}

.history-status {
  font-weight: 800;
}

.checkbox-grid ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.checkbox-grid li label {
  display: flex;
  flex-direction: row;
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,0.86);
}

.checkbox-grid input[type="checkbox"] {
  width: 18px;
  height: 18px;
}

.user-row {
  grid-template-columns: 1fr;
}

.checklist-mobile-body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  background: #eef2f5;
  color: var(--ink);
}

.checklist-mobile-shell {
  max-width: 760px;
  margin: 0 auto;
  padding: 18px 14px 40px;
}

.checklist-mobile-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.checklist-brand-top .app-brand-header {
  padding: 0;
  margin: 0;
}

.checklist-mobile-form {
  display: grid;
}

.checklist-step {
  display: none;
}

.checklist-step.is-active {
  display: block;
}

.checklist-card,
.checklist-success-card {
  padding: 26px 22px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 20px 44px rgba(17, 42, 61, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.92);
}

.intro-card h1,
.checklist-card h2,
.checklist-success-card h1 {
  margin: 10px 0 14px;
  font-family: "Sora", sans-serif;
  line-height: 1.1;
}

.checklist-instructions {
  display: grid;
  gap: 12px;
  margin: 20px 0 24px;
}

.checklist-instructions p,
.check-question-card p,
.condition-score p,
.normativa-list li,
.checklist-card small,
.checklist-success-card p {
  color: var(--muted);
  line-height: 1.65;
}

.draft-resume-card {
  margin-top: 16px;
  padding: 18px;
  border-radius: 22px;
  background: #f7fbfc;
  border: 1px solid rgba(23, 48, 66, 0.08);
}

.draft-resume-card h3 {
  margin: 0 0 8px;
  font-family: "Sora", sans-serif;
}

.checklist-form-grid,
.checklist-upload-grid,
.checklist-photo-grid,
.checklist-question-list,
.checklist-message-stack {
  display: grid;
  gap: 14px;
}

.checklist-upload-card,
.check-question-card {
  display: grid;
  gap: 10px;
  padding: 18px;
  border-radius: 20px;
  background: #f9fcfd;
  border: 1px solid rgba(23, 48, 66, 0.08);
}

.checklist-upload-card span,
.check-question-card h3,
.condition-score h3 {
  font-family: "Sora", sans-serif;
  margin: 0;
}

.saved-file-chip {
  display: inline-flex;
  width: fit-content;
  padding: 7px 11px;
  border-radius: 999px;
  background: rgba(28, 140, 105, 0.12);
  color: #17694f;
  font-size: 0.78rem;
}

.checklist-example-photo {
  margin: 12px 0 18px;
  border-radius: 24px;
  overflow: hidden;
  background: #f4f7f9;
  border: 1px solid rgba(23, 48, 66, 0.08);
  box-shadow: 0 10px 24px rgba(17, 42, 61, 0.08);
}

.checklist-example-photo img {
  display: block;
  width: 100%;
  height: auto;
}

.check-answer-group,
.condition-score-options,
.acceptance-box,
.checklist-step-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.check-answer-option,
.condition-score-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: #ffffff;
  border: 1px solid rgba(23, 48, 66, 0.1);
  font-weight: 800;
  color: var(--ink);
}

.acceptance-option {
  flex: 1 1 220px;
}

.check-answer-option input,
.condition-score-option input {
  width: 18px;
  height: 18px;
  margin: 0;
}

.normativa-list {
  padding-left: 20px;
  display: grid;
  gap: 12px;
}

.checklist-success-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
}

.checklist-success-card {
  text-align: center;
  max-width: 420px;
}

.checklist-success-card .logo-mark {
  justify-content: center;
}

@media (max-width: 760px) {
  .checklist-card,
  .checklist-success-card {
    padding: 22px 18px;
    border-radius: 22px;
  }

  .checklist-step-actions,
  .check-answer-group,
  .condition-score-options,
  .acceptance-box {
    display: grid;
    grid-template-columns: 1fr;
  }

  .checklist-mobile-topbar {
    align-items: flex-start;
  }
}

@media (max-width: 1180px) {
  .portal-screen.active-screen,
  .sidebar-shell,
  .login-panel,
  .hero-panel,
  .review-hero,
  .field-hero,
  .panel-grid-3,
  .stats-grid,
  .panel-grid-2,
  .form-row-3,
  .preventivas-columns {
    grid-template-columns: 1fr;
  }

  .review-panel-span {
    grid-column: span 1;
  }
}

@media (max-width: 760px) {
  .portal-screen,
  .login-screen,
  .field-layout {
    padding: 14px;
  }

  .brand-block,
  .login-card,
  .hero-panel,
  .admin-hero,
  .stat-card,
  .list-panel,
  .details-panel,
  .table-panel,
  .single-form-panel,
  .review-hero,
  .field-form-shell,
  .field-card-preview {
    padding: 20px;
    border-radius: 24px;
  }

  .topbar,
  .topbar-actions,
  .field-topbar,
  .field-section-title,
  .checklist-header,
  .section-head,
  .admin-hero-metrics,
  .form-row-2,
  .upload-grid,
  .checklist-grid,
  .review-check-grid,
  .field-checklist,
  .field-actionbar,
  .completion-fields {
    display: grid;
    grid-template-columns: 1fr;
  }

  .sidebar {
    padding: 18px;
  }

  .fancy-checks ul {
    grid-template-columns: 1fr;
  }

  .comparison-grid {
    grid-template-columns: 1fr;
  }

  .login-panel {
    min-height: auto;
    align-items: stretch;
  }

  .login-brand-top {
    justify-content: flex-start;
  }

  .login-card {
    width: 100%;
    padding: 26px 20px;
    border-radius: 24px;
  }

  .login-card h2 {
    font-size: 1.7rem;
  }

  .demo-access {
    font-size: 0.92rem;
    line-height: 1.55;
  }

  .review-modal-card,
  .modal-large {
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: 96vh;
  }

  .review-modal-image-wrap img {
    max-height: 60vh;
  }
}
