/* ============================================================================
   Hardrock Cyber — delivery-plane client shell
   Mobile first: authored at 390px, scales up. Navy ground, white content
   surface, green as ACCENT ONLY. Never green text on white (fails 2.11:1).
   Brand tokens from branding/BRANDING.md — not invented.
   ============================================================================ */

:root {
  --navy:      #0B2545;   /* primary dark ground        */
  --navy-mid:  #102C53;   /* lifted navy band           */
  --green:     #6EC82B;   /* accent only (7.30:1 on navy)*/
  --green-strong: #61B026;/* button hover               */
  --white:     #FFFFFF;
  --off-white: #F3F5F8;   /* light content surface tint */
  --muted:     #8E8DAD;   /* muted text — ON NAVY ONLY  */

  /* Ink for text ON the white card. Green/muted are NOT usable here. */
  --ink:       #0B2545;   /* 15.4:1 on white            */
  --ink-soft:  #43507A;   /* 7.8:1 on white — labels    */

  --radius: 14px;
  --gap: 16px;
  --maxw: 640px;

  --font: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body { margin: 0; }

body {
  font-family: var(--font);
  color: var(--white);
  background-color: var(--navy);
  background-image: url("../assets/background.png");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--white);
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 0 0 8px 0;
  z-index: 10;
}
.skip-link:focus { left: 0; }

/* ── Top bar ──────────────────────────────────────────────────────────────── */
.topbar {
  padding: 18px 20px;
  display: flex;
  align-items: center;
}
.topbar__logo { height: 36px; width: auto; display: block; }

/* ── Layout ───────────────────────────────────────────────────────────────── */
.main {
  flex: 1 0 auto;
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 8px 20px 40px;
}

.view { animation: fade 160ms ease-out; }
@keyframes fade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; } }

/* ── Signed-out hero ─────────────────────────────────────────────────────── */
.view--hero {
  text-align: center;
  padding-top: 8vh;
}
.hero__mark { display: block; margin: 0 auto 20px; width: 72px; height: 72px; }
.hero__title {
  font-size: 1.7rem;
  line-height: 1.2;
  margin: 0 0 10px;
  color: var(--white);
  letter-spacing: -0.01em;
}
.hero__lead {
  color: var(--muted);          /* muted on navy — OK (4.81:1) */
  margin: 0 auto 28px;
  max-width: 34ch;
  font-size: 1.02rem;
}

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
  font: inherit;
  font-weight: 600;
  border: 0;
  border-radius: 10px;
  padding: 13px 22px;
  min-height: 48px;             /* comfortable touch target */
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; }

/* Green button carries NAVY text (7.30:1). Never white text on green. */
.btn--primary { background: var(--green); color: var(--navy); }
.btn--primary:hover { background: var(--green-strong); }

/* Ghost button used on the white card: navy outline + navy text. */
.btn--ghost {
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--ink-soft);
}
.btn--ghost:hover { background: var(--off-white); }

/* ── Status / loading ────────────────────────────────────────────────────── */
.view--status { text-align: center; padding-top: 12vh; }
.status__text { color: var(--muted); margin-top: 16px; }
.spinner {
  width: 38px; height: 38px;
  margin: 0 auto;
  border: 4px solid rgba(255,255,255,0.22);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .spinner { animation: none; }
  .view { animation: none; }
}

/* ── White content card ──────────────────────────────────────────────────── */
.card {
  background: var(--white);
  color: var(--ink);
  border-radius: var(--radius);
  padding: 26px 22px 22px;
  box-shadow: 0 18px 50px rgba(0,0,0,0.28);
  border-top: 4px solid var(--green);   /* green as accent only */
}
.card__eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 8px;
}
.card__title {
  font-size: 1.5rem;
  line-height: 1.2;
  margin: 0 0 4px;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.card__subtitle {
  margin: 0 0 20px;
  color: var(--ink-soft);
  font-size: 1.05rem;
}
.card__subtitle[hidden], .card__title[hidden] { display: none; }

/* ── Field list ──────────────────────────────────────────────────────────── */
.fields {
  margin: 0 0 22px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}
.fields dt {
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding-top: 14px;
}
.fields dd {
  margin: 2px 0 0;
  font-size: 1.06rem;
  color: var(--ink);
  word-break: break-word;
}
.fields dt:first-of-type { padding-top: 0; }
/* subtle separators */
.fields dd { border-bottom: 1px solid #E7EAF0; padding-bottom: 12px; }
.fields dd:last-of-type { border-bottom: 0; }

.prepared {
  color: var(--ink-soft);
  font-size: 0.95rem;
  margin: 0 0 22px;
}

/* ── About block ─────────────────────────────────────────────────────────── */
.about {
  background: var(--off-white);
  border-radius: 10px;
  padding: 16px 16px 4px;
  margin-bottom: 22px;
}
.about__heading {
  font-size: 0.95rem;
  margin: 0 0 8px;
  color: var(--ink);
}
.about__body {
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--ink-soft);
  margin: 0 0 12px;
}

/* ── Message cards (403 / error) ─────────────────────────────────────────── */
.card--message { text-align: left; }
.message__body { font-size: 1.02rem; line-height: 1.55; color: var(--ink); margin: 6px 0 14px; }
.message__contact { margin: 0 0 20px; }
.message__contact a, .card a { color: var(--ink); font-weight: 600; }

.card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 6px;
}

/* ── Footer ──────────────────────────────────────────────────────────────── */
.footer {
  text-align: center;
  color: var(--muted);
  font-size: 0.8rem;
  padding: 18px;
  flex-shrink: 0;
}

/* ── Scale up (tablet / desktop). Mobile is the base above. ──────────────── */
@media (min-width: 700px) {
  .main { padding: 20px 24px 56px; }
  .card { padding: 34px 34px 28px; }
  .card__title { font-size: 1.8rem; }
  .hero__title { font-size: 2.1rem; }
  .fields {
    grid-template-columns: 200px 1fr;
    column-gap: 24px;
  }
  .fields dt { padding-top: 16px; align-self: center; }
  .fields dd {
    padding-top: 16px;
    margin-top: 0;
    align-self: center;
  }
  .fields dt:first-of-type, .fields dd:first-of-type { padding-top: 0; }
}
