/* ============================================================
   01 THE PLATFORM · KIT · v1.0 · MMXXVI
   Shared family stylesheet. Inherited by all views.
   Locked variables (parent system from SOTER):
     - Obsidian #1C1C1E surface
     - Cream #F5F5F0 text
     - DM Mono (display / structural)
     - Figtree (body)
   Signature accent: not yet assigned. Pure greyscale + cream.
   ============================================================ */

:root {
  /* surface family */
  --obsidian:    #1C1C1E;
  --charcoal:    #28282B;
  --charcoal-2:  #2E2E32;
  --charcoal-3:  #353539;
  --ash:         #B5B0A8;
  --ash-30:      rgba(181, 176, 168, 0.30);
  --ash-15:      rgba(181, 176, 168, 0.15);
  --ash-08:      rgba(181, 176, 168, 0.08);

  /* text family */
  --cream:       #F5F5F0;
  --cream-70:    rgba(245, 245, 240, 0.70);
  --cream-50:    rgba(245, 245, 240, 0.50);
  --cream-30:    rgba(245, 245, 240, 0.30);
  --cream-15:    rgba(245, 245, 240, 0.15);

  /* typography */
  --font-mono:   'DM Mono', ui-monospace, monospace;
  --font-body:   'Figtree', system-ui, sans-serif;

  /* layout constants */
  --rail-w:           220px;
  --rail-w-collapsed: 28px;
  --console-h:        150px;
  --console-h-collapsed: 22px;
  --status-h:         26px;
  --topbar-h:         48px;

  /* motion */
  --ease:      cubic-bezier(0.22, 1, 0.36, 1);
  --ease-fast: cubic-bezier(0.4, 0, 0.2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--obsidian);
  color: var(--cream);
  font-family: var(--font-body);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  height: 100%;
  overflow: hidden;
  user-select: none;
}

/* ============================================================
   TOPBAR (shared across views)
   ============================================================ */
.topbar {
  background: var(--obsidian);
  border-bottom: 1px solid var(--ash-15);
  display: flex; align-items: center;
  padding: 0 20px; gap: 28px;
  height: var(--topbar-h);
}
.brand {
  font-family: var(--font-mono); font-weight: 500;
  font-size: 11px; letter-spacing: 0.20em;
  color: var(--cream); text-transform: uppercase;
  cursor: pointer;
}
.brand .num { color: var(--cream-50); margin-right: 12px; }

.crumbs {
  font-family: var(--font-mono); font-size: 10px;
  letter-spacing: 0.16em; color: var(--cream-50);
  text-transform: uppercase;
}
.crumbs .sep { color: var(--cream-30); margin: 0 9px; }
.crumbs .here { color: var(--cream); }

.topbar-right {
  margin-left: auto;
  display: flex; align-items: center; gap: 14px;
}

.view-switch {
  display: flex; border: 1px solid var(--ash-15);
}
.view-switch a {
  background: transparent; color: var(--cream-50);
  font-family: var(--font-mono); font-size: 9px;
  letter-spacing: 0.18em; text-transform: uppercase;
  padding: 5px 11px;
  text-decoration: none;
  border-right: 1px solid var(--ash-15);
  transition: all 0.15s var(--ease-fast);
}
.view-switch a:last-child { border-right: none; }
.view-switch a:hover { color: var(--cream); background: var(--ash-08); }
.view-switch a.on { background: var(--ash-15); color: var(--cream); }

.panel-toggles { display: flex; border: 1px solid var(--ash-15); }
.panel-toggles button {
  background: transparent; border: none; color: var(--cream-50);
  font-family: var(--font-mono); font-size: 9px;
  letter-spacing: 0.16em; text-transform: uppercase;
  padding: 5px 9px; cursor: pointer;
  transition: all 0.15s var(--ease-fast);
  border-right: 1px solid var(--ash-15);
}
.panel-toggles button:last-child { border-right: none; }
.panel-toggles button:hover { color: var(--cream); }
.panel-toggles button.off { background: var(--ash-08); color: var(--cream-30); }

.topbar .name {
  font-family: var(--font-mono); font-size: 10px;
  letter-spacing: 0.16em; color: var(--cream-70);
  text-transform: uppercase;
  padding-left: 16px;
  border-left: 1px solid var(--ash-15);
  height: 20px;
  display: flex; align-items: center;
}

/* ============================================================
   STATUS BAR (shared)
   ============================================================ */
