/* ============================================================
   САЙТ ПРИКОЛОВ — styles
   Тёмная и светлая тема через [data-theme]
   ============================================================ */

:root {
  --font-body: "Manrope", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-display: "Unbounded", "Manrope", "Segoe UI", system-ui, sans-serif;
  --radius: 20px;
  --shadow: 0 24px 60px rgba(0, 0, 0, .45);
}

:root,
html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0a0a0c;
  --bg-soft: #0f0f13;
  --surface: #141419;
  --surface-2: #1a1a21;
  --line: #26262e;
  --line-soft: #1d1d24;
  --text: #f3f3f0;
  --muted: #8d8d99;
  --accent: #ffd600;
  --accent-strong: #ffe033;
  --accent-ink: #0a0a0c;
  --glow: rgba(255, 214, 0, .16);
  --hero-grad: radial-gradient(900px 500px at 80% -10%, rgba(255, 214, 0, .1), transparent 60%);
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #f4f4f2;
  --bg-soft: #ffffff;
  --surface: #ffffff;
  --surface-2: #f0f0ed;
  --line: #e2e2dd;
  --line-soft: #ecece8;
  --text: #1a1a1c;
  --muted: #6b6b70;
  --accent: #ffd600;
  --accent-strong: #f2c900;
  --accent-ink: #16160f;
  --glow: rgba(255, 214, 0, .28);
  --hero-grad: radial-gradient(900px 500px at 80% -10%, rgba(255, 214, 0, .2), transparent 60%);
  --shadow: 0 20px 50px rgba(20, 20, 24, .14);
}

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

html { scroll-behavior: smooth; }

[hidden] { display: none !important; }

body {
  margin: 0;
  background: var(--hero-grad), var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color .3s ease, color .3s ease;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: 1.05;
  margin: 0;
}

p { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
img, svg { display: block; max-width: 100%; }

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

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.container {
  width: min(1200px, 100% - 40px);
  margin-inline: auto;
}

.container--narrow { width: min(820px, 100% - 40px); }

.muted { color: var(--muted); }
.small { font-size: 13px; line-height: 1.6; }

/* ---------- header ---------- */

.header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(var(--bg-rgb, 10, 10, 12), .78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-soft);
}

html[data-theme="light"] .header { background: rgba(244, 244, 242, .82); }

.header__inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.logo__mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--surface);
  border: 1px solid var(--line);
  overflow: hidden;
}

.logo__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.logo__text {
  font-family: var(--font-display);
  font-size: 10px;
  line-height: 1.15;
  letter-spacing: .18em;
  color: var(--muted);
  text-transform: uppercase;
}

.logo__text b {
  font-size: 14px;
  letter-spacing: .04em;
  color: var(--text);
}

/* ---------- theme toggle ---------- */

.theme-toggle { margin-left: 8px; }

.theme-btn {
  position: relative;
  width: 76px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  transition: border-color .25s, background .25s;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 9px;
}

.theme-btn:hover { border-color: #4a4a56; }

.theme-icon {
  width: 20px;
  height: 20px;
  color: var(--muted);
  transition: color .3s, opacity .3s;
  z-index: 2;
}

.theme-icon--moon { color: var(--accent); }
html[data-theme="light"] .theme-icon--moon { color: var(--muted); opacity: .5; }
html[data-theme="light"] .theme-icon--sun { color: #d27b00; }

.theme-btn__pill {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 2px 8px rgba(0, 0, 0, .25);
  transition: transform .3s cubic-bezier(.3, .8, .3, 1.1), background .3s;
  z-index: 1;
}

html[data-theme="light"] .theme-btn__pill {
  transform: translateX(38px);
  background: #ffd166;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: transform .18s, background .2s, border-color .2s, box-shadow .2s;
  white-space: nowrap;
}

.btn:active { transform: scale(.97); }

.btn--primary {
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 10px 30px var(--glow);
}

.btn--primary:hover {
  background: var(--accent-strong);
  box-shadow: 0 14px 36px var(--glow);
}

.btn--lg { padding: 17px 32px; font-size: 16px; }

/* ---------- hero ---------- */

.hero { padding: 72px 0 48px; }

.hero__grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 48px;
  align-items: center;
}

.hero__copy { min-width: 0; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(var(--surface-rgb, 20, 20, 25), .8);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
}

html[data-theme="light"] .pill { background: rgba(255, 255, 255, .8); }

.pill i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent);
  animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
  50% { opacity: .35; transform: scale(.8); }
}

