/* Texicon Social. Stilen følger DESIGN_SYSTEM.md og design.md i new-texicon-homepage.
 * Verdiene under er de samme tokenene, oversatt fra Tailwind til ren CSS fordi
 * dette nettstedet er statisk uten byggesteg. Ikke innfør nye farger, radier
 * eller skriftstørrelser her. */

@font-face {
  font-family: "Satoshi";
  src: url("/assets/fonts/Satoshi-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("/assets/fonts/Satoshi-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Satoshi";
  src: url("/assets/fonts/Satoshi-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --background: #ffffff;
  --foreground: #000000;
  --lightgrey: #f5f5f5;

  --ink: #17171d;
  --ink-hover: #2b2b33;
  --ink-soft: #3d3d46;
  --ink-faint: #3d3d46;

  --hairline: #d4d4d8;
  --hairline-soft: #e4e4e7;
  --lede: #525252;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);

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

* {
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  font-weight: 400;
  overflow-x: clip;
}

button:not(:disabled),
a[href],
summary {
  cursor: pointer;
}

a {
  color: inherit;
}

/* ---------- container ---------- */

.container {
  margin: 0 auto;
  width: 100%;
  max-width: 1512px;
  padding-inline: 24px;
}

@media (min-width: 640px) {
  .container { padding-inline: 40px; }
}
@media (min-width: 1024px) {
  .container { padding-inline: 128px; }
}

/* ---------- typografi ---------- */

h1, h2, h3, p, ul, ol, dl {
  margin: 0;
}

.h1 {
  font-size: 40px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
}
@media (min-width: 640px) {
  .h1 { font-size: 52px; }
}

.lede {
  font-size: 22px;
  font-weight: 500;
  line-height: 1.375;
  color: var(--lede);
}
@media (min-width: 640px) {
  .lede { font-size: 24px; }
}

.h2 {
  font-size: 32px;
  font-weight: 700;
  color: var(--foreground);
}

.h2-sub {
  font-size: 28px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--foreground);
}

.card-title {
  font-size: 24px;
  font-weight: 500;
  color: var(--foreground);
}

.body {
  font-size: 20px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--ink-soft);
}

.card-desc {
  font-size: 18px;
  line-height: 1.625;
  color: var(--ink-soft);
}

.eyebrow {
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-faint);
}

.meta {
  font-size: 16px;
  font-weight: 500;
  color: var(--foreground);
}

.textlink {
  font-size: 18px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: opacity 0.15s var(--ease-out);
}
.textlink:hover { opacity: 0.6; }

.balance { text-wrap: balance; }

/* Signaturbehandlingen. Kun på sidens H1 og på H2-en i avslutnings-CTA-en. */
.gradient-text {
  background-image: radial-gradient(
    115% 130% at 100% 105%,
    #3a3aff 0%,
    #2424bf 22%,
    #14146a 42%,
    #0a0a35 60%,
    #000000 82%
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding-bottom: 0.12em;
  margin-bottom: -0.12em;
}

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--background);
  border-bottom: 1px solid transparent;
  transition: border-color 0.5s ease-out;
}
.site-header[data-scrolled="true"] {
  border-bottom-color: var(--hairline-soft);
}

.header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 16px;
  padding-bottom: 16px;
}

.wordmark {
  display: block;
  flex-shrink: 0;
  height: 24px;
  width: auto;
}

.site-nav {
  display: none;
  align-items: center;
  gap: 32px;
}
@media (min-width: 768px) {
  .site-nav { display: flex; }
}

.site-nav a {
  padding: 8px 4px;
  font-size: 16px;
  font-weight: 500;
  color: var(--foreground);
  text-decoration: none;
  transition: opacity 0.15s var(--ease-out);
}
.site-nav a:hover { opacity: 0.6; }
.site-nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 6px; }

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 16px;
  font-weight: 500;
}
.lang-switch a {
  color: var(--ink-soft);
  text-decoration: none;
  transition: opacity 0.15s var(--ease-out);
}
.lang-switch a:hover { opacity: 0.6; }
.lang-switch a[aria-current="true"] { color: var(--foreground); }
.lang-switch span { color: var(--hairline); }

/* På mobil faller navigasjonen ned under logoen i stedet for å forsvinne,
 * fordi nettstedet er for lite til å forsvare en full menyskuff. */
.mobile-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  padding-bottom: 14px;
}
@media (min-width: 768px) {
  .mobile-nav { display: none; }
}
.mobile-nav a {
  font-size: 16px;
  font-weight: 500;
  color: var(--foreground);
  text-decoration: none;
}
.mobile-nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 5px; }

/* ---------- knapper ---------- */

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding-inline: 28px;
  border: 0;
  border-radius: 9999px;
  background: var(--ink);
  color: #ffffff;
  font-family: inherit;
  font-size: 18px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  transition: background-color 0.15s var(--ease-out), transform 0.15s var(--ease-out);
}
.pill:hover { background: var(--ink-hover); }
.pill:active { transform: scale(0.97); }
.pill:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

.pill-sm {
  height: 40px;
  padding-inline: 20px;
  font-size: 16px;
}

.arrow-link {
  font-size: 18px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  transition: opacity 0.15s var(--ease-out);
}
.arrow-link:hover { opacity: 0.6; }
.arrow-link span {
  display: inline-block;
  transition: transform 0.2s var(--ease-out);
}
.arrow-link:hover span { transform: translateX(4px); }

/* ---------- seksjoner ---------- */

