/* GKZiD ID Reel — premium Gen-Z / builder-adjacent energy (no frameworks) */

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

:root {
  --gk: #00ff9d;
  --gk-hot: #5cffc8;
  --gk-deep: #00c97a;
  --void: #030506;
  --ink: #0a0e12;
  --glass: rgba(12, 18, 28, 0.55);
  --glass-strong: rgba(8, 12, 20, 0.82);
  --line: rgba(0, 255, 157, 0.12);
  --line-bright: rgba(0, 255, 157, 0.35);
  --text: #f4f8fb;
  --text-dim: rgba(244, 248, 251, 0.55);
  --font-display: "Syne", system-ui, sans-serif;
  --font-ui: "Outfit", system-ui, sans-serif;
  /* Match site spine: bar height + safe area (see site-spine.css --gkz-spine-h) */
  --topbar-h: calc(52px + env(safe-area-inset-top));
  --dock-w: 76px;
  --idreel-bottombar-stack: 0px;
  /* Nudge title left so GKZiD sits over the phone (rail + stage gaps + pager sit to the right) */
  --idreel-brand-over-phone: 85px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

html {
  -webkit-tap-highlight-color: transparent;
}

html,
body.idreel {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-ui);
  background: var(--void);
  color: var(--text);
}

/* Animated mesh atmosphere */
.idreel-ambient {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.idreel-ambient__blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.5;
  animation: idreelBlob 18s ease-in-out infinite;
}

.idreel-ambient__blob--a {
  width: 55vmax;
  height: 55vmax;
  top: -20%;
  left: -15%;
  background: radial-gradient(circle, rgba(0, 255, 157, 0.35) 0%, transparent 70%);
}

.idreel-ambient__blob--b {
  width: 45vmax;
  height: 45vmax;
  bottom: -10%;
  right: -20%;
  background: radial-gradient(circle, rgba(100, 80, 255, 0.22) 0%, transparent 70%);
  animation-delay: -7s;
}

@keyframes idreelBlob {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(4%, 6%) scale(1.08);
  }
}

.idreel-ambient__grain {
  position: absolute;
  inset: 0;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

/* —— Top bar —— */
.idreel-topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px 0 10px;
  z-index: 200;
  background: linear-gradient(180deg, rgba(3, 5, 8, 0.94) 0%, rgba(3, 5, 8, 0.72) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.idreel-topbar__left,
.idreel-topbar__right {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.idreel-topbar__center {
  display: flex;
  align-items: center;
  gap: 10px;
  position: absolute;
  /* Center in the main column (past dock), then align with phone frame */
  left: calc(50vw + var(--dock-w) / 2 - var(--idreel-brand-over-phone, 0px));
  transform: translateX(-50%);
}

.idreel-brand-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  letter-spacing: 0.08em;
  background: linear-gradient(135deg, #fff 0%, var(--gk) 55%, var(--gk-deep) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 40px rgba(0, 255, 157, 0.15);
}

.idreel-brand-title--screen {
  font-size: 0.8125rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.92;
}

.idreel-icon-btn {
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--glass);
  color: var(--text);
  font-size: 17px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.12s ease;
}

.idreel-icon-btn:hover {
  border-color: var(--line-bright);
  box-shadow: 0 0 20px rgba(0, 255, 157, 0.12);
}

/* Primary Create — impossible to miss */
.idreel-create {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px 10px 14px;
  border-radius: 999px;
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #030506;
  background: linear-gradient(135deg, var(--gk) 0%, var(--gk-hot) 50%, var(--gk-deep) 100%);
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.25),
    0 0 32px rgba(0, 255, 157, 0.45),
    0 8px 28px rgba(0, 0, 0, 0.4);
  transition: transform 0.14s var(--ease-out), box-shadow 0.18s ease;
  animation: idreelCreatePulse 2.8s ease-in-out infinite;
}

@keyframes idreelCreatePulse {
  0%,
  100% {
    box-shadow:
      0 0 0 1px rgba(0, 0, 0, 0.25),
      0 0 28px rgba(0, 255, 157, 0.4),
      0 8px 28px rgba(0, 0, 0, 0.4);
  }
  50% {
    box-shadow:
      0 0 0 1px rgba(0, 255, 157, 0.2),
      0 0 48px rgba(0, 255, 157, 0.55),
      0 12px 32px rgba(0, 0, 0, 0.45);
  }
}

.idreel-create:hover {
  transform: scale(1.04) translateY(-1px);
  animation: none;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.2),
    0 0 56px rgba(0, 255, 157, 0.6),
    0 14px 36px rgba(0, 0, 0, 0.5);
}