.hero h1 {
  margin: 22px 0 20px;
  font-size: clamp(2.4rem, 5.4vw, 4.4rem);
  font-weight: 900;
  letter-spacing: -.05em;
}

.hl {
  display: block;
  color: var(--accent);
  letter-spacing: -.05em;
  font-size: 1.05em;
}

.lead {
  max-width: 44ch;
  color: #b0b0b8;
  font-size: 17px;
}

html[data-theme="light"] .lead { color: #5b5b60; }

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 30px 0 0;
}

/* hero art — стикер */

.hero__art {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 380px;
  isolation: isolate;
}

.hero__glow {
  position: absolute;
  inset: 4%;
  background: radial-gradient(circle at 50% 55%, var(--glow), transparent 70%);
  filter: blur(30px);
  z-index: -1;
  animation: glow 6s ease-in-out infinite;
}

@keyframes glow {
  50% { opacity: .55; transform: scale(1.06); }
}

.hero__card {
  width: 220px;
  padding: 14px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero__card--sticker {
  transform: rotate(-4deg);
  animation: float 7s ease-in-out infinite;
  z-index: 2;
  background: var(--bg-soft);
  display: grid;
  place-items: center;
}

.hero__sticker {
  width: 100%;
  height: 190px;
  object-fit: contain;
  border-radius: 12px;
  background: transparent;
}

@keyframes float {
  50% { transform: translateY(-14px) rotate(-2deg); }
}

/* ---------- sections ---------- */

.section { padding: 88px 0; }

section[id] { scroll-margin-top: 88px; }

.section__head {
  margin-bottom: 42px;
}

.section__intro { max-width: 640px; }

.eyebrow {
  display: inline-block;
  margin-bottom: 14px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--accent);
}

.section h2 { font-size: clamp(1.8rem, 3.4vw, 2.8rem); }
.section__intro h2 + p { margin-top: 14px; }

/* ---------- карточки ---------- */

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .3s cubic-bezier(.2, .7, .3, 1), border-color .3s, box-shadow .3s;
  animation: fadeUp .45s ease backwards;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
}

.card:hover {
  transform: translateY(-5px);
  border-color: #3b3b47;
  box-shadow: var(--shadow);
}

html[data-theme="light"] .card:hover { border-color: #cfcfc9; }

.card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 50% 120%, var(--glow), transparent 55%),
    linear-gradient(160deg, var(--surface-2), var(--bg-soft));
  border-bottom: 1px solid var(--line-soft);
}

.card--live {
  cursor: pointer;
  color: inherit;
  text-decoration: none;
}
.card--live:hover .card__media .card__emoji { transform: scale(1.1) rotate(-4deg); }

.card__emoji {
  font-size: 72px;
  filter: drop-shadow(0 16px 24px rgba(0, 0, 0, .4));
  transition: transform .45s cubic-bezier(.2, .7, .3, 1);
}

.card__sticker {
  width: 58%;
  height: 70%;
  object-fit: contain;
  filter: drop-shadow(0 16px 24px rgba(0, 0, 0, .4));
}

.card__title {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -.02em;
  margin-top: 10px;
  text-align: center;
}

.badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  background: rgba(255, 214, 0, .14);
  border: 1px solid rgba(255, 214, 0, .35);
  color: var(--accent);
  backdrop-filter: blur(6px);
}

.badge--soon {
  background: rgba(255, 138, 106, .13);
  border-color: rgba(255, 138, 106, .4);
  color: #ff8a6a;
}

.card--soon { opacity: .8; }
.card--soon .card__media { cursor: default; }

