/* DT Software Studio – dtsoftwarestudio.com
   Eine Schriftfamilie (Archivo, variabel in Breite und Stärke), selbst gehostet. */

@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-variable.woff2") format("woff2-variations"),
       url("../fonts/archivo-variable.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light dark;

  /* Studio */
  --paper: #f6f7f9;
  --paper-2: #eceff4;
  --ink: #142036;
  --muted: #566176;
  --rule: #d9dee7;
  --marker: #f2b705;

  /* BudgetDesk */
  --bd-bg: #0e1b2e;
  --bd-panel: #13243c;
  --bd-line: #2e4466;
  --bd-green: #34c58a;
  --bd-text: #e6edf6;
  --bd-muted: #9fb0c8;

  /* CardHub TCG */
  --ch-bg: #e8eef7;
  --ch-ink: #1b3a6b;
  --ch-mid: #4c79be;
  --ch-soft: #9db4d8;
  --ch-muted: #4a5d7c;

  /* FarWorld Industries */
  --fw-bg: #0f1a29;
  --fw-ice: #8cc6ea;
  --fw-gold: #d2ab4c;
  --fw-text: #e9eff6;
  --fw-muted: #a7b6c9;

  --wrap: 76rem;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --wide: 118%;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0d1522;
    --paper-2: #131d2e;
    --ink: #e8ecf3;
    --muted: #9aa5b8;
    --rule: #26324a;
    --ch-bg: #152440;
    --ch-ink: #dfe8f6;
    --ch-mid: #7fa3db;
    --ch-soft: #4c79be;
    --ch-muted: #a9bad6;
  }
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 4.5rem;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Archivo", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  font-stretch: 100%;
  font-weight: 400;
  text-rendering: optimizeLegibility;
}

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

a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-color: var(--marker); }

:focus-visible {
  outline: 3px solid var(--marker);
  outline-offset: 3px;
  border-radius: 3px;
}

.skip {
  position: absolute; left: -999px; top: 0;
  background: var(--ink); color: var(--paper);
  padding: 0.6rem 1rem; z-index: 50;
}
.skip:focus { left: 1rem; top: 1rem; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

h1, h2, h3 { margin: 0; line-height: 1.1; }
p { margin: 0 0 1em; }

/* ---------- Kopfzeile ---------- */

.top {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--rule);
}

.top .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; min-height: 4rem;
}

.brand {
  display: inline-flex; align-items: center; gap: 0.65rem;
  text-decoration: none; font-weight: 700; font-stretch: 108%;
  letter-spacing: -0.005em; white-space: nowrap;
}
.brand img { width: 2rem; height: 2rem; }

.nav { display: flex; align-items: center; gap: clamp(0.9rem, 2.4vw, 1.8rem); font-size: 0.97rem; }
.nav a { text-decoration: none; color: var(--muted); }
.nav a:hover { color: var(--ink); text-decoration: underline; text-decoration-color: var(--marker); text-decoration-thickness: 2px; }
.nav .lang {
  color: var(--ink); font-weight: 600;
  border: 1px solid var(--rule); border-radius: 999px;
  padding: 0.2rem 0.75rem;
}
.nav .lang:hover { border-color: var(--ink); text-decoration: none; }

@media (max-width: 40rem) {
  .nav .hide-sm { display: none; }
}

/* ---------- Einstieg ---------- */

.intro { padding-block: clamp(3rem, 9vw, 6.5rem) clamp(1.5rem, 4vw, 2.5rem); }

.intro h1 {
  font-size: clamp(2rem, 4.6vw, 3.4rem);
  font-weight: 650;
  font-stretch: 100%;
  letter-spacing: -0.02em;
  max-width: 24ch;
  text-wrap: balance;
}

.intro .lede {
  margin-top: 1.25rem;
  max-width: 58ch;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
}

/* Projekt-Index: das tragende Element der Startseite */

.index {
  list-style: none; margin: 0; padding: 0;
  border-top: 2px solid var(--ink);
  margin-bottom: clamp(3rem, 8vw, 6rem);
}

.index li { border-bottom: 1px solid var(--rule); }

.index a {
  position: relative; isolation: isolate;
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-areas: "mark name meta" "mark desc meta";
  align-items: center;
  column-gap: clamp(0.9rem, 2.5vw, 2rem);
  padding: clamp(1rem, 2.6vw, 1.6rem) clamp(0.25rem, 1.5vw, 1rem);
  text-decoration: none;
  color: var(--ink);
  transition: color 0.3s ease;
}

.index a::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--row-bg);
  transform: scaleX(0); transform-origin: left center;
  transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.1, 1);
}

