:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  --page: #fbfbf8;
  --surface: #ffffff;
  --surface-soft: #f1f1ed;
  --text: #111111;
  --muted: #66666d;
  --border: #deded9;
  --jai: #1677ff;
  --jai-dark: #0759c7;
  --jai-soft: #e7f1ff;
  --jai-pale: #f3f7ff;
  --focus: #005fcc;
  --radius-outer: 32px;
  --radius-inner: 20px;
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --shadow-card:
    0 0 0 1px rgb(17 17 17 / 6%),
    0 2px 5px -2px rgb(17 17 17 / 8%),
    0 20px 54px rgb(17 17 17 / 6%);
  --shadow-card-hover:
    0 0 0 1px rgb(17 17 17 / 10%),
    0 4px 8px -3px rgb(17 17 17 / 11%),
    0 28px 64px rgb(17 17 17 / 10%);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  background: var(--page);
}

body {
  min-width: 0;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background: var(--page);
}

a {
  color: inherit;
}

button,
input,
select,
textarea {
  font: inherit;
}

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

.skip-link {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 20;
  min-height: 44px;
  padding: 12px 16px;
  color: var(--surface);
  background: var(--text);
  border-radius: 12px;
  transform: translateY(-160%);
  transition-property: transform;
  transition-duration: 150ms;
  transition-timing-function: var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

.shell {
  width: min(100% - 48px, 1180px);
  margin-inline: auto;
}

.site-header {
  border-bottom: 1px solid var(--border);
}

.header-shell,
.footer-shell,
.shelf-heading,
.drop-meta,
.drop-action-row,
.waiting-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.header-shell {
  min-height: 72px;
}

.header-actions,
.social-links {
  display: flex;
  align-items: center;
}

.header-actions {
  flex: 0 0 auto;
  gap: 8px;
}

.social-links {
  gap: 2px;
}

.social-icon-link {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  border-radius: 12px;
  text-decoration: none;
  transition-property: color, background-color, box-shadow, scale;
  transition-duration: 150ms;
  transition-timing-function: var(--ease);
}

.social-icon-link:hover {
  color: var(--text);
  background: var(--surface);
  box-shadow: 0 0 0 1px rgb(17 17 17 / 8%);
}

.social-icon-link:active,
.language-button:active,
.language-option:active {
  scale: 0.96;
}

.social-icon-link svg {
  display: block;
  width: 18px;
  height: 18px;
}

.social-icon--threads {
  font-size: 12px;
  font-weight: 780;
  letter-spacing: -0.08em;
  transform: translateY(-0.5px);
}

.language {
  position: relative;
}

.language-button {
  min-width: 46px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  color: var(--text);
  background: transparent;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition-property: color, background-color, box-shadow, scale;
  transition-duration: 150ms;
  transition-timing-function: var(--ease);
}

.language-button:hover,
.language.is-open .language-button {
  background: var(--surface);
  box-shadow: 0 0 0 1px rgb(17 17 17 / 8%);
}

.language-popover {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 30;
  width: min(230px, calc(100vw - 32px));
  padding: 8px;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow-card);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  visibility: hidden;
  transition-property: opacity, transform, visibility;
  transition-duration: 160ms;
  transition-timing-function: var(--ease);
}

.language.is-open .language-popover {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
  visibility: visible;
}

.language-option {
  width: 100%;
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 12px;
  border: 0;
  border-radius: 10px;
  color: var(--text);
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition-property: color, background-color, scale;
  transition-duration: 150ms;
  transition-timing-function: var(--ease);
}

.language-option:hover {
  background: var(--surface-soft);
}

.language-option.is-active {
  color: var(--jai-dark);
  font-weight: 680;
}

.language-option.is-active::after {
  content: "таңдалды";
  color: var(--muted);
  font-size: 12px;
  font-weight: 520;
}

.language-message {
  margin: 6px 0 0;
  padding: 0 12px 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
  opacity: 0;
  transform: translateY(-4px);
  transition-property: opacity, transform;
  transition-duration: 180ms;
  transition-timing-function: var(--ease);
}

.language-message.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.family-link,
.site-footer a,
.return-link {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.family-link {
  gap: 8px;
  font-weight: 650;
  letter-spacing: -0.035em;
}

.family-path {
  width: 42px;
  display: inline-flex;
  align-items: center;
  color: var(--jai);
}

.family-path i {
  height: 1px;
  flex: 1;
  background: currentColor;
}

.family-path b {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
}

.family-current,
.eyebrow,
.waiting-kicker {
  color: var(--jai-dark);
}

.header-note,
.site-footer p,
.shelf-count,
.drop-meta,
.drop-secondary,
.waiting-copy > p:last-child,
.noscript-note,
.error-code {
  color: var(--muted);
}

.header-note,
.site-footer p,
.shelf-count,
.waiting-copy > p,
.error-code {
  margin: 0;
}

.header-note,
.shelf-count,
.drop-meta,
.drop-secondary,
.waiting-meta,
.signal-topline,
.signal-legend,
.waiting-kicker,
.waiting-corner,
.drop-preview-index,
.error-code {
  font-size: 0.8125rem;
  line-height: 1.4;
  letter-spacing: 0.025em;
}

.page-main {
  padding-block: 76px 104px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.7fr);
  align-items: stretch;
  gap: clamp(44px, 7vw, 96px);
}

