/* ──────────────────────────────────────────────────────────────
   utopik.ai — single-page business card
   Dark-first · warm-amber accent on cool ink · editorial precision
   ────────────────────────────────────────────────────────────── */

:root {
  /* Foundation — cool dark ink */
  --bg:        #0a0b0d;
  --bg-soft:   #101216;
  --surface:   #131519;
  --surface-2: #181b20;

  /* Contrast hierarchy: foreground → secondary → muted → faint */
  --fg:        #f1f0ec;
  --secondary: #b7b9bd;
  --muted:     #80838a;
  --faint:     #4a4d54;

  /* Lines */
  --line:        rgba(241, 240, 236, 0.09);
  --line-soft:   rgba(241, 240, 236, 0.055);

  /* One accent — warm amber against the cold dark */
  --accent:      #e8a83a;
  --accent-soft: rgba(232, 168, 58, 0.13);
  --accent-line: rgba(232, 168, 58, 0.32);

  --display: "Instrument Serif", Georgia, "Times New Roman", serif;
  --sans: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, monospace;

  --maxw: 1080px;
  --ease: cubic-bezier(0.25, 1, 0.5, 1);
}

@media (prefers-color-scheme: light) {
  :root {
    --bg:        #f7f6f2;
    --bg-soft:   #f1efe9;
    --surface:   #ffffff;
    --surface-2: #faf9f5;
    --fg:        #15161a;
    --secondary: #44474d;
    --muted:     #6c6f76;
    --faint:     #a9acb2;
    --line:      rgba(20, 21, 25, 0.10);
    --line-soft: rgba(20, 21, 25, 0.06);
    --accent:    #b9791a;
    --accent-soft: rgba(185, 121, 26, 0.10);
    --accent-line: rgba(185, 121, 26, 0.30);
  }
}

* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

::selection { background: var(--accent-soft); color: var(--fg); }

/* ── Grain / atmosphere overlay ───────────────────────────────── */
.grain {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.04;
  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.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ── Layout shell ─────────────────────────────────────────────── */
main, .nav, .footer { position: relative; z-index: 1; }

.nav, .block, .footer { padding-left: 32px; padding-right: 32px; }

/* ── Navigation ───────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  max-width: var(--maxw);
  margin: 0 auto;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--line-soft);
}
/* widen the sticky bar's blurred backdrop to full viewport */
.nav::before {
  content: "";
  position: absolute;
  inset: 0 -50vw;
  z-index: -1;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--line-soft);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 16px;
  letter-spacing: -0.02em;
}
.brand-mark {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.brand-tld { color: var(--muted); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
  color: var(--secondary);
}
.nav-links a { transition: color 0.15s var(--ease); }
.nav-links a:hover { color: var(--fg); }
.nav-cta {
  color: var(--fg) !important;
  border: 1px solid var(--line);
  padding: 7px 15px;
  border-radius: 8px;
  transition: border-color 0.15s var(--ease), background 0.15s var(--ease);
}
.nav-cta:hover { border-color: var(--accent-line); background: var(--accent-soft); }

/* ── Hero ─────────────────────────────────────────────────────── */
.hero {
  position: relative;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(72px, 16vh, 168px) 32px clamp(56px, 10vh, 104px);
}
.hero-glow {
  position: absolute;
  top: -120px;
  left: -8%;
  width: 620px;
  height: 620px;
  max-width: 90vw;
  background: radial-gradient(circle at 30% 30%, var(--accent-soft), transparent 62%);
  filter: blur(20px);
  pointer-events: none;
  z-index: -1;
}

.eyebrow {
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 26px;
}

.hero-title {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(46px, 8.2vw, 96px);
  line-height: 0.98;
  letter-spacing: -0.02em;
  margin-bottom: 30px;
}
.hero-title span { display: block; }
.hero-title em {
  font-style: italic;
  color: var(--accent);
}
.accent-line { position: relative; }

.hero-sub {
  max-width: 40ch;
  font-size: clamp(17px, 2.1vw, 20px);
  color: var(--secondary);
  line-height: 1.55;
  margin-bottom: 38px;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  padding: 0 22px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: transform 0.15s var(--ease), background 0.18s var(--ease),
              border-color 0.18s var(--ease), color 0.18s var(--ease);
}
.btn-primary {
  background: var(--accent);
  color: #1a1205;
}
.btn-primary:hover { transform: translateY(-1px); background: #f0b54d; }
.btn-ghost {
  border: 1px solid var(--line);
  color: var(--fg);
}
.btn-ghost:hover { border-color: var(--accent-line); background: var(--accent-soft); }

/* ── Flagship · featured frame ────────────────────────────────── */
.flagship {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(8px, 2vh, 24px) 32px clamp(8px, 2vh, 24px);
}
.flagship-frame {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--accent-line);
  border-radius: 20px;
  padding: clamp(28px, 4vw, 48px);
  background:
    radial-gradient(120% 90% at 0% 0%, var(--accent-soft), transparent 58%),
    linear-gradient(180deg, var(--surface-2), var(--surface));
  box-shadow:
    0 0 0 1px var(--line-soft) inset,
    0 24px 60px -36px rgba(232, 168, 58, 0.45);
}
.flagship-glow {
  position: absolute;
  top: -40%;
  right: -10%;
  width: 460px;
  height: 460px;
  max-width: 80%;
  background: radial-gradient(circle at 50% 50%, var(--accent-soft), transparent 64%);
  filter: blur(26px);
  pointer-events: none;
  z-index: 0;
}
.flagship-frame > *:not(.flagship-glow) { position: relative; z-index: 1; }

.flagship-head { margin-bottom: 30px; }
.flagship-eyebrow {
  display: inline-block;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}
.flagship-title {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(28px, 4.6vw, 44px);
  letter-spacing: -0.02em;
  line-height: 1.04;
  margin-bottom: 14px;
}
.flagship-lede {
  max-width: 52ch;
  color: var(--secondary);
  font-size: 16px;
}

/* analogy chip — plain-English handle, never a metric */
.analogy {
  font-family: var(--display);
  font-style: italic;
  font-size: 1.02em;
  color: var(--accent);
  margin-bottom: 10px !important;
}

.flag-tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
}
.flag-tag--hero {
  color: var(--accent);
  border: 1px solid var(--accent-line);
  background: var(--accent-soft);
  padding: 4px 11px;
  border-radius: 999px;
}

