:root {
  --bg: #071016;
  --panel: rgba(10, 16, 21, .92);
  --panel-2: rgba(16, 24, 31, .94);
  --line: rgba(255,255,255,.12);
  --text: #eef7fb;
  --muted: #98afbb;
  --gold: #d7a84b;
  --red: #ef4444;
  --green: #6ee35f;
  --blue: #4bb3d7;
  --shadow: 0 24px 70px rgba(0,0,0,.48);
  font-family: "Segoe UI", Arial, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; color: var(--text); background: #05080b; }
.background { position: fixed; inset: 0; z-index: -2; background: linear-gradient(120deg, rgba(0,0,0,.82), rgba(0,0,0,.42)), url("/sf-bg-dashboard.jpg") center/cover; }
.background:after { content: ""; position: fixed; inset: 0; background: radial-gradient(circle at 70% 25%, rgba(75,179,215,.18), transparent 34%), linear-gradient(180deg, transparent, rgba(0,0,0,.76)); }
.shell { width: min(1500px, calc(100% - 32px)); margin: 0 auto; padding: 18px 0 34px; }
.header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 22px; background: linear-gradient(180deg, rgba(20,27,33,.96), rgba(7,10,13,.96)); border: 1px solid var(--line); border-radius: 8px 8px 0 0; box-shadow: var(--shadow); }
.brand { display: flex; align-items: center; gap: 16px; }
.brand img { width: 72px; height: 72px; object-fit: contain; }
.brand strong { display: block; font-size: 34px; text-transform: uppercase; letter-spacing: .04em; }
.brand span { display: block; margin-top: 5px; color: var(--gold); font-size: 13px; text-transform: uppercase; font-weight: 800; }
.header-actions { display: flex; align-items: center; gap: 12px; }
.status-pill, .mini { display: inline-flex; align-items: center; gap: 8px; min-height: 34px; padding: 0 13px; border: 1px solid var(--line); border-radius: 999px; background: rgba(255,255,255,.05); color: var(--muted); text-transform: uppercase; font-size: 12px; font-weight: 800; }
#connDot { width: 9px; height: 9px; border-radius: 50%; background: #777; box-shadow: 0 0 12px currentColor; }
#connDot.on { color: var(--green); background: var(--green); }
#connDot.off { color: var(--red); background: var(--red); }
.tabs { display: grid; grid-template-columns: repeat(7, 1fr); background: rgba(5,8,11,.96); border: 1px solid var(--line); border-top: 0; border-radius: 0 0 8px 8px; overflow: hidden; }
.tabs button { min-height: 58px; border: 0; border-left: 1px solid rgba(255,255,255,.08); color: #cfe1e8; background: transparent; cursor: pointer; text-transform: uppercase; font-weight: 900; letter-spacing: .03em; }
.tabs button:first-child { border-left: 0; }
.tabs button.active, .tabs button:hover { color: #fff; background: linear-gradient(180deg, rgba(215,168,75,.24), rgba(215,168,75,.06)); box-shadow: inset 0 -3px 0 var(--gold); }
.hero { display: flex; align-items: center; justify-content: space-between; gap: 22px; margin: 18px 0; padding: 28px 30px; background: linear-gradient(100deg, rgba(11,18,24,.95), rgba(15,20,24,.82)); border: 1px solid var(--line); box-shadow: var(--shadow); }
.hero small, .download-panel small { color: var(--gold); font-weight: 900; letter-spacing: .18em; }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 8px; font-size: clamp(34px, 5vw, 58px); line-height: .95; text-transform: uppercase; }
h2 { margin-bottom: 0; font-size: 20px; text-transform: uppercase; }
p { color: #b8cbd4; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 20px; border: 1px solid rgba(255,255,255,.16); color: var(--text); background: linear-gradient(180deg, #1b242c, #080c10); text-decoration: none; text-transform: uppercase; font-weight: 900; cursor: pointer; }
.button.primary { color: #ffe7a8; border-color: rgba(215,168,75,.65); background: linear-gradient(180deg, #72541c, #211707); }
.button.big { min-height: 66px; padding: 0 32px; font-size: 18px; }
.button.full { width: 100%; }
.button.disabled { pointer-events: none; opacity: .45; }
.warning { margin: 18px 0; padding: 14px 18px; border: 1px solid rgba(215,168,75,.45); background: rgba(56,38,10,.8); color: #ffe7a8; }
.hidden { display: none !important; }
.page { display: none; }
.page.active { display: block; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 18px; }
.metrics article, .panel, .download-panel { background: var(--panel); border: 1px solid var(--line); box-shadow: var(--shadow); }
.metrics article { min-height: 136px; padding: 22px; text-align: center; }
.metrics span { color: var(--muted); text-transform: uppercase; font-weight: 900; }
.metrics b { display: block; margin: 12px 0; color: var(--gold); font-size: 44px; line-height: 1; }
.metrics small { color: #92a9b5; }
.grid { display: grid; gap: 16px; }
.grid.two { grid-template-columns: 1fr 1fr; }
.panel { overflow: hidden; }
.panel-head { min-height: 58px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 0 18px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.035); }
.feed { padding: 14px; display: grid; gap: 10px; }
.feed-row, .service-card { padding: 14px; border: 1px solid rgba(255,255,255,.08); background: var(--panel-2); }
.feed-row b, .feed-row span, .feed-row small { display: block; }
.feed-row span, .feed-row small { color: var(--muted); margin-top: 4px; }
.services { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; padding: 16px; }
.service-card { display: grid; grid-template-columns: 52px 1fr; align-items: center; gap: 14px; }
.service-card img { width: 52px; height: 52px; object-fit: contain; }
.service-card b, .service-card span, .service-card small { display: block; }
.online { color: var(--green); font-weight: 900; text-transform: uppercase; }
.offline { color: var(--red); font-weight: 900; text-transform: uppercase; }
.table-wrap { overflow: auto; }
table { width: 100%; min-width: 900px; border-collapse: collapse; }
th, td { padding: 14px 16px; border-bottom: 1px solid rgba(255,255,255,.08); text-align: left; }
th { color: var(--muted); text-transform: uppercase; font-size: 12px; }
td small { display: block; color: var(--muted); margin-top: 4px; }
input, select { min-height: 42px; width: 100%; padding: 0 12px; border: 1px solid var(--line); color: var(--text); background: #070b0f; outline: 0; }
.form { padding: 18px; display: grid; gap: 14px; }
.form label { display: grid; gap: 7px; color: var(--muted); text-transform: uppercase; font-size: 12px; font-weight: 900; }
.form.compact { grid-template-columns: 1fr 1fr auto; align-items: end; border-top: 1px solid var(--line); }
.profile-panel { margin-top: 16px; }
.profile-box { padding: 18px; color: var(--muted); }
.profile-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.profile-grid article { padding: 14px; background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.08); }
.profile-grid span { display: block; color: var(--muted); text-transform: uppercase; font-size: 11px; font-weight: 900; }
.profile-grid b { display: block; margin-top: 8px; color: var(--gold); font-size: 22px; }
.download-panel { display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 32px; }
.download-panel h2 { margin: 6px 0 10px; font-size: 42px; }
.download-info { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.download-info span { padding: 8px 12px; border: 1px solid var(--line); background: rgba(255,255,255,.05); color: var(--muted); }
pre { min-height: 420px; max-height: 620px; overflow: auto; margin: 0; padding: 18px; color: #cce3ee; background: #030506; font: 13px/1.55 Consolas, monospace; }
.empty { padding: 24px; color: var(--muted); }
footer { padding: 22px 0 0; color: #8096a1; text-align: center; text-transform: uppercase; font-size: 12px; letter-spacing: .08em; }
@media (max-width: 980px) {
  .metrics, .grid.two, .profile-grid { grid-template-columns: 1fr 1fr; }
  .tabs { grid-template-columns: repeat(2, 1fr); }
  .hero, .download-panel, .header { align-items: stretch; flex-direction: column; }
  .header-actions { justify-content: space-between; }
}
@media (max-width: 620px) {
  .shell { width: calc(100% - 18px); }
  .metrics, .profile-grid, .form.compact { grid-template-columns: 1fr; }
  .brand strong { font-size: 25px; }
  .brand img { width: 56px; height: 56px; }
}
