/* RepairTicket shared application shell: header, menus and footer. */
:root {
  --shell-canvas:#f3f1ec; --shell-surface:#fffefa; --shell-soft:#f7f6f1;
  --shell-ink:#17212b; --shell-copy:#455463; --shell-muted:#71808d;
  --shell-line:#dcded9; --shell-line-strong:#c9cec8;
  --shell-navy:#122a3a; --shell-navy-2:#173548; --shell-green:#147d64;
  --shell-green-dark:#0d6853; --shell-amber:#f3b75c; --shell-red:#b84a44;
  --shell-radius:12px; --shell-radius-sm:8px;
  --shell-shadow:0 12px 30px rgba(24,39,48,.10);
}
html { background:var(--shell-canvas); }
body { background:var(--shell-canvas) !important; color:var(--shell-copy); }
.app-shell { min-height:100dvh; background:var(--shell-canvas); }
.app-header :focus-visible,.rt-footer :focus-visible { outline:3px solid rgba(20,125,100,.3) !important; outline-offset:3px; }

/* Header */
.app-header {
  position:sticky !important; top:0; z-index:1020 !important;
  min-height:64px !important; border-bottom:1px solid rgba(255,255,255,.1) !important;
  background:linear-gradient(110deg,var(--shell-navy),var(--shell-navy-2)) !important;
  box-shadow:0 8px 22px rgba(18,42,58,.14) !important;
  backdrop-filter:none !important;
}
.app-header-inner { max-width:1680px !important; min-height:64px !important; height:64px !important; padding:0 24px !important; gap:18px !important; }
.brand-row { gap:10px !important; padding:5px 0 !important; color:#fff !important; }
.brand-mark { width:38px !important; height:38px !important; border:1px solid rgba(255,255,255,.14) !important; border-radius:10px !important; background:rgba(255,255,255,.08) !important; box-shadow:none !important; }
.brand-mark-inner { background:transparent !important; border-radius:8px !important; }
.brand-logo { max-width:29px !important; max-height:29px !important; }
.brand-title { color:#fff !important; font-size:15px !important; font-weight:750 !important; letter-spacing:-.015em !important; }
.brand-subtitle { color:rgba(226,239,241,.58) !important; font-size:9.5px !important; letter-spacing:.02em !important; }
.header-actions { gap:8px !important; }
.hdr-bug-btn {
  width:36px !important; height:36px !important; border:1px solid rgba(255,255,255,.14) !important;
  border-radius:var(--shell-radius-sm) !important; background:rgba(255,255,255,.06) !important;
  color:rgba(239,246,247,.75) !important; box-shadow:none !important;
}
.hdr-bug-btn:hover { background:rgba(255,255,255,.12) !important; color:#fff !important; transform:translateY(-1px); }

/* Branch control */
.hdr-branch-trigger {
  min-height:40px !important; padding:5px 9px !important;
  border:1px solid rgba(255,255,255,.14) !important; border-radius:var(--shell-radius-sm) !important;
  background:rgba(255,255,255,.06) !important; color:#fff !important; box-shadow:none !important;
}
.hdr-branch-trigger:hover,.hdr-branch-trigger:focus,.hdr-branch-trigger.show { background:rgba(255,255,255,.11) !important; border-color:rgba(255,255,255,.24) !important; }
.hdr-branch-icon { width:28px !important; height:28px !important; border:0 !important; border-radius:7px !important; background:rgba(255,255,255,.1) !important; }
.hdr-branch-icon-img { filter:brightness(0) invert(1) !important; opacity:.94 !important; }
.hdr-branch-current { color:#fff !important; font-size:11px !important; font-weight:700 !important; }
.hdr-branch-code,.hdr-branch-count,.hdr-branch-subline { color:rgba(235,245,246,.76) !important; font-size:9px !important; }
.hdr-branch-code { border:0 !important; background:transparent !important; padding:0 !important; }
.hdr-branch-chevron { color:#fff !important; }
.hdr-branch-menu,.dropdown-profile-menu {
  margin-top:9px !important; border:1px solid var(--shell-line) !important; border-radius:var(--shell-radius) !important;
  background:var(--shell-surface) !important; box-shadow:0 22px 55px rgba(18,42,58,.2) !important;
}
.hdr-branch-menu::before { display:none !important; }
.hdr-branch-menu-head,.pm-header { border-bottom:1px solid var(--shell-line) !important; background:var(--shell-soft) !important; }
.hdr-branch-menu-kicker,.pm-section { color:var(--shell-green) !important; letter-spacing:.08em !important; }
.hdr-branch-menu-title,.pm-name { color:var(--shell-ink) !important; }
.hdr-branch-menu-sub,.pm-email,.pm-item-sub { color:var(--shell-muted) !important; }
.hdr-branch-menu-chip { border-radius:6px !important; background:#e8f1ed !important; color:var(--shell-green-dark) !important; }
.hdr-branch-options {
  max-height:min(420px,calc(100dvh - 160px)); overflow-y:auto; overscroll-behavior:contain;
  padding-right:2px; scrollbar-width:thin; scrollbar-color:var(--shell-line-strong) transparent;
}
.hdr-branch-option {
  border:1px solid var(--shell-line) !important; border-radius:var(--shell-radius-sm) !important;
  background:#fff !important; color:var(--shell-copy) !important; box-shadow:none !important;
}
.hdr-branch-option:hover,.hdr-branch-option:focus {
  border-color:#b9cec4 !important; background:#eef4f0 !important; color:var(--shell-ink) !important;
  box-shadow:0 8px 18px rgba(18,42,58,.08) !important;
}
.hdr-branch-option.is-active {
  border-color:#b8d5ca !important; background:#e8f1ed !important; color:var(--shell-ink) !important;
}
.hdr-branch-option-icon,.pm-avatar-lg,.pm-icon { border-radius:var(--shell-radius-sm) !important; }
.hdr-branch-option-icon {
  border:1px solid #d5ddd8 !important; background:#f2f5f2 !important;
}
.hdr-branch-option-icon-img { filter:none !important; opacity:1 !important; }
.hdr-branch-option-name,.pm-item-label { color:var(--shell-ink) !important; }
.hdr-branch-option-code {
  border:1px solid #efc98e !important; background:#fff3df !important; color:#86550d !important;
}
.hdr-branch-option-text { color:#5f6f7d !important; }
.hdr-branch-option-state {
  border:1px solid #d1d9d4 !important; border-radius:5px !important;
  background:#f4f6f3 !important; color:#53616b !important;
}
.hdr-branch-option.is-active .hdr-branch-option-state {
  border-color:#b5d5c8 !important; background:#dcece5 !important; color:var(--shell-green-dark) !important;
}
.hdr-branch-option:disabled { opacity:1 !important; }

/* User control */
.user-chip {
  min-height:40px !important; padding:4px 8px 4px 5px !important;
  border:1px solid rgba(255,255,255,.14) !important; border-radius:var(--shell-radius-sm) !important;
  background:rgba(255,255,255,.06) !important; color:#fff !important; box-shadow:none !important;
}
.user-chip:hover,.user-chip.show { background:rgba(255,255,255,.11) !important; border-color:rgba(255,255,255,.24) !important; }
.user-avatar { border:0 !important; border-radius:7px !important; background:var(--shell-green) !important; color:#fff !important; box-shadow:none !important; }
.online-dot { border-color:var(--shell-navy-2) !important; background:#66d3ad !important; }
.uc-name { color:#fff !important; font-size:10.5px !important; }.uc-role,.uc-chevron { color:rgba(226,239,241,.58) !important; }
.pm-item { border-radius:var(--shell-radius-sm) !important; }.pm-item:hover { background:#eef4f0 !important; }
.pm-role-pill { border-radius:5px !important; background:#e8f1ed !important; color:var(--shell-green-dark) !important; }
.pm-logout { border-radius:var(--shell-radius-sm) !important; background:#f8ecea !important; color:var(--shell-red) !important; border-color:#eed0cc !important; }
.pm-logout:hover { background:#f3dfdc !important; color:#963a35 !important; }

/* Footer */
.rt-footer {
  margin-top:auto !important; border-top:1px solid var(--shell-line) !important;
  background:var(--shell-surface) !important; box-shadow:none !important; backdrop-filter:none !important;
}
.rt-footer::before { display:none !important; }
.rt-footer-inner { max-width:1680px !important; padding:13px 24px !important; }
.rt-footer-name { color:var(--shell-ink) !important; font-size:10.5px !important; letter-spacing:.04em !important; }
.rt-footer-icon { color:var(--shell-green) !important; }.rt-footer-meta { color:var(--shell-muted) !important; }
.rt-social {
  width:30px !important; height:30px !important; border:1px solid var(--shell-line) !important;
  border-radius:7px !important; background:var(--shell-soft) !important; color:var(--shell-muted) !important; box-shadow:none !important;
}
.rt-social:hover { transform:translateY(-1px) !important; border-color:var(--shell-line-strong) !important; background:#fff !important; box-shadow:none !important; }

@media(max-width:991.98px){.app-header-inner{padding:0 16px !important}.hdr-branch-current{max-width:110px !important}}
@media(max-width:767.98px){.app-header,.app-header-inner{min-height:58px !important;height:58px !important}.brand-mark{width:34px !important;height:34px !important}.uc-info,.hdr-branch-meta{display:none !important}.hdr-branch-trigger,.user-chip{width:38px !important;justify-content:center !important;padding:4px !important}.hdr-branch-chevron,.uc-chevron{display:none !important}}
@media(max-width:575.98px){.app-header-inner{padding:0 12px !important}.brand-title{font-size:13px !important}.rt-footer-inner{padding:12px 14px !important;gap:10px !important}.rt-footer-social{width:100%}}
@media(prefers-reduced-motion:reduce){.app-header *,.rt-footer *{animation:none !important;transition:none !important}}
