/* YUGUR: a made-up sneaker store, a G Development portfolio demo */

@font-face { font-family: 'Unbounded'; src: url('/demo/yugur/assets/fonts/unbounded-latin-wght-normal.woff2') format('woff2'); font-weight: 200 900; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Unbounded'; src: url('/demo/yugur/assets/fonts/unbounded-latin-ext-wght-normal.woff2') format('woff2'); font-weight: 200 900; font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Unbounded'; src: url('/demo/yugur/assets/fonts/unbounded-cyrillic-wght-normal.woff2') format('woff2'); font-weight: 200 900; font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Manrope'; src: url('/demo/yugur/assets/fonts/manrope-latin-wght-normal.woff2') format('woff2'); font-weight: 200 800; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Manrope'; src: url('/demo/yugur/assets/fonts/manrope-latin-ext-wght-normal.woff2') format('woff2'); font-weight: 200 800; font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Manrope'; src: url('/demo/yugur/assets/fonts/manrope-cyrillic-wght-normal.woff2') format('woff2'); font-weight: 200 800; font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'JetBrains Mono'; src: url('/demo/yugur/assets/fonts/jetbrains-mono-latin-500-normal.woff2') format('woff2'); font-weight: 500; font-display: swap;
  unicode-range: U+0000-00FF, U+02BB-02BC, U+2000-206F; }
@font-face { font-family: 'JetBrains Mono'; src: url('/demo/yugur/assets/fonts/jetbrains-mono-cyrillic-500-normal.woff2') format('woff2'); font-weight: 500; font-display: swap;
  unicode-range: U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }

:root {
  --bg: #101112;
  --bg-2: #17191a;
  --line: rgba(242, 242, 236, 0.1);
  --text: #f2f2ec;
  --dim: #a3a69f;
  --faint: #6f726c;
  --lime: #c8ff3a;
  --lime-deep: #9fd81c;
  --tile: #e6e6e2;
  --radius: 22px;
  --display: 'Unbounded', 'Manrope', system-ui, sans-serif;
  --body: 'Manrope', system-ui, -apple-system, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  --pad: clamp(18px, 4vw, 64px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* one fixed environment layer: a faint lime glow and grain, behind everything */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(60vw 50vh at 78% 12%, rgba(200, 255, 58, 0.07), transparent 70%),
    radial-gradient(50vw 60vh at 0% 100%, rgba(200, 255, 58, 0.04), transparent 70%),
    var(--bg);
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--lime); outline-offset: 3px; border-radius: 8px; }
.wrap { width: 100%; max-width: 1320px; margin: 0 auto; padding: 0 var(--pad); }

/* ---------- top line and header ---------- */
.topline {
  display: flex;
  justify-content: center;
  gap: 28px;
  flex-wrap: wrap;
  padding: 9px var(--pad);
  background: var(--lime);
  color: #111;
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.02em;
}
.header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(16, 17, 18, 0.92);
  border-bottom: 1px solid var(--line);
}
.header .wrap { display: flex; align-items: center; gap: 28px; height: 68px; }
.logo { font-family: var(--display); font-weight: 800; font-size: 22px; letter-spacing: 0.04em; text-decoration: none; }
.logo span { color: var(--lime); }
.nav { display: flex; gap: 24px; margin-right: auto; }
.nav a { text-decoration: none; color: var(--dim); font-weight: 600; font-size: 14.5px; transition: color .2s; }
.nav a:hover { color: var(--text); }
.langs { display: flex; gap: 2px; }
.langs button {
  background: none; border: 0; padding: 8px 7px; font-family: var(--mono); font-size: 12.5px; color: var(--faint);
}
.langs button[aria-pressed='true'] { color: var(--text); }
.cart-btn {
  display: inline-flex; align-items: center; gap: 9px;
  background: var(--text); color: #111; border: 0; border-radius: 999px;
  padding: 10px 16px; font-weight: 700; font-size: 14px;
}
.cart-btn b {
  display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px;
  border-radius: 999px; background: var(--lime); font-size: 12px;
}

