:root {
  --bg: #f5f4ef;
  --ink: #17202b;
  --muted: #667085;
  --line: rgba(23, 32, 43, 0.08);
  --line-strong: rgba(23, 32, 43, 0.16);
  --card: rgba(255, 255, 255, 0.92);
  --brand: #b63a2b;
  --brand-dark: #7f231a;
  --brand-soft: rgba(182, 58, 43, 0.1);
  --accent: #f0c44c;
  --navy: #12344d;
  --ok: #0f8b63;
  --danger: #c23b22;
  --shadow: 0 28px 70px rgba(15, 23, 42, 0.08);
}

html {
  font-size: 14px;
  min-height: 100%;
}

body.app-shell {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(240, 196, 76, 0.26), transparent 24%),
    radial-gradient(circle at top right, rgba(18, 52, 77, 0.12), transparent 26%),
    linear-gradient(180deg, #faf8f2 0%, #eef1f3 100%);
  font-family: "Aptos", "Segoe UI", sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

.container-xl {
  max-width: 1440px;
}

.app-frame {
  display: grid;
  grid-template-columns: 256px minmax(0, 1fr);
  gap: 1.1rem;
  padding: 1rem 0 1.35rem;
  max-width: 100%;
}

.app-sidebar {
  position: sticky;
  top: 1.5rem;
  align-self: start;
  min-height: calc(100vh - 3rem);
  max-height: calc(100vh - 3rem);
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(18, 52, 77, 0.96), rgba(15, 34, 49, 0.98)),
    var(--navy);
  color: white;
  box-shadow: var(--shadow);
  padding: 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  overflow: hidden;
}

.brand-block {
  display: grid;
  gap: 0.25rem;
  margin-bottom: 2rem;
}

.brand-block strong {
  font-size: 1.6rem;
  letter-spacing: -0.03em;
}

.brand-kicker,
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.74rem;
  color: #f7d56e;
}

.brand-tagline {
  color: rgba(255, 255, 255, 0.68);
}

.stack-nav {
  display: grid;
  gap: 0.55rem;
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding-right: 0.3rem;
}

.stack-nav a {
  padding: 0.9rem 1rem;
  border-radius: 16px;
  color: rgba(255, 255, 255, 0.88);
  transition: transform 0.18s ease, background 0.18s ease;
}

.stack-nav a:visited,
.stack-nav a:focus,
.stack-nav a:hover,
.stack-nav a:active {
  color: rgba(255, 255, 255, 0.88);
}

.stack-nav a:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateX(3px);
}

.stack-nav a.active {
  background: rgba(240, 196, 76, 0.18);
  border-color: rgba(240, 196, 76, 0.38);
}

.sidebar-foot {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: grid;
  gap: 0.2rem;
  flex: 0 0 auto;
}

.app-main {
  min-width: 0;
  overflow-x: clip;
}

.app-header {
  margin-bottom: 0.9rem;
}

.header-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 0.85rem 1rem;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(12px);
}

.header-title {
  font-size: 1rem;
}

.hero-panel,
.surface-card,
.page-header {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.surface-card,
.page-header {
  padding: clamp(0.85rem, 1.2vw, 1.1rem);
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.page-header h1,
.hero-panel h1 {
  margin: 0.35rem 0 0;
  font-size: clamp(1.7rem, 2.5vw, 2.45rem);
  line-height: 1;
  letter-spacing: -0.04em;
}

.hero-copy,
.page-header p,
.workflow-card p,
.table-subtext,
.login-copy {
  color: var(--muted);
}

.content-grid,
.workflow-grid,
.company-grid,
.lower-grid {
  display: grid;
  gap: 1.25rem;
}

.content-grid {
  grid-template-columns: 1.2fr 0.8fr;
}

.company-grid,
.workflow-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.section-heading h2,
.workflow-card h2,
.workflow-card h3 {
  margin: 0;
}

.workflow-card,
.task-item,
.metric-card {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.85);
  padding: 0.85rem 0.95rem;
}

.planner-more-chip {
  margin-top: 0.45rem;
  padding: 0.55rem 0.75rem;
  border-radius: 14px;
  background: rgba(18, 52, 77, 0.08);
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
}

.metric-card strong {
  display: block;
  font-size: 2rem;
  margin-top: 0.45rem;
}

.metric-label {
  color: var(--muted);
}

.app-table th {
  color: var(--muted);
  font-weight: 600;
  border-bottom-color: var(--line-strong);
}

.app-table td {
  vertical-align: middle;
  border-bottom-color: var(--line);
}

.operations-table-wrap {
  overflow-x: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.78);
  max-width: 100%;
}