section { padding-block: 64px; }
@media (min-width: 1024px) {
  section { padding-block: 112px; }
}

.section-hero { padding-block: 48px; }
@media (min-width: 1024px) {
  .section-hero { padding-block: 96px; }
}

.section-cta { padding-block: 96px; }
@media (min-width: 1024px) {
  .section-cta { padding-block: 144px; }
}

.stack { display: flex; flex-direction: column; gap: 20px; }
.stack-lg { display: flex; flex-direction: column; gap: 40px; }

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 720px;
}

.hero-split {
  display: flex;
  flex-direction: column;
  gap: 32px;
}
@media (min-width: 1024px) {
  .hero-split {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 64px;
  }
  .hero-split .hero-copy { max-width: 760px; }
  .hero-split .hero-aside { max-width: 460px; padding-bottom: 6px; }
}

.hero-aside {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
  margin-top: 12px;
}

/* Delt overskrift og ingress, S8 i seksjonskatalogen. */
.split-header {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
@media (min-width: 768px) {
  .split-header {
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
  }
  .split-header .h2, .split-header .h2-sub { width: 600px; }
  .split-header .body { max-width: 610px; }
}

/* ---------- kort ---------- */

.grid {
  display: grid;
  gap: 28px;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border: 1px solid var(--hairline);
  border-radius: 20px;
  background: #ffffff;
  padding: 24px;
}

.panel {
  border-radius: 20px;
  background: var(--lightgrey);
  padding: 32px;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.tags li {
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 9999px;
  background: #ffffff;
  padding: 8px 16px;
  font-size: 16px;
  font-weight: 500;
  color: var(--foreground);
}

/* Stegnummer er svarte, ikke blå. Blått hører hjemme i grafikk og i
 * gradient-text, ikke på UI-elementer. */
.steps {
  display: grid;
  gap: 32px 28px;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) {
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.step { display: flex; flex-direction: column; gap: 8px; }
.step-num {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 9999px;
  background: var(--foreground);
  color: #ffffff;
  font-size: 16px;
  font-weight: 500;
}

/* ---------- brødtekst og tabeller ---------- */

.prose { max-width: 700px; display: flex; flex-direction: column; gap: 16px; }
.prose p { font-size: 20px; line-height: 1.7; color: var(--foreground); }
.prose ul, .prose ol { padding-left: 22px; display: flex; flex-direction: column; gap: 8px; }
.prose li { font-size: 20px; line-height: 1.6; color: var(--foreground); }
.prose .h2-sub { margin-top: 24px; }
.prose a { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.prose a:hover { opacity: 0.6; }

.table-wrap { overflow-x: auto; max-width: 100%; }
table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
  font-size: 18px;
}
th, td {
  text-align: left;
  padding: 14px 16px 14px 0;
  border-bottom: 1px solid var(--hairline);
  vertical-align: top;
  color: var(--ink-soft);
}
th {
  font-weight: 500;
  color: var(--foreground);
  font-size: 16px;
}
td code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 16px;
  color: var(--foreground);
}

.kv {
  display: grid;
  gap: 4px 40px;
  grid-template-columns: max-content 1fr;
}
.kv dt { font-size: 18px; color: var(--ink-soft); }
.kv dd { margin: 0; font-size: 18px; color: var(--foreground); }
@media (max-width: 639px) {
  .kv { grid-template-columns: 1fr; }
  .kv dd { margin-bottom: 12px; }
}

/* ---------- avslutnings-CTA ---------- */

.cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}
.cta .cta-title {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
}
@media (min-width: 640px) {
  .cta .cta-title { font-size: 44px; }
}
.cta .body { max-width: 560px; }

/* ---------- footer ---------- */

.site-footer {
  position: relative;
  z-index: 30;
  overflow: hidden;
  background: var(--background);
  padding-block: 48px;
}
@media (min-width: 1024px) {
  .site-footer { padding-block: 64px; }
}
.site-footer .container {
  display: flex;
  flex-direction: column;
  gap: 80px;
}
.footer-top {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 48px;
}
@media (min-width: 640px) {
  .footer-top { flex-direction: row; gap: 32px; }
}
.footer-col { display: flex; flex-direction: column; gap: 8px; color: var(--ink); }
.footer-lead { font-size: 28px; font-weight: 700; }
.footer-col a { font-size: 18px; font-weight: 400; text-decoration: none; transition: opacity 0.15s var(--ease-out); }
.footer-col a:hover { opacity: 0.6; }
.footer-col .footer-strong { font-size: 18px; font-weight: 500; text-decoration: underline; }
.footer-col p { font-size: 20px; font-weight: 700; }
.footer-cols { display: flex; gap: 64px; }
@media (min-width: 640px) {
  .footer-cols { gap: 128px; }
}
.footer-wordmark { display: block; width: 100%; height: auto; }
.footer-legal {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  text-align: center;
  font-size: 16px;
  font-weight: 400;
  color: var(--ink-soft);
}
@media (min-width: 640px) {
  .footer-legal { flex-direction: row; }
}
.footer-legal a { text-decoration: none; transition: opacity 0.15s var(--ease-out); }
.footer-legal a:hover { opacity: 0.6; }
.footer-legal div { display: flex; gap: 24px; }

/* ---------- scroll reveal ---------- */

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
  will-change: opacity, transform;
}
.reveal[data-visible="true"] {
  opacity: 1;
  transform: none;
  will-change: auto;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { transition: opacity 0.3s var(--ease-out); transform: none; }
  .pill:active { transform: none; }
  .arrow-link:hover span { transform: none; }
}
