/* Kedalin Tech: coming soon page. No JavaScript; strict CSP (no inline styles). */

@font-face {
  font-family: "Geist";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url("fonts/geist-latin-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Geist";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url("fonts/geist-latin-ext-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Geist Mono";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url("fonts/geist-mono-latin-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Geist Mono";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url("fonts/geist-mono-latin-ext-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: italic;
  font-display: swap;
  font-weight: 400;
  src: url("fonts/instrument-serif-latin-400-italic.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: italic;
  font-display: swap;
  font-weight: 400;
  src: url("fonts/instrument-serif-latin-ext-400-italic.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  color-scheme: dark light;

  --bg: #06070b;
  --bg-elev: rgb(255 255 255 / 0.035);
  --text: #eceef3;
  --muted: #9ba1ae;
  --faint: #7d8392;
  --line: rgb(255 255 255 / 0.09);
  --line-strong: rgb(255 255 255 / 0.16);
  --accent-1: #93a4ff;
  --accent-2: #c3a6ff;
  --accent-3: #74e4d4;
  --ok: #74e4b0;
  --glow-1: rgb(88 101 242 / 0.30);
  --glow-2: rgb(147 84 255 / 0.20);
  --glow-3: rgb(45 212 191 / 0.16);
  --grid: rgb(255 255 255 / 0.055);
  --noise-opacity: 0.05;
  --shadow: 0 30px 80px -20px rgb(0 0 0 / 0.65), 0 0 0 1px var(--line);

  --font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --font-serif: "Instrument Serif", ui-serif, Georgia, serif;

  --gutter: clamp(16px, 4vw, 48px);
  --radius: 18px;
}

/* Light theme: when the system is light and the visitor has not chosen dark, or when they chose light. */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f6f6f3;
    --bg-elev: rgb(255 255 255 / 0.7);
    --text: #0d0f14;
    --muted: #4c5260;
    --faint: #5f6573;
    --line: rgb(13 15 20 / 0.09);
    --line-strong: rgb(13 15 20 / 0.16);
    --accent-1: #3347d1;
    --accent-2: #7a3fd6;
    --accent-3: #0b7f72;
    --ok: #0a7d55;
    --glow-1: rgb(88 101 242 / 0.20);
    --glow-2: rgb(167 120 255 / 0.16);
    --glow-3: rgb(45 212 191 / 0.16);
    --grid: rgb(13 15 20 / 0.06);
    --noise-opacity: 0.035;
    --shadow: 0 30px 70px -30px rgb(30 35 60 / 0.35), 0 0 0 1px var(--line);
  }
}

:root[data-theme="light"] {
  --bg: #f6f6f3;
  --bg-elev: rgb(255 255 255 / 0.7);
  --text: #0d0f14;
  --muted: #4c5260;
  --faint: #5f6573;
  --line: rgb(13 15 20 / 0.09);
  --line-strong: rgb(13 15 20 / 0.16);
  --accent-1: #3347d1;
  --accent-2: #7a3fd6;
  --accent-3: #0b7f72;
  --ok: #0a7d55;
  --glow-1: rgb(88 101 242 / 0.20);
  --glow-2: rgb(167 120 255 / 0.16);
  --glow-3: rgb(45 212 191 / 0.16);
  --grid: rgb(13 15 20 / 0.06);
  --noise-opacity: 0.035;
  --shadow: 0 30px 70px -30px rgb(30 35 60 / 0.35), 0 0 0 1px var(--line);
}

:root[data-theme="dark"] {
  color-scheme: dark;
}

:root[data-theme="light"] {
  color-scheme: light;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
  isolation: isolate;
}

/* ---------- Atmosphere: aurora, grid, grain ---------- */

.backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.aurora {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  will-change: transform;
}

.aurora--one {
  width: 62vmax;
  height: 62vmax;
  top: -28vmax;
  left: -12vmax;
  background: radial-gradient(circle at center, var(--glow-1), transparent 65%);
  animation: drift-one 26s ease-in-out infinite alternate;
}

.aurora--two {
  width: 52vmax;
  height: 52vmax;
  top: -18vmax;
  right: -20vmax;
  background: radial-gradient(circle at center, var(--glow-2), transparent 65%);
  animation: drift-two 32s ease-in-out infinite alternate;
}

.aurora--three {
  width: 48vmax;
  height: 48vmax;
  bottom: -30vmax;
  left: 22vw;
  background: radial-gradient(circle at center, var(--glow-3), transparent 65%);
  animation: drift-three 38s ease-in-out infinite alternate;
}

.grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--grid) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid) 1px, transparent 1px);
  background-size: 64px 64px;
  background-position: center top;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 20%, transparent 75%);
}

