/* MITC.dk — Designer layout, real content */

:root {
  --bg: #020617;
  --bg-alt: #0B1120;
  --card: #0A162B;
  --border: rgba(148, 163, 184, 0.1);

  --text: #E5E7EB;
  --text-muted: #94A3B8;
  --text-strong: #FFFFFF;

  --accent: #2563EB;
  --accent-hover: #1D4ED8;
  --accent-outline: rgba(71, 85, 105, 0.4);

  --header-h: 68px;
  --transition: 0.25s ease;
}

/* ——— Reset ——— */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; }
}

body {
  font-family: Inter, system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Noise overlay — separates "nice" from "premium" */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: url('../images/noise.png');
  opacity: 0.06;
  pointer-events: none;
  z-index: 0;
}

main { flex: 1; position: relative; z-index: 1; }

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

a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--text-strong); }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

h1, h2, h3, h4 {
  color: var(--text-strong);
  line-height: 1.2;
  letter-spacing: -0.02em;
}
h2 { font-size: 32px; }
h3 { font-size: 1.0625rem; }
p { margin: 0; }

/* ——— Layout ——— */
.container {
  max-width: 1100px;
  margin-inline: auto;
  padding-inline: 20px;
}

/* ——— Skip link ——— */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 200;
  padding: 0.75rem 1rem;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  border-radius: 6px;
}
.skip-link:focus { top: 1rem; }

/* ——— Header ——— */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(2, 6, 23, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.header.is-scrolled {
  background: rgba(2, 6, 23, 0.95);
  border-bottom-color: rgba(148, 163, 184, 0.1);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  min-height: var(--header-h);
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}
.logo img {
  height: 48px;
  width: auto;
  max-width: min(280px, 90vw);
  flex-shrink: 0;
  display: block;
  object-fit: contain;
  object-position: left center;
  transition: opacity var(--transition);
}
.logo:hover img { opacity: 0.85; }

/* Desktop nav links */
.nav-links {
  display: none;
  list-style: none;
  gap: 4px;
}
@media (min-width: 768px) { .nav-links { display: flex; align-items: center; } }

.nav-links a {
  display: block;
  padding: 6px 12px;
  color: var(--text-muted);
  font-size: 0.9375rem;
  font-weight: 500;
  border-radius: 6px;
}
.nav-links a:hover { color: var(--text-strong); background: rgba(255,255,255,0.04); }
.nav-links a.is-active { color: var(--text-strong); }

/* Mobile toggle */
.nav-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  border-radius: 6px;
}
.nav-toggle:hover { background: rgba(255,255,255,0.06); }
.nav-toggle__bars { display: flex; flex-direction: column; gap: 5px; width: 1.25rem; }
.nav-toggle__bar {
  display: block;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition: transform var(--transition), opacity var(--transition);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
@media (min-width: 768px) { .nav-toggle { display: none; } }

/* Mobile nav drawer */
.nav-drawer {
  position: fixed;
  inset: var(--header-h) 0 auto 0;
  background: rgba(2, 6, 23, 0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 1rem 20px;
  transform: translateY(-100%);
  opacity: 0;
  visibility: hidden;
  transition: transform var(--transition), opacity var(--transition), visibility var(--transition);
  z-index: 99;
}
.nav-drawer.is-open { transform: translateY(0); opacity: 1; visibility: visible; }
.nav-drawer ul { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.nav-drawer a {
  display: block;
  padding: 10px 12px;
  color: var(--text);
  font-weight: 500;
  border-radius: 6px;
}
.nav-drawer a:hover { color: var(--text-strong); background: rgba(255,255,255,0.04); }
.nav-drawer a.is-active { color: var(--text-strong); }

/* ——— Buttons ——— */
.btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition), border-color var(--transition);
}
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.btn.primary {
  background: linear-gradient(135deg, #2563EB, #1D4ED8);
  color: #fff;
  box-shadow: 0 4px 20px rgba(37, 99, 235, 0.4);
}
.btn.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 25px rgba(37, 99, 235, 0.5);
  color: #fff;
}

.btn.outline {
  background: var(--accent-outline);
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.2);
  backdrop-filter: blur(6px);
  margin-left: 10px;
}
.btn.outline:hover {
  border-color: rgba(59, 130, 246, 0.4);
  color: var(--text-strong);
}

/* ——— Hero ——— */
.hero {
  padding: 100px 0;
  position: relative;
  background:
    radial-gradient(circle at 75% 30%, rgba(37, 99, 235, 0.15), transparent 40%),
    linear-gradient(180deg, #020617 0%, #0A1A3A 100%);
}

/* Vignette overlay */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, transparent 60%, rgba(2, 6, 23, 0.6));
  pointer-events: none;
}

.hero-content {
  display: flex;
  align-items: center;
  gap: 40px;
  position: relative;
  z-index: 1;
}

.hero-text { flex: 1; }

