/* cache-bust 20260513T114943Z d7a2fa6fe4f2 */
/* shared.css — Anchor House v21
   Common styles for operations.html, principal.html, estate.html
   ---------------------------------------------------------------- */

/* FONTS — consolidated superset covering all pages */
/* Loaded via <link> in each HTML head — see note below */

/* CSS VARIABLES */
:root {
  --navy: #1f2a44;
  --navy-mid: #283655;
  --navy-light: #324268;
  --gold: #c2a46d;
  --gold-light: #d4bc96;
  --cream: #f7f6f4;
  --cream-dark: #e8e4dc;
  --white: #ffffff;
  --text: #1f2a44;
  --text-mid: #4a5568;
  --text-muted: #8a9bb0;
  --text-light: #a0aec0;
  --border: #ddd8ce;
  --border-light: #e8e4dc;
  --green: #2a6e47;
  --green-bg: #eaf3ee;
  --amber: #7a5c1e;
  --amber-bg: #fdf5e4;
  --red: #7a2a2a;
  --red-bg: #fdf0f0;
  --sidebar-w: 200px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);

  --font-family-sans: "Jost", sans-serif;
  --font-family-serif: "Playfair Display", serif;

  --font-size-body: 16px;
  --font-size-search: var(--font-size-body);

  --transition-ease: var(--ease);
  --transition-duration: 0.28s;
  
  --z-index-detail-pane: 620;
  --z-index-header: 390;
  --z-index-sidebar: 390;
  --z-index-sidebar-overlay: 380;
  --z-index-workspace-heading: 300;
}

/* RESET */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}
body {
  font-family: "Jost", sans-serif;
  background: var(--cream);
  color: var(--text);
  font-weight: 300;
  font-size: 14px;
  line-height: 1.5;
  overflow-x: hidden;
}
a {
  color: inherit;
  text-decoration: none;
}
button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}
img {
  display: block;
}

/* LAYOUT — fixed height app shell */
.layout {
  display: flex;
  height: 100vh;
  overflow: hidden;
}
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
}

/* SIDEBAR */
.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--sidebar-w);
  background: var(--navy);
  display: flex;
  flex-direction: column;
  z-index: var(--z-index-sidebar);
  transition: transform 0.32s var(--ease);
}
.sb-brand {
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  flex-shrink: 0;
  padding: 18px 20px 16px;
}
.sb-nav {
  padding: 12px 0;
  flex: 1;
  overflow-y: auto;
}
.sb-group {
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.48);
  padding: 16px 22px 4px;
}
.sb-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 20px 8px 22px;
  font-size: 13px;
  letter-spacing: 0.01em;
  color: rgba(255, 255, 255, 0.62);
  cursor: pointer;
  transition: all 0.18s;
  border-left: 2px solid transparent;
  font-weight: 300;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  width: 100%;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sb-item:hover {
  color: rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.04);
}
.sb-item.active {
  color: rgba(255, 255, 255, 0.96);
  background: rgba(255, 255, 255, 0.06);
  border-left-color: var(--gold);
  padding-left: 20px;
  font-weight: 400;
}
.sb-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.4;
  flex-shrink: 0;
}
.sb-foot {
  padding: 14px 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 8.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.26);
  flex-shrink: 0;
}

/* MOBILE / HAMBURGER */
.sb-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(14, 31, 56, 0.55);
  z-index: var(--z-index-sidebar-overlay);
  opacity: 0;
  transition: opacity 0.32s var(--ease);
  backdrop-filter: blur(3px);
  pointer-events: none;
}
.sb-overlay.open {
  opacity: 1;
  pointer-events: all;
}
.hamburger {
  display: none;
  position: fixed;
  top: 14px;
  left: 14px;
  z-index: 400;
  background: var(--navy);
  border-radius: 3px;
  width: 40px;
  height: 40px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  box-shadow: 0 2px 12px rgba(14, 31, 56, 0.3);
  -webkit-tap-highlight-color: transparent;
}
.hamburger span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 1px;
  transition: all 0.22s;
}
.hamburger.open span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}
.hamburger.open span:nth-child(2) {
  opacity: 0;
}
.hamburger.open span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* HEADER */
.header {
  background: var(--navy);
  padding: 14px 36px 16px;
  flex-shrink: 0;
}
.hdr-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}
.hdr-command-strip {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.hdr-cmd-label {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}
.hdr-cmd-sep {
  font-size: 9px;
  color: rgba(255, 255, 255, 0.2);
}
.hdr-cmd-stat {
  font-size: 9px;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.45);
}
.hdr-cmd-sync {
  font-size: 8px;
  letter-spacing: 0.1em;
  color: rgba(194, 164, 109, 0.5);
  margin-left: auto;
  white-space: nowrap;
}
.hdr-greet {
  font-family: "Playfair Display", serif;
  font-size: 22px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.01em;
  line-height: 1.2;
}
.hdr-date {
  margin-top: 3px;
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

/* KPI BOXES (header) */
.hdr-kpi-row {
  display: none !important;
}
.hdr-kpi-box {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 9px 12px 8px;
  position: relative;
  overflow: hidden;
  cursor: default;
}
.hdr-kpi-box::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gold);
  opacity: 0.45;
}
.hdr-kpi-box.alert::before {
  background: #ef4444;
  opacity: 0.8;
}
.hdr-kpi-box-label {
  font-size: 7.5px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 4px;
}
.hdr-kpi-box-val {
  font-family: "Jost", sans-serif;
  font-size: 22px;
  font-weight: 300;
  color: var(--white);
  line-height: 1;
  letter-spacing: -0.5px;
}
.hdr-kpi-box.alert .hdr-kpi-box-val {
  color: #fca5a5;
}
.hdr-kpi-box-sub {
  font-size: 8px;
  color: rgba(255, 255, 255, 0.32);
  margin-top: 2px;
  letter-spacing: 0.04em;
}
.hdr-kpi-skel {
  display: inline-block;
  width: 28px;
  height: 20px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.12);
  animation: kpiPulse 1.4s ease-in-out infinite;
  vertical-align: middle;
}
@keyframes kpiPulse {
  0%,
  100% {
    opacity: 0.4;
  }
  50% {
    opacity: 0.8;
  }
}