.status {
  background: var(--obsidian);
  border-top: 1px solid var(--ash-15);
  padding: 0 20px;
  display: flex; align-items: center; gap: 22px;
  font-family: var(--font-mono); font-size: 9px;
  letter-spacing: 0.18em; color: var(--cream-30);
  text-transform: uppercase;
  overflow: hidden;
  height: var(--status-h);
}
.status .live { display: inline-flex; align-items: center; gap: 6px; }
.status .live::before {
  content: '';
  width: 5px; height: 5px;
  background: var(--cream-50); border-radius: 50%;
  animation: pulse 2.5s infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
.status .right-meta { margin-left: auto; display: flex; gap: 22px; }

/* ============================================================
   CONTINENT MARKS (geometric glyphs)
   Used everywhere a continent appears.
   ============================================================ */
.mark {
  width: 14px; height: 14px;
  flex-shrink: 0; position: relative;
  margin-top: 1px;
}
.mini-mark { width: 10px; height: 10px; flex-shrink: 0; position: relative; }

.mark-archiva::before, .mark-archiva::after {
  content: ''; position: absolute; background: var(--cream-70);
}
.mark-archiva::before { left: 0; top: 0; width: 100%; height: 1px; }
.mark-archiva::after  { left: 0; bottom: 0; width: 100%; height: 1px; }
.mark-archiva-mid {
  position: absolute; left: 0; top: 50%; width: 100%; height: 1px;
  background: var(--cream-70); transform: translateY(-50%);
}

.mark-citadel::before {
  content: ''; position: absolute; inset: 0;
  border: 1px solid var(--cream-70);
}
.mark-citadel::after {
  content: ''; position: absolute; left: 50%; top: 50%;
  width: 30%; height: 30%; background: var(--cream-70);
  transform: translate(-50%, -50%);
}

.mark-ordo::before {
  content: ''; position: absolute; left: 0; top: 50%;
  width: 100%; height: 1px; background: var(--cream-70);
}
.mark-ordo::after {
  content: ''; position: absolute; left: 50%; top: 0;
  width: 1px; height: 100%; background: var(--cream-70);
}

.mark-porta {
  border-top: 1px solid var(--cream-70);
  border-left: 1px solid var(--cream-70);
  border-right: 1px solid var(--cream-70);
}
.mark-porta::after {
  content: ''; position: absolute; left: 50%; top: 22%;
  width: 28%; height: 78%; background: var(--cream-70);
  transform: translateX(-50%);
}

.mark-tabula { border: 1px solid var(--cream-70); }
.mark-tabula::before {
  content: ''; position: absolute; left: 18%; top: 30%;
  right: 18%; height: 1px; background: var(--cream-70);
}
.mark-tabula::after {
  content: ''; position: absolute; left: 18%; top: 60%;
  right: 36%; height: 1px; background: var(--cream-70);
}

.mark-origin {
  border-radius: 50%;
  border: 1px solid var(--cream-70);
}
.mark-origin::after {
  content: ''; position: absolute; left: 50%; top: 50%;
  width: 30%; height: 30%; background: var(--cream-70);
  border-radius: 50%; transform: translate(-50%, -50%);
}

.mark-vita::before {
  content: ''; position: absolute; left: 50%; top: 0;
  width: 1px; height: 100%; background: var(--cream-70);
  transform: translateX(-50%);
}
.mark-vita::after {
  content: ''; position: absolute; left: 0; top: 50%;
  width: 100%; height: 1px; background: var(--cream-70);
  transform: translateY(-50%);
}

.mark-futura::before {
  content: ''; position: absolute; left: 0; bottom: 0;
  width: 100%; height: 1px; background: var(--cream-70);
}
.mark-futura::after {
  content: ''; position: absolute; right: 0; top: 0;
  width: 1px; height: 100%; background: var(--cream-70);
}
.mark-futura-diag {
  position: absolute; left: 0; bottom: 0;
  width: 140%; height: 1px; background: var(--cream-70);
  transform: rotate(-45deg); transform-origin: 0 100%;
}

.mark-nexus::before, .mark-nexus::after {
  content: ''; position: absolute;
  width: 55%; height: 55%;
  border: 1px solid var(--cream-70);
}
.mark-nexus::before { left: 0; top: 0; }
.mark-nexus::after  { right: 0; bottom: 0; }

.mark-axis::before {
  content: ''; position: absolute; left: 50%; top: 0;
  width: 1px; height: 100%; background: var(--cream);
  transform: translateX(-50%);
}
.mark-axis::after {
  content: ''; position: absolute; left: 50%; top: 50%;
  width: 55%; height: 55%; border: 1px solid var(--cream);
  transform: translate(-50%, -50%);
}

.mark-domina::before {
  content: ''; position: absolute; left: 50%; top: 50%;
  width: 70%; height: 70%; border: 1px solid var(--cream-70);
  transform: translate(-50%, -50%) rotate(45deg);
}

/* ============================================================
   DRAG GHOST
   ============================================================ */
.drag-ghost {
  position: fixed; background: var(--charcoal-3);
  border: 1px solid var(--cream-50); padding: 10px 14px;
  font-family: var(--font-mono); font-size: 10px;
  letter-spacing: 0.18em; color: var(--cream); text-transform: uppercase;
  pointer-events: none; z-index: 1000;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
  max-width: 280px;
  display: flex; flex-direction: column; gap: 4px;
}
.drag-ghost .ghost-meta {
  font-size: 8px; color: var(--cream-50);
  letter-spacing: 0.15em;
}
