/* RESET */
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }

/* THEME */
:root {
  --panel-bg: #f2f2f2;
}

body {
  background: var(--panel-bg);
  color: #000;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
               Roboto, Helvetica, Arial, sans-serif;
}

/* LAYOUT */
.wrap {
  min-height: 100vh;
  display: grid;
  grid-template-rows: 1fr auto;
}

/* HERO */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--panel-bg);
  min-height: 0;
}

.hero picture {
  display: block;
  width: 100%;
  height: 100%;
}

.hero-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain; /* desktop: no-crop */
  object-position: center;
  background: var(--panel-bg);
}

/* Gradient under the title (compact) */
.hero-fade {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 8vh; /* desktop */
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    rgba(242,242,242,0) 0%,
    rgba(242,242,242,0.9) 60%,
    var(--panel-bg) 100%
  );
}

/* TITLE (always on top of hero) */
.title {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 18px;

  margin: 0;
  padding: 0 24px;

  text-align: center;
  font-size: clamp(26px, 5.5vw, 40px);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;

  z-index: 5;
  pointer-events: none;
}

/* PANEL */
.panel {
  background: var(--panel-bg);
  text-align: center;
  padding: 28px 24px calc(34px + env(safe-area-inset-bottom));
}

/* LINKS */
.links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 14px;
  margin: 0 0 16px;
}

.links a {
  color: #000;
  text-decoration: none;
  font-size: 13px;
  border-bottom: 1px solid rgba(0,0,0,0.25);
  padding-bottom: 2px;
}

.links a:hover { border-bottom-color: rgba(0,0,0,0.85); }

/* BUTTONS */
.buttons {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid #000;
  background: #000;
  color: #fff;
  text-decoration: none;
  font-size: 14px;
}

.btn.ghost {
  background: transparent;
  color: #000;
}

.btn:hover { opacity: 0.92; }

/* SPACING (x1.5) */
.section-gap { height: 84px; }

/* MEDIA WIDTHS */
.media {
  max-width: 820px;
  margin: 0 auto;
}

/* SPOTIFY */
.media.music iframe {
  display: block;
  width: 100%;
  height: 352px;
}

/* VIDEO (custom preview) */
.video-card { width: 100%; }

.video-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
  display: block;
}

.video-thumb img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  border-radius: 12px;
}

.video-thumb .play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.video-thumb .play::before {
  content: "";
  width: 0;
  height: 0;
  border-left: 34px solid rgba(255,255,255,0.75);
  border-top: 22px solid transparent;
  border-bottom: 22px solid transparent;
  transform: translateX(2px);
}

/* EMBED AFTER CLICK */
.video-embed {
  width: 100%;
  aspect-ratio: 16 / 9;
}

.video-embed iframe {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 12px;
  border: 0;
}

/* INFO under video */
.info {
  max-width: 820px;
  margin: 14px auto 0;
  text-align: left;
  font-size: 14px;
  line-height: 1.35;
}

.info p { margin: 0 0 10px; }
.info strong { font-weight: 600; }

/* MOBILE */
@media (max-width: 520px) {
  .wrap {
    display: block;
    min-height: 100vh;
  }

  /* full-bleed hero on iOS */
  .hero {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
  }

  .hero picture { width: 100vw; }

  .hero-img {
    width: 100vw;
    height: 88vh;
    object-fit: cover;
    object-position: center 20%;
  }

  /* gradient starts higher on mobile */
  .hero-fade { height: 10vh; }

  /* title position tuned for mobile */
  .title {
    bottom: 14px;
    padding: 0 18px;
  }

  /* panel normal (no поднятия вверх) */
  .panel {
    padding: 28px 18px calc(30px + env(safe-area-inset-bottom));
  }

  .btn { width: 100%; }

  /* spacing a bit smaller than desktop, but still big */
  .section-gap { height: 72px; }

  .info { margin-top: 12px; }
}

/* OPTIONAL: subtle page fade-in */
@media (prefers-reduced-motion: no-preference) {
  body {
    opacity: 0;
    animation: pageFadeIn 0.6s ease-out forwards;
  }

  @keyframes pageFadeIn {
    to { opacity: 1; }
  }
}