.operations-table {
  margin-bottom: 0;
  width: 100%;
  table-layout: fixed;
}

.operations-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #f7f4ee;
  white-space: normal;
  word-break: break-word;
  padding: 0.55rem 0.5rem;
  line-height: 1.2;
  font-size: 0.82rem;
}

.operations-table tbody td {
  background: rgba(255, 255, 255, 0.92);
  padding: 0.45rem 0.5rem;
  line-height: 1.2;
  font-size: 0.84rem;
}

.operations-table tbody tr:nth-child(even) td {
  background: rgba(247, 244, 238, 0.9);
}

.operations-row-alert-yellow td {
  background: rgba(240, 196, 76, 0.16);
}

.operations-row-alert-red td {
  background: rgba(194, 59, 34, 0.14);
}

.operations-remarks-cell {
  min-width: 0;
  max-width: 220px;
}

.operations-history-row td {
  background: rgba(247, 244, 238, 0.94);
}

.operations-revision-history {
  padding: 0.9rem 1rem;
  border-top: 1px solid var(--line);
}

.operations-revision-history ol {
  margin: 0.5rem 0 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.35rem;
}

.operations-modal {
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
}

.operations-history-row td {
  padding: 0;
  background: #fcfbf8;
}

.operations-history-panel {
  padding: 1rem 1.1rem 1.15rem;
  border-top: 1px solid var(--line);
  background: #fcfbf8;
}

.operations-revision-timeline {
  display: grid;
  gap: 0.85rem;
}

.operations-timeline-item {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 0.8rem;
  align-items: start;
}

.operations-timeline-dot {
  width: 14px;
  height: 14px;
  margin-top: 0.4rem;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 5px rgba(182, 58, 43, 0.12);
}

.operations-timeline-card {
  padding: 0.9rem 1rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(247, 244, 238, 0.9);
  white-space: pre-wrap;
}

.score-rag-link {
  text-decoration: none;
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.score-rag-link:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.12);
}


.operations-report-shell {
  gap: 1rem;
}

.operations-nav-card,
.operations-filter-card,
.operations-summary-card,
.operations-data-card,
.verification-spotlight-card {
  background:
    radial-gradient(circle at top right, rgba(240, 196, 76, 0.16), transparent 18%),
    rgba(255, 255, 255, 0.94);
}

.operations-report-nav {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.operations-report-nav .btn,
.planner-sidebar-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.operations-filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.8rem;
  align-items: end;
}

.operations-filter-grid label,
.filter-form label {
  display: grid;
  gap: 0.4rem;
}

.operations-stat-grid .report-stat-card {
  background:
    linear-gradient(180deg, rgba(18, 52, 77, 0.04), rgba(255, 255, 255, 0.94)),
    rgba(255, 255, 255, 0.92);
}

.operations-data-card .section-heading {
  margin-bottom: 1rem;
}

.operations-table-wrap {
  border: 1px solid rgba(18, 52, 77, 0.08);
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.92);
}

.verification-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.verification-card {
  display: grid;
  gap: 0.9rem;
  padding: 1rem;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
  min-width: 0;
}

.verification-card-pending {
  background: linear-gradient(180deg, rgba(18, 52, 77, 0.08), rgba(255, 255, 255, 0.96) 54%);
  border-color: rgba(18, 52, 77, 0.18);
}

.verification-card-assigned {
  background: linear-gradient(180deg, rgba(15, 139, 99, 0.12), rgba(255, 255, 255, 0.96) 54%);
  border-color: rgba(15, 139, 99, 0.28);
}

.verification-card-yellow {
  background: linear-gradient(180deg, rgba(240, 196, 76, 0.16), rgba(255, 255, 255, 0.96) 54%);
  border-color: rgba(240, 196, 76, 0.48);
}

