/* DMD Liner visual layer shared by the website and the Tracker WebView. */
:root {
  --red: #f51e39;
  --red-hot: #ff4b5f;
  --dmd-display: "Bahnschrift", "Arial Narrow", "Segoe UI", sans-serif;
  --dmd-glow: 0 0 18px #ff244052, 0 0 44px #ed173128;
  font-family: "Segoe UI Variable", "Segoe UI", Arial, sans-serif;
}

body { background: #090a0e; }
.dmd-workspace {
  background:
    radial-gradient(ellipse 58% 45% at 76% 4%, #82203320, transparent 75%),
    radial-gradient(ellipse 50% 60% at 10% 65%, #3b102016, transparent 75%),
    #090a0e;
}
.dmd-workspace::before {
  content: ""; position: fixed; inset: 0 0 0 228px; z-index: 0; pointer-events: none;
  background: linear-gradient(#fff 1px, transparent 1px), linear-gradient(90deg, #fff 1px, transparent 1px);
  background-size: 52px 52px; opacity: .018;
}
.dmd-workspace > * { position: relative; z-index: 1; }
.dmd-sidebar {
  background: linear-gradient(160deg, #171016f7, #0b0c10 54%, #0b0b0df7);
  border-right-color: #ff324b38;
  box-shadow: 14px 0 44px #0008, inset -1px 0 #ff375417;
}
.dmd-sidebar::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, #8f0719, #ff344d, #ffb17b, transparent);
  box-shadow: var(--dmd-glow);
}
.dmd-logo b, .mobile-toolbar strong {
  font-family: var(--dmd-display); font-weight: 900; letter-spacing: -.055em;
  text-shadow: 0 0 18px #fa193760;
}
.dmd-logo b { font-size: 39px; }
.dmd-sidebar nav button {
  transition: background-color .22s ease, color .22s ease, transform .22s ease, box-shadow .22s ease;
}
.dmd-sidebar nav button:hover:not(.selected) {
  transform: translateX(4px); background: linear-gradient(90deg, #f72b4b20, #ffffff05);
  color: #fff;
}
.dmd-sidebar nav button.selected {
  background: linear-gradient(100deg, #a3091e, #f01b37 66%, #ff485b);
  box-shadow: 0 6px 25px #ed153c46, inset 0 1px #ffffff38;
}
.sidebar-photo img { filter: contrast(1.12) saturate(1.18); }
.sidebar-photo::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(0deg, #0b0c10 2%, transparent 65%);
}
.sidebar-photo strong { z-index: 1; text-shadow: 0 0 18px #ff24407d, 0 3px 8px #000; }
.dmd-banner { border-bottom-color: #ff3e585e; box-shadow: 0 10px 38px #0008; }
.dmd-banner-photo { filter: contrast(1.1) saturate(1.16); }
.dmd-banner::before {
  content: ""; position: absolute; z-index: 1; inset: 0; pointer-events: none;
  background: linear-gradient(112deg, transparent 30%, #ff546014 48%, transparent 65%);
  background-size: 200% 100%; animation: dmd-light-pass 16s ease-in-out infinite;
}
.banner-slogan { font-size: clamp(20px, 1.8vw, 34px); text-shadow: 0 3px 7px #000, 0 0 18px #ffeff26c; }
.weather, .header-profile, .tool-button {
  background: linear-gradient(145deg, #1e1e24e8, #0e0e15df);
  border-color: #ffffff35; backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 10px 28px #0007, inset 0 1px #ffffff14;
}
.tool-button, .header-profile { transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease; }
.tool-button:hover, .header-profile:hover { transform: translateY(-2px); border-color: #ff3d60; box-shadow: var(--dmd-glow); }
.header-profile img, .profile-main > img { box-shadow: 0 0 0 3px #ff365435, 0 0 20px #fa28493b; }
.dashboard-body { margin-top: -11px; }
.dmd-panel, .dmd-workspace .panel, .panel {
  background: linear-gradient(145deg, #1d1f27f2, #111218f5 72%);
  border-color: #ffffff26; box-shadow: 0 14px 36px #0004, inset 0 1px #ffffff0d;
}
.dmd-panel { border-radius: 12px; }
.dmd-workspace .panel, .panel { border-radius: 12px; }
.dmd-stats { gap: 12px; margin-bottom: 12px; }
.dmd-stat {
  position: relative; background: linear-gradient(145deg, #22232bf5, #121319f4);
  border-color: #ffffff30; overflow: hidden;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.dmd-stat::before {
  content: ""; position: absolute; left: 0; top: 12px; bottom: 12px; width: 2px;
  background: linear-gradient(transparent, #ff4256, transparent); box-shadow: 0 0 11px #ff2440;
}
.dmd-stat > svg { color: #ff5768; filter: drop-shadow(0 0 9px #ff34536c); }
.dmd-stat b { font-family: var(--dmd-display); letter-spacing: -.02em; font-size: clamp(18px, 1.5vw, 25px); }
.dmd-panel-title { background: linear-gradient(90deg, #ffffff09, transparent); }
.dmd-panel-title h2, .page-heading h1, .connection h1, .site-release h2 {
  font-family: var(--dmd-display); letter-spacing: .015em; font-weight: 750;
}
.dmd-panel-title svg { filter: drop-shadow(0 0 7px #ff354a7a); }
.dashboard-grid { gap: 12px; }
.dmd-empty { color: #bec1cb; }
.dmd-table-scroll tr:hover td, .panel table tr:hover td { background: #ff334b0a; }
.primary, .map-action, .map-toolbar button {
  background: linear-gradient(125deg, #ad1027, #f32441 55%, #ff4b60);
  box-shadow: 0 8px 24px #fa213834, inset 0 1px #ffffff42;
  transition: transform .23s ease, filter .23s ease, box-shadow .23s ease;
}
.primary:hover:not(:disabled), .map-action:hover, .map-toolbar button:hover {
  transform: translateY(-2px); filter: brightness(1.12);
  box-shadow: 0 12px 32px #fb213e66, inset 0 1px #ffffff55;
}
.secondary { transition: background-color .2s ease, border-color .2s ease, transform .2s ease; }
.secondary:hover:not(:disabled) { background: #ff344018; border-color: #ff455d69; transform: translateY(-1px); }
.text-link { text-underline-offset: 3px; transition: color .2s ease; }
.text-link:hover { color: #ff9ba7; }
.eyebrow { font-family: var(--dmd-display); letter-spacing: .19em; }
.login {
  background-image: linear-gradient(90deg, #05050825, #05050818 45%, #0505084b), url('/login-welcome.png');
}
.login::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(circle at 78% 75%, #f11d3c2a, transparent 34%);
  animation: dmd-ambient-glow 9s ease-in-out infinite alternate;
}
.login form.login-card {
  border-color: #ff485d9c; background: linear-gradient(155deg, #15151edc, #08090eef);
  box-shadow: 0 24px 70px #000b, 0 0 36px #ff153b32, inset 0 1px #ffffff20;
  animation: login-enter .65s cubic-bezier(.2,.8,.2,1) both, dmd-card-breath 7s ease-in-out infinite 1s;
}
.login .eyebrow::before { content: "✦"; font-size: 12px; margin-right: 9px; text-shadow: 0 0 12px #ff526b; }
.login h1 { font-family: var(--dmd-display); font-size: clamp(28px, 2.4vw, 36px); font-weight: 800; letter-spacing: .01em; }
.login .login-input { border-color: #ffffff28; background: #252833dc; transition: border-color .2s ease, box-shadow .2s ease; }
.login-input:focus-within { box-shadow: 0 0 18px #ff304b38; }
.login .primary { font-family: var(--dmd-display); letter-spacing: .03em; font-size: 16px; }
.tracker-status { border-top: 1px solid #ffffff15; }
.map-live-dot { animation: dmd-live-pulse 2.3s ease-in-out infinite; }
.site-release { border-left-color: #ff3a54; box-shadow: 0 10px 35px #0003; }
.release-notice { box-shadow: 0 0 25px #ed20342b; }
@media (hover:hover) {
  .dmd-stat:hover { transform: translateY(-3px); border-color: #ff465b8a; box-shadow: 0 16px 36px #0008, var(--dmd-glow); }
  .dmd-panel:not(.dmd-stat):hover { border-color: #ff52603f; }
}
@media (max-width: 800px) { .dmd-workspace::before { left: 205px; } }
@media (max-width: 700px) {
  .dmd-workspace::before { left: 0; }
  .dmd-banner { height: 220px; }
  .dmd-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dmd-stat { min-height: 77px; padding: 10px; gap: 9px; }
  .dmd-stat > svg { width: 24px; height: 24px; }
  .dmd-stat b { font-size: clamp(14px, 3.6vw, 20px); white-space: normal; }
  .dmd-stat small { font-size: 10px; }
  .mobile-toolbar { background: #111017f5; border-bottom-color: #ff345540; box-shadow: 0 6px 23px #0008; }
  .login { background-image: linear-gradient(#0505085c, #0505089c), url('/login-welcome.png'); }
  .login form.login-card { backdrop-filter: blur(18px); }
}
@keyframes dmd-light-pass { 0%, 28% { background-position: 160% 0; opacity: 0; } 52% { opacity: 1; } 72%, 100% { background-position: -90% 0; opacity: 0; } }
@keyframes dmd-ambient-glow { from { opacity: .38; transform: scale(.95); } to { opacity: .88; transform: scale(1.06); } }
@keyframes dmd-card-breath { 0%, 100% { box-shadow: 0 24px 70px #000b, 0 0 25px #ff153b27, inset 0 1px #ffffff20; } 50% { box-shadow: 0 24px 70px #000b, 0 0 43px #ff153b49, inset 0 1px #ffffff20; } }
@keyframes dmd-live-pulse { 0%, 100% { box-shadow: 0 0 5px #35d677; } 50% { box-shadow: 0 0 13px #35d677, 0 0 23px #35d6779a; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
