/* ==========================================================================
   KATKA GmbH — landing page
   Editorial / Swiss-Bauhaus inspired. Black ink on warm paper, with the
   brand's red + yellow used only as precise accent rules (echoing the logo).
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  --ink:        #131210;   /* near-black, softer than pure */
  --paper:      #f6f3ec;   /* warm paper */
  --paper-2:    #efeae0;   /* slightly darker paper for surfaces */
  --muted:      #6c675d;   /* secondary text */
  --rule:       #d8d2c4;   /* hairline rules */
  --red:        #e2231a;   /* from logo */
  --yellow:     #f2b705;   /* from logo */

  --maxw: 1200px;
  --gut: clamp(20px, 5vw, 64px);

  --font: "Space Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "Space Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --ease: cubic-bezier(.2, .7, .2, 1);
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-weight: 400;
  color: var(--ink);
  background-color: var(--paper);
  /* subtle paper grain so it never reads as a flat "AI" fill */
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
  background-size: 160px 160px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ol { margin: 0; padding: 0; list-style: none; }

::selection { background: var(--yellow); color: var(--ink); }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gut);
}

/* ---------- Brand rule (echoes the logo's red / yellow lines) ---------- */
.brand-rule {
  height: 2px;
  width: 100%;
  border: 0;
  background:
    linear-gradient(to right,
      var(--red)     0, var(--red)     36px,
      var(--ink)     36px, var(--ink)  calc(100% - 36px),
      var(--yellow)  calc(100% - 36px), var(--yellow) 100%);
}
.container-rule { max-width: var(--maxw); margin-inline: auto; }

/* ==========================================================================
   NAV
   ========================================================================== */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
}
.nav__inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 76px;
}
.nav__brand { display: inline-flex; }
.nav__logo  { height: 40px; width: auto; }

.nav__links {
  margin-inline-start: auto;
  display: flex;
  gap: 28px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.nav__links a {
  position: relative;
  padding: 6px 0;
  color: var(--ink);
  transition: color .2s var(--ease);
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 2px;
  background: var(--red);
  transition: width .25s var(--ease);
}
.nav__links a:hover { color: var(--red); }
.nav__links a:hover::after { width: 100%; }

.nav__tools { display: flex; align-items: center; }

/* ---------- Language toggle ---------- */
.lang {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .06em;
}
.lang__sep { color: var(--rule); }
.lang__btn {
  padding: 4px 2px;
  color: var(--muted);
  transition: color .2s var(--ease);
}
.lang__btn:hover { color: var(--ink); }
.lang__btn[aria-pressed="true"] {
  color: var(--ink);
  font-weight: 700;
  box-shadow: inset 0 -3px 0 var(--yellow);
}

.nav__rule { margin-top: -1px; }

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
  position: relative;
  padding-block: clamp(72px, 12vh, 150px) clamp(56px, 9vh, 110px);
  overflow: hidden;
}
.hero__inner { position: relative; z-index: 1; max-width: 980px; }

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 28px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink);
}
.kicker__dot {
  width: 9px; height: 9px;
  background: var(--red);
  border-radius: 50%;
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--red) 18%, transparent);
}

.hero__title {
  margin: 0 0 28px;
  font-size: clamp(2.4rem, 6.4vw, 5.4rem);
  line-height: 1.02;
  letter-spacing: -.02em;
  font-weight: 700;
  max-width: 16ch;
}
.hero__title em { font-style: normal; color: var(--red); }

.hero__sub {
  margin: 0 0 40px;
  max-width: 56ch;
  font-size: clamp(1.02rem, 1.6vw, 1.22rem);
  color: var(--muted);
}

.hero__cta { display: flex; flex-wrap: wrap; gap: 16px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 26px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .08em;
  text-transform: uppercase;
  border: 2px solid var(--ink);
  transition: transform .2s var(--ease), background .2s var(--ease), color .2s var(--ease);
}
.btn:hover { background: var(--red); border-color: var(--red); transform: translateY(-2px); }

.btn--ghost {
  background: transparent;
  color: var(--ink);
}
.btn--ghost:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }

/* corner stamp */
.hero__corner {
  position: absolute;
  right: var(--gut);
  top: clamp(80px, 13vh, 130px);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}
.hero__est { color: var(--ink); font-weight: 700; }