.idreel-create__plus {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.2);
  font-size: 1.25rem;
  font-weight: 300;
  line-height: 1;
}

.idreel-signin {
  margin-left: 8px;
  padding: 8px 14px;
  border-radius: 12px;
  text-decoration: none;
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--gk);
  border: 1px solid rgba(0, 255, 157, 0.35);
  background: rgba(0, 255, 157, 0.06);
  transition: background 0.15s ease, border-color 0.15s ease;
}

.idreel-signin:hover {
  background: rgba(0, 255, 157, 0.12);
  border-color: var(--line-bright);
}

/* Mobile-only Create (desktop topbar is hidden on small screens) */
.idreel-create-mobile {
  display: none;
  position: fixed;
  top: max(12px, env(safe-area-inset-top, 0px));
  right: max(12px, env(safe-area-inset-right, 0px));
  z-index: 60;
  align-items: center;
  gap: 6px;
  padding: 10px 16px 10px 12px;
  border-radius: 999px;
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #030506;
  background: linear-gradient(135deg, var(--gk), var(--gk-hot));
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow:
    0 0 40px rgba(0, 255, 157, 0.5),
    0 8px 24px rgba(0, 0, 0, 0.5);
}

.idreel-create-mobile__plus {
  font-size: 1.2rem;
  font-weight: 400;
  line-height: 1;
  margin-right: 2px;
}

/* —— Dock (sidebar) —— */
.idreel-dock {
  position: fixed;
  top: var(--topbar-h);
  left: 0;
  width: var(--dock-w);
  bottom: 0;
  z-index: 150;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 6px;
  background: rgba(4, 6, 10, 0.65);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-right: 1px solid var(--line);
}

.idreel-dock__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 100%;
  padding: 8px 2px;
  text-decoration: none;
  color: var(--text-dim);
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 12px;
  transition: color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  text-align: center;
  line-height: 1.15;
}

.idreel-dock__item:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.idreel-dock__item--active {
  color: var(--gk);
  background: rgba(0, 255, 157, 0.08);
  box-shadow: inset 0 0 0 1px rgba(0, 255, 157, 0.2), 0 0 24px rgba(0, 255, 157, 0.08);
}

.idreel-dock__item--muted {
  opacity: 0.38;
  pointer-events: none;
  cursor: default;
}

.idreel-dock__item--cta {
  color: var(--gk);
}

.idreel-dock__item--cta:hover {
  color: #fff;
}

.idreel-dock__label {
  display: block;
  max-width: 100%;
}

.idreel-dock__label--stack {
  line-height: 1.2;
}

.idreel-dock__ico {
  font-size: 17px;
  line-height: 1;
  opacity: 0.95;
}

/* —— Main stage —— */
.idreel-main.shorts-main {
  position: relative;
  z-index: 1;
  margin-top: var(--topbar-h);
  margin-left: var(--dock-w);
  min-height: calc(100vh - var(--topbar-h));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 16px 28px;
}

/* Vertical grayscale brand — left gutter only; sits under the stage stack */
.idreel-brand-hero {
  --idreel-hero-h: min(clamp(55vh, 60vh, 65vh), calc(100dvh - var(--topbar-h) - 48px));
  position: absolute;
  left: max(10px, env(safe-area-inset-left, 0px));
  top: 50%;
  transform: translateY(-50%);
  z-index: 0;
  width: clamp(2.5rem, 7vmin, 4rem);
  height: var(--idreel-hero-h);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  pointer-events: none;
}

