/* Piqqers bio link – ortak stiller */

:root,
[data-theme="light"] {
  --page: #F4F3F0;
  --surface: #FFFFFF;
  --surface-2: #F1F0EC;
  --ink: #141416;
  --muted: #5C5C66;
  --body: #45454D;
  --line: rgba(20, 20, 22, 0.08);
  --chip: rgba(20, 20, 22, 0.07);
  --shadow: 0 0 0 1px rgba(20, 20, 30, 0.04), 0 18px 40px rgba(20, 20, 30, 0.08);
  --hero: var(--accent-light, #ECE7FE);
  --overlay: rgba(244, 243, 240, 0.55);
  color-scheme: light;
}

[data-theme="dark"] {
  --page: #0F0E12;
  --surface: #1B1A20;
  --surface-2: #232229;
  --ink: #F4F2EE;
  --muted: #A6A4AF;
  --body: #CFCDD6;
  --line: rgba(255, 255, 255, 0.08);
  --chip: rgba(255, 255, 255, 0.09);
  --shadow: 0 0 0 1px rgba(255, 255, 255, 0.05), 0 18px 40px rgba(0, 0, 0, 0.45);
  --hero: var(--accent-dark, #241D3D);
  --overlay: rgba(15, 14, 18, 0.55);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font-body, 'Inter'), system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
  transition: background-color 400ms ease, color 400ms ease;
}
img { max-width: 100%; }
h1, h2, h3 { font-family: var(--font-heading, 'Sora'), system-ui, sans-serif; }

.icon-btn {
  width: 44px; height: 44px; flex: none;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer; padding: 0;
  text-decoration: none;
}
.icon-btn:focus-visible, a:focus-visible, button:focus-visible { outline: 2px solid var(--accent, #7C5CFA); outline-offset: 2px; }

/* Tema düğmesi: açıkta ay, koyuda güneş */
.theme-btn .sun { display: none; }
[data-theme="dark"] .theme-btn .sun { display: block; }
[data-theme="dark"] .theme-btn .moon { display: none; }

/* ============ ANA SAYFA ============ */

.shell {
  max-width: 460px;
  margin: 0 auto;
  padding: 14px 16px 28px;
  padding-top: calc(14px + env(safe-area-inset-top));
  display: flex; flex-direction: column; gap: 14px;
}

.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 48px;
}
.brand {
  display: flex; align-items: center; justify-content: center;
  min-width: 0; color: var(--ink); text-decoration: none;
  font-family: var(--font-heading, 'Sora'), sans-serif; font-weight: 700; font-size: 17px;
}
.brand img { display: block; max-height: 36px; max-width: 180px; object-fit: contain; }

.hero {
  border-radius: 32px;
  background: var(--hero);
  padding: 34px 24px 30px;
  text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  transition: background-color 400ms ease;
}
.hero__logo { max-height: 104px; max-width: 72%; object-fit: contain; display: block; margin-bottom: 6px; }
.hero h1 { margin: 0; font-size: 30px; line-height: 1.15; font-weight: 800; letter-spacing: -0.02em; text-wrap: balance; }
.hero p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--body); max-width: 340px; text-wrap: pretty; }

/* Uygulama kart butonları */
.app-card {
  position: relative;
  display: flex;
  min-height: 156px;
  border-radius: 26px;
  overflow: hidden;
  background: var(--c-l);
  color: var(--ink);
  text-decoration: none;
  transition: transform 200ms ease, background-color 400ms ease;
}
[data-theme="dark"] .app-card { background: var(--c-d); }
.app-card:active { transform: scale(0.985); }
.app-card__text {
  position: relative; z-index: 1;
  width: 62%;
  padding: 20px 0 18px 20px;
  display: flex; flex-direction: column; gap: 8px;
}
.app-card__top { display: flex; align-items: center; gap: 10px; }
.app-card__top img { width: 40px; height: 40px; border-radius: 11px; object-fit: cover; flex: none; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); }
.app-card h2 { margin: 0; font-size: 20px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; }
.app-card p { margin: 0; font-size: 13.5px; line-height: 1.45; color: var(--body); }
.chip {
  align-self: flex-start; margin-top: auto;
  display: inline-flex; align-items: center; gap: 6px;
  height: 32px; padding: 0 12px; border-radius: 999px;
  background: var(--surface); color: var(--ink);
  font-size: 13px; font-weight: 600;
}
.app-card__shot {
  position: absolute; right: 16px; top: 18px;
  width: 112px; height: 236px;
  border-radius: 18px; overflow: hidden;
  transform: rotate(8deg);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.22);
  background: var(--surface-2);
}
.app-card__shot img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }

/* Ek butonlar */
.links { display: flex; flex-direction: column; gap: 10px; }
.link-btn {
  display: flex; align-items: center; gap: 12px;
  min-height: 58px; padding: 0 18px;
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow);
  color: var(--ink); text-decoration: none;
  font-size: 15px; font-weight: 600;
}
.link-btn .lbl { flex: 1; min-width: 0; }
.link-btn .arr { color: var(--muted); }

/* Yazı blokları */
.text-block {
  border-radius: 24px; background: var(--surface); box-shadow: var(--shadow);
  padding: 20px 20px 22px;
}
.text-block h3 { margin: 0 0 8px; font-size: 18px; font-weight: 700; }
.text-block p { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--body); }

.foot { text-align: center; font-size: 12px; color: var(--muted); padding: 10px 0 4px; }