.verification-card-red {
  background: linear-gradient(180deg, rgba(194, 59, 34, 0.13), rgba(255, 255, 255, 0.96) 54%);
  border-color: rgba(194, 59, 34, 0.42);
}

.verification-card-reverted {
  background: linear-gradient(180deg, rgba(102, 112, 133, 0.12), rgba(255, 255, 255, 0.96) 54%);
  border-color: rgba(102, 112, 133, 0.28);
}

.verification-card-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
}

.verification-card-head h3 {
  margin: 0;
}

.verification-meta {
  display: grid;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.83rem;
  word-break: break-word;
}

.verification-remarks {
  padding: 0.85rem 0.95rem;
  border-radius: 16px;
  background: rgba(18, 52, 77, 0.05);
  white-space: pre-wrap;
  font-size: 0.83rem;
}

.verification-actions {
  display: grid;
  gap: 0.75rem;
}

.verification-dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 0.9rem;
}

.verification-card-compact {
  gap: 0.75rem;
  padding: 0.9rem;
}

.operations-action-cell {
  min-width: 120px;
  vertical-align: top;
}

.operations-task-edit,
.operations-inline-form {
  margin-bottom: 0.35rem;
}

.operations-task-edit summary {
  display: block;
  margin-bottom: 0.2rem;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.82rem;
}

.operations-action-cell .planner-edit-form,
.operations-inline-form {
  min-width: 0;
  width: 100%;
}

.operations-action-cell .form-control,
.operations-action-cell textarea,
.operations-action-cell input[type="datetime-local"] {
  width: 100%;
  min-height: 32px;
  padding: 0.35rem 0.45rem;
  font-size: 0.82rem;
}

.operations-table th,
.operations-table td {
  white-space: normal;
  word-break: break-word;
  vertical-align: top;
}

.operations-date-cell {
  display: block;
  white-space: normal;
  word-break: normal;
  overflow-wrap: anywhere;
  line-height: 1.25;
  min-width: 0;
}

.operations-table td:nth-child(5),
.operations-table td:nth-child(6),
.operations-table td:nth-child(9),
.operations-table td:nth-child(10),
.operations-table th:nth-child(5),
.operations-table th:nth-child(6),
.operations-table th:nth-child(9),
.operations-table th:nth-child(10) {
  white-space: nowrap;
}

.operations-table th:nth-child(1),
.operations-table td:nth-child(1) {
  width: 15%;
}

.operations-table th:nth-child(2),
.operations-table td:nth-child(2),
.operations-table th:nth-child(3),
.operations-table td:nth-child(3) {
  width: 10%;
}

.operations-table th:nth-child(4),
.operations-table td:nth-child(4),
.operations-table th:nth-child(5),
.operations-table td:nth-child(5),
.operations-table th:nth-child(6),
.operations-table td:nth-child(6) {
  width: 10%;
}

.operations-table th:nth-child(7),
.operations-table td:nth-child(7) {
  width: 10%;
}

.operations-table th:nth-child(8),
.operations-table td:nth-child(8),
.operations-table th:nth-child(9),
.operations-table td:nth-child(9) {
  width: 9%;
}

.operations-table th:nth-child(10),
.operations-table td:nth-child(10) {
  width: 7%;
}

.operations-table th:nth-child(11),
.operations-table td:nth-child(11) {
  width: 7%;
}

.operations-table th:nth-child(12),
.operations-table td:nth-child(12) {
  width: 14%;
}

.operations-table th:nth-child(13),
.operations-table td:nth-child(13) {
  width: 12%;
}

.operations-table th:nth-child(14),
.operations-table td:nth-child(14) {
  width: 11%;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
}

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

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
}

.form-control,
.form-select {
  border-radius: 14px;
  border: 1px solid rgba(23, 32, 43, 0.14);
  padding: 0.72rem 0.9rem;
  background: white;
}

.form-control:focus,
.form-select:focus {
  border-color: rgba(182, 58, 43, 0.45);
  box-shadow: 0 0 0 0.2rem rgba(182, 58, 43, 0.12);
}