.idreel-brand-hero__text {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  transform: rotate(180deg);
  font-family: var(--font-display);
  /* Slot count > glyph count so letter-spacing + bullets don’t clip (e.g. final “D”) */
  font-size: clamp(
    1rem,
    calc((var(--idreel-hero-h) - 2.5rem) * 0.78 / 38),
    1.9rem
  );
  font-weight: 700;
  letter-spacing: 0.07em;
  line-height: 1;
  text-transform: uppercase;
  color: rgba(168, 176, 186, 0.44);
  text-shadow: 0 0 28px rgba(0, 0, 0, 0.55);
  white-space: nowrap;
  /* Keep paint inside hero band without hard clip: shrink-to-fit via font calc above */
  max-height: 100%;
}

.idreel-stage.shorts-center {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  max-width: 100%;
  outline: none;
}

.idreel-stage:focus-visible {
  border-radius: 20px;
  box-shadow: 0 0 0 2px rgba(0, 255, 157, 0.35);
}

/* Phone / player */
.idreel-player-wrap.shorts-player-shell {
  flex-shrink: 0;
}

.idreel-player.shorts-player {
  position: relative;
  width: min(360px, calc((100vh - var(--topbar-h) - 56px) * 9 / 16));
  aspect-ratio: 9 / 16;
  max-height: calc(100vh - var(--topbar-h) - 56px);
  background: #000;
  border-radius: 24px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(0, 255, 157, 0.15),
    0 0 60px rgba(0, 255, 157, 0.12),
    0 24px 80px rgba(0, 0, 0, 0.65);
}

.idreel-player__vignette {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background: radial-gradient(ellipse 90% 75% at 50% 45%, transparent 30%, rgba(0, 0, 0, 0.5) 100%);
}

.idreel-player__scan {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  opacity: 0.04;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.15) 2px,
    rgba(0, 0, 0, 0.15) 4px
  );
}

.idreel-player__shine {
  position: absolute;
  top: -30%;
  right: -20%;
  width: 70%;
  height: 70%;
  z-index: 6;
  pointer-events: none;
  background: radial-gradient(circle, rgba(0, 255, 157, 0.12) 0%, transparent 65%);
  animation: idreelShine 6s ease-in-out infinite;
}

@keyframes idreelShine {
  0%,
  100% {
    opacity: 0.5;
    transform: rotate(0deg);
  }
  50% {
    opacity: 0.85;
    transform: rotate(8deg) scale(1.05);
  }
}

.idreel-media.shorts-media-host {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.shorts-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Share FAB — aligned with mobile-builder (.share-fab: top/right 10px, 42px, radius 10) */
.idreel-share-fab.reel-share-fab {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 20;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  border: 1px solid rgba(0, 255, 157, 0.4);
  background: linear-gradient(160deg, rgba(12, 22, 32, 0.98), rgba(8, 14, 22, 0.96));
  color: var(--gk);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  touch-action: manipulation;
  padding: 0;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35),
    0 0 20px rgba(0, 255, 157, 0.35),
    0 6px 18px rgba(0, 0, 0, 0.45);
  transition:
    box-shadow 0.1s ease,
    transform 0.1s cubic-bezier(0.25, 0.8, 0.25, 1),
    border-color 0.15s ease;
}

.idreel-share-fab svg {
  width: 20px;
  height: 20px;
}

/* Share: no hover lift / glow change (feed spec); keep pulse animation only */
.idreel-share-fab:hover,
.idreel-share-fab:focus-visible {
  transform: none;
}

.idreel-share-fab:focus-visible {
  outline: 2px solid rgba(0, 255, 157, 0.6);
  outline-offset: 3px;
}

.idreel-share-fab:active {
  transform: scale(0.96);
}

/* Caption */
.idreel-caption.shorts-caption {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 120px;
  z-index: 12;
  margin: 0;
  text-align: left;
  font-family: var(--font-ui);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: #fff;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.9);
  pointer-events: none;
  padding-left: 12px;
  border-left: 3px solid var(--gk);
}

.idreel-caption:empty {
  display: none;
}

/* Identity stack */
.idreel-identity-wrap {
  position: absolute;
  left: 14px;
  right: 88px;
  bottom: 14px;
  z-index: 14;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  pointer-events: none;
}

.idreel-identity.shorts-identity {
  position: static;
  flex: 1;
  min-width: 0;
  padding: 5px 8px 7px;
  border-radius: 11px;
  background: linear-gradient(135deg, rgba(4, 8, 14, 0.72), rgba(4, 12, 18, 0.42));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(0, 255, 157, 0.1);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.4);
}

