/* Gateclave.io — tek sayfa, kaydırmayla ilerleyen 3B anlatı.
   Tasarım kaynağı: design/Gateclave Website.dc.html (inline stiller buraya taşındı). */

:root {
  --ink: #0A0907;
  --paper: #F2EEE4;
  --amber: #F0A400;
  --amber-hi: #FFB61F;
  --cyan: #5BC8D8;
  --cyan-lo: #9BDCE6;
  --tan: #C9C0AE;
  --muted: #A79E8D;
  --dim: #7A7264;
  --dimmer: #6E6656;
  --faint: #4E4739;
  --line: rgba(242, 238, 228, .12);
  --hairline: rgba(242, 238, 228, .08);
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--paper); text-decoration: none; }
a:hover { color: var(--amber); }
::selection { background: rgba(240, 164, 0, .3); }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }

/* İki yönlü ışık halesi — amber sağ üstte, soğuk mavi sol altta. */
.gc {
  background:
    radial-gradient(900px 620px at 74% 12%, rgba(240, 164, 0, .13), transparent 70%),
    radial-gradient(700px 500px at 8% 60%, rgba(91, 200, 216, .06), transparent 70%),
    var(--ink);
}

/* ---------- Kaydırma parkuru ---------- */

.gc-track { position: relative; height: var(--track-h); }

.gc-stage {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
}

/* ---------- Marka ve dil ---------- */

.gc-brand {
  position: absolute;
  left: 40px;
  top: 36px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 12px;
}

.gc-brand-link { display: flex; align-items: center; gap: 12px; }
.gc-brand img { display: block; border-radius: 6px; }
.gc-word { font-size: 18px; font-weight: 600; letter-spacing: -.01em; }
.gc-word span { color: var(--dim); }

.gc-lang {
  margin-left: 12px;
  background: transparent;
  border: 1px solid rgba(242, 238, 228, .16);
  color: var(--dim);
  border-radius: 6px;
  padding: 5px 9px;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  cursor: pointer;
}

.gc-lang:hover { border-color: var(--amber); color: var(--amber); }

/* ---------- 3B sahne ---------- */

.gc-scene-wrap {
  position: absolute;
  right: 6%;
  top: 0;
  width: 62%;
  height: 100%;
  display: grid;
  place-items: center;
  perspective: 1500px;
}

/* --camz/--cams katman derinliğini, --gc-rx/--gc-rz imleç parallaxını taşır. */
.gc-scene {
  width: 460px;
  height: 460px;
  position: relative;
  transform-style: preserve-3d;
  transform:
    rotateX(calc(58deg + var(--gc-rx, 0deg)))
    rotateZ(calc(-34deg + var(--gc-rz, 0deg)))
    translateZ(var(--camz, 0px))
    scale(var(--cams, .72));
  transition: transform .9s cubic-bezier(.3, .7, .25, 1);
}

.gc-layer {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: opacity .7s ease;
}

.gc-layer-systems { opacity: var(--ls, 1); }
.gc-layer-gate { inset: 40px; transform: translateZ(168px); opacity: var(--lg, 1); }
.gc-layer-agents { inset: 24px; transform: translateZ(330px); opacity: var(--la, 1); }

.gc-grid-lines {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(242, 238, 228, .07);
  background-image:
    linear-gradient(rgba(242, 238, 228, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(242, 238, 228, .05) 1px, transparent 1px);
  background-size: 46px 46px;
}

.gc-systems {
  position: absolute;
  inset: 46px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 12px;
  font-family: var(--mono);
  color: var(--tan);
}

.gc-systems span {
  border: 1px solid rgba(242, 238, 228, .16);
  background: rgba(242, 238, 228, .05);
  border-radius: 3px;
  display: grid;
  place-items: center;
  font-size: 13px;
}

.gc-systems .sm { font-size: 11px; }
.gc-systems .more {
  border: 1px dashed rgba(242, 238, 228, .14);
  background: none;
  font-size: 15px;
  color: var(--dimmer);
}

.gc-layer-gate {
  border-radius: 6px;
  background: rgba(20, 17, 12, .86);
  box-shadow: 0 0 0 1px rgba(240, 164, 0, .45), 0 0 70px -8px rgba(240, 164, 0, .4);
}

.gc-cells {
  position: absolute;
  inset: 26px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, 1fr);
  gap: 9px;
}

.gc-cells span { border-radius: 3px; background: var(--amber); opacity: .12; }
.gc-cells .live { animation: gcCell 6s linear infinite; }

.gc-agents {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
  gap: 16px;
  font-family: var(--mono);
  color: var(--cyan-lo);
}

.gc-agents span {
  border: 1px solid rgba(91, 200, 216, .3);
  background: rgba(91, 200, 216, .07);
  border-radius: 4px;
  display: grid;
  place-items: center;
  font-size: 12px;
}

.gc-agents .wrap { font-size: 11px; text-align: center; padding: 4px; }