.status-block,
.pill-row,
.stats-inline,
.bulk-actions,
.user-fms-nav {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.app-pill,
.status-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
}

.app-pill {
  background: var(--brand-soft);
  color: var(--brand-dark);
}

.pin-user-selected {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.5rem;
}

.pin-user-chip {
  border: 1px solid var(--border-color);
  cursor: pointer;
}

.status-tag {
  background: rgba(102, 112, 133, 0.12);
  color: var(--muted);
  white-space: normal;
  word-break: break-word;
  max-width: 100%;
}

.status-tag-report {
  display: inline-grid;
  width: 100%;
  min-width: 96px;
  padding: 0.35rem 0.5rem;
}

.status-tag.completed {
  background: rgba(15, 139, 99, 0.12);
  color: var(--ok);
}

.status-tag.inprogress {
  background: rgba(18, 52, 77, 0.12);
  color: var(--navy);
}

.status-tag.delayed {
  background: rgba(194, 59, 34, 0.12);
  color: var(--danger);
}

.status-tag.pending {
  background: rgba(240, 196, 76, 0.18);
  color: #8f6600;
}

.status-tag.verificationpending {
  background: rgba(18, 52, 77, 0.12);
  color: var(--navy);
}

.status-tag.assignedtoverifier {
  background: rgba(15, 139, 99, 0.14);
  color: var(--ok);
}

.status-tag.reverted {
  background: rgba(102, 112, 133, 0.16);
  color: var(--muted);
}

.step-list {
  margin: 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.9rem;
}

.step-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
}

.timeline-side {
  text-align: right;
  display: grid;
  gap: 0.35rem;
}

.bulk-field-form,
.bulk-rows {
  display: grid;
  gap: 1rem;
}

.bulk-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.9rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.78);
}

.inline-form {
  display: flex;
  gap: 0.65rem;
  align-items: center;
}

.dropdown-builder {
  display: grid;
  gap: 0.65rem;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem;
}

.login-panel {
  width: min(1100px, 100%);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.5rem;
}

.login-panel-rich {
  align-items: stretch;
}

.login-showcase {
  border-radius: 30px;
  padding: 2rem;
  color: white;
  background:
    radial-gradient(circle at top right, rgba(240, 196, 76, 0.36), transparent 22%),
    linear-gradient(155deg, #12344d 0%, #0e2538 100%);
  box-shadow: var(--shadow);
}

.login-form {
  display: grid;
  gap: 1rem;
}

.login-showcase-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.login-feature-card {
  padding: 1rem;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.login-feature-card strong {
  display: block;
  margin: 0.3rem 0;
  font-size: 1.1rem;
}

.login-form-rich {
  align-content: center;
  padding: 2rem;
}

.login-form-copy h2 {
  margin: 0.3rem 0;
}

.btn-primary {
  background: var(--brand);
  border-color: var(--brand);
  border-radius: 14px;
  padding: 0.7rem 1rem;
}

.btn-primary:hover,
.btn-primary:focus {
  background: var(--brand-dark);
  border-color: var(--brand-dark);
}

.btn-outline-primary {
  color: var(--brand-dark);
  border-color: rgba(182, 58, 43, 0.34);
  border-radius: 14px;
}

.dashboard-hero {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.mini-stat {
  padding: 1rem;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.78);
}

.mini-stat strong {
  display: block;
  font-size: 1.9rem;
}

.upcoming-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 1.25rem;
}

.upcoming-sidebar {
  align-self: start;
  position: sticky;
  top: 1rem;
}

.upcoming-nav {
  display: grid;
  gap: 0.4rem;
}

.upcoming-nav a {
  padding: 0.85rem 0.95rem;
  border-radius: 16px;
  color: var(--muted);
}

.upcoming-nav a.active,
.upcoming-nav a:hover {
  background: rgba(182, 58, 43, 0.08);
  color: var(--brand-dark);
}

.template-search-bar {
  margin-bottom: 1rem;
}

.upcoming-main {
  display: grid;
  gap: 1.25rem;
}

.checklist-expiry-popup {
  position: sticky;
  top: 1rem;
  z-index: 20;
  display: flex;
  justify-content: flex-end;
  margin-bottom: 1rem;
}

.checklist-expiry-popup__card {
  width: min(420px, 100%);
  padding: 1rem;
  border-radius: 20px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
}

.quick-add-card {
  background:
    radial-gradient(circle at top right, rgba(240, 196, 76, 0.22), transparent 18%),
    rgba(255, 255, 255, 0.96);
}

.quick-add-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.upcoming-board {
  display: grid;
  gap: 1.25rem;
}

.meeting-frame-wrap {
  border: 1px solid var(--line);
  border-radius: 22px;
  overflow: hidden;
  background: #0d1117;
  min-height: 540px;
}

.meeting-frame {
  width: 100%;
  min-height: 540px;
  border: 0;
}

.meeting-mom-box {
  min-height: 320px;
}

.meeting-mom-helper {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.meeting-jitsi-frame {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: #0f172a;
}

.meeting-jitsi-frame iframe {
  display: block;
  width: 100%;
  min-height: 620px;
  border: 0;
}

.meeting-live-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.1rem;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: linear-gradient(135deg, rgba(13, 148, 136, 0.08), rgba(59, 130, 246, 0.08));
}

.upcoming-day {
  border-top: 1px solid var(--line);
  padding-top: 1rem;
}

.upcoming-day:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.upcoming-day-head {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  margin-bottom: 0.75rem;
}

.upcoming-day-head h3 {
  margin: 0;
}

.upcoming-list {
  display: grid;
  gap: 0.75rem;
}

.upcoming-task-row {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr) auto;
  gap: 0.9rem;
  align-items: center;
  padding: 0.95rem 1rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.84);
}