.idreel-identity__name.shorts-identity__name {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.18;
  background: linear-gradient(90deg, #fff 0%, rgba(255, 255, 255, 0.88) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 1px 6px rgba(0, 0, 0, 0.75));
}

.idreel-identity__meta.shorts-identity__meta {
  font-size: 0.5625rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--gk);
  margin-top: 2px;
  text-shadow: 0 0 20px rgba(0, 255, 157, 0.35);
}

.idreel-frame-stats {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  pointer-events: none;
}

.idreel-frame-stats__actions {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  pointer-events: auto;
}

.idreel-frame-stats__views {
  font-family: var(--font-ui);
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.72);
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.85);
  pointer-events: none;
}

.idreel-frame-comment {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  pointer-events: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  cursor: pointer;
  color: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.12s ease;
}

.idreel-frame-comment:hover {
  border-color: rgba(0, 255, 157, 0.45);
  box-shadow: 0 0 22px rgba(0, 255, 157, 0.25);
  transform: translateY(-1px);
}

.idreel-frame-comment:focus-visible {
  outline: 2px solid var(--gk);
  outline-offset: 2px;
}

.idreel-frame-comment:active {
  transform: scale(0.96);
}

.idreel-frame-comment__ico {
  font-size: 0.75rem;
  line-height: 1;
}

/* Delete (own posts only): same footprint as comment — visible above bottom nav */
.idreel-frame-delete {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid rgba(255, 130, 140, 0.35);
  border-radius: 8px;
  background: rgba(40, 12, 16, 0.45);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  cursor: pointer;
  color: rgba(255, 160, 168, 0.95);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.12s ease;
}

.idreel-frame-delete:hover {
  border-color: rgba(255, 130, 140, 0.65);
  box-shadow: 0 0 18px rgba(255, 90, 100, 0.28);
  transform: translateY(-1px);
}

.idreel-frame-delete:focus-visible {
  outline: 2px solid rgba(255, 130, 140, 0.85);
  outline-offset: 2px;
}

.idreel-frame-delete:active {
  transform: scale(0.96);
}

.idreel-frame-delete__ico {
  font-size: 0.7rem;
  line-height: 1;
}

.idreel-mark {
  position: absolute;
  top: 56px;
  left: 16px;
  z-index: 16;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.2em;
  color: rgba(0, 255, 157, 0.35);
  text-shadow: 0 0 24px rgba(0, 255, 157, 0.25);
  pointer-events: none;
}

.idreel-swipe-hint {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 11;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  opacity: 0.35;
  pointer-events: none;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.idreel-swipe-hint__chev {
  font-size: 11px;
  line-height: 1;
}

.idreel-swipe-hint__txt {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  transform: rotate(180deg);
}

@keyframes reelPlayerTick {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(0.988);
  }
  100% {
    transform: scale(1);
  }
}

.shorts-player--tick {
  animation: reelPlayerTick 0.42s var(--ease-out);
}

/* Rail */
.idreel-rail.shorts-rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
  padding-bottom: 32px;
}

.idreel-rail-btn.rail-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  border: none;
  background: none;
  cursor: pointer;
  padding: 2px;
  min-width: 58px;
  color: var(--text);
}

.idreel-rail-btn__ring.rail-btn__glyph {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(0, 0, 0, 0.35));
  border: 1px solid rgba(0, 255, 157, 0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 23px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
  transition: transform 0.14s var(--ease-out), box-shadow 0.18s ease, border-color 0.18s ease;
}

.idreel-rail-btn__val.rail-btn__value,
.idreel-rail-btn__lbl.rail-btn__label {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text-dim);
  max-width: 76px;
}

.idreel-rail-btn--card .idreel-rail-btn__ring {
  border-color: rgba(0, 255, 157, 0.4);
  box-shadow: 0 0 24px rgba(0, 255, 157, 0.15);
}

.idreel-rail-btn:hover .idreel-rail-btn__ring {
  transform: scale(1.08) translateY(-2px);
  border-color: var(--line-bright);
  box-shadow: 0 0 28px rgba(0, 255, 157, 0.22);
}