.grain {
  position: absolute;
  inset: -50%;
  background-image: url("noise.svg");
  background-size: 220px 220px;
  opacity: var(--noise-opacity);
  mix-blend-mode: overlay;
}

@keyframes drift-one {
  to { transform: translate3d(8vw, 6vh, 0) scale(1.08); }
}
@keyframes drift-two {
  to { transform: translate3d(-10vw, 10vh, 0) scale(0.94); }
}
@keyframes drift-three {
  to { transform: translate3d(-6vw, -8vh, 0) scale(1.1); }
}

/* ---------- Layout ---------- */

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

.site-header {
  padding-block: clamp(20px, 3.5vw, 36px);
}

.site-header .shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  text-decoration: none;
  border-radius: 10px;
}

.brand__mark {
  width: 34px;
  height: 34px;
  flex: none;
}

.brand__name {
  font-weight: 600;
  font-size: 1.125rem;
  letter-spacing: -0.02em;
}

.brand__name span {
  color: var(--muted);
  font-weight: 400;
}

.controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.theme {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.theme[hidden] {
  display: none;
}

.theme button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.theme button:hover {
  color: var(--text);
}

.theme button[aria-pressed="true"] {
  color: var(--text);
  background: var(--line-strong);
}

.theme svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.theme svg .fill {
  fill: currentColor;
  stroke: none;
}

.lang {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
}

.lang a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.lang abbr {
  text-decoration: none;
}

.lang a:hover {
  color: var(--text);
}

.lang a[aria-current="page"] {
  color: var(--text);
  background: var(--line-strong);
}

main {
  flex: 1;
  display: flex;
  align-items: center;
  padding-block: clamp(24px, 6vh, 72px);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(40px, 6vw, 88px);
}

/* ---------- Hero copy ---------- */

.status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 28px;
  padding: 7px 14px 7px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.status strong {
  color: var(--text);
  font-weight: 500;
}

.status__dot {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ok);
  flex: none;
}

.status__dot::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--ok);
  animation: ping 2.4s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes ping {
  75%,
  100% {
    transform: scale(2.6);
    opacity: 0;
  }
}

h1 {
  margin: 0;
  font-size: clamp(2.6rem, 1.4rem + 5.2vw, 5.4rem);
  line-height: 1.02;
  letter-spacing: -0.045em;
  font-weight: 600;
  text-wrap: balance;
}

h1 em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.02em;
  padding-right: 0.06em;
  background: linear-gradient(100deg, var(--accent-1) 0%, var(--accent-2) 45%, var(--accent-3) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead {
  margin: 28px 0 0;
  max-width: 34rem;
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
  line-height: 1.6;
  color: var(--muted);
  text-wrap: pretty;
}

.capabilities {
  list-style: none;
  margin: 40px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 34rem;
  border-top: 1px solid var(--line);
}

.capabilities li {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.9375rem;
  color: var(--text);
}

.capabilities li:nth-child(odd) {
  padding-right: 16px;
}

.capabilities li span {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--faint);
  letter-spacing: 0.04em;
}

/* ---------- Console card ---------- */

