/* ES Beck Capital — shared styles (dark navy "desk" palette) */
:root {
  --ground: #0A1226;
  --surface: #111C38;
  --app-bg: #0E1630;
  --line: #1C2850;
  --line-strong: #22305A;
  --text: #E8ECF6;
  --text-soft: #C9D2EA;
  --muted: #9AA6C4;
  --faint: #8F9BBB;
  --brand: #1E3A8A;
  --action: #2F54D6;
  --action-hover: #3A61E6;
  --link: #A9BCFF;
  --live-text: #7EE2B0;
  --live-bg: #0E2A24;
  --live-line: #1D5244;
  --live-dot: #3DD68C;
  --off-text: #FFC58A;
  --off-bg: #2E1F0E;
  --off-line: #5A3A14;
  --off-dot: #F59E3B;
  --off-copy: #D9C3A8;
  --mono: 'IBM Plex Mono', ui-monospace, Consolas, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body { height: 100%; }

body {
  font-family: 'Instrument Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  background: var(--ground);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--link); }

/* ── Brand ── */
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
}

.monogram {
  width: 34px;
  height: 34px;
  border-radius: 7px;
  background: var(--brand);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  flex: none;
}

/* ── Status pill ── */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--muted);
  white-space: nowrap;
}

.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }

.pill[data-status="live"] { color: var(--live-text); background: var(--live-bg); border-color: var(--live-line); }
.pill[data-status="live"] .dot { background: var(--live-dot); }
.pill[data-status="offline"] { color: var(--off-text); background: var(--off-bg); border-color: var(--off-line); }
.pill[data-status="offline"] .dot { background: var(--off-dot); }

/* ── Site header / footer (home + about) ── */
.site-header {
  padding: 20px 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}

.site-header nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 15px;
  padding: 12px 6px;
}

.site-header nav a:hover,
.site-header nav a[aria-current="page"] { color: var(--text); }

.site-footer {
  padding: 18px 24px;
  text-align: center;
  font-size: 13px;
  color: var(--faint);
  border-top: 1px solid var(--line);
}

.page {
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

/* ── Home: the door ── */
.door {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 16px 64px;
}

.door-inner {
  width: 100%;
  max-width: 560px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.door h1 {
  text-align: center;
  font-size: 48px;
  line-height: 1.1;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.door-card {
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}

.door-card .pill { align-self: flex-start; }

.enter {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--action);
  color: #fff;
  text-decoration: none;
  font-size: 18px;
  font-weight: 600;
  padding: 18px;
  border-radius: 10px;
  transition: background 0.15s;
}

.enter:hover { background: var(--action-hover); }

.offline-note { font-size: 15px; line-height: 1.6; color: var(--off-copy); }

[hidden] { display: none !important; }

/* ── Tracker page ── */
.app-page {
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.app-bar {
  height: 44px;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 8px 0 12px;
  background: var(--ground);
  border-bottom: 1px solid var(--line);
}

.app-bar .brand { font-size: 14px; min-width: 0; }
.app-bar .monogram { width: 24px; height: 24px; border-radius: 5px; font-size: 11px; }
.app-bar .pill { font-size: 11px; padding: 3px 8px; gap: 6px; }
.app-bar .pill .dot { width: 7px; height: 7px; }

.exit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 44px;
  padding: 0 12px;
  color: #B4BED8;
  text-decoration: none;
  font-size: 14px;
}

.exit:hover { color: var(--text); }

.app-frame {
  flex: 1 1 auto;
  min-height: 0;
  background: var(--app-bg);
  display: flex;
}

.app-frame iframe {
  flex: 1 1 auto;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.app-message {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 48px 24px;
  text-align: center;
}

.app-message h2 { font-size: 22px; font-weight: 600; }
.app-message p { max-width: 420px; font-size: 15px; line-height: 1.6; color: #B4BED8; }

/* ── About ── */
.about {
  flex: 1 1 auto;
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
  padding: 56px 24px 80px;
}

.about h1 { font-size: 40px; font-weight: 600; letter-spacing: -0.02em; margin-bottom: 8px; }
.about .section { margin-top: 40px; }
.about h2 { font-size: 17px; font-weight: 600; margin-bottom: 6px; }
.about p { font-size: 15px; color: var(--muted); line-height: 1.65; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  padding: 20px;
}

.card h3 { font-size: 15px; font-weight: 600; margin-bottom: 6px; }
.card p { font-size: 14px; }

@media (max-width: 520px) {
  .door h1 { font-size: 38px; }
  .door-card { padding: 22px; }
}