.idreel-rail-btn:hover .idreel-rail-btn__val,
.idreel-rail-btn:hover .idreel-rail-btn__lbl {
  color: var(--text);
}

.idreel-rail-btn:focus-visible .idreel-rail-btn__ring {
  outline: 2px solid var(--gk);
  outline-offset: 3px;
}

.idreel-rail-btn:active .idreel-rail-btn__ring {
  transform: scale(1.02) translateY(0);
}

.shorts-rail--gkz .rail-btn--liked .idreel-rail-btn__ring {
  background: rgba(0, 255, 157, 0.12);
  border-color: rgba(0, 255, 157, 0.65);
  box-shadow:
    0 0 28px rgba(0, 255, 157, 0.35),
    0 0 50px rgba(0, 255, 157, 0.12);
}

.shorts-rail--gkz .rail-btn--liked .idreel-rail-btn__val {
  color: var(--gk);
}

.shorts-rail--gkz .rail-btn--liked.idreel-rail-btn:hover .idreel-rail-btn__val {
  color: var(--gk-hot);
}

.shorts-rail--gkz .rail-btn--tap .idreel-rail-btn__ring {
  transform: scale(0.9);
}

/* Pager */
.idreel-pager.shorts-pager {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-shrink: 0;
  margin-left: 4px;
}

.idreel-page-btn.pager-btn {
  width: 50px;
  height: 50px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--glass-strong);
  color: var(--gk);
  font-size: 18px;
  cursor: pointer;
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.4);
  transition: transform 0.12s ease, box-shadow 0.15s ease;
}

.idreel-page-btn:hover {
  border-color: rgba(0, 255, 157, 0.4);
  box-shadow: 0 0 28px rgba(0, 255, 157, 0.28);
  transform: translateY(-2px);
}

.idreel-page-btn:focus-visible {
  outline: 2px solid var(--gk);
  outline-offset: 2px;
}

.idreel-page-btn:active {
  transform: translateY(0) scale(0.96);
}

/* Mobile bottom bar (dock is hidden <600px) */
.idreel-bottombar {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 180;
  align-items: stretch;
  justify-content: space-around;
  gap: 2px;
  padding: 6px 4px max(6px, env(safe-area-inset-bottom, 0px));
  background: linear-gradient(180deg, transparent 0%, rgba(3, 5, 8, 0.78) 28%, rgba(3, 5, 8, 0.96) 100%);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-top: 1px solid var(--line);
}

.idreel-bottombar__link,
.idreel-bottombar__muted {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 0;
  padding: 4px 2px;
  text-decoration: none;
  color: var(--text-dim);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 10px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-family: var(--font-ui);
  transition: color 0.15s ease, background 0.15s ease, transform 0.12s ease;
}

.idreel-bottombar__link:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.07);
  transform: translateY(-1px);
}

.idreel-bottombar__link:focus-visible {
  outline: 2px solid var(--gk);
  outline-offset: 1px;
}

.idreel-bottombar__link:active {
  transform: translateY(0) scale(0.97);
}

.idreel-bottombar__link--active {
  color: var(--gk);
  background: rgba(0, 255, 157, 0.1);
}

.idreel-bottombar__link--active:hover {
  color: var(--gk-hot);
}

.idreel-bottombar__muted {
  opacity: 0.38;
  pointer-events: none;
  cursor: default;
}

.idreel-bottombar__link--cta {
  color: var(--gk);
}

.idreel-bottombar__link--cta:hover {
  color: var(--gk-hot);
  background: rgba(0, 255, 157, 0.12);
}

.idreel-bottombar__ico {
  font-size: 16px;
  line-height: 1;
  opacity: 0.95;
}

.idreel-bottombar__txt {
  line-height: 1.1;
  text-align: center;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.idreel-bottombar__txt--stack {
  white-space: normal;
  font-size: 7px;
  line-height: 1.2;
  overflow: visible;
  text-overflow: clip;
}

/* Toast */
.idreel-toast.gkz-reel-toast {
  position: fixed;
  left: 50%;
  bottom: max(28px, env(safe-area-inset-bottom, 0px));
  transform: translate3d(-50%, 10px, 0);
  padding: 14px 24px;
  border-radius: 16px;
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: 600;
  z-index: 400;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s var(--ease-out);
  background: rgba(6, 10, 18, 0.92);
  border: 1px solid rgba(0, 255, 157, 0.35);
  color: var(--gk);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55), 0 0 40px rgba(0, 255, 157, 0.08);
}