.grid__empty {
  padding: 60px 0;
  text-align: center;
  color: var(--muted);
}

/* ---------- доска позора ---------- */

.section--shame { position: relative; }

.shame {
  position: relative;
  height: 180vh;
}

.shame__sticky {
  position: sticky;
  top: 0;
  display: grid;
  place-items: center;
  height: 100vh;
  height: 100svh;
  padding: 0 20px;
}

.shame__board {
  position: relative;
  width: min(100%, 980px, 120vh);
  transform: rotate(6deg);
  transform-origin: 50% 50%;
}

.shame__board-img {
  width: 100%;
  height: auto;
  aspect-ratio: 1536 / 1024;
  filter: drop-shadow(0 28px 52px rgba(0, 0, 0, .45));
  user-select: none;
  -webkit-user-drag: none;
}

.shame__photo {
  position: absolute;
  top: 39%;
  left: 50%;
  z-index: 2;
  width: 23%;
  margin: 0;
  padding: 7px 7px 0;
  border-radius: 3px;
  background: #fdfdf8;
  box-shadow: 0 16px 30px rgba(0, 0, 0, .28);
  transform: translate(-50%, 0) rotate(-12deg);
  transform-origin: 50% 8%;
  will-change: transform;
}

.shame__photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 750 / 850;
  border-radius: 2px;
  filter: saturate(1.04) contrast(1.02);
}

.shame__photo figcaption {
  padding: 6px 2px 7px;
  font-size: clamp(7px, 1.1vw, 12px);
  font-weight: 700;
  letter-spacing: .04em;
  text-align: center;
  color: #55555f;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.shame__pin {
  position: absolute;
  top: -9px;
  left: 50%;
  z-index: 3;
  width: 20px;
  height: 20px;
  margin-left: -10px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #ff9a9a, #d61f1f 58%, #8a0d0d);
  box-shadow:
    0 3px 6px rgba(0, 0, 0, .45),
    inset 0 -2px 3px rgba(0, 0, 0, .35),
    inset 0 2px 3px rgba(255, 255, 255, .45);
  opacity: 0;
  transform: scale(.35) rotate(-20deg);
  transition: opacity .45s ease, transform .55s cubic-bezier(.2, .8, .3, 1.4);
}

.shame__photo.is-stuck .shame__pin {
  opacity: 1;
  transform: scale(1) rotate(0deg);
}

/* ---------- cta ---------- */

.cta { padding: 0 0 96px; }

.cta__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 44px;
  border-radius: 26px;
  border: 1px solid rgba(255, 214, 0, .25);
  background:
    radial-gradient(circle at 90% 10%, var(--glow), transparent 55%),
    linear-gradient(120deg, var(--surface), var(--bg-soft));
}

.cta__copy { min-width: 0; }

.cta__img {
  width: 130px;
  height: 130px;
  object-fit: contain;
  flex-shrink: 0;
}

.cta h2 { font-size: clamp(1.7rem, 3.4vw, 2.7rem); }
.cta p { margin-top: 12px; max-width: 52ch; }

.cta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  flex-shrink: 0;
}

/* Большой кликабельный блок-кнопка «Служба по контракту» */
.cta-contract {
  position: relative;
  display: flex;
  align-items: center;
  gap: 28px;
  margin-top: 20px;
  padding: 28px 36px;
  border-radius: 26px;
  overflow: hidden;
  isolation: isolate;
  color: #1b1b24;
  border: 1px solid rgba(91, 206, 250, .5);
  background:
    radial-gradient(circle at 88% 10%, rgba(245, 169, 184, .5), transparent 55%),
    linear-gradient(120deg, #e9f8ff, #ffffff 48%, #ffeef2);
  box-shadow: 0 16px 40px rgba(91, 150, 200, .16);
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.cta-contract::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, .9) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform .75s ease;
}

.cta-contract:hover {
  transform: translateY(-3px);
  border-color: rgba(245, 169, 184, .9);
  box-shadow: 0 22px 52px rgba(245, 169, 184, .35);
}