.console {
  position: relative;
  border-radius: var(--radius);
  background: var(--bg-elev);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  backdrop-filter: blur(20px) saturate(1.2);
  box-shadow: var(--shadow);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  line-height: 1.9;
  overflow: hidden;
}

.console::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(140deg, var(--accent-1), transparent 35%, transparent 65%, var(--accent-3));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  opacity: 0.55;
  pointer-events: none;
}

.console__bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
}

.console__bar i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--line-strong);
}

.console__bar b {
  margin-left: auto;
  font-weight: 400;
  font-size: 0.75rem;
  color: var(--faint);
}

.console__body {
  padding: 20px 22px 24px;
  color: var(--muted);
}

.console__body p {
  margin: 0;
  display: flex;
  gap: 10px;
  white-space: nowrap;
}

.console__body .cmd {
  color: var(--text);
  margin-bottom: 10px;
}

.console__body .prompt {
  color: var(--accent-3);
}

.console__body .key {
  flex: 1;
  overflow: hidden;
}

.console__body .key::after {
  content: " ..............................................";
  color: var(--faint);
  opacity: 0.6;
}

.console__body .ok {
  color: var(--ok);
}

.console__body .wip {
  color: var(--accent-2);
}

.cursor {
  display: inline-block;
  width: 0.6em;
  height: 1.15em;
  margin-left: 2px;
  vertical-align: -0.2em;
  background: var(--accent-2);
  animation: blink 1.1s steps(2, start) infinite;
}

@keyframes blink {
  to { visibility: hidden; }
}

.console__body .progress {
  margin-top: 16px;
  height: 3px;
  border-radius: 3px;
  background: var(--line);
  overflow: hidden;
}

.console__body .progress span {
  display: block;
  width: 72%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent-1), var(--accent-2), var(--accent-3));
  background-size: 200% 100%;
  animation: shimmer 3.5s linear infinite;
}

@keyframes shimmer {
  to { background-position: -200% 0; }
}

/* ---------- Footer ---------- */

.site-footer {
  padding-block: 28px clamp(24px, 4vw, 36px);
  font-size: 0.8125rem;
  color: var(--faint);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.site-footer p {
  margin: 0;
}

.site-footer .mono {
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
}

/* ---------- Entrance ---------- */

.reveal {
  animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.reveal--2 { animation-delay: 0.08s; }
.reveal--3 { animation-delay: 0.16s; }
.reveal--4 { animation-delay: 0.24s; }
.reveal--5 { animation-delay: 0.36s; }

@keyframes rise {
  from {
    opacity: 0;
    transform: translate3d(0, 14px, 0);
  }
}

.link {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--accent-1);
  text-underline-offset: 4px;
}

/* ---------- Focus, selection ---------- */

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent-1);
  outline-offset: 3px;
}

::selection {
  background: var(--accent-1);
  color: var(--bg);
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .hero {
    grid-template-columns: minmax(0, 1fr);
  }
  .console {
    max-width: 34rem;
  }
}

@media (max-width: 480px) {
  .status {
    font-size: 0.75rem;
    letter-spacing: 0.02em;
    white-space: nowrap;
  }
  .capabilities {
    grid-template-columns: minmax(0, 1fr);
  }
  .capabilities li:nth-child(odd) {
    padding-right: 0;
  }
  .brand__name span {
    display: none;
  }
  .controls {
    gap: 6px;
  }
  .theme button {
    width: 32px;
  }
  .console {
    font-size: 0.8125rem;
  }
}

@media (max-width: 359px) {
  .status__more {
    display: none;
  }
  /* The logo alone is enough here; the link keeps its accessible name. */
  .brand__name {
    display: none;
  }
}

/* ---------- Accessibility preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

@media (prefers-contrast: more) {
  :root {
    --muted: var(--text);
    --faint: var(--text);
    --line: var(--line-strong);
  }
  .grain,
  .grid {
    display: none;
  }
}

@media (forced-colors: active) {
  h1 em {
    color: CanvasText;
    background: none;
  }
  .console::before {
    display: none;
  }
}
