/*
 * MixR iOS-style bottom drawer — shared styles for every in-webview modal.
 *
 * Usage: add `.drawer-overlay` to the outer overlay, `.drawer-sheet` to the
 * content container. The existing per-view overlay classes + open-state
 * classes (.open / .active / .visible) keep working — this file just adds
 * the drawer look, slide-up animation, drag handle, and max-height.
 *
 * Not used by the native Edit Profile drawer (which is a real iOS sheet in
 * the React Native WebViewScreen).
 */

.drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  z-index: 1000;
  display: none;
  align-items: flex-end;
  justify-content: center;
  transition: background 0.2s ease;
}
/* Any of the common open-state class names trigger the drawer. */
.drawer-overlay.open,
.drawer-overlay.active,
.drawer-overlay.visible {
  display: flex;
  background: rgba(0, 0, 0, 0.75);
}

.drawer-sheet {
  position: relative;
  background: var(--surface-mid, #141414);
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.08));
  border-bottom: none;
  border-radius: 18px 18px 0 0;
  width: 100%;
  max-width: 32rem;
  padding: 1.75rem 1.5rem 1.5rem;
  padding-bottom: calc(1.5rem + env(safe-area-inset-bottom));
  max-height: 90vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  transform: translateY(100%);
  transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
  will-change: transform;
  touch-action: pan-y;
  box-shadow: 0 -12px 32px rgba(0, 0, 0, 0.45);
}
.drawer-overlay.open .drawer-sheet,
.drawer-overlay.active .drawer-sheet,
.drawer-overlay.visible .drawer-sheet {
  transform: translateY(0);
}

/* Drag handle indicator at the top of the sheet. */
.drawer-sheet::before {
  content: '';
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 36px;
  height: 5px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.25);
  pointer-events: none;
}

/* Pause the snap transition while the user is actively dragging. */
.drawer-sheet.dragging {
  transition: none;
}