.hero-copy-panel {
  min-width: 0;
  align-self: center;
  padding-block: 18px;
  animation: rise-in 520ms var(--ease) both;
}

.eyebrow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 190px;
  gap: 24px;
  margin: 0 0 20px;
  font-weight: 650;
}

.eyebrow span:last-child {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.hero h1,
.error-title {
  margin: 0;
  font-size: clamp(6rem, 14vw, 10.5rem);
  line-height: 0.76;
  letter-spacing: -0.085em;
  font-weight: 520;
  text-wrap: balance;
}

.hero-copy {
  max-width: 590px;
  margin: 64px 0 0;
  font-size: clamp(1.125rem, 2.2vw, 1.5rem);
  line-height: 1.45;
  text-wrap: pretty;
}

.hero-signal {
  min-width: 0;
  min-height: 440px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  padding: 22px;
  overflow: hidden;
  color: #ffffff;
  background: var(--jai);
  border-radius: 28px;
  box-shadow:
    0 1px 2px rgb(0 49 120 / 20%),
    0 28px 70px rgb(22 119 255 / 18%);
  animation: rise-in 520ms 80ms var(--ease) both;
}

.signal-topline,
.signal-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  opacity: 0.82;
  font-variant-numeric: tabular-nums;
}

.signal-canvas {
  position: relative;
  min-height: 300px;
}

.signal-line,
.signal-node,
.signal-frame {
  position: absolute;
  display: block;
}

.signal-line {
  height: 2px;
  background: currentColor;
  transform-origin: left center;
}

.signal-line--one {
  top: 43%;
  left: -22px;
  width: 78%;
}

.signal-line--two {
  top: 43%;
  left: 63%;
  width: 44%;
  transform: rotate(90deg);
}

.signal-node {
  width: 18px;
  height: 18px;
  border: 2px solid currentColor;
  border-radius: 50%;
  background: var(--jai);
}

.signal-node--one {
  top: calc(43% - 8px);
  left: 18%;
}

.signal-node--two {
  top: calc(43% - 8px);
  left: calc(63% - 8px);
  animation: signal-breathe 2.8s var(--ease) infinite;
}

.signal-node--three {
  top: 76%;
  left: calc(63% - 8px);
}

.signal-frame {
  border: 1px solid rgb(255 255 255 / 58%);
  border-radius: 15px;
}

.signal-frame--one {
  top: 16%;
  right: 2%;
  width: 30%;
  height: 27%;
}

.signal-frame--two {
  right: 12%;
  bottom: 4%;
  width: 48%;
  height: 33%;
}

.signal-legend span {
  flex: 1;
}

.signal-legend span:nth-child(2) {
  text-align: center;
}

.signal-legend span:last-child {
  text-align: right;
}

.shelf {
  margin-top: 112px;
}

.shelf-heading {
  margin-bottom: 20px;
  padding-inline: 4px;
}

.shelf-heading h2 {
  margin: 0;
  font-size: 1rem;
  font-weight: 650;
}

.waiting-field {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
  grid-template-rows: auto minmax(310px, auto);
  gap: 12px;
  padding: 12px;
  background: var(--surface);
  border-radius: var(--radius-outer);
  box-shadow: var(--shadow-card);
}

.waiting-field > * {
  min-width: 0;
  max-width: 100%;
}

.waiting-meta {
  grid-column: 1 / -1;
  padding: 10px 14px 6px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.waiting-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.waiting-status i {
  width: 7px;
  height: 7px;
  background: var(--jai);
  border-radius: 50%;
}

.waiting-visual {
  position: relative;
  min-height: 310px;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--jai);
  background: var(--jai-soft);
  border-radius: var(--radius-inner);
}

.waiting-visual::before,
.waiting-visual::after {
  position: absolute;
  content: "";
  border: 1px solid rgb(22 119 255 / 28%);
  border-radius: 18px;
}

.waiting-visual::before {
  width: 38%;
  height: 38%;
  top: -9%;
  right: 9%;
}

.waiting-visual::after {
  width: 28%;
  height: 31%;
  right: -7%;
  bottom: 6%;
}

