/* ELS application shell and shared Tabler conventions. Page-specific legacy
   styles remain in portal.css until each workflow is migrated deliberately. */
:root {
  --tblr-primary: #0b3f73;
  --tblr-primary-rgb: 11, 63, 115;
  --tblr-link-color: #0b4f8a;
  --tblr-link-hover-color: #072d52;
  --tblr-border-radius: 8px;
  --tblr-border-radius-lg: 12px;
  --els-navy: #0a3a68;
  --els-navy-deep: #062b50;
  --els-navy-soft: #dceaf6;
  --els-blue: #2d6ea3;
  --els-gold: #f3c451;
  --els-gold-dark: #b67a08;
  --els-gold-soft: #fff4d4;
  --els-surface: #ffffff;
  --els-surface-soft: #f3f8fc;
  --els-border: #d5e0e9;
  --els-text: #0b2949;
  --els-text-muted: #61758a;
  --els-success: #24724e;
  --els-warning: #9a671c;
  --els-danger: #a43f3f;
  --els-info: #315d78;
  --els-forest-900: #00523d;
  --els-forest-800: #006249;
  --els-forest-700: #087553;
  --els-forest-100: #e4f1e9;
  --els-gold-500: var(--els-gold);
  --els-ink: var(--els-text);
  --els-muted: var(--els-text-muted);
  --els-canvas: var(--els-surface-soft);
  --els-blue-soft: #edf4ff;
  --els-amber: #e49000;
  --els-amber-soft: #fff3d8;
  --els-red-soft: #fff0ef;
  --els-green-soft: #ebf7ef;
  --els-panel-shadow: 0 12px 32px rgba(6, 43, 80, 0.1);
  --els-topbar-height: 74px;
  --els-sidebar-width: 260px;
}

.els-context-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 10px;
  border-radius: 12px;
  background: var(--els-forest-100);
  color: var(--els-forest-700);
  font-size: 11px;
  font-weight: 750;
}

.els-icon-tile {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 7px;
  background: var(--els-green-soft);
  color: var(--els-forest-700);
  font-size: 23px;
}