/* Menü */
.menu { position: fixed; inset: 0; z-index: 50; }
.menu[hidden] { display: none; }
.menu__backdrop {
  position: absolute; inset: 0;
  background: var(--overlay);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  animation: fadeIn 220ms ease;
}
.menu__panel {
  position: relative;
  max-width: 428px;
  margin: calc(70px + env(safe-area-inset-top)) auto 0;
  width: calc(100% - 32px);
  border-radius: 28px;
  background: var(--surface);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.25);
  padding: 18px 18px 14px;
  animation: dropIn 260ms cubic-bezier(0.22, 0.8, 0.2, 1);
}
.menu__head { display: flex; align-items: center; justify-content: space-between; padding: 0 2px 8px; }
.menu__head span { font-size: 11px; font-weight: 700; letter-spacing: 0.16em; color: var(--muted); }
.menu__close { width: 44px; height: 44px; border: 0; background: transparent; color: var(--ink); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.menu__item {
  display: flex; align-items: center; gap: 12px;
  min-height: 52px; padding: 0 4px;
  border-top: 1px solid var(--line);
  color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 500;
}
.menu__item .lbl { flex: 1; }
.menu__item .arr { color: var(--muted); }
.menu__empty { padding: 14px 4px; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes dropIn { from { opacity: 0; transform: translateY(-12px) scale(0.98); } to { opacity: 1; transform: none; } }

/* ============ UYGULAMA KARTLARI SAYFASI ============ */

body.flow { overflow: hidden; height: 100%; background: var(--flow-bg, var(--page)); transition: background-color 600ms ease; }
html:has(body.flow) { height: 100%; }
.flow-page {
  position: relative;
  width: 100%; max-width: 440px; margin: 0 auto;
  height: 100vh; height: 100dvh;
  overflow: hidden;
}
.flow-glow {
  position: absolute; top: -120px; left: 50%;
  width: 420px; height: 280px; margin-left: -210px;
  border-radius: 50%;
  background: var(--glow, #7C5CFA);
  opacity: 0.18; filter: blur(90px);
  transition: background-color 600ms ease;
  pointer-events: none;
}
[data-theme="dark"] .flow-glow { opacity: 0.22; }
.flow-head {
  position: absolute; left: 0; right: 0; top: 0;
  height: calc(84px + env(safe-area-inset-top));
  padding: calc(18px + env(safe-area-inset-top)) 20px 0;
  display: flex; align-items: flex-start; justify-content: space-between;
  z-index: 2;
}
.flow-head .center { display: flex; flex-direction: column; align-items: center; }
.flow-head .brand { height: 26px; font-size: 16px; }
.flow-head .brand img { max-height: 26px; }
.flow-head .icon-btn { border-radius: 50%; border: 0; box-shadow: 0 2px 10px rgba(20, 20, 30, 0.08); }
.dots { display: flex; align-items: center; height: 36px; }
.dots button { width: 26px; height: 36px; padding: 0; border: 0; background: transparent; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.dots span { display: block; height: 6px; width: 6px; border-radius: 3px; background: var(--chip); transition: width 300ms ease, background-color 300ms ease; }
[data-theme="light"] .dots span { background: rgba(20, 20, 22, 0.2); }
.dots button[aria-current="true"] span { width: 18px; background: var(--ink); }

.viewport {
  position: absolute; left: 0; right: 0; bottom: 0;
  top: calc(84px + env(safe-area-inset-top));
  overflow: hidden;
  touch-action: pan-x;
}
.track { will-change: transform; }
.track.anim { transition: transform 620ms cubic-bezier(0.22, 0.8, 0.2, 1); }

.card {
  position: relative;
  height: var(--card-h, 702px);
  margin: 0 20px 14px;
  border-radius: 32px;
  background: var(--surface);
  padding: 22px;
  display: flex; flex-direction: column; gap: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.card-head { display: flex; align-items: center; justify-content: center; gap: 12px; }
.card-head img { width: 48px; height: 48px; flex: none; border-radius: 13px; object-fit: cover; box-shadow: 0 6px 16px rgba(20, 20, 30, 0.18); }
.card-head h2 { margin: 0; font-size: 21px; font-weight: 800; letter-spacing: -0.02em; }
.card-head p { margin: 2px 0 0; font-size: 12.5px; color: var(--muted); }

.rail {
  flex: 1; min-height: 0;
  display: flex; gap: 10px;
  overflow-x: auto; overflow-y: hidden;
  scroll-snap-type: x mandatory; scroll-padding-left: 22px;
  margin: 0 -22px; padding: 0 22px;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}
.rail::-webkit-scrollbar { display: none; }
.rail figure {
  flex: none; height: 100%;
  aspect-ratio: 276 / 470;
  max-width: calc(100% - 32px);
  margin: 0;
  scroll-snap-align: start;
  border-radius: 22px; overflow: hidden;
  background: var(--surface-2);
  box-shadow: inset 0 0 0 1px var(--line);
}
.rail img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.rail-empty { flex: 1; display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: 14px; border-radius: 22px; background: var(--surface-2); }

.desc { margin: 0; padding: 0 6px; text-align: center; font-size: 13.5px; line-height: 1.5; color: var(--body); text-wrap: balance; }

.stores { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.stores.single { grid-template-columns: 1fr; }
.stores a {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  height: 50px; border-radius: 999px;
  text-decoration: none; font-size: 14px; font-weight: 700;
}
.stores .primary { background: var(--ink); color: var(--surface); }
.stores .secondary { border: 1.5px solid var(--ink); color: var(--ink); }
.stores a[aria-disabled="true"] { opacity: 0.45; pointer-events: none; }

.flow-empty { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .track.anim { transition-duration: 1ms; }
  .menu__backdrop, .menu__panel { animation: none; }
}