.task-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(23, 32, 43, 0.24);
}

.upcoming-task-main {
  min-width: 0;
}

.planner-shell {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 1rem;
  min-width: 0;
  max-width: 100%;
}

.planner-sidebar {
  position: sticky;
  top: 1rem;
  align-self: start;
  display: grid;
  gap: 1rem;
  background:
    linear-gradient(180deg, rgba(18, 52, 77, 0.98), rgba(15, 34, 49, 0.96)),
    var(--navy);
  color: white;
}

.planner-brand,
.planner-sidebar-block {
  padding: 0.2rem 0;
}

.planner-brand h2,
.planner-command h1,
.planner-calendar-head h2 {
  margin: 0.2rem 0 0;
  letter-spacing: -0.04em;
}

.planner-sidebar .table-subtext,
.planner-sidebar .eyebrow {
  color: rgba(255, 255, 255, 0.74);
}

.planner-rules {
  display: grid;
  gap: 0.65rem;
  padding-left: 1rem;
  margin: 0.7rem 0 0;
}

.planner-rules li {
  color: rgba(255, 255, 255, 0.92);
}

.planner-sidebar-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.8rem;
}

.planner-sidebar-links a {
  padding: 0.65rem 0.85rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  min-width: 0;
}

.planner-main {
  display: grid;
  gap: 0.95rem;
  min-width: 0;
  max-width: 100%;
}

.planner-command {
  position: relative;
  overflow: visible;
  background:
    radial-gradient(circle at top right, rgba(240, 196, 76, 0.28), transparent 16%),
    radial-gradient(circle at bottom left, rgba(18, 52, 77, 0.12), transparent 28%),
    rgba(255, 255, 255, 0.96);
  min-width: 0;
  max-width: 100%;
}

.planner-command-form {
  display: grid;
  gap: 0.8rem;
  margin-top: 0.8rem;
}

.planner-command-bar {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.06);
  min-width: 0;
  max-width: 100%;
}

.planner-command-bar > * {
  min-width: 0;
}

.planner-command-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 1.5rem;
}

.planner-command-input {
  border: 0;
  background: transparent;
  font-size: 1.04rem;
  color: var(--ink);
  outline: none;
  min-width: 0;
}

.planner-mention-menu {
  position: absolute;
  left: 1.4rem;
  top: calc(100% - 2.3rem);
  z-index: 20;
  width: min(440px, calc(100% - 2.8rem));
  display: grid;
  gap: 0.3rem;
  padding: 0.55rem;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 22px 55px rgba(15, 23, 42, 0.16);
}