/* Katmanlar arasında yükselen çağrı paketleri. */
.gc-packet { position: absolute; transform-style: preserve-3d; }

.gc-packet i {
  display: block;
  width: 11px;
  height: 11px;
  border-radius: 2px;
  background: var(--amber);
  box-shadow: 0 0 14px 2px rgba(240, 164, 0, .6);
  animation: gcPacket 4.6s cubic-bezier(.5, 0, .5, 1) infinite;
}

.gc-packet i.cyan {
  background: var(--cyan);
  box-shadow: 0 0 14px 2px rgba(91, 200, 216, .55);
}

/* ---------- Metin sütunu ---------- */

.gc-copy {
  position: absolute;
  left: 40px;
  top: 0;
  width: 44%;
  height: 100%;
  display: grid;
  align-content: center;
  z-index: 4;
}

.gc-copy-in { position: relative; height: 420px; }

.gc-hero {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  transition: opacity .5s ease, transform .5s ease;
  pointer-events: none;
}

/* Anlatı başladığında giriş başlığı yukarı süzülüp kaybolur. */
.gc-hero.is-off { opacity: 0; transform: translateY(calc(-50% - 28px)); }

.gc-hero h1 {
  margin: 0;
  font-size: clamp(38px, 4.6vw, 62px);
  line-height: 1.02;
  letter-spacing: -.038em;
  font-weight: 700;
}

.gc-hero h1 span { display: block; }
.gc-hero h1 .amber { color: var(--amber); margin-top: 6px; }

.gc-panel {
  position: absolute;
  left: 0;
  top: 50%;
  max-width: 34ch;
  opacity: 0;
  transform: translateY(calc(-50% + 28px));
  transition: opacity .45s ease, transform .45s ease;
  pointer-events: none;
}

.gc-panel.is-on { opacity: 1; transform: translateY(-50%); }
.gc-panel.is-past { opacity: 0; transform: translateY(calc(-50% - 28px)); }

.gc-panel-head { display: flex; align-items: center; gap: 14px; }

.gc-kicker {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .18em;
  color: var(--accent);
}

.gc-counter {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--dimmer);
}

.gc-progress { margin-top: 14px; width: 210px; height: 2px; background: var(--line); }
.gc-progress i { display: block; height: 2px; background: var(--accent); }

.gc-panel h2 {
  margin: 22px 0 0;
  font-size: clamp(28px, 3.1vw, 42px);
  line-height: 1.08;
  letter-spacing: -.03em;
  font-weight: 700;
}

/* Uzun başlıklar bir kademe küçülür ki sütun yüksekliği taşmasın. */
.gc-panel h2.long { font-size: clamp(26px, 2.7vw, 38px); }

.gc-panel p {
  margin: 16px 0 0;
  font-size: 16.5px;
  line-height: 1.62;
  color: var(--muted);
}

/* ---------- Bölüm göstergesi ve kaydırma ipucu ---------- */

.gc-dots {
  position: absolute;
  right: 40px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 5;
}

.gc-dots span {
  width: 22px;
  height: 2px;
  opacity: .18;
  transition: opacity .4s ease;
}

.gc-dots span:nth-child(1) { background: var(--amber); }
.gc-dots span:nth-child(2) { background: var(--cyan-lo); }
.gc-dots span:nth-child(3) { background: var(--amber); }
.gc-dots span:nth-child(4) { background: var(--tan); }
.gc-dots span.on { opacity: 1; }

.gc-cue {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  transition: opacity .4s ease;
  z-index: 5;
}

.gc-cue.is-off { opacity: 0; }

.gc-mouse {
  width: 22px;
  height: 34px;
  border: 1px solid rgba(242, 238, 228, .28);
  border-radius: 12px;
  display: flex;
  justify-content: center;
  padding-top: 6px;
}

.gc-mouse i {
  display: block;
  width: 3px;
  height: 7px;
  border-radius: 2px;
  background: var(--amber);
  animation: gcWheel 1.9s ease-in-out infinite;
}

.gc-cue-text {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .2em;
  color: var(--faint);
}

/* ---------- Demo bölümü ---------- */

.gc-demo { border-top: 1px solid var(--hairline); }

.gc-demo-in {
  max-width: 1280px;
  margin: 0 auto;
  padding: 110px 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.gc-demo h2 {
  margin: 0;
  font-size: clamp(32px, 3.4vw, 46px);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1.06;
  max-width: 20ch;
}

.gc-demo-copy p {
  margin: 22px 0 0;
  font-size: 17px;
  line-height: 1.62;
  color: var(--muted);
  max-width: 44ch;
}

.gc-demo-meta {
  margin-top: 34px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--dim);
}

.gc-demo-meta a { color: var(--dim); }
.gc-demo-meta a:hover { color: var(--amber); }

.gc-form {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #12100C, #0C0A08);
  border-radius: 12px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.gc-form label { display: flex; flex-direction: column; gap: 8px; }

.gc-form label > span {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--dim);
  text-transform: uppercase;
}

