/* ekkorun.com: ett nattsvart register med ett projekt per rad. Projektets bild
   syns svagt bakom raden och fullt vid hovring eller fokus. På mobil visas bilden
   under texten i stället. */
:root {
  --bg: #0b0b0b;
  --text: #f2f2ee;
  --dampad: #8f8f88;
  --linje: #2a2a2a;
  --accent: #9cb46a; /* mossgrön */
  --sans: "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.5 var(--sans); }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

.ram {
  max-width: 1280px;
  margin: 0 auto;
  padding-inline: max(16px, env(safe-area-inset-left)) max(16px, env(safe-area-inset-right));
}

.sidhuvud {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: max(10px, env(safe-area-inset-top));
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--dampad);
}
.toppratt { display: flex; align-items: center; gap: 14px; }
.sprak { display: inline-flex; border: 1px solid var(--linje); border-radius: 999px; padding: 2px; }
.sprak button {
  min-width: 44px;
  min-height: 44px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--dampad);
  font: 600 0.78rem var(--mono);
  letter-spacing: 0.06em;
  cursor: pointer;
}
.sprak button[aria-pressed="true"] { background: var(--accent); color: var(--bg); }
.sprak button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ordmarke { display: inline-flex; align-items: center; min-height: 44px; color: var(--text); font-weight: 600; }

.hjalte { padding-block: 48px 44px; }
.hjalte h1 {
  margin: 0;
  font-size: clamp(3.4rem, 17vw, 12rem);
  line-height: 0.9;
  letter-spacing: -0.06em;
  font-weight: 800;
}
.hjalte .punkt { color: var(--accent); }
.hjalte p { margin: 20px 0 0; max-width: 28rem; color: var(--dampad); font-size: 1.125rem; line-height: 1.55; }

.register { list-style: none; margin-block: 0; padding-block: 0; }
.rad { position: relative; border-top: 1px solid var(--linje); overflow: hidden; }
.rad:last-child { border-bottom: 1px solid var(--linje); }

.innehall {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 10px;
  padding-block: 26px;
}
@media (min-width: 900px) {
  .innehall { grid-template-columns: 120px minmax(0, 1fr) auto; align-items: end; gap: 24px; padding-block: 30px; }
}

.bakgrund { position: absolute; inset: 0; opacity: 0; transition: opacity 0.45s; }
@media (min-width: 900px) { .bakgrund { opacity: 0.35; } }
.bakgrund img { width: 100%; height: 100%; object-fit: cover; }
.bakgrund::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(11, 11, 11, 0.85) 20%, rgba(11, 11, 11, 0.3) 60%, rgba(11, 11, 11, 0.8));
}
@media (hover: hover) and (min-width: 900px) {
  .rad:hover .bakgrund, .rad:focus-within .bakgrund { opacity: 1; }
}

.nr { font-family: var(--mono); font-size: 0.8rem; color: var(--dampad); }
.namn {
  margin: 0;
  font-size: clamp(2.6rem, 10vw, 7.5rem);
  line-height: 0.88;
  letter-spacing: -0.05em;
  font-weight: 800;
  hyphens: manual;
  transition: color 0.3s;
}
.rad:hover .namn, .rad:focus-within .namn { color: var(--accent); }
.besk { margin: 12px 0 0; max-width: 38rem; color: var(--dampad); }

.meta { display: grid; gap: 2px; font-family: var(--mono); font-size: 0.78rem; color: var(--dampad); }
.pil { margin-top: 8px; color: var(--text); font-weight: 600; }
@media (min-width: 900px) { .meta { text-align: right; } }

.mobilbild { margin-top: 14px; aspect-ratio: 16 / 9; border-radius: 6px; overflow: hidden; background: #151515; }
.mobilbild img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 900px) { .mobilbild { display: none; } }

.sidfot {
  display: flex;
  justify-content: space-between;
  padding-block: 22px max(30px, env(safe-area-inset-bottom));
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--dampad);
}

@media (prefers-reduced-motion: reduce) {
  .bakgrund, .namn { transition: none; }
}