.index a:hover, .index a:focus-visible { color: var(--row-fg); outline-offset: -3px; }
.index a:hover::before, .index a:focus-visible::before { transform: scaleX(1); }
.index a:hover .desc, .index a:focus-visible .desc,
.index a:hover .meta, .index a:focus-visible .meta { color: var(--row-muted); }

.index .mark { grid-area: mark; width: clamp(2.75rem, 6vw, 4.5rem); height: auto; border-radius: 22%; }
.index .name {
  grid-area: name;
  font-size: clamp(1.7rem, 6.2vw, 4.6rem);
  font-weight: 800; font-stretch: var(--wide);
  letter-spacing: -0.025em; line-height: 1;
}
.index .desc { grid-area: desc; color: var(--muted); margin-top: 0.4rem; font-size: clamp(0.95rem, 1.5vw, 1.1rem); transition: color 0.3s ease; }
.index .meta { grid-area: meta; color: var(--muted); font-size: 0.95rem; text-align: right; white-space: nowrap; transition: color 0.3s ease; }

.row-bd { --row-bg: var(--bd-bg); --row-fg: #fff; --row-muted: var(--bd-muted); }
.row-ch { --row-bg: #1b3a6b; --row-fg: #fff; --row-muted: #c4d3ea; }
.row-fw { --row-bg: var(--fw-bg); --row-fg: var(--fw-text); --row-muted: var(--fw-gold); }

@media (max-width: 40rem) {
  .index a { grid-template-columns: auto 1fr; grid-template-areas: "mark name" "mark desc" "mark meta"; }
  .index .meta { text-align: left; margin-top: 0.2rem; font-size: 0.9rem; }
}

/* Ein einziger, abgestimmter Einstieg beim Laden */
@media (prefers-reduced-motion: no-preference) {
  .index li { animation: rise 0.7s cubic-bezier(0.2, 0.7, 0.1, 1) both; }
  .index li:nth-child(1) { animation-delay: 0.08s; }
  .index li:nth-child(2) { animation-delay: 0.2s; }
  .index li:nth-child(3) { animation-delay: 0.32s; }
  @keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .index a::before, .index a, .index .desc, .index .meta { transition: none; }
}

/* ---------- Gemeinsame Bausteine der Projektflächen ---------- */

.plate { padding-block: clamp(3.5rem, 9vw, 7rem); }

.plate .head { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.25rem; }
.plate .head img { width: 3.25rem; height: 3.25rem; border-radius: 22%; }

.plate h2 {
  font-size: clamp(2.2rem, 5.6vw, 4rem);
  font-weight: 800; font-stretch: var(--wide);
  letter-spacing: -0.025em; line-height: 1;
}

.plate .claim {
  font-size: clamp(1.2rem, 2.2vw, 1.55rem);
  font-weight: 600; line-height: 1.3;
  max-width: 30ch; margin-bottom: 1rem;
  text-wrap: balance;
}

.plate .body { max-width: 58ch; }

.platforms { font-weight: 600; margin-top: 1.25rem; }

.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.75rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 2.9rem; padding: 0.65rem 1.3rem;
  border-radius: 0.5rem;
  font-weight: 650; text-decoration: none;
  border: 1.5px solid currentColor;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 clamp(1.5rem, 3vw, 2.75rem);
  margin: clamp(2.5rem, 6vw, 4rem) 0 0;
}
.features div { border-top: 1px solid var(--f-rule); padding: 1.1rem 0 1.4rem; }
.features dt { font-weight: 700; margin-bottom: 0.3rem; }
.features dd { margin: 0; color: var(--f-muted); font-size: 0.98rem; }
.plate-fw .features { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 62rem) {
  .features, .plate-fw .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 36rem) {
  .features, .plate-fw .features { grid-template-columns: 1fr; }
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
@media (max-width: 56rem) { .split { grid-template-columns: minmax(0, 1fr); } }

/* ---------- BudgetDesk ---------- */

.plate-bd { background: var(--bd-bg); color: var(--bd-text); --f-rule: var(--bd-line); --f-muted: var(--bd-muted); }
.plate-bd .body { color: var(--bd-muted); }
.plate-bd .btn-main { background: var(--bd-green); border-color: var(--bd-green); color: #08261a; }
.plate-bd .btn-main:hover { background: #4fd69f; border-color: #4fd69f; }
.plate-bd .btn-alt { color: var(--bd-text); border-color: var(--bd-line); }
.plate-bd .btn-alt:hover { border-color: var(--bd-text); }
.plate-bd :focus-visible { outline-color: var(--bd-green); }

/* Programmfenster als Illustration */
.window {
  background: var(--bd-panel);
  border: 1px solid var(--bd-line);
  border-radius: 0.9rem;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  font-size: 0.95rem;
}
.window .bar {
  display: flex; align-items: center; gap: 0.45rem;
  padding: 0.7rem 1rem; border-bottom: 1px solid var(--bd-line);
  color: var(--bd-muted); font-size: 0.85rem;
}
.window .bar i { width: 0.7rem; height: 0.7rem; border-radius: 50%; background: var(--bd-line); }
.window .bar span { margin-left: 0.6rem; }
.window .content { padding: clamp(1.1rem, 3vw, 1.75rem); }
.window .ref { color: var(--bd-muted); font-size: 0.85rem; }
.window h3 { font-size: 1.35rem; font-weight: 700; margin: 0.2rem 0 0.2rem; }
.window .sum { color: var(--bd-muted); }
.window .sum b { color: var(--bd-text); font-weight: 650; }

.track {
  list-style: none; padding: 0; margin: 1.5rem 0 1.25rem;
  display: grid; grid-template-columns: repeat(5, 1fr);
  counter-reset: step;
}
.track li {
  position: relative; padding-top: 1.6rem;
  font-size: 0.8rem; color: var(--bd-muted); text-align: center;
}
.track li::before {
  content: ""; position: absolute; top: 0.3rem; left: 50%; transform: translateX(-50%);
  width: 0.9rem; height: 0.9rem; border-radius: 50%;
  background: var(--bd-panel); border: 2px solid var(--bd-line); z-index: 1;
}
.track li::after {
  content: ""; position: absolute; top: 0.68rem; left: -50%; width: 100%; height: 2px;
  background: var(--bd-line);
}
.track li:first-child::after { display: none; }
.track li.done::before { background: var(--bd-green); border-color: var(--bd-green); }
.track li.done::after, .track li.now::after { background: var(--bd-green); }
.track li.now { color: var(--bd-text); font-weight: 650; }
.track li.now::before { border-color: var(--bd-green); box-shadow: 0 0 0 4px rgba(52, 197, 138, 0.22); }

.checks { display: grid; gap: 0.55rem; border-top: 1px solid var(--bd-line); padding-top: 1.1rem; }
.checks p { margin: 0; display: flex; gap: 0.6rem; align-items: baseline; color: var(--bd-muted); font-size: 0.9rem; }
.checks p::before {
  content: ""; flex: none; width: 0.55rem; height: 0.55rem; border-radius: 2px;
  background: var(--bd-green); transform: translateY(-0.05rem);
}
.checks p.open::before { background: transparent; border: 1.5px solid var(--bd-muted); }


/* ---------- CardHub TCG ---------- */

.plate-ch { background: var(--ch-bg); color: var(--ch-ink); --f-rule: var(--ch-soft); --f-muted: var(--ch-muted); }
.plate-ch .body { color: var(--ch-muted); }
.plate-ch .split > .visual { order: -1; }
.plate-ch .btn-main { background: var(--ch-ink); border-color: var(--ch-ink); color: var(--ch-bg); }
.plate-ch .btn-main:hover { background: var(--ch-mid); border-color: var(--ch-mid); color: #fff; }
.plate-ch .note { font-size: 0.85rem; color: var(--ch-muted); max-width: 62ch; margin-top: 2rem; }

.scan {
  position: relative; aspect-ratio: 1; max-width: 26rem; margin-inline: auto;
}
.scan svg { width: 100%; height: auto; }

@media (max-width: 56rem) {
  .plate-ch .split > .visual { order: 0; }
  .scan { max-width: 18rem; }
}

/* ---------- FarWorld Industries ---------- */

.plate-fw {
  position: relative;
  background: var(--fw-bg); color: var(--fw-text);
  --f-rule: rgba(140, 198, 234, 0.28); --f-muted: var(--fw-muted);
  padding-top: 0;
}

.fw-hero {
  position: relative;
  min-height: clamp(30rem, 72vh, 44rem);
  display: flex; align-items: flex-end;
  background:
    linear-gradient(90deg, rgba(15, 26, 41, 0.96) 0%, rgba(15, 26, 41, 0.82) 38%, rgba(15, 26, 41, 0.15) 75%),
    linear-gradient(0deg, var(--fw-bg) 0%, rgba(15, 26, 41, 0) 35%),
    url("../img/fw-hero.webp") center / cover no-repeat;
  padding-block: clamp(4rem, 10vw, 7rem) clamp(2rem, 5vw, 3.5rem);
}
.fw-hero .wrap > div { max-width: 36rem; }
.fw-hero .head img { width: 4rem; height: 4rem; border-radius: 0; }
.fw-hero h2 { font-size: clamp(2.4rem, 6.4vw, 4.8rem); font-stretch: 100%; font-weight: 850; letter-spacing: -0.01em; line-height: 0.95; }
.fw-hero .claim { color: var(--fw-text); }
.fw-hero .body { color: var(--fw-muted); }
.plate-fw .platforms { color: var(--fw-gold); }

.plate-fw .btn-main { background: var(--fw-gold); border-color: var(--fw-gold); color: #1d1606; }
.plate-fw .btn-main:hover { background: #e2c06a; border-color: #e2c06a; }
.plate-fw .btn-alt { color: var(--fw-text); border-color: rgba(233, 239, 246, 0.4); }
.plate-fw .btn-alt:hover { border-color: var(--fw-text); }
.plate-fw :focus-visible { outline-color: var(--fw-gold); }

.shots {
  display: grid; gap: clamp(0.6rem, 1.4vw, 1rem);
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: auto auto;
  margin: clamp(1.5rem, 4vw, 2.5rem) 0 0;
}
.shots figure { margin: 0; position: relative; overflow: hidden; border-radius: 0.6rem; background: #1a2a40; }
.shots figure:first-child { grid-row: span 2; }
.shots img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 16 / 9; }
.shots figure:first-child img { aspect-ratio: auto; }
.shots figcaption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 1.6rem 0.9rem 0.65rem;
  background: linear-gradient(0deg, rgba(10, 18, 30, 0.85), rgba(10, 18, 30, 0));
  font-size: 0.85rem; color: var(--fw-text);
}
.plate-fw .fineprint { color: var(--fw-muted); font-size: 0.9rem; margin-top: 1.25rem; max-width: 62ch; }

@media (max-width: 48rem) {
  .shots { grid-template-columns: 1fr 1fr; }
  .shots figure:first-child { grid-column: span 2; grid-row: auto; }
  .shots figure:first-child img { aspect-ratio: 16 / 9; }
  .fw-hero {
    background:
      linear-gradient(0deg, var(--fw-bg) 0%, rgba(15, 26, 41, 0.88) 55%, rgba(15, 26, 41, 0.35) 100%),
      url("../img/fw-hero.webp") 60% center / cover no-repeat;
  }
}

/* ---------- Studio ---------- */

.studio { padding-block: clamp(4rem, 9vw, 7rem); }
.studio .split { align-items: start; }
.studio h2 {
  font-size: clamp(2rem, 4.4vw, 3rem); font-weight: 800; font-stretch: var(--wide);
  letter-spacing: -0.02em; margin-bottom: 1.25rem;
}
.studio .body { max-width: 56ch; }
.studio .body p:first-child { font-size: 1.2rem; line-height: 1.5; }

.ways { list-style: none; margin: 0; padding: 0; }
.ways li { border-top: 1px solid var(--rule); padding: 1.2rem 0 1.3rem; }
.ways li:last-child { border-bottom: 1px solid var(--rule); }
.ways h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 0.35rem; }
.ways p { margin: 0; color: var(--muted); }

/* ---------- Kontakt ---------- */

.contact {
  background: var(--paper-2);
  padding-block: clamp(4rem, 9vw, 6.5rem);
  border-top: 1px solid var(--rule);
}
.contact h2 { font-size: clamp(1.4rem, 2.4vw, 1.8rem); font-weight: 650; margin-bottom: 0.75rem; }
.contact p { color: var(--muted); max-width: 56ch; }
.mail {
  display: inline-block; margin-top: 1rem;
  font-size: clamp(1.35rem, 5vw, 3.6rem);
  font-weight: 800; font-stretch: var(--wide); letter-spacing: -0.025em; line-height: 1.1;
  text-decoration: none;
  overflow-wrap: anywhere;
  background-image: linear-gradient(var(--marker), var(--marker));
  background-size: 100% 0.14em; background-position: 0 92%; background-repeat: no-repeat;
  transition: background-size 0.3s ease;
}
.mail:hover { background-size: 100% 0.32em; }

/* ---------- Fußzeile ---------- */

.foot { border-top: 1px solid var(--rule); padding-block: 2rem 2.5rem; font-size: 0.95rem; color: var(--muted); }
.foot .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 2rem; align-items: center; }
.foot nav { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--ink); text-decoration: underline; text-decoration-color: var(--marker); }
.fw-hero h2 + .claim { margin-top: 1rem; }

figure.visual { margin: 0; }

@media (max-width: 34rem) {
  .track li { font-size: 0; }
  .track li.now { font-size: 0.78rem; white-space: nowrap; }
  .mail { font-size: 1.3rem; font-stretch: 100%; letter-spacing: -0.01em; }
}