/* Hero product — visually primary */
.flagship-hero {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 28px;
  padding: clamp(24px, 3vw, 34px);
  margin-bottom: 16px;
  border: 1px solid var(--accent-line);
  border-radius: 16px;
  background:
    linear-gradient(180deg, var(--accent-soft), transparent 72%),
    var(--surface);
}
.flagship-hero-copy h3 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(26px, 3.6vw, 38px);
  letter-spacing: -0.02em;
  line-height: 1.06;
  margin-bottom: 8px;
}
.flagship-hero-copy > p:last-child {
  color: var(--secondary);
  font-size: 16px;
  max-width: 54ch;
}
.flagship-hero-copy .analogy { font-size: clamp(17px, 2.2vw, 21px); }

.flagship-hero-mark {
  position: relative;
  width: 92px;
  height: 92px;
  flex: none;
}
.hero-mark-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1.5px solid var(--accent-line);
  box-shadow: 0 0 0 8px var(--accent-soft);
}
.hero-mark-dot {
  position: absolute;
  inset: 34px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 24px 2px rgba(232, 168, 58, 0.55);
  animation: pulse 2.8s var(--ease) infinite;
}

/* Three supporting paths */
.flagship-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.flag-card {
  background: color-mix(in srgb, var(--surface) 70%, transparent);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease),
              transform 0.2s var(--ease);
}
.flag-card:hover {
  border-color: var(--accent-line);
  transform: translateY(-2px);
  background: var(--surface-2);
}
.flag-card h4 {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.25;
  margin-bottom: 8px;
}
.flag-card .analogy { font-size: 15px; }
.flag-card > p:last-child { color: var(--muted); font-size: 14.5px; line-height: 1.55; }

/* ── Generic block ────────────────────────────────────────────── */
.block {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-top: clamp(64px, 11vh, 112px);
  padding-bottom: clamp(8px, 2vh, 24px);
  border-top: 1px solid var(--line-soft);
}

.block-head { margin-bottom: 48px; }
.section-index {
  display: inline-block;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 14px;
}
.section-title {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(30px, 5vw, 46px);
  letter-spacing: -0.02em;
  line-height: 1.05;
  margin-bottom: 16px;
}
.section-lede {
  max-width: 46ch;
  color: var(--muted);
  font-size: 16px;
}

/* ── What-we-do cards ─────────────────────────────────────────── */
.cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease),
              transform 0.2s var(--ease);
}
.card:hover {
  border-color: var(--accent-line);
  transform: translateY(-2px);
  background: var(--surface-2);
}
.card-tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 18px;
}
.card h3 {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-bottom: 10px;
}
.card p { color: var(--secondary); font-size: 15.5px; line-height: 1.55; }