.planner-mention-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
  width: 100%;
  border: 0;
  border-radius: 14px;
  background: transparent;
  text-align: left;
  padding: 0.8rem 0.9rem;
}

.planner-mention-item:hover {
  background: rgba(18, 52, 77, 0.06);
}

.planner-mention-item span {
  color: var(--muted);
  font-size: 0.82rem;
}

.planner-mention-item.is-create {
  color: var(--brand-dark);
  font-weight: 700;
}

.planner-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.planner-toolbar-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.planner-advanced {
  min-width: 0;
  max-width: 100%;
}

.planner-advanced summary {
  cursor: pointer;
  color: var(--brand-dark);
  font-weight: 700;
}

.planner-calendar {
  display: grid;
  gap: 0.8rem;
  min-width: 0;
  max-width: 100%;
}

.planner-calendar-head,
.planner-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.planner-weekdays,
.planner-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0.6rem;
  min-width: 0;
  max-width: 100%;
}

.planner-weekdays {
  color: var(--muted);
  font-weight: 700;
  padding: 0 0.1rem;
}

.planner-day {
  min-height: 132px;
  max-height: 188px;
  overflow: hidden;
  padding: 0.72rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(248, 248, 245, 0.92));
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.planner-day.is-muted {
  opacity: 0.56;
}

.planner-day.is-today {
  border-color: rgba(182, 58, 43, 0.35);
  box-shadow: inset 0 0 0 1px rgba(182, 58, 43, 0.08);
}

.planner-day.is-selected {
  border-color: rgba(18, 52, 77, 0.4);
  box-shadow: inset 0 0 0 1px rgba(18, 52, 77, 0.12);
}

.planner-day.is-drop-target {
  border-color: rgba(15, 139, 99, 0.55);
  background: rgba(15, 139, 99, 0.08);
  transform: translateY(-2px);
}

.planner-day-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.55rem;
}

.planner-day-head span {
  color: var(--muted);
  font-size: 0.8rem;
}

.planner-day-head strong {
  font-size: 1rem;
}

.planner-day-list {
  display: grid;
  gap: 0.45rem;
  max-height: 124px;
  overflow: hidden;
}

.planner-task-chip {
  display: grid;
  gap: 0.25rem;
  border: 1px solid rgba(18, 52, 77, 0.08);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(18, 52, 77, 0.05), rgba(182, 58, 43, 0.04)),
    #fff;
  padding: 0.6rem 0.7rem;
  cursor: grab;
}

.planner-chip-status {
  font-size: 0.77rem;
  font-weight: 700;
  color: var(--muted);
}

.planner-task-chip:active {
  cursor: grabbing;
}

.planner-task-time {
  font-size: 0.77rem;
  font-weight: 700;
  color: var(--brand-dark);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.planner-task-desc {
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.planner-task-actions {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 0.35rem;
}

.planner-agenda {
  display: grid;
  gap: 0.75rem;
}

.planner-agenda-compact {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.planner-agenda-card {
  padding: 0.85rem 0.95rem;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
  min-width: 0;
}

.planner-agenda-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
  margin-bottom: 0.6rem;
}

.planner-agenda-head h3 {
  margin: 0;
}

.workspace-queue {
  display: grid;
  gap: 0.9rem;
}

.queue-card {
  padding: 0.8rem 0.9rem;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
}

.queue-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 0.65rem;
}

.queue-fms,
.queue-checklist,
.queue-delegation,
.queue-assigned-form,
.queue-fms-start {
  border-left: 5px solid rgba(18, 52, 77, 0.18);
}

.queue-fms {
  border-left-color: rgba(182, 58, 43, 0.55);
}

.queue-checklist {
  border-left-color: rgba(240, 196, 76, 0.8);
}

.queue-delegation {
  border-left-color: rgba(15, 139, 99, 0.6);
}

.queue-assigned-form,
.queue-fms-start {
  border-left-color: rgba(18, 52, 77, 0.45);
}

.planner-task-edit summary {
  cursor: pointer;
  color: var(--brand-dark);
  font-size: 0.82rem;
  font-weight: 700;
}

.planner-edit-form {
  display: grid;
  gap: 0.6rem;
  margin-top: 0.55rem;
  padding-top: 0.55rem;
  border-top: 1px solid var(--line);
}

.module-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 1.25rem;
}