/* SEARCH PILL */
.srch-wrap {
  position: relative;
}
.srch-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 40px;
  padding: 13px 28px 13px 52px;
  font-family: "Jost", sans-serif;
  font-size: 14px;
  font-weight: 300;
  color: var(--white);
  letter-spacing: 0.04em;
  outline: none;
  transition-property: border, color;
  transition-duration: var(--transition-duration);
  transition-timing-function: var(--transition-ease);
}
.srch-input::placeholder {
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 0.02em;
  font-size: 13.5px;
}
.srch-input:focus {
  background: rgba(255, 255, 255, 0.11);
  border-color: rgba(194, 164, 109, 0.5);
  box-shadow: 0 0 0 3px rgba(194, 164, 109, 0.08);
}
.srch-icon {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255, 255, 255, 0.35);
  font-size: 16px;
  pointer-events: none;
}
.srch-drop {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--white);
  border: 1px solid var(--cream-dark);
  border-radius: 14px;
  box-shadow:
    0 20px 60px rgba(14, 31, 56, 0.22),
    0 4px 12px rgba(14, 31, 56, 0.1);
  z-index: 500;
  max-height: 400px;
  overflow-y: auto;
  contain: paint;
}
.srch-drop.open {
  display: block;
  animation: fadeDown 0.18s ease;
}
.sd-label {
  font-size: 8px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 10px 18px 5px;
  background: #f2efe9;
}
.sd-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 9px 18px;
  cursor: pointer;
  transition:
    background 0.2s ease,
    padding-left 0.2s ease,
    border-left-color 0.2s ease;
  border-bottom: 1px solid #ede9e1;
  border-left: 3px solid transparent;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}
.sd-item:last-of-type {
  border-bottom: none;
}
.sd-item:hover,
.sd-item:focus {
  background: rgba(194, 164, 109, 0.05);
  border-left-color: var(--gold);
  padding-left: 22px;
}
.sd-icon {
  width: 22px;
  height: 22px;
  border-radius: 3px;
  background: rgba(14, 31, 56, 0.07);
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  flex-shrink: 0;
}
.sd-p {
  font-size: 12.5px;
  color: var(--text);
}
.sd-s {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 1px;
}
.sd-footer {
  padding: 7px 18px;
  border-top: 1px solid #ede9e1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: #f2efe9;
  border-radius: 0 0 14px 14px;
}
.sd-kbd {
  background: #e2ddd5;
  color: var(--text-muted);
  padding: 2px 5px;
  border-radius: 3px;
  font-size: 9px;
  letter-spacing: 0;
}
.srch-loading {
  padding: 16px 18px;
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* SECTION HEADERS */
.sec-hd {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 14px;
  padding-top: 28px;
}
.sec-title {
  font-family: "Playfair Display", serif;
  font-size: 15px;
  font-weight: 400;
  color: var(--navy);
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.sec-rule {
  flex: 1;
  height: 1px;
  background: #dde2e8;
  margin: 0 14px;
}
.sec-ct {
  font-size: 8.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-muted);
  white-space: nowrap;
  opacity: 0.7;
}

/* FOOTER */
.footer {
  background: var(--navy);
  padding: 11px 36px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
}
.footer-text {
  font-size: 8.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.38);
  cursor: default;
}
.footer-link {
  font-size: 8.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.3);
  text-decoration: none;
  transition: color 0.15s;
}
.footer-link:hover {
  color: rgba(255, 255, 255, 0.6);
}

/* ANIMATIONS */
@keyframes fadeDown {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes cardIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes wsIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}
@keyframes skelPulse {
  0%,
  100% {
    opacity: 0.5;
  }
  50% {
    opacity: 1;
  }
}

/* RESPONSIVE — shared breakpoint */
@media (max-width: 768px) {
  .main {
    margin-left: 0;
  }
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 4px 0 24px rgba(14, 31, 56, 0.3);
  }
  .hamburger {
    display: flex;
  }
  .sb-overlay {
    display: block;
  }
  .header {
    padding: 14px 20px 14px 62px;
  }
  .hdr-greet {
    font-size: 18px;
  }
  .footer {
    padding: 10px 20px;
    flex-direction: column;
    gap: 4px;
    text-align: center;
  }
}