.waiting-ghost {
  position: absolute;
  left: 24px;
  bottom: -0.18em;
  color: rgb(22 119 255 / 10%);
  font-size: clamp(6rem, 15vw, 11rem);
  line-height: 0.8;
  letter-spacing: -0.09em;
  font-weight: 600;
}

.waiting-corner {
  position: absolute;
  top: 22px;
  left: 24px;
  color: var(--jai-dark);
  font-variant-numeric: tabular-nums;
}

.waiting-mark,
.drop-mark {
  width: min(230px, 62%);
  display: flex;
  align-items: center;
  color: currentColor;
}

.waiting-mark i,
.drop-mark i {
  height: 2px;
  flex: 1;
  background: currentColor;
}

.waiting-mark b,
.drop-mark b {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  border: 2px solid currentColor;
  border-radius: 50%;
  background: inherit;
}

.waiting-copy {
  min-height: 310px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: clamp(28px, 5vw, 56px);
  background: var(--surface-soft);
  border-radius: var(--radius-inner);
}

.waiting-kicker {
  margin-bottom: auto !important;
  font-weight: 650;
}

.waiting-copy h2 {
  margin: 40px 0 14px;
  font-size: clamp(1.75rem, 3.4vw, 3.25rem);
  line-height: 1.02;
  letter-spacing: -0.05em;
  font-weight: 520;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.waiting-copy > p:last-child {
  line-height: 1.55;
  text-wrap: pretty;
}

.drop-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.drop-grid[data-count="1"] {
  grid-template-columns: 1fr;
}

.drop-grid[data-count]:not([data-count="1"]) .drop-card--featured {
  grid-column: 1 / -1;
}

.drop-grid[data-count="2"] .drop-card:not(.drop-card--featured) {
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
}

.drop-card {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 12px;
  padding: 12px;
  color: var(--text);
  background: var(--surface);
  border-radius: var(--radius-outer);
  box-shadow: var(--shadow-card);
  text-decoration: none;
  transition-property: transform, box-shadow;
  transition-duration: 150ms;
  transition-timing-function: var(--ease);
}

.drop-card:not(.drop-card--featured) {
  grid-template-columns: 1fr;
}

.drop-card:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.drop-card:active {
  transform: scale(0.96);
}

.drop-body,
.drop-preview {
  min-width: 0;
  min-height: 280px;
  padding: 28px;
  border-radius: var(--radius-inner);
}

.drop-body {
  display: flex;
  flex-direction: column;
  gap: 22px;
  background: var(--surface);
}

.drop-meta,
.drop-secondary {
  font-variant-numeric: tabular-nums;
}

.drop-title {
  margin: auto 0 0;
  font-size: clamp(1.85rem, 4vw, 3.4rem);
  line-height: 0.98;
  letter-spacing: -0.055em;
  font-weight: 520;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.drop-description {
  max-width: 40ch;
  margin: 0;
  font-size: clamp(1.08rem, 1.6vw, 1.25rem);
  line-height: 1.55;
  text-wrap: pretty;
}

.drop-action-row {
  margin-top: auto;
}

.drop-action {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  font-weight: 650;
  color: var(--jai-dark);
}

.drop-preview {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
  overflow: hidden;
  color: var(--jai);
  background: var(--jai-soft);
  text-align: center;
}

.drop-preview::after {
  position: absolute;
  right: -8%;
  bottom: -15%;
  width: 42%;
  aspect-ratio: 1;
  content: "";
  border: 1px solid rgb(22 119 255 / 28%);
  border-radius: 24px;
  pointer-events: none;
}

.drop-preview-index {
  position: absolute;
  top: 24px;
  left: 24px;
  color: var(--jai-dark);
  font-variant-numeric: tabular-nums;
}

.drop-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 16px;
  outline: 1px solid rgb(0 0 0 / 10%);
  outline-offset: -1px;
}

.drop-preview.drop-preview--image {
  padding: 0;
  background: transparent;
}

.drop-preview--image::after,
.drop-preview--image .drop-preview-index {
  display: none;
}

.drop-preview--image img {
  border-radius: inherit;
}

.drop-preview-label {
  position: relative;
  z-index: 1;
  max-width: 16ch;
  color: var(--jai-dark);
  font-size: 1.125rem;
  font-weight: 650;
  overflow-wrap: anywhere;
}

.drop-mark {
  position: relative;
  z-index: 1;
}

.noscript-note {
  margin: 18px 0 0;
}

.site-footer {
  border-top: 1px solid var(--border);
}

.footer-shell {
  min-height: 100px;
}

.site-footer a,
.return-link {
  color: var(--jai-dark);
  font-weight: 600;
}

.error-main {
  min-height: calc(100vh - 172px);
  display: grid;
  align-items: center;
}

.error-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.72fr);
  gap: 12px;
  padding: 12px;
  background: var(--surface);
  border-radius: var(--radius-outer);
  box-shadow: var(--shadow-card);
}

