/* hub/ui/css/base.css — Graystone OS v3.0 base tokens + typography.
   Brand values per CLAUDE.md. Hub uses 6-12px radii (utilitarian) —
   the 2-3px landing-page radii are NOT ported here.
*/

:root {
  /* Primary palette — Graystone brand identity (Phase 6A).
     Values extracted from the GMG logo, replacing the prior near-navy
     ink tones. The variable names stay (--ink / --ink-2 / --white)
     so every component that references them inherits the new palette
     automatically. New canonical names are exported alongside:
     --bg, --surface, --surface-deep, --text, --text-muted, --stone*. */
  --ink:    #0A0A0A;   /* near-black, the logo's ground */
  --ink-2:  #141414;   /* card / panel surface */
  --navy:   #1A3C5E;
  --gold:   #C8A04A;   /* matches the GRAYSTONE wordmark */
  --gold-2: #E0BC6C;
  --gold-3: #907030;
  --white:  #F0EDE8;   /* warm near-white text on near-black */
  --silver: #909090;

  /* Stone palette — extracted from the G mark gradient. Used for
     muted text, borders, and any panel chrome that should sit between
     the gold accents and the dark surfaces. */
  --stone:       #8A8680;
  --stone-warm:  #B8B1A2;
  --stone-light: #D3CBB9;

  /* Status colors (hub-only — never on the marketing landing page). */
  --green:  #059669;
  --amber:  #D97706;
  --red:    #DC2626;

  /* Translucent whites for depth hierarchy. */
  --w80: rgba(242,240,234, .80);
  --w50: rgba(242,240,234, .50);
  --w30: rgba(242,240,234, .30);
  --w12: rgba(242,240,234, .12);
  --w06: rgba(242,240,234, .06);

  /* Surfaces. */
  --bg:           var(--ink);     /* #0A0A0A */
  --surface:      var(--ink-2);   /* #141414 */
  --surface-deep: #1A1A1A;        /* nested elements */
  --surface-2:    rgba(242,240,234, .04);
  --border:       rgba(200,160,74, .25);
  --border-2:     rgba(242,240,234, .12);
  --hairline:     rgba(200,160,74, .15);

  /* Spec-named text aliases (Phase 6A). Components new and old can
     reference --text / --text-muted as the canonical names. */
  --text:       var(--white);     /* #F0EDE8 */
  --text-muted: var(--stone);     /* #8A8680 */

  /* Typography. */
  --serif: 'Playfair Display', Georgia, serif;
  --sans:  'DM Sans', system-ui, -apple-system, sans-serif;
  --mono:  'DM Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  /* Fluid type scale. */
  --t-h1:    clamp(36px, 5vw, 60px);
  --t-h2:    clamp(28px, 3.5vw, 40px);
  --t-h3:    24px;
  --t-body:  15px;
  --t-small: 13px;
  --t-eyebrow: 11px;

  /* Spacing. */
  --gutter: clamp(20px, 4vw, 48px);
  --section-pad: 60px;
  --radius:    8px;
  --radius-sm: 6px;
  --radius-xs: 3px;

  /* Animation. */
  --ease: cubic-bezier(.2, .6, .2, 1);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--white);
  font-family: var(--sans);
  font-size: var(--t-body);
  font-weight: 400;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Subtle SVG noise overlay for film-grain texture. .04 opacity, fixed,
   pointer-events:none — same pattern as the landing page's body::before. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: .04;
  background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)' opacity='.6'/></svg>");
}

#gs-shell {
  position: relative;
  z-index: 2;
  min-height: 100vh;
}

/* Headings — Playfair for display contexts only. */
h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 700;
  margin: 0 0 12px;
  color: var(--white);
}
h1 { font-size: var(--t-h1); line-height: 1.05; font-weight: 900; }
h2 { font-size: var(--t-h2); line-height: 1.15; }
h3 { font-size: var(--t-h3); line-height: 1.25; }

p { margin: 0 0 12px; }

a {
  color: var(--gold);
  text-decoration: none;
  border-bottom: 1px solid var(--gold-3);
  transition: color .15s var(--ease), border-color .15s var(--ease);
}
a:hover { color: var(--gold-2); border-color: var(--gold-2); }

em, .accent { color: var(--gold); font-style: italic; }

/* Eyebrow / small-caps DM Mono labels — uppercase, letter-spaced. */
.eyebrow,
.small-caps {
  font-family: var(--mono);
  font-size: var(--t-eyebrow);
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold);
}

/* Muted text. */
.muted   { color: var(--w50); }
.muted-2 { color: var(--w30); }

/* Layout primitives — page container with gutter. */
.page {
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--section-pad) var(--gutter);
}
.row     { display: flex; gap: 16px; align-items: center; }
.row-end { display: flex; gap: 16px; align-items: center; justify-content: flex-end; }
.stack   { display: flex; flex-direction: column; gap: 16px; }
.grid-2  { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3  { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; }
.grid-4  { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }

/* SHELL — top nav + body container. */
.gs-nav {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 16px;
  /* min-height tuned to the rendered logo: the full GMG logo at
     120px wide produces a comfortable 72px bar. The min-height
     keeps the bar steady before the image loads (no layout shift). */
  min-height: 72px;
  padding: 12px var(--gutter);
  background: rgba(10,10,10,.88);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--hairline);
}
.gs-nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--serif);
  font-weight: 900;
  font-size: 18px;
  color: var(--text);
  letter-spacing: .02em;
  text-decoration: none;
  cursor: pointer;
  transition: opacity .15s var(--ease);
}
.gs-nav-brand:hover { opacity: .82; }
.gs-nav-mark {
  width: 28px; height: 28px;
  border: 1.5px solid var(--gold);
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  color: var(--gold);
  font-family: var(--serif);
  font-weight: 900;
  font-size: 16px;
}
.gs-nav-logo {
  /* Phase 6A · full GMG logo (logo_full_240.png) — locked to 120px
     width with height: auto so the G mark + GRAYSTONE MEDIA GROUP
     wordmark render at their native aspect ratio. The image carries
     a black background that blends into the hub's #0A0A0A surface,
     so no transparency handling is needed here. */
  width: 120px;
  height: auto;
  display: block;
  flex-shrink: 0;
}
.gs-nav-tabs {
  display: flex;
  gap: 4px;
  margin-left: 24px;
  flex: 1;
}
.gs-nav-tab {
  padding: 8px 14px;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--w50);
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: color .15s var(--ease), background .15s var(--ease);
}
.gs-nav-tab:hover { color: var(--white); background: var(--w06); }
.gs-nav-tab.active { color: var(--gold); background: rgba(200,160,74, .08); }
.gs-nav-user {
  display: flex; align-items: center; gap: 10px;
  font-size: 13px; color: var(--w80);
}
.gs-nav-logout {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  background: transparent;
  border: 1px solid var(--border-2);
  color: var(--w50);
  padding: 6px 10px;
  border-radius: var(--radius-xs);
  cursor: pointer;
}
.gs-nav-logout:hover { color: var(--white); border-color: var(--w50); }

/* View container — the area each module renders into. */
.gs-view {
  padding: 32px var(--gutter) 80px;
}

/* Login screen — full-viewport centered card. */
.gs-login {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}
.gs-login-card {
  width: 100%;
  max-width: 420px;
  padding: 36px 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.gs-login-card h1 {
  font-size: 28px;
  letter-spacing: -.01em;
  margin-bottom: 4px;
}
.gs-login-sub {
  color: var(--w50);
  font-size: 13px;
  margin-bottom: 28px;
}