.module-sidebar {
  position: sticky;
  top: 1rem;
  align-self: start;
}

.module-main {
  display: grid;
  gap: 1.25rem;
}

.sales-note {
  padding: 1rem 1.1rem;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
}

.sales-lead-grid {
  display: grid;
  gap: 1rem;
}

.sales-lead-card {
  padding: 1rem 1.1rem;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
}

.toggle-field {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-height: 52px;
  padding: 0.9rem 1rem;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  font-weight: 600;
}

.toggle-field input {
  width: 18px;
  height: 18px;
}

.sales-studio-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.permission-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.sales-studio-card {
  display: grid;
  gap: 1rem;
  padding: 1.1rem;
  border-radius: 24px;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 244, 239, 0.92));
}

.sales-studio-block {
  display: grid;
  gap: 0.7rem;
}

.sales-studio-block h4 {
  margin: 0;
  font-size: 0.96rem;
}

.sales-stage-flow {
  display: grid;
  gap: 0.7rem;
}

.sales-stage-chip {
  display: grid;
  gap: 0.15rem;
  padding: 0.85rem 0.95rem;
  border-radius: 18px;
  border: 1px solid rgba(18, 52, 77, 0.08);
  background: rgba(250, 247, 243, 0.92);
}

.sales-stage-chip strong,
.sales-stage-chip span,
.sales-stage-chip small {
  display: block;
}

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

.report-card-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  margin-top: 0.75rem;
  align-items: stretch;
}

.report-stat-card {
  display: grid;
  gap: 0.35rem;
  padding: 0.8rem 0.9rem;
  min-height: 104px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
  align-content: start;
}

.report-stat-card span {
  color: var(--muted);
  font-size: 0.82rem;
}

.report-stat-card strong {
  font-size: 1.65rem;
  color: var(--brand-dark);
}

.scorecard-user-grid {
  display: grid;
  gap: 1.1rem;
}

.scorecard-user-card {
  padding: 1rem 1.1rem;
  min-width: 0;
}

.scorecard-user-card .section-heading {
  margin-bottom: 0.9rem;
}

.scorecard-type-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
  align-items: stretch;
}

.score-type-card {
  display: grid;
  gap: 0.8rem;
  padding: 0.9rem;
  height: 100%;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  grid-template-rows: auto auto 1fr;
  align-content: start;
  min-width: 0;
}

.score-type-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 0.75rem;
}

.score-type-head h3 {
  margin: 0;
}

.score-rag-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.5rem;
  min-width: 0;
  align-items: stretch;
}

.score-rag-box {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.2rem;
  padding: 0.55rem 0.6rem;
  min-height: 122px;
  border-radius: 14px;
  color: #fff;
  text-align: center;
  text-decoration: none;
  border: 2px solid transparent;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

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

.score-rag-box small {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.78rem;
  opacity: 0.92;
}

.score-rag-box strong {
  font-size: 1.05rem;
}

.score-rag-red {
  background: linear-gradient(180deg, #d6422b, #a92e1d);
  border-color: rgba(122, 16, 4, 0.4);
}

.score-rag-yellow {
  background: linear-gradient(180deg, #f0c44c, #d49f12);
  color: #4b3900;
  border-color: rgba(126, 87, 0, 0.24);
}

.score-rag-green {
  background: linear-gradient(180deg, #15936a, #0d6c4d);
  border-color: rgba(5, 74, 52, 0.32);
}

.score-delegation-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0.7rem 0.85rem;
  margin-bottom: 0.75rem;
  min-height: 68px;
  border-radius: 16px;
  background: rgba(18, 52, 77, 0.05);
  border: 1px solid rgba(18, 52, 77, 0.08);
}

.score-delegation-total span {
  color: var(--muted);
}

.score-delegation-total strong {
  font-size: 1.1rem;
  color: var(--brand-dark);
}

.score-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  align-items: stretch;
}

.score-metric-box {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 0.75rem 0.8rem;
  min-height: 122px;
  border-radius: 16px;
  background: rgba(18, 52, 77, 0.05);
  border: 1px solid rgba(18, 52, 77, 0.08);
}

.score-metric-link {
  text-decoration: none;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.score-metric-link:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.08);
  border-color: rgba(17, 101, 143, 0.2);
}

.score-metric-box span,
.score-metric-box small {
  display: block;
  color: var(--muted);
}

.score-metric-box strong {
  display: block;
  font-size: 1.25rem;
  color: var(--brand-dark);
}

.report-stat-card-accent {
  background:
    linear-gradient(180deg, rgba(15, 139, 99, 0.12), rgba(255, 255, 255, 0.92)),
    rgba(255, 255, 255, 0.9);
  border-color: rgba(15, 139, 99, 0.24);
}

.user-dashboard-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(280px, 0.85fr);
  gap: 0.85rem;
  align-items: start;
}

