/* ============================================================================
   studio.syllovo.com (v2) — Dedicated Native iOS / YouTube Studio Mobile UX
   Active on <= 768px (INV-UX-07, INV-UX-11, INV-UX-13: >= 44x44px touch targets)
   ============================================================================ */

.v2-mob-shell {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  width: 100%;
  max-width: 100vw;
  overflow: hidden;
  background: var(--v2-bg-canvas);
}

/* Single 48px Contextual Mobile Navigation Header (INV-UX-09: <= 56px) */
.v2-mob-header {
  height: 48px;
  max-height: 48px;
  padding: 0 10px;
  background: var(--v2-bg-card);
  border-bottom: 1px solid var(--v2-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  flex-shrink: 0;
}

.v2-mob-body {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Enforce >= 44x44px ergonomic touch targets across Mobile/Tablet (<= 768px) */
@media (max-width: 768px) {
  .v2-mob-shell button,
  .v2-mob-shell .v2-touch-btn,
  .v2-mob-shell [role="button"],
  .v2-mob-shell input[type="text"],
  .v2-mob-shell input[type="email"],
  .v2-mob-shell input[type="password"],
  .v2-auth-wrap button,
  .v2-auth-wrap input,
  .v2-mob-shell a.v2-btn,
  .v2-modal-backdrop button,
  .v2-modal-backdrop a.v2-btn,
  .v2-modal-backdrop input,
  .v2-bottom-sheet-backdrop button,
  .v2-bottom-sheet-backdrop input {
    min-height: 44px;
    min-width: 44px;
  }

  .v2-auth-main,
  .v2-auth-aside {
    padding: 16px;
  }

  .v2-grid-2,
  .v2-grid-3,
  .v2-grid-4 {
    grid-template-columns: 1fr;
  }

  .v2-tl-headers-col {
    width: 84px;
  }

  .v2-tl-headers-col .v2-tl-hdr-cell:nth-child(2),
  .v2-tl-headers-col .v2-tl-hdr-cell:nth-child(3),
  .v2-tl-headers-col .v2-tl-hdr-cell:nth-child(4),
  .v2-tl-lane-callouts,
  .v2-tl-lane-audio,
  .v2-tl-lane-video {
    height: 52px;
  }

  .v2-tl-callout-pill,
  .v2-tl-at-pill,
  .v2-tl-proportional-lane .v2-tl-chunk-pill {
    height: 44px;
    min-height: 44px;
    min-width: 46px;
    top: 4px;
  }
}

/* Mobile Edge-to-Edge 16:9 Stage */
.v2-mob-stage {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #ffffff;
  color: #09090b;
  border-bottom: 1px solid var(--v2-border);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex-shrink: 0;
  overflow: hidden;
}

.v2-mob-scrubber-wrap {
  padding: 8px 12px;
  background: var(--v2-bg-card);
  border-bottom: 1px solid var(--v2-border);
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
}

.v2-mob-scrub-hit {
  min-height: 44px;
  display: flex;
  align-items: center;
  cursor: pointer;
  width: 100%;
}

.v2-mob-scrub-track {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: var(--v2-bg-subtle);
  position: relative;
}

.v2-mob-scrub-fill {
  height: 8px;
  border-radius: 999px;
  background: var(--v2-ink);
}

/* Dedicated 3-Button Thumb Lesson Switcher Bar (INV-UX-13) */
.v2-mob-thumb-nav {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 6px;
  padding: 6px 12px;
  background: var(--v2-bg-card);
  border-bottom: 1px solid var(--v2-border);
  flex-shrink: 0;
}

/* Native 4-Segment Control (AI | Beats | Quality | Script) */
.v2-mob-seg4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 3px;
  padding: 3px;
  margin: 8px 12px 4px;
  border-radius: 12px;
  background: var(--v2-bg-subtle);
  border: 1px solid var(--v2-border);
  flex-shrink: 0;
}

.v2-mob-pane {
  padding: 8px 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Apple Inset-Grouped Hairline Cards */
.v2-ios-group {
  border-radius: 14px;
  background: var(--v2-bg-card);
  border: 1px solid var(--v2-border);
  overflow: hidden;
}

.v2-ios-row {
  width: 100%;
  padding: 10px 14px;
  border: none;
  border-bottom: 1px solid var(--v2-border);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  text-align: left;
  cursor: pointer;
}

.v2-ios-row:last-child {
  border-bottom: none;
}

/* Sticky Mobile AI Composer + 5-Icon Bottom Tab Bar */
.v2-mob-composer {
  padding: 8px 10px;
  background: var(--v2-bg-card);
  border-top: 1px solid var(--v2-border);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.v2-mob-tabbar {
  padding: 4px 6px 8px;
  background: var(--v2-bg-card);
  border-top: 1px solid var(--v2-border);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 2px;
  flex-shrink: 0;
}

.v2-mob-tabbtn {
  border: none;
  background: transparent;
  color: var(--v2-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 4px 2px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
}

.v2-mob-tabbtn.active {
  color: var(--v2-ink);
  font-weight: 700;
  background: var(--v2-bg-subtle);
}

/* Native iOS Slide-Up Bottom Sheet */
.v2-bottom-sheet-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(9, 9, 11, 0.5);
  z-index: 65;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.v2-bottom-sheet {
  width: 100%;
  max-height: 90dvh;
  overflow-y: auto;
  background: var(--v2-bg-card);
  border-top: 1px solid var(--v2-border);
  border-radius: 22px 22px 0 0;
  padding: 12px 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.v2-sheet-handle {
  width: 38px;
  height: 4px;
  border-radius: 999px;
  background: var(--v2-border-strong);
  margin: 0 auto 2px;
}