.gc-form input,
.gc-form textarea {
  background: rgba(242, 238, 228, .05);
  border: 1px solid rgba(242, 238, 228, .14);
  border-radius: 7px;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 15px;
  color: var(--paper);
}

.gc-form textarea { resize: vertical; }

.gc-form input:focus,
.gc-form textarea:focus { border-color: var(--amber); outline: none; }

/* Honeypot — ekranda da, ekran okuyucuda da yok. */
.gc-form input[name="_honey"] {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.gc-form button {
  margin-top: 4px;
  background: var(--amber);
  color: var(--ink);
  border: none;
  border-radius: 8px;
  padding: 15px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.gc-form button:hover { background: var(--amber-hi); }
.gc-form button:disabled { opacity: .6; cursor: default; }

/* Gönderim sonrası formun yerini alan bildirim. */
.gc-form-note {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #12100C, #0C0A08);
  border-radius: 12px;
  padding: 44px 32px;
  text-align: center;
}

.gc-form-note h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -.02em;
  color: var(--cyan-lo);
}

.gc-form-note p { margin: 12px 0 0; font-size: 15px; line-height: 1.6; color: var(--muted); }

/* ---------- Alt bilgi ---------- */

.gc-foot { border-top: 1px solid var(--hairline); }

.gc-foot-in {
  max-width: 1280px;
  margin: 0 auto;
  padding: 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.gc-foot-brand { display: flex; align-items: center; gap: 10px; }
.gc-foot-brand img { display: block; border-radius: 4px; }
.gc-foot-brand span { font-size: 14px; font-weight: 500; }
.gc-foot-note { font-family: var(--mono); font-size: 12px; color: var(--dim); }

/* ---------- Hata sayfası ---------- */

/* Hata sayfasında sabitlenmiş sahne yok; marka normal akışta durur. */
.gc-brand--static { position: static; padding: 36px 40px 0; }

.gc-error {
  max-width: 1280px;
  margin: 0 auto;
  padding: 140px 40px;
}

.gc-error h1 {
  margin: 0;
  font-size: clamp(34px, 4vw, 54px);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1.06;
}

.gc-error p { margin: 20px 0 0; font-size: 17px; line-height: 1.62; color: var(--muted); max-width: 48ch; }

.gc-btn {
  display: inline-block;
  margin-top: 34px;
  background: var(--amber);
  color: var(--ink);
  border-radius: 8px;
  padding: 14px 22px;
  font-size: 15px;
  font-weight: 600;
}

.gc-btn:hover { background: var(--amber-hi); color: var(--ink); }

/* ---------- Küçük ekranlar ---------- */
/* Sabitlenmiş sahne 100vh + iki sütun ister; dar ekranda parkur çözülür,
   sahne tek seferlik bir görsel olur ve panolar normal akışta dizilir. */

@media (max-width: 1000px) {
  .gc-track { height: auto; }

  .gc-stage {
    position: static;
    height: auto;
    overflow: visible;
    padding: 28px 20px 72px;
  }

  .gc-brand { position: static; margin-bottom: 8px; }

  .gc-scene-wrap {
    position: static;
    width: 100%;
    height: 420px;
    overflow: hidden;
  }

  /* Masaüstünde kamera giriş konumunda (--camz: 0) en üstteki ajan katmanına
     yakın durur; dar ekranda üç katmanın da sığması için yığının ortasına
     (gate katmanı, ~165px derinlik) çekilir. */
  .gc-scene { --cams: .42; --camz: -165px; transition: none; }

  .gc-copy { position: static; width: auto; height: auto; display: block; }
  .gc-copy-in { height: auto; }

  .gc-hero { position: static; transform: none; opacity: 1; }
  .gc-hero.is-off { opacity: 1; transform: none; }

  .gc-panel {
    position: static;
    max-width: none;
    opacity: 1;
    transform: none;
    margin-top: 56px;
    pointer-events: auto;
  }

  .gc-panel.is-past { opacity: 1; transform: none; }

  .gc-dots, .gc-cue { display: none; }

  .gc-demo-in { grid-template-columns: 1fr; padding: 72px 20px; gap: 40px; }
  .gc-form { padding: 24px; }
  .gc-foot-in { padding: 32px 20px; }
}

@media (max-width: 560px) {
  .gc-scene-wrap { height: 400px; }
  .gc-scene { --cams: .32; }
  .gc-brand { flex-wrap: wrap; }
}

/* ---------- Hareket ---------- */

@keyframes gcPacket {
  0%   { transform: translateZ(6px) scale(.6); opacity: 0; }
  14%  { opacity: 1; }
  86%  { opacity: 1; }
  100% { transform: translateZ(330px) scale(.6); opacity: 0; }
}

@keyframes gcCell {
  0%, 70%, 100% { opacity: .12; }
  18%, 40%      { opacity: 1; }
}

@keyframes gcWheel {
  0%, 100% { transform: translateY(0); opacity: .3; }
  45%      { transform: translateY(9px); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001s !important;
  }
}