/* ==========================================================================
   TICKER
   ========================================================================== */
.ticker {
  border-block: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  overflow: hidden;
  white-space: nowrap;
  padding-block: 14px;
}
.ticker__track {
  display: inline-flex;
  gap: 0;
  animation: tick 32s linear infinite;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.ticker__track span { padding-inline: 8px; }
.ticker__track span:nth-child(3n) { color: var(--yellow); }
.ticker__track span:nth-child(3n+1) { color: var(--red); }

@keyframes tick {
  from { transform: translateX(0); }
  to   { transform: translateX(-33.333%); }
}

/* ==========================================================================
   SECTIONS
   ========================================================================== */
.section { padding-block: clamp(64px, 10vh, 120px); }

.section__head {
  display: flex;
  align-items: baseline;
  gap: 18px;
  margin-bottom: 44px;
}
.section__index {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
  color: var(--paper);
  background: var(--ink);
  padding: 4px 10px;
  letter-spacing: .04em;
}
.section__label {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}

.section__title {
  margin: 0;
  font-size: clamp(1.7rem, 3.6vw, 2.9rem);
  line-height: 1.08;
  letter-spacing: -.02em;
  font-weight: 700;
}
.section__title--lead { margin-bottom: 48px; max-width: 20ch; }

/* split (about) */
.split {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}
.split .section__body { color: var(--muted); font-size: 1.05rem; }
.split .section__body p { margin: 0 0 1em; }
.split .section__body p:last-child { margin-bottom: 0; }

/* ---------- Services (editorial list, not cards) ---------- */
.services { border-top: 1px solid var(--ink); }

.service {
  display: grid;
  grid-template-columns: 70px 1fr auto;
  align-items: center;
  gap: clamp(16px, 4vw, 48px);
  padding: clamp(24px, 4vw, 40px) 0;
  border-bottom: 1px solid var(--rule);
  transition: padding-left .3s var(--ease), background .3s var(--ease);
}
.service:hover {
  padding-left: 12px;
  background: linear-gradient(to right,
    color-mix(in srgb, var(--yellow) 26%, transparent) 0,
    transparent 8%);
}
.service__num {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
  color: var(--red);
  letter-spacing: .04em;
}
.service__name {
  margin: 0 0 8px;
  font-size: clamp(1.2rem, 2.4vw, 1.8rem);
  font-weight: 700;
  letter-spacing: -.01em;
  line-height: 1.1;
}
.service__desc {
  margin: 0;
  max-width: 60ch;
  color: var(--muted);
  font-size: 1.02rem;
}
.service__tag {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--rule);
  padding: 6px 12px;
  border-radius: 999px;
  white-space: nowrap;
}

/* ==========================================================================
   CONTACT
   ========================================================================== */
.contact { max-width: 880px; }
.contact__sub {
  margin: 20px 0 44px;
  max-width: 58ch;
  font-size: 1.08rem;
  color: var(--muted);
}
.contact__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-bottom: 44px;
  padding-block: 28px;
  border-block: 1px solid var(--rule);
}
.contact__cap {
  display: block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}
.contact__val {
  font-size: 1.1rem;
  font-weight: 500;
}
a.contact__val:hover { color: var(--red); }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.footer { padding-bottom: 48px; }
.footer__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
  padding-top: 48px;
}
.footer__logo { height: 38px; width: auto; margin-bottom: 14px; }
.footer__claim {
  margin: 0;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}
.footer__meta { justify-self: end; text-align: right; }
.footer__copy {
  margin: 0 0 10px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .06em;
  color: var(--ink);
}
.footer__imprint {
  font-size: 12px;
  color: var(--muted);
  max-width: 34ch;
  line-height: 1.5;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 860px) {
  .nav__links { display: none; }            /* short page — reachable by scroll */
  .hero__corner { display: none; }
  .split { grid-template-columns: 1fr; }
  .contact__grid { grid-template-columns: 1fr; gap: 24px; }
  .footer__inner { grid-template-columns: 1fr; }
  .footer__meta { justify-self: start; text-align: left; }
}

@media (max-width: 560px) {
  .service { grid-template-columns: 44px 1fr; }
  .service__tag { display: none; }
  .hero__cta .btn { flex: 1 1 auto; justify-content: center; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker__track { animation: none; }
  * { transition: none !important; }
}