.hero h1 {
  font-size: 52px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
  background: linear-gradient(90deg, #ffffff, #c7d2fe);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  color: var(--text-muted);
  font-size: 18px;
  margin-bottom: 30px;
  max-width: 500px;
}

.hero-image {
  flex: 1;
  display: flex;
  justify-content: flex-end;
}
.hero-image img {
  width: 100%;
  max-width: 420px;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  opacity: 0.95;
}

/* ——— Sections ——— */
.section {
  padding: 100px 0;
  background: var(--bg);
}
.section.alt {
  background: var(--bg-alt);
  border-top: 1px solid rgba(59, 130, 246, 0.08);
  border-bottom: 1px solid rgba(59, 130, 246, 0.08);
}

h2 { margin-bottom: 48px; }

/* ——— Grid ——— */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

/* ——— Cards ——— */
.card {
  background: #0A162B;
  padding: 24px;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.card:hover {
  transform: translateY(-6px);
  border-color: rgba(59, 130, 246, 0.3);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.card h3 { margin-bottom: 10px; font-size: 1rem; }
.card p { color: var(--text-muted); font-size: 0.9375rem; }

.card.light {
  background: #F8FAFC;
  color: #0F172A;
  border-color: rgba(51, 65, 85, 0.12);
}
.card.light:hover {
  border-color: rgba(51, 65, 85, 0.3);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}
.card.light strong { font-size: 1rem; font-weight: 700; display: block; margin-bottom: 6px; }
.card.light p { color: #475569; }

/* Tags */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin-top: 14px;
  padding: 0;
}
.tag {
  padding: 3px 10px;
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: 999px;
}

/* ——— Partnership section ——— */
.partnership-inner {
  max-width: 44rem;
}
.partnership h2 {
  margin-bottom: 16px;
}
.partnership p {
  color: var(--text-muted);
  font-size: 1.0625rem;
  line-height: 1.7;
}
.partnership strong { color: var(--text-strong); }

/* ——— CTA strip ——— */
.cta-strip {
  padding: 80px 0;
  text-align: center;
  background: var(--bg-alt);
  border-top: 1px solid rgba(59, 130, 246, 0.08);
  border-bottom: 1px solid rgba(59, 130, 246, 0.08);
}
.cta-strip h2 { margin-bottom: 24px; }

/* ——— Page hero (inner pages) ——— */
.page-hero {
  padding: 72px 0 56px;
  background: linear-gradient(180deg, #0b1120 0%, #020617 100%);
  border-bottom: 1px solid var(--border);
}
.page-hero h1 {
  font-size: clamp(2rem, 5vw, 2.75rem);
  margin-bottom: 12px;
}
.page-hero p {
  color: var(--text-muted);
  font-size: 1.0625rem;
  max-width: 40rem;
}

/* ——— Prose ———
   Use <div class="container"><div class="prose">…</div></div>. Do not combine
   container+prose on one element: both set max-width and .container’s margin-inline
   auto then centers the narrow column, misaligning it vs the page hero. ——— */
.prose { max-width: 42rem; }
.prose h2 { margin-top: 2.5rem; margin-bottom: 1rem; font-size: 1.25rem; }
.prose h2:first-child { margin-top: 0; }
.prose p {
  color: var(--text-muted);
  font-size: 1.0625rem;
}
.prose p + p { margin-top: 1rem; }
.prose strong { color: var(--text-strong); }
.prose .lead { font-size: 1.0625rem; color: var(--text-muted); }

/* ——— Project cards ——— */
.project-card .card__link {
  display: inline-block;
  margin-top: 14px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent);
}
.project-card .card__link:hover { text-decoration: underline; color: var(--accent-hover); }

/* ——— Contact block ——— */
.contact-block {
  background: #0A162B;
  border: 1px solid rgba(148, 163, 184, 0.1);
  border-radius: 10px;
  padding: 28px;
  max-width: 28rem;
}
.contact-block__item { margin-bottom: 20px; }
.contact-block__item:last-child { margin-bottom: 0; }
.contact-block__label {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.contact-block__value a { color: var(--text); word-break: break-word; }
.contact-block__value a:hover { color: var(--text-strong); }

/* ——— Footer ——— */
.footer {
  padding: 48px 0;
  border-top: 1px solid rgba(51, 65, 85, 0.25);
  background: #020617;
  position: relative;
  z-index: 1;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: start;
}
.footer-grid strong { color: var(--text-strong); font-size: 1rem; display: block; margin-bottom: 4px; }
.footer-grid p { color: var(--text-muted); font-size: 0.875rem; }
.footer-grid a { color: var(--text-muted); font-size: 0.875rem; }
.footer-grid a:hover { color: var(--text-strong); }
.footer-bottom {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid rgba(51, 65, 85, 0.2);
  font-size: 0.8125rem;
  color: var(--text-muted);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
}
.footer-bottom-nav { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.footer-bottom-nav a { color: var(--text-muted); font-size: 0.8125rem; }
.footer-bottom-nav a:hover { color: var(--text-strong); }

.footer-cookie-settings {
  font: inherit;
  font-size: 0.8125rem;
  color: var(--text-muted);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.footer-cookie-settings:hover { color: var(--text-strong); }
.footer-cookie-settings:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ——— Cookie consent ——— */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 250;
  padding: 16px 0 max(16px, env(safe-area-inset-bottom));
  background: rgba(2, 6, 23, 0.92);
  border-top: 1px solid rgba(51, 65, 85, 0.35);
  backdrop-filter: blur(10px);
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.35);
}
.cookie-consent--hidden {
  display: none !important;
}
.cookie-consent__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 24px;
}
.cookie-consent__text {
  flex: 1 1 280px;
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 640px;
}
.cookie-consent__text a { color: var(--accent); }
.cookie-consent__text a:hover { color: var(--accent-hover); }
.cookie-consent__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  flex-shrink: 0;
}

/* ——— Utilities ——— */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
.link-arrow {
  font-weight: 600;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.link-arrow::after { content: "→"; transition: transform var(--transition); }
.link-arrow:hover::after { transform: translateX(4px); }
.link-arrow:hover { color: var(--accent-hover); }

/* ——— Responsive ——— */
@media (max-width: 900px) {
  .hero-content { flex-direction: column; }
  .hero-image { justify-content: center; }
  .hero-image img { max-width: 320px; }
  .grid-3 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .hero { padding: 60px 0; }
  .hero h1 { font-size: 36px; }
  .section { padding: 60px 0; }
  .cta-strip { padding: 56px 0; }
  .btn.outline { margin-left: 0; margin-top: 10px; }
}