/* ---------- hero with the 3D sneaker ---------- */
.hero { position: relative; overflow: hidden; }
.hero .wrap {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  align-items: center;
  gap: 24px;
  min-height: calc(100svh - 104px);
  padding-top: 24px;
  padding-bottom: 48px;
}
.hero-bigword {
  position: absolute;
  right: -2vw;
  bottom: -3vw;
  font-family: var(--display);
  font-weight: 900;
  font-size: 22vw;
  line-height: 0.8;
  color: transparent;
  -webkit-text-stroke: 1px rgba(242, 242, 236, 0.07);
  pointer-events: none;
  user-select: none;
}
.hero h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(44px, 6.2vw, 104px);
  line-height: 0.95;
  letter-spacing: -0.02em;
  margin: 0 0 22px;
}
.hero h1 em { font-style: normal; color: var(--lime); }
.hero .lead { color: var(--dim); font-size: clamp(16px, 1.3vw, 19px); max-width: 34ch; margin: 0 0 32px; }
.btns { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  border-radius: 999px; padding: 16px 26px; font-weight: 700; font-size: 15.5px; text-decoration: none; border: 0;
  transition: transform .2s ease, background .2s ease;
}
.btn:active { transform: scale(0.97); }
.btn-lime { background: var(--lime); color: #111; }
.btn-lime:hover { background: #d6ff66; }
.btn-ghost { background: transparent; color: var(--text); border: 1.5px solid rgba(242, 242, 236, 0.25); }
.btn-ghost:hover { border-color: var(--text); }
.facts { display: flex; gap: 28px; margin-top: 44px; font-family: var(--mono); font-size: 12.5px; color: var(--faint); flex-wrap: wrap; }
.facts b { display: block; font-family: var(--display); font-size: 22px; color: var(--text); font-weight: 700; margin-bottom: 4px; }

.stage { position: relative; height: min(72svh, 680px); }
.stage canvas { position: absolute; inset: 0; pointer-events: none; }
/* a running line that draws itself between the hero and the story */
.track { display: block; width: 100%; height: 90px; }
.track path { fill: none; stroke: var(--lime); stroke-width: 1.5; stroke-linecap: round; opacity: 0.6; }
.stage::before {
  content: '';
  position: absolute;
  left: 12%; right: 12%; bottom: 10%;
  height: 18%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(200, 255, 58, 0.22), transparent);
  filter: blur(8px);
}
model-viewer {
  width: 100%;
  height: 100%;
  --poster-color: transparent;
  --progress-bar-color: var(--lime);
  --progress-bar-height: 3px;
  background: transparent;
}
.drag-hint {
  position: absolute; left: 50%; bottom: 4%; transform: translateX(-50%);
  font-family: var(--mono); font-size: 12px; color: var(--dim);
  padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; background: rgba(16,17,18,.7);
  transition: opacity .4s; pointer-events: none; white-space: nowrap;
}
.stage.touched .drag-hint { opacity: 0; }

/* ---------- 3D story: the shoe turns as you scroll ---------- */
.story { position: relative; height: 320vh; border-top: 1px solid var(--line); }
.story-sticky { position: sticky; top: 68px; height: calc(100svh - 68px); display: grid; grid-template-columns: 1fr 1fr; align-items: center; }
.story-model { height: 100%; }
.story-steps { position: relative; height: 60%; padding-right: var(--pad); }
.step {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center;
  opacity: 0; transform: translateY(24px); transition: opacity .5s ease, transform .5s ease;
}
.step.on { opacity: 1; transform: none; }
.step .num { font-family: var(--mono); color: var(--lime); font-size: 13px; margin-bottom: 14px; }
.step h3 { font-family: var(--display); font-weight: 700; font-size: clamp(28px, 3.2vw, 52px); line-height: 1.02; margin: 0 0 16px; letter-spacing: -0.01em; }
.step p { color: var(--dim); max-width: 38ch; font-size: 17px; margin: 0; }
.progress { display: flex; gap: 8px; margin-top: 30px; }
.progress i { width: 36px; height: 3px; border-radius: 3px; background: var(--line); transition: background .3s; }
.progress i.on { background: var(--lime); }

/* ---------- catalog ---------- */
.section { padding: clamp(80px, 10vw, 140px) 0; }
.sec-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; margin-bottom: 36px; }
.sec-head h2 { font-family: var(--display); font-weight: 700; font-size: clamp(30px, 3.6vw, 56px); line-height: 1; margin: 0; letter-spacing: -0.01em; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  border: 1.5px solid var(--line); background: transparent; border-radius: 999px; padding: 9px 16px;
  font-weight: 600; font-size: 14px; color: var(--dim); transition: all .2s;
}
.chip[aria-pressed='true'] { background: var(--text); color: #111; border-color: var(--text); }
.sort { background: var(--bg-2); border: 1.5px solid var(--line); color: var(--text); border-radius: 999px; padding: 9px 14px; font: inherit; font-size: 14px; }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card {
  position: relative; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; text-align: left; padding: 0; transition: transform .35s cubic-bezier(.2,.8,.2,1), border-color .3s;
}
.card:hover { transform: translateY(-4px); border-color: rgba(200, 255, 58, 0.4); }
.card .pic { background: var(--tile); aspect-ratio: 1 / 0.86; overflow: hidden; }
/* the photo's own light grey background is the tile, so there is no visible edge */
.card .pic img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s cubic-bezier(.2,.8,.2,1); }
.card:hover .pic img { transform: rotate(-6deg) scale(1.05); }
.card .info { padding: 18px 20px 20px; display: grid; gap: 4px; }
.card .row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.card h3 { margin: 0; font-family: var(--display); font-weight: 700; font-size: 19px; }
.card .price { font-weight: 800; white-space: nowrap; }
.card .kind { color: var(--faint); font-size: 13.5px; }
.badge {
  position: absolute; top: 14px; left: 14px; background: #111; color: var(--lime); font-family: var(--mono);
  font-size: 11.5px; padding: 6px 10px; border-radius: 999px;
}