body.els-portal-body {
  min-height: 100vh;
  background: var(--els-canvas);
  color: var(--els-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

.els-topbar.navbar {
  position: sticky;
  top: 0;
  z-index: 1030;
  display: flex;
  flex-wrap: nowrap;
  min-height: var(--els-topbar-height);
  height: var(--els-topbar-height);
  padding: 0 22px;
  border: 0;
  background: linear-gradient(90deg, #006247 0%, var(--els-forest-900) 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08);
}

.els-topbar-start,
.els-user-menu,
.els-brand,
.els-sign-out {
  display: flex;
  align-items: center;
}

.els-topbar-start {
  min-width: 0;
  gap: 12px;
}

.els-brand {
  gap: 11px;
  min-width: 0;
  color: #fff;
}

.els-brand:hover,
.els-brand:focus {
  color: #fff;
  text-decoration: none;
}

.els-mobile-logo {
  display: block;
  width: 150px;
  max-width: min(38vw, 150px);
  height: auto;
  object-fit: contain;
}

.els-brand .brand-mark {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 6px;
  background: var(--els-gold-500);
  color: #123d30;
  font-size: 11px;
  letter-spacing: 0;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

.els-brand-copy {
  display: grid;
  line-height: 1.15;
}

.els-brand-copy strong {
  font-size: 14px;
  font-weight: 750;
}

.els-brand-copy small {
  margin-top: 2px;
  color: #b9cec5;
  font-size: 10px;
  letter-spacing: 0;
}

.els-nav-toggle.btn {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  background: transparent;
}

.els-nav-toggle.btn:hover,
.els-nav-toggle.btn:focus {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.els-user-menu {
  gap: 10px;
  color: #e8f0ec;
}

.els-user-menu form {
  margin: 0;
}

.els-user-avatar.avatar {
  width: 32px;
  height: 32px;
  background: #e7efe9;
  color: var(--els-forest-900);
  font-weight: 800;
}

.els-user-name {
  max-width: 180px;
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.els-sign-out.link-button {
  gap: 6px;
  min-height: 36px;
  padding: 6px 8px;
  border-radius: 5px;
  color: #dceae2;
  text-decoration: none;
}

.els-sign-out.link-button:hover,
.els-sign-out.link-button:focus {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.els-shell.shell {
  display: grid;
  grid-template-columns: var(--els-sidebar-width) minmax(0, 1fr);
  min-height: calc(100vh - var(--els-topbar-height));
}

.els-sidebar.sidebar {
  position: sticky;
  top: var(--els-topbar-height);
  align-self: start;
  display: block;
  width: var(--els-sidebar-width);
  height: calc(100vh - var(--els-topbar-height));
  padding: 18px 14px 28px;
  overflow-y: auto;
  border-right: 1px solid var(--els-border);
  background: #f8faf8;
}

.els-sidebar-collapse {
  width: 100%;
}

.els-nav-section + .els-nav-section {
  margin-top: 22px;
}

.els-nav-label {
  margin: 0 10px 7px;
  color: #78847f;
  font-family: inherit;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.4;
  text-transform: uppercase;
}

.els-nav-link,
.els-sidebar.sidebar a.els-nav-link {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 40px;
  margin: 2px 0;
  padding: 9px 10px;
  border-radius: 6px;
  color: #35443e;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.25;
  text-decoration: none;
}

.els-nav-link .ti {
  color: #71817a;
  font-size: 19px;
}

.els-nav-link:hover,
.els-sidebar.sidebar a.els-nav-link:hover {
  color: var(--els-forest-900);
  background: #edf2ef;
}

.els-nav-link.active,
.els-sidebar.sidebar a.els-nav-link.active {
  color: var(--els-forest-900);
  background: var(--els-forest-100);
  box-shadow: inset 3px 0 0 var(--els-forest-700);
}

.els-nav-link.active .ti {
  color: var(--els-forest-700);
}

.els-owner-nav {
  padding-top: 18px;
  border-top: 1px solid var(--els-border);
}

.els-content.content {
  width: 100%;
  min-width: 0;
  padding: 28px clamp(22px, 2.4vw, 34px) 72px;
  margin: 0 auto;
}

.els-alert.alert {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  margin-bottom: 18px;
  padding: 13px 14px;
  border: 1px solid currentColor;
  border-radius: 6px;
  box-shadow: none;
}

.els-alert.alert .ti {
  margin-top: 1px;
  font-size: 19px;
}

.els-alert.flash.success {
  border-color: #b9d4c3;
  background: #e8f3ec;
  color: #225f45;
}

.els-alert.flash.warning {
  border-color: #e6c98d;
  background: #fff6df;
  color: #805919;
}

.els-alert.flash.error {
  border-color: #e6b9b5;
  background: #fbeae8;
  color: #9a3838;
}

.els-page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.els-page-header h1 {
  margin: 0;
  font-size: 30px;
  line-height: 1.2;
}

.els-page-description {
  max-width: 760px;
  margin: 7px 0 0;
  color: var(--els-muted);
}

.els-page-actions,
.els-loading,
.els-btn {
  display: flex;
  align-items: center;
  gap: 8px;
}

.els-btn-primary {
  border-color: var(--els-forest-700);
  background: var(--els-forest-700);
  color: #fff;
}

.els-btn-secondary {
  border-color: #b9c9c0;
  background: #fff;
  color: var(--els-forest-700);
}

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

.els-card.card {
  border: 1px solid var(--els-border);
  border-radius: 8px;
  box-shadow: 0 5px 18px rgba(23, 35, 31, 0.05);
}

.els-status.badge {
  border-radius: 4px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.els-status-ready,
.els-status-verified,
.els-status-clear {
  background: #e3f1e8;
  color: #286346;
}

.els-status-warning,
.els-status-pending,
.els-status-needs-information {
  background: #fff1d5;
  color: #805919;
}

.els-status-error,
.els-status-exception,
.els-status-failed {
  background: #f7e2df;
  color: #983f3f;
}

.els-empty-state.empty {
  padding: 36px 24px;
  border: 1px dashed #bbc8c0;
  border-radius: 8px;
  background: #fbfcfb;
}

.els-empty-state .empty-icon .ti {
  color: var(--els-muted);
  font-size: 34px;
}

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

.els-portal-body .modal-content {
  border: 1px solid var(--els-border);
  border-radius: 8px;
  box-shadow: 0 18px 48px rgba(23, 35, 31, 0.18);
}

.els-portal-body .table.els-table > :not(caption) > * > * {
  padding: 11px 12px;
  border-color: var(--els-border);
}

.help-widget-button .ti,
.reminder-widget-button .ti {
  font-size: 24px;
}

.help-widget-close .ti,
.reminder-add .ti {
  font-size: 18px;
}

.els-login-body .els-topbar {
  justify-content: center;
}

.els-login-body .els-shell {
  display: block;
}

@media (max-width: 991.98px) {
  .els-topbar.navbar {
    padding: 0 14px;
  }

  .els-user-name {
    display: none;
  }

  .els-shell.shell {
    display: block;
  }

  .els-sidebar.sidebar {
    position: sticky;
    top: var(--els-topbar-height);
    z-index: 1020;
    width: 100%;
    height: auto;
    max-height: calc(100vh - var(--els-topbar-height));
    padding: 0;
    overflow-y: auto;
    border-right: 0;
    border-bottom: 1px solid var(--els-border);
  }

  .els-sidebar-collapse {
    padding: 14px;
    background: #f8faf8;
  }

  .els-nav-section + .els-nav-section {
    margin-top: 16px;
  }

  .els-content.content {
    width: 100%;
    padding: 24px 18px 76px;
  }
}

@media (max-width: 575.98px) {
  .els-brand-copy small,
  .els-user-avatar {
    display: none;
  }

  .els-user-menu {
    gap: 2px;
  }

  .els-sign-out.link-button span {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }

  .els-sign-out.link-button {
    width: 38px;
    height: 38px;
    justify-content: center;
  }

  .els-page-header {
    display: block;
  }

  .els-page-actions {
    margin-top: 16px;
  }
}

/* Phase 1: authoritative navy/gold shell and Home foundation. Legacy workflow
   bodies retain their current page CSS until their scheduled modernization. */
.els-topbar.navbar {
  margin-left: var(--els-sidebar-width);
  justify-content: flex-end;
  border-bottom: 1px solid var(--els-border);
  background: var(--els-surface);
  box-shadow: 0 2px 10px rgba(6, 43, 80, 0.04);
}

.els-topbar-start {
  display: none;
}

.els-user-menu {
  color: var(--els-text);
}

.els-user-avatar.avatar {
  width: 42px;
  height: 42px;
  background: var(--els-navy-soft);
  color: var(--els-navy);
  font-size: 16px;
}

.els-user-name {
  font-size: 14px;
  font-weight: 650;
}

.els-sign-out.link-button {
  margin-left: 12px;
  padding-left: 22px;
  border-left: 1px solid var(--els-border);
  border-radius: 0;
  color: var(--els-navy);
}

.els-sign-out.link-button:hover,
.els-sign-out.link-button:focus-visible {
  color: var(--els-navy-deep);
  background: var(--els-surface-soft);
}

.els-shell.shell {
  display: block;
  min-height: calc(100vh - var(--els-topbar-height));
}

.els-sidebar.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 1040;
  display: flex;
  flex-direction: column;
  width: var(--els-sidebar-width);
  height: 100vh;
  padding: 0 12px 24px;
  border: 0;
  background: var(--els-navy-deep);
  color: #fff;
}

.els-sidebar-brand {
  display: flex;
  min-height: 142px;
  padding: 24px 10px 20px;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .18em;
  text-align: center;
  text-transform: uppercase;
  text-decoration: none;
}

.els-sidebar-logo {
  display: block;
  width: 100%;
  max-width: 214px;
  height: auto;
  object-fit: contain;
}

.els-sidebar-brand:hover,
.els-sidebar-brand:focus-visible {
  color: var(--els-gold);
  text-decoration: none;
}

.els-sidebar-brand-mark {
  display: grid;
  width: 58px;
  height: 52px;
  place-items: center;
  color: var(--els-gold);
  font-size: 52px;
  line-height: 1;
}

.els-sidebar-brand > span:last-child {
  color: #fff;
}

.els-sidebar-collapse {
  display: flex !important;
  flex: 1;
  flex-direction: column;
  min-height: 0;
}

.els-nav-link,
.els-sidebar.sidebar a.els-nav-link,
.els-nav-disclosure > summary {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  margin: 2px 0;
  padding: 11px 16px;
  border-radius: 8px;
  color: #edf5fc;
  font-size: 15px;
  font-weight: 550;
  line-height: 1.25;
  text-decoration: none;
}

.els-nav-link .ti,
.els-nav-disclosure > summary > .ti:first-child {
  color: #d9e7f4;
  font-size: 23px;
}

.els-nav-link:hover,
.els-sidebar.sidebar a.els-nav-link:hover,
.els-nav-disclosure > summary:hover {
  color: #fff;
  background: rgba(255, 255, 255, .08);
}

.els-nav-link:focus-visible,
.els-nav-disclosure > summary:focus-visible,
.els-nav-submenu a:focus-visible,
.els-sidebar-brand:focus-visible {
  outline: 3px solid var(--els-gold);
  outline-offset: 2px;
}

.els-nav-link.active,
.els-sidebar.sidebar a.els-nav-link.active {
  position: relative;
  color: var(--els-gold);
  background: rgba(88, 142, 191, .18);
  box-shadow: none;
}

.els-nav-link.active::before {
  position: absolute;
  inset: 0 auto 0 -12px;
  width: 5px;
  background: var(--els-gold);
  content: "";
}

.els-nav-link.active .ti {
  color: var(--els-gold);
}

.els-nav-disclosure > summary {
  cursor: pointer;
  list-style: none;
}

.els-nav-disclosure > summary::-webkit-details-marker {
  display: none;
}

.els-nav-chevron {
  font-size: 17px;
  transition: transform 160ms ease;
}

.els-nav-disclosure[open] .els-nav-chevron {
  transform: rotate(180deg);
}

.els-nav-submenu {
  display: grid;
  gap: 2px;
  margin: 2px 0 7px 36px;
  padding: 2px 0 2px 14px;
  border-left: 1px solid rgba(255, 255, 255, .2);
}

.els-nav-submenu a {
  padding: 8px 10px;
  border-radius: 6px;
  color: #c9d9e8;
  font-size: 12px;
  line-height: 1.25;
  text-decoration: none;
}

.els-nav-submenu a:hover,
.els-nav-submenu a.active {
  color: var(--els-gold);
  background: rgba(255, 255, 255, .07);
}

.els-owner-nav {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, .28);
}

.els-role-nav {
  margin-top: 0;
}

.els-content.content {
  width: calc(100% - var(--els-sidebar-width));
  max-width: none;
  margin-left: var(--els-sidebar-width);
  padding: 34px clamp(28px, 4vw, 68px) 72px;
}

.els-card.card {
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(6, 43, 80, .07);
}

.els-btn-primary {
  border-color: var(--els-navy);
  background: var(--els-navy);
}

.els-btn-secondary {
  border-color: var(--els-border);
  color: var(--els-navy);
}

.els-login-body .els-topbar {
  margin-left: 0;
  justify-content: center;
  background: var(--els-navy-deep);
}

.els-login-body .els-topbar-start,
.els-login-body .els-brand-mobile {
  display: flex;
}

.els-login-body .els-brand-mobile {
  color: #fff;
}

.els-login-body .els-content.content {
  margin-left: 0;
}

.els-home {
  max-width: 1220px;
  margin: 16px auto 0;
}

.els-home-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(420px, 1fr) minmax(220px, .48fr);
  min-height: 248px;
  padding: 34px 20px 44px;
  overflow: hidden;
  border-radius: 16px;
  background: linear-gradient(105deg, #fff 0%, #f7fbfe 42%, #eaf4fb 100%);
}

.els-home-welcome {
  position: relative;
  z-index: 2;
}

.els-home-eyebrow {
  margin: 0 0 12px;
  color: var(--els-navy);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .22em;
  text-transform: uppercase;
}

.els-home-welcome h1 {
  margin: 0;
  color: var(--els-text);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(44px, 5vw, 64px);
  font-weight: 500;
  line-height: 1;
}

.els-home-welcome > p:not(.els-home-eyebrow) {
  margin: 14px 0 0;
  color: var(--els-text);
  font-size: 18px;
}

.els-home-welcome .els-home-question {
  color: var(--els-blue);
}

.els-home-tagline {
  position: relative;
  z-index: 2;
  align-self: start;
  justify-self: end;
  margin: 4px 0 0;
  color: var(--els-navy);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .2em;
  line-height: 1.8;
  text-transform: uppercase;
}

.els-home-tagline span {
  display: block;
  width: 62px;
  height: 3px;
  margin-top: 12px;
  background: var(--els-gold);
}

.els-home-skyline {
  position: absolute;
  right: 110px;
  bottom: 0;
  left: 36%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 7px;
  height: 145px;
  opacity: .23;
}

.els-home-skyline::after {
  position: absolute;
  right: -80px;
  bottom: 0;
  left: -80px;
  height: 38px;
  background: linear-gradient(180deg, rgba(45, 110, 163, .2), rgba(45, 110, 163, .04));
  content: "";
}

.els-home-skyline span {
  width: 30px;
  height: var(--skyline-height);
  border: 2px solid var(--els-blue);
  background: repeating-linear-gradient(to bottom, var(--els-blue) 0 3px, transparent 3px 10px);
}

.els-destination-grid {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 28px 0 0;
}

.els-destination-grid-limited {
  grid-template-columns: repeat(2, minmax(0, 380px));
}

.els-destination-card {
  position: relative;
  display: grid;
  min-height: 292px;
  padding: 28px 30px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 12px;
  background: var(--els-navy-deep);
  box-shadow: 0 12px 28px rgba(6, 43, 80, .12);
  color: #fff;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}

.els-destination-card:hover {
  color: #fff;
  background: var(--els-navy);
  box-shadow: 0 17px 34px rgba(6, 43, 80, .2);
  transform: translateY(-3px);
  text-decoration: none;
}

.els-destination-card:focus-visible {
  outline: 4px solid var(--els-gold);
  outline-offset: 3px;
}

.els-destination-icon {
  display: grid;
  width: 70px;
  height: 70px;
  place-items: center;
  border-radius: 50%;
  background: var(--els-gold);
  color: var(--els-navy-deep);
  font-size: 36px;
}

.els-destination-card h2 {
  align-self: end;
  margin: 20px 0 0;
  color: #fff;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 31px;
  font-weight: 500;
}

.els-destination-card p {
  max-width: 245px;
  margin: 9px 54px 0 0;
  color: #e2edf6;
  font-size: 16px;
  line-height: 1.55;
}

.els-destination-arrow {
  position: absolute;
  right: 26px;
  bottom: 24px;
  display: grid;
  width: 50px;
  height: 50px;
  place-items: center;
  border: 2px solid var(--els-gold);
  border-radius: 50%;
  color: var(--els-gold);
  font-size: 25px;
}

@media (max-width: 1100px) {
  .els-home-hero {
    grid-template-columns: 1fr 220px;
  }

  .els-destination-grid {
    gap: 16px;
  }

  .els-destination-card {
    padding: 24px;
  }
}

@media (max-width: 991.98px) {
  .els-topbar.navbar {
    margin-left: 0;
    justify-content: space-between;
  }

  .els-topbar-start,
  .els-brand-mobile {
    display: flex;
  }

  .els-brand-mobile {
    color: var(--els-navy);
  }

  .els-brand-mobile .brand-mark {
    display: grid;
    background: var(--els-gold);
    color: var(--els-navy-deep);
    place-items: center;
  }

  .els-nav-toggle.btn {
    border-color: var(--els-border);
    color: var(--els-navy);
  }

  .els-nav-toggle.btn:hover,
  .els-nav-toggle.btn:focus {
    color: var(--els-navy-deep);
    background: var(--els-surface-soft);
  }

  .els-sidebar.sidebar {
    position: sticky;
    top: var(--els-topbar-height);
    width: 100%;
    height: auto;
    max-height: calc(100vh - var(--els-topbar-height));
    padding: 0;
    overflow-y: auto;
    border-bottom: 1px solid var(--els-border);
    background: transparent;
    pointer-events: none;
  }

  .els-sidebar-brand {
    display: none !important;
  }

  .els-sidebar-collapse {
    display: none !important;
    padding: 14px;
    background: var(--els-navy-deep);
  }

  .els-sidebar-collapse.show,
  .els-sidebar-collapse.collapsing {
    display: flex !important;
  }

  .els-sidebar-collapse {
    pointer-events: auto;
  }

  .els-owner-nav {
    margin-top: 14px;
  }

  .els-content.content {
    width: 100%;
    margin-left: 0;
    padding: 24px 18px 76px;
  }

  .els-home {
    margin-top: 0;
  }

  .els-destination-grid {
    grid-template-columns: 1fr;
    margin-top: 18px;
  }

  .els-destination-card {
    min-height: 230px;
  }
}

@media (max-width: 575.98px) {
  .els-topbar.navbar {
    min-height: 64px;
    height: 64px;
  }

  .els-mobile-logo {
    width: 126px;
    max-width: 34vw;
  }

  .els-home-hero {
    display: block;
    min-height: 270px;
    padding: 28px 22px;
  }

  .els-home-tagline {
    display: none;
  }

  .els-home-skyline {
    right: 0;
    left: 36%;
    height: 110px;
  }

  .els-home-welcome h1 {
    font-size: 42px;
  }

  .els-home-welcome > p:not(.els-home-eyebrow) {
    font-size: 15px;
  }

  .els-destination-card {
    min-height: 244px;
  }
}