.cta-contract:hover::before { transform: translateX(120%); }

.cta-contract:active { transform: translateY(-1px) scale(.995); }

.cta-contract__copy {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.cta-contract__copy b {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.8vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: 1.05;
}

.cta-contract__copy span {
  color: #55556a;
  font-size: 15px;
  max-width: 62ch;
}

.cta-contract__img {
  width: 96px;
  height: 96px;
  margin-left: auto;
  border-radius: 20px;
  object-fit: cover;
  border: 3px solid #fff;
  box-shadow: 0 10px 24px rgba(91, 150, 200, .25);
  flex-shrink: 0;
}

.cta-contract__go {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(120deg, #5bcefa, #f5a9b8);
  color: #14141c;
  font-size: 26px;
  font-weight: 800;
  flex-shrink: 0;
  animation: contract-arrow 2.4s ease-in-out infinite;
}

@keyframes contract-arrow {
  50% { transform: translateX(5px); }
}

.cta-contract:hover .cta-contract__go { animation-duration: .9s; }

/* ---------- footer ---------- */

.footer {
  border-top: 1px solid var(--line-soft);
  background: var(--bg);
  padding: 56px 0 26px;
}

.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 40px;
}

.logo--footer { margin-bottom: 16px; }

.footer__nav {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 14px;
}

.footer__nav b {
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}

.footer__nav a { color: var(--muted); transition: color .2s; }
.footer__nav a:hover { color: var(--accent); }

.footer__bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 46px;
  padding-top: 22px;
  border-top: 1px solid var(--line-soft);
  font-size: 12px;
  color: var(--muted);
}

/* ---------- responsive ---------- */

@media (max-width: 1024px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .hero__grid { gap: 24px; }
  .hero h1 { font-size: clamp(2rem, 4.6vw, 3.6rem); }

  /* планшет: hero в одну колонку, стикер по центру */
  .hero__grid { grid-template-columns: 1fr; }
  .hero__art { order: -1; min-height: auto; display: grid; place-items: center; padding: 24px 0 8px; }
  .hero__card { position: static; transform: none; }
  .hero__glow { inset: 10%; }

  /* планшет: CTA в колонку, картинка сверху по центру */
  .cta__inner { flex-direction: column; align-items: center; text-align: center; padding: 34px; }
  .cta__copy { max-width: 52ch; }
  .cta__copy h2 { margin-bottom: 10px; }
  .cta__img { order: -1; margin-bottom: 6px; }
  .cta__actions { justify-content: center; }
}

@media (max-width: 860px) {
  .hero { padding: 44px 0 24px; }
  .hero__art { min-height: auto; padding: 18px 0 6px; }
  .section { padding: 64px 0; }

  .cta-contract { gap: 18px; padding: 24px 26px; }
  .cta-contract__img { width: 76px; height: 76px; border-radius: 16px; }
  .cta-contract__go { width: 54px; height: 54px; font-size: 22px; }

  .shame__sticky { padding: 0 16px; }
  .shame__photo { width: 26%; }
}

@media (max-width: 600px) {
  .container { width: calc(100% - 32px); }
  .grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: clamp(1.9rem, 9vw, 2.8rem); }
  .hero__art { min-height: 220px; }
  .hero__card { width: 180px; }
  .footer__inner { grid-template-columns: 1fr; }
  .footer__bottom { flex-direction: column; }

  .cta-contract { flex-wrap: wrap; gap: 16px; padding: 22px; }
  .cta-contract__copy { flex: 1 1 100%; }
  .cta-contract__copy b { font-size: 1.35rem; }
  .cta-contract__copy span { font-size: 14px; }
  .cta-contract__img { width: 64px; height: 64px; margin-left: 0; }
  .cta-contract__go { width: 52px; height: 52px; margin-left: auto; font-size: 21px; }

  .shame__board { transform: rotate(5deg); }
  .shame__photo { top: 41%; width: 32%; }
  .shame__photo figcaption { font-size: 8px; }
}

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

  .shame { height: auto; }
  .shame__sticky { position: static; height: auto; }
}