/* ---------- product dialog and cart drawer ---------- */
.overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.6); z-index: 60; opacity: 0; pointer-events: none; transition: opacity .3s; }
.overlay.on { opacity: 1; pointer-events: auto; }
.dialog {
  position: fixed; z-index: 70; left: 50%; top: 50%; width: min(980px, calc(100vw - 32px)); max-height: calc(100svh - 32px); overflow: auto;
  transform: translate(-50%, -46%) scale(.98); opacity: 0; pointer-events: none;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 26px;
  display: grid; grid-template-columns: 1.1fr 1fr; transition: opacity .3s, transform .35s cubic-bezier(.2,.8,.2,1);
}
.dialog.on { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%); }
.dialog .pic { background: var(--tile); min-height: 360px; overflow: hidden; }
.dialog .pic img { width: 100%; height: 100%; object-fit: cover; }
.dialog .body { padding: 34px; display: flex; flex-direction: column; gap: 14px; }
.dialog h3 { font-family: var(--display); font-size: 30px; margin: 0; line-height: 1.05; }
.dialog .desc { color: var(--dim); margin: 0; }
.sizes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.size { border: 1.5px solid var(--line); background: none; border-radius: 12px; padding: 11px 0; font-weight: 700; }
.size[aria-pressed='true'] { background: var(--lime); color: #111; border-color: var(--lime); }
.size:disabled { opacity: .3; text-decoration: line-through; cursor: not-allowed; }
.close { position: absolute; top: 14px; right: 14px; width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(16,17,18,.8); font-size: 20px; }
.note { font-size: 13px; color: var(--faint); }

.drawer {
  position: fixed; z-index: 70; top: 0; right: 0; height: 100%; width: min(440px, 100vw);
  background: var(--bg-2); border-left: 1px solid var(--line); transform: translateX(100%); transition: transform .4s cubic-bezier(.2,.8,.2,1);
  display: flex; flex-direction: column;
}
.drawer.on { transform: none; }
.drawer header { display: flex; justify-content: space-between; align-items: center; padding: 22px 24px; border-bottom: 1px solid var(--line); }
.drawer h3 { margin: 0; font-family: var(--display); font-size: 20px; }
.drawer .items { flex: 1; overflow: auto; padding: 8px 24px; }
.line { display: grid; grid-template-columns: 76px 1fr auto; gap: 14px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.line img { background: var(--tile); border-radius: 12px; object-fit: cover; }
.line .t { font-weight: 700; }
.line .s { color: var(--faint); font-size: 13.5px; }
.qty { display: flex; align-items: center; gap: 8px; }
.qty button { width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line); background: none; }
.drawer footer { padding: 20px 24px 26px; border-top: 1px solid var(--line); display: grid; gap: 14px; }
.total { display: flex; justify-content: space-between; font-weight: 800; font-size: 18px; }
.empty { color: var(--faint); padding: 40px 0; text-align: center; }
.field { width: 100%; background: var(--bg); border: 1.5px solid var(--line); border-radius: 14px; padding: 13px 15px; color: var(--text); font: inherit; }
.field:focus { outline: none; border-color: var(--lime); }
.done { text-align: center; padding: 30px 10px; }
.done b { display: block; font-family: var(--display); font-size: 22px; margin-bottom: 8px; }

/* ---------- perks and footer ---------- */
.perks { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.perk { border-top: 1px solid var(--line); padding-top: 22px; }
.perk b { display: block; font-family: var(--display); font-weight: 700; font-size: 19px; margin-bottom: 8px; }
.perk p { color: var(--dim); margin: 0; font-size: 15px; }
.footer { border-top: 1px solid var(--line); padding: 48px 0 40px; }
.footer .wrap { display: grid; gap: 22px; }
.footer .demo { color: var(--dim); font-size: 14px; max-width: 70ch; }
.footer .made {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 26px;
}
.footer .made p { margin: 0; font-weight: 600; }

/* ---------- entrances ---------- */
.rise { opacity: 0; transform: translateY(22px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.8,.2,1); }
.rise.in { opacity: 1; transform: none; }

@media (max-width: 960px) {
  .nav { display: none; }
  .header .wrap { justify-content: space-between; }
  .hero .wrap { grid-template-columns: 1fr; min-height: 0; padding-top: 18px; }
  .stage { height: 52svh; order: -1; }
  .story { height: auto; }
  .story-sticky { position: relative; top: 0; height: auto; grid-template-columns: 1fr; }
  .story-model { height: 46svh; }
  .story-steps { height: auto; padding: 0 var(--pad) 40px; display: grid; gap: 34px; }
  .step { position: relative; opacity: 1; transform: none; }
  .progress { display: none; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .perks { grid-template-columns: 1fr 1fr; }
  .dialog { grid-template-columns: 1fr; }
  .dialog .pic { min-height: 240px; }
}
@media (max-width: 560px) {
  .perks { grid-template-columns: 1fr; }
  .cart-btn span { display: none; }
  .topline { gap: 14px; font-size: 11.5px; }
  .topline span:nth-child(3) { display: none; }
  /* two columns like a real shop: the name and price stack in a narrow card */
  .grid { gap: 10px; }
  .card .info { padding: 12px 12px 14px; }
  .card .row { flex-direction: column; align-items: flex-start; gap: 2px; }
  .card h3 { font-size: 15px; }
  .card .price { font-size: 14px; }
  .card .kind { font-size: 12.5px; }
  .badge { top: 10px; left: 10px; font-size: 10.5px; padding: 5px 8px; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .rise { opacity: 1; transform: none; }
}