.gkz-reel-toast--visible {
  opacity: 1;
  transform: translate3d(-50%, 0, 0);
}

/* —— Tablet —— */
@media (max-width: 900px) and (min-width: 601px) {
  :root {
    --idreel-brand-over-phone: 0px;
  }

  .idreel-stage {
    flex-wrap: wrap;
    justify-content: center;
  }

  .idreel-rail {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
    max-width: 360px;
    padding-bottom: 0;
    order: 3;
    gap: 14px;
  }

  .idreel-pager {
    flex-direction: row;
    order: 2;
    margin-left: 0;
  }

  .idreel-player {
    width: min(300px, 88vw);
  }

  .idreel-swipe-hint {
    display: none;
  }
}

/* —— Mobile full bleed —— */
@media (max-width: 600px) {
  :root {
    /* Taller than min bar so identity + actions sit fully above the dock */
    --idreel-bottombar-stack: calc(60px + env(safe-area-inset-bottom, 0px));
  }

  .idreel-topbar,
  .idreel-dock {
    display: none !important;
  }

  .idreel-bottombar {
    display: flex;
  }

  .idreel-main.shorts-main {
    margin: 0;
    padding: 0;
    min-height: 100dvh;
    height: 100dvh;
  }

  .idreel-brand-hero {
    display: none;
  }

  .idreel-stage.shorts-center {
    position: relative;
    width: 100%;
    height: 100dvh;
    gap: 0;
    flex-wrap: nowrap;
    align-items: stretch;
  }

  .idreel-stage:focus-visible {
    box-shadow: none;
  }

  .idreel-player-wrap.shorts-player-shell {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    touch-action: none;
  }

  .idreel-player.shorts-player {
    width: 100%;
    height: 100%;
    max-height: none;
    aspect-ratio: auto;
    border-radius: 0;
    box-shadow: none;
    border: none;
  }

  .idreel-share-fab.reel-share-fab {
    top: max(10px, env(safe-area-inset-top, 0px));
    right: max(10px, env(safe-area-inset-right, 0px));
  }

  .idreel-caption.shorts-caption {
    left: max(14px, env(safe-area-inset-left, 0px));
    right: calc(64px + env(safe-area-inset-right, 0px));
    bottom: calc(124px + var(--idreel-bottombar-stack));
    font-size: 0.875rem;
  }

  .idreel-identity-wrap {
    left: max(12px, env(safe-area-inset-left, 0px));
    right: calc(58px + env(safe-area-inset-right, 0px));
    bottom: calc(10px + var(--idreel-bottombar-stack));
  }

  .idreel-mark {
    top: max(14px, env(safe-area-inset-top, 0px));
    left: max(14px, env(safe-area-inset-left, 0px));
  }

  .idreel-rail.shorts-rail {
    position: absolute;
    z-index: 40;
    right: max(8px, env(safe-area-inset-right, 0px));
    bottom: calc(96px + var(--idreel-bottombar-stack));
    flex-direction: column;
    gap: 16px;
    padding: 0;
  }

  .idreel-rail-btn__ring.rail-btn__glyph {
    width: 50px;
    height: 50px;
    border-radius: 16px;
    background: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
  }

  .idreel-rail-btn__val,
  .idreel-rail-btn__lbl {
    color: rgba(255, 255, 255, 0.85);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
  }

  .idreel-pager {
    display: none;
  }

  .idreel-swipe-hint {
    right: max(6px, env(safe-area-inset-right, 0px));
    opacity: 0.28;
  }

  .idreel-create-mobile {
    display: inline-flex;
  }

  .idreel-toast.gkz-reel-toast {
    bottom: calc(14px + var(--idreel-bottombar-stack));
  }
}

@media (prefers-reduced-motion: reduce) {
  .idreel-ambient__blob,
  .idreel-player__shine,
  .idreel-share-fab,
  .idreel-create {
    animation: none;
  }

  .shorts-player--tick,
  .idreel-share-fab,
  .idreel-rail-btn__ring {
    transition: none;
  }
}
