/* ============================================================
   NN CLIENT PORTAL – Shared Design System
   All clients inherit this file. No per-client CSS needed.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Schibsted+Grotesk:wght@600&family=Manrope:wght@400;500;600;700&display=swap');

/* ------------------------------------------------------------
   1. RESET
   ------------------------------------------------------------ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

[hidden] { display: none !important; }

/* ------------------------------------------------------------
   2. DESIGN TOKENS
   ------------------------------------------------------------ */
:root {
  /* Colour */
  --ink:               #0A0A0A;
  --paper:             #F6F4EF;
  --off-white:         #FAFAF8;
  --charcoal:          #1C1C1C;
  --bone:              #EBE7DE;
  --accent:            #F5C842;

  --stone-100:         #ECE8DF;
  --stone-200:         #DAD5C9;
  --stone-300:         #BFB9AC;
  --stone-400:         #9D978B;
  --stone-500:         #75716A;
  --stone-600:         #56534D;
  --stone-700:         #3B3935;
  --stone-800:         #232220;
  --stone-900:         #0A0A0A;

  --hairline:          rgba(10, 10, 10, 0.12);
  --hairline-on-dark:  rgba(255, 255, 255, 0.16);

  /* Typography */
  --font-headline:     'Schibsted Grotesk', sans-serif;
  --font-sans:         'Manrope', system-ui, sans-serif;

  /* Radii */
  --r-sm:  4px;
  --r-md:  8px;
  --r-lg:  14px;

  /* Motion */
  --ease-out:  cubic-bezier(0.2, 0.7, 0.2, 1);
  --ease-in:   cubic-bezier(0.4, 0, 0.6, 1);
  --t-hover:   160ms;
  --t-trans:   220ms;
}

/* ------------------------------------------------------------
   3. BASE
   ------------------------------------------------------------ */
html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--paper);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

/* ------------------------------------------------------------
   4. PAGE WRAPPER
   ------------------------------------------------------------ */
.page {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 40px 96px;
}

/* ------------------------------------------------------------
   5. COLLAB HEADER
   Used on all client-facing pages (dashboard + report pages).
   Shows NN wordmark left, client logo right.
   ------------------------------------------------------------ */
.collab-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 48px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--hairline);
  gap: 20px;
}

.collab-header-logos {
  display: flex;
  align-items: center;
  gap: 0;
  flex: 1;
}

.collab-logo-nn img {
  height: 28px;
  width: auto;
}

.collab-separator {
  width: 1px;
  height: 24px;
  background: var(--stone-300);
  margin: 0 20px;
  flex-shrink: 0;
}

.collab-logo-client img {
  height: 28px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
}

.collab-doc-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--stone-500);
  flex-shrink: 0;
}

/* Legacy logo-bar alias */
.logo-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 48px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--hairline);
}

.logo-bar .logo img {
  height: 28px;
  width: auto;
}

.logo-bar .doc-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--stone-500);
}

/* ------------------------------------------------------------
   18. DOCUMENT CARDS (client dashboard)
   ------------------------------------------------------------ */
.doc-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.doc-card {
  background: var(--paper);
  border: 1px solid var(--hairline);
  border-radius: var(--r-md);
  padding: 24px;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: border-color var(--t-hover) var(--ease-out);
}

.doc-card:hover {
  border-color: rgba(10, 10, 10, 0.28);
}

.doc-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.doc-card-type {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--bone);
  padding: 3px 8px;
  border-radius: 2px;
}

.doc-card-date {
  font-size: 12px;
  color: var(--stone-500);
  font-weight: 500;
}

.doc-card-title {
  font-family: var(--font-headline);
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.25;
  margin-bottom: 8px;
  flex: 1;
}

.doc-card-desc {
  font-size: 13.5px;
  color: var(--stone-600);
  line-height: 1.55;
  margin-bottom: 20px;
}

.doc-card-cta {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  display: inline-block;
  transition: border-color var(--t-hover) var(--ease-out);
}

.doc-card:hover .doc-card-cta {
  border-bottom-color: var(--ink);
}

/* ------------------------------------------------------------
   19. DASHBOARD HEADER
   ------------------------------------------------------------ */
.dashboard-header {
  margin-bottom: 40px;
}

.dashboard-header h2 {
  font-family: var(--font-headline);
  font-size: 26px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 8px;
  line-height: 1.15;
}

.dashboard-header p {
  font-size: 14px;
  color: var(--stone-600);
  line-height: 1.6;
  max-width: 520px;
}

/* ------------------------------------------------------------
   21. RESPONSIVE
   ------------------------------------------------------------ */
@media (max-width: 600px) {
  .page {
    padding: 32px 20px 64px;
  }

  .collab-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .collab-doc-label {
    align-self: flex-end;
  }

  .doc-grid {
    grid-template-columns: 1fr;
  }
}

/* ------------------------------------------------------------
   22. PRINT
   ------------------------------------------------------------ */
@media print {
  body {
    background: white;
    font-size: 13px;
  }

  .page {
    padding: 20px;
  }
}