.user-dashboard-main,
.user-dashboard-side,
.compact-stack {
  display: grid;
  gap: 0.8rem;
}

.compact-queue {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.compact-card {
  display: grid;
  gap: 0.55rem;
  padding: 0.85rem 0.95rem;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
}

.dashboard-fold {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.9);
  overflow: hidden;
}

.dashboard-fold summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0.95rem;
}

.dashboard-fold summary::-webkit-details-marker {
  display: none;
}

.dashboard-fold-body {
  padding: 0 0.95rem 0.95rem;
}

@media (max-width: 1400px) {
  .app-frame {
    grid-template-columns: 236px minmax(0, 1fr);
  }

  .planner-shell {
    grid-template-columns: 248px minmax(0, 1fr);
  }
}

@media (max-width: 1280px) {
  .operations-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .planner-agenda-compact {
    grid-template-columns: 1fr;
  }

  .planner-weekdays,
  .planner-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .operations-table th:nth-child(10),
  .operations-table td:nth-child(10),
  .operations-table th:nth-child(11),
  .operations-table td:nth-child(11) {
    width: auto;
  }
}

@media (max-width: 1100px) {
  .app-frame,
  .content-grid,
  .dashboard-hero,
  .login-panel,
  .bulk-row,
  .form-grid,
  .upcoming-shell,
  .planner-shell,
  .module-shell,
  .user-dashboard-shell,
  .login-showcase-grid {
    grid-template-columns: 1fr;
  }

  .app-sidebar {
    position: static;
    min-height: auto;
  }

  .upcoming-sidebar {
    position: static;
  }

  .planner-sidebar {
    position: static;
  }

  .module-sidebar {
    position: static;
  }

  .page-header,
  .header-wrap {
    align-items: start;
  }

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

  .surface-card,
  .page-header {
    padding: 0.9rem;
  }

  .scorecard-type-grid {
    grid-template-columns: 1fr;
  }

  .score-metric-grid,
  .score-rag-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .operations-table-wrap {
    overflow-x: auto;
  }

  .operations-table {
    min-width: 980px;
    table-layout: auto;
  }

  .operations-action-cell {
    min-width: 220px;
  }
}

@media (max-width: 700px) {
  .operations-filter-grid,
  .report-card-grid,
  .verification-grid,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .score-metric-grid,
  .score-rag-grid {
    grid-template-columns: 1fr;
  }

  .planner-command-bar,
  .planner-nav,
  .planner-toolbar {
    grid-template-columns: 1fr;
    display: grid;
  }

  .planner-command-bar {
    padding: 0.75rem;
  }

  .planner-weekdays,
  .planner-grid {
    grid-template-columns: 1fr;
  }

  .app-frame {
    padding: 0.8rem 0 1rem;
  }

  .stack-nav a,
  .operations-report-nav .btn,
  .planner-sidebar-links a,
  .planner-task-actions .btn,
  .filter-form .btn {
    width: 100%;
  }

  .header-wrap,
  .section-heading,
  .planner-agenda-head,
  .verification-card-head,
  .page-header {
    grid-template-columns: 1fr;
    display: grid;
  }

  .surface-card,
  .page-header,
  .compact-card,
  .queue-card,
  .planner-agenda-card {
    border-radius: 16px;
  }

  .meeting-jitsi-frame iframe {
    min-height: 420px;
  }
}