.card--preview {
  border-color: var(--accent-line);
  background: linear-gradient(180deg, var(--accent-soft), transparent 70%), var(--surface);
}
.card--preview .card-tag {
  color: var(--accent);
}
.card--preview .card-tag::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  margin-right: 7px;
  vertical-align: middle;
  animation: pulse 2.4s var(--ease) infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

/* ── Selected work list ───────────────────────────────────────── */
.work-list { list-style: none; }
.work-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: baseline;
  gap: 24px;
  padding: 26px 4px;
  border-top: 1px solid var(--line-soft);
  transition: padding-left 0.22s var(--ease);
}
.work-item:last-child { border-bottom: 1px solid var(--line-soft); }
.work-item:hover { padding-left: 12px; }
.work-num {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--faint);
  font-variant-numeric: tabular-nums;
  padding-top: 4px;
}
.work-body h3 {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-bottom: 6px;
}
.work-body p { color: var(--muted); font-size: 15px; max-width: 56ch; }
.work-kind {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--secondary);
  white-space: nowrap;
  padding-top: 4px;
}
.work-item:hover .work-kind { color: var(--accent); }

/* ── Contact ──────────────────────────────────────────────────── */
.contact { text-align: center; }
.contact .section-index { display: block; }
.contact-title {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(34px, 6vw, 60px);
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 14px 0 18px;
}
.contact-sub {
  color: var(--muted);
  max-width: 44ch;
  margin: 0 auto 34px;
}
.mail {
  display: inline-block;
  font-family: var(--display);
  font-size: clamp(26px, 5vw, 40px);
  font-style: italic;
  color: var(--accent);
  letter-spacing: -0.01em;
  border-bottom: 1px solid var(--accent-line);
  padding-bottom: 4px;
  transition: border-color 0.2s var(--ease), opacity 0.2s var(--ease);
}
.mail:hover { opacity: 0.82; border-color: var(--accent); }

/* ── Footer ───────────────────────────────────────────────────── */
.footer {
  max-width: var(--maxw);
  margin: clamp(72px, 12vh, 120px) auto 0;
  padding-top: 28px;
  padding-bottom: 40px;
  border-top: 1px solid var(--line-soft);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-brand { font-weight: 600; letter-spacing: -0.02em; }
.footer-meta { font-family: var(--mono); font-size: 12px; color: var(--faint); }

/* ── Entrance animation ───────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  animation: rise 0.7s var(--ease) forwards;
  animation-delay: calc(var(--d) * 110ms + 80ms);
}
@keyframes rise {
  to { opacity: 1; transform: translateY(0); }
}

/* ── Responsive ───────────────────────────────────────────────── */
/* tablet — supporting paths drop to a single column before they get cramped */
@media (max-width: 860px) {
  .flagship-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  body { font-size: 16px; }
  .nav { height: 60px; }
  .nav-links { gap: 16px; font-size: 13px; }
  .nav-links a:not(.nav-cta) { display: none; }
  .nav, .block, .footer, .hero, .flagship { padding-left: 22px; padding-right: 22px; }
  .cards { grid-template-columns: 1fr; }
  .flagship-hero { grid-template-columns: 1fr; gap: 20px; }
  .flagship-hero-mark { display: none; }
  .work-item {
    grid-template-columns: auto 1fr;
    gap: 10px 16px;
  }
  .work-kind { grid-column: 2; padding-top: 2px; }
  .work-item:hover { padding-left: 4px; }
}

@media (prefers-reduced-motion: reduce) {
  *, html { scroll-behavior: auto; }
  .reveal { animation: none; opacity: 1; transform: none; }
  .card--preview .card-tag::before { animation: none; }
  .hero-mark-dot { animation: none; }
}

/* ── Language toggle (EN/TR) ──────────────────────────────────── */
.nav-lang {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 4px;
  padding-left: 16px;
  border-left: 1px solid var(--line-soft);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.04em;
}
.nav-lang a {
  color: var(--muted);
  padding: 4px 7px;
  border-radius: 6px;
  transition: color 0.15s var(--ease), background 0.15s var(--ease);
}
.nav-lang a:hover { color: var(--fg); }
.nav-lang a.is-current {
  color: var(--accent);
  background: var(--accent-soft);
}
@media (max-width: 720px) {
  /* keep the language toggle visible even though other nav links hide */
  .nav-links .nav-lang { display: inline-flex; padding-left: 12px; }
  .nav-lang a { padding: 3px 5px; }
}