.error-copy-panel,
.error-visual {
  min-height: 420px;
  padding: clamp(30px, 6vw, 64px);
  border-radius: var(--radius-inner);
}

.error-copy-panel {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  background: var(--surface-soft);
}

.error-title {
  margin-top: auto;
  font-size: clamp(4.5rem, 12vw, 8.5rem);
}

.error-copy {
  max-width: 34ch;
  margin: 24px 0 28px;
  font-size: 1.125rem;
  line-height: 1.5;
  text-wrap: pretty;
}

.return-link {
  border-bottom: 1px solid currentColor;
}

.error-visual {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: #ffffff;
  background: var(--jai);
}

.error-visual .waiting-mark {
  width: min(260px, 80%);
}

.error-visual::before {
  position: absolute;
  top: 26px;
  left: 28px;
  content: "404 / JAI";
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes signal-breathe {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgb(255 255 255 / 0%);
  }

  50% {
    box-shadow: 0 0 0 10px rgb(255 255 255 / 15%);
  }
}

@media (max-width: 900px) {
  .header-note {
    display: none;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(270px, 0.65fr);
    gap: 36px;
  }

  .hero-signal {
    min-height: 380px;
  }

  .drop-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .shell {
    width: min(100% - 32px, 1180px);
  }

  .header-shell {
    align-items: center;
    flex-direction: row;
    justify-content: space-between;
    gap: 8px;
    padding-block: 8px;
  }

  .footer-shell {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    gap: 2px;
    padding-block: 12px;
  }

  .header-note {
    padding-left: 0;
  }

  .page-main {
    padding-block: 52px 72px;
  }

  .hero,
  .waiting-field,
  .error-card {
    grid-template-columns: 1fr;
  }

  .hero {
    gap: 48px;
  }

  .hero h1 {
    font-size: clamp(6rem, 30vw, 8rem);
  }

  .hero-copy {
    margin-top: 68px;
    font-size: 1.125rem;
  }

  .hero-signal {
    min-height: 340px;
    border-radius: 24px;
  }

  .signal-canvas {
    min-height: 230px;
  }

  .shelf {
    margin-top: 82px;
  }

  .waiting-field {
    grid-template-rows: auto auto auto;
    border-radius: 28px;
  }

  .waiting-visual,
  .waiting-copy {
    min-height: 280px;
  }

  .waiting-copy {
    padding: 28px;
  }

  .waiting-copy h2 {
    margin-top: 56px;
  }

  .drop-card,
  .drop-card.drop-card--featured,
  .drop-grid[data-count="2"] .drop-card:not(.drop-card--featured) {
    grid-template-columns: 1fr;
  }

  .drop-body,
  .drop-preview {
    min-height: 250px;
    padding: 24px;
  }

  .drop-preview-index {
    top: 20px;
    left: 20px;
  }

  .shelf-heading,
  .drop-action-row {
    align-items: flex-start;
  }

  .error-main {
    min-height: auto;
  }

  .error-copy-panel,
  .error-visual {
    min-height: 330px;
    padding: 30px;
  }
}

@media (max-width: 360px) {
  .shell {
    width: min(100% - 24px, 1180px);
  }

  .shelf-heading,
  .drop-action-row {
    flex-direction: column;
    gap: 4px;
  }

  .family-link {
    gap: 5px;
    font-size: 0.9rem;
  }

  .family-path {
    width: 20px;
  }

  .header-actions {
    gap: 2px;
  }

  .social-icon-link {
    width: 38px;
    height: 38px;
  }

  .language-button {
    min-width: 40px;
    padding-inline: 8px;
  }

  .hero-signal,
  .waiting-field,
  .error-card {
    border-radius: 22px;
  }

  .waiting-visual,
  .waiting-copy,
  .drop-body,
  .drop-preview,
  .error-copy-panel,
  .error-visual {
    border-radius: 12px;
  }
}

@media (forced-colors: active) {
  :focus-visible {
    outline-color: Highlight;
  }

  .hero-signal,
  .waiting-field,
  .waiting-visual,
  .waiting-copy,
  .drop-card,
  .drop-preview,
  .error-card,
  .error-copy-panel,
  .error-visual {
    color: CanvasText;
    background: Canvas;
    border: 1px solid CanvasText;
    box-shadow: none;
  }

  .family-current,
  .eyebrow,
  .waiting-kicker,
  .waiting-mark,
  .drop-mark,
  .site-footer a,
  .return-link,
  .drop-action {
    color: LinkText;
  }

  .waiting-status i {
    background: LinkText;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .drop-card:hover,
  .drop-card:active {
    transform: none;
  }
}
