/* --- 1. Base Container --- */
.phone-container {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 750px; 
  perspective: 1200px; 
}

/* --- 2. Phone Chassis (Matte Stealth Finish) --- */
.phone-chassis {
  position: relative;
  background-color: #000;
  border-radius: 3.2rem;
  transform-style: preserve-3d;
  
  /* Very tight shadow for minimal lift */
  box-shadow: 
    0 0 0 1px #1a202c,
    0 0 0 6px #0a0a0a,
    0 2px 8px rgba(0, 0, 0, 0.4),      /* Immediate contact */
    0 10px 25px -5px rgba(0, 0, 0, 0.5); /* Short, soft floor shadow */
    
  /* A slightly slower transition makes the small movement feel more deliberate */
  transition: transform 0.4s cubic-bezier(0.1, 1, 0.2, 1); 
}

.phone-bezel {
  position: absolute;
  inset: -2px;
  border-radius: 3.1rem;
  border: 4px solid #000;
  pointer-events: none;
  z-index: 30;
  transform: translateZ(5px);
}

/* --- 3. The Screen & Content --- */
.phone-screen.reel-mode {
  position: relative;
  width: 100%;
  height: 100%;
  background-color: #000;
  border-radius: 2.8rem;
  overflow: hidden;
  color: #ffffff;
  transform: translateZ(2px);
  transform-style: preserve-3d;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* --- 4. 3D Floating Effects (Parallax) --- */
.floating-ui {
  transform: translateZ(25px); 
  filter: drop-shadow(0 8px 15px rgba(0,0,0,0.4));
}

.floating-ui-heavy {
  transform: translateZ(40px); 
  filter: drop-shadow(0 12px 20px rgba(0,0,0,0.5));
}

.island-3d {
  position: absolute;
  left: 50%;
  transform: translateX(-50%) translateZ(32px); 
  top: 8px;
  width: 100px;
  height: 28px;
  background-color: #000;
  border-radius: 20px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.6);
}

/* --- 5. Background Layering --- */
.reel-container {
  position: absolute;
  inset: 0;
  z-index: 1;
  transform: translateZ(0);
}

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

.reel-overlay-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom, 
    rgba(0,0,0,0.4) 0%, 
    transparent 20%, 
    transparent 60%, 
    rgba(0,0,0,0.8) 100%
  );
  z-index: 2;
  pointer-events: none;
}

/* --- 6. Status Bar & Icons --- */
.status-bar {
  top: 0;
  left: 0;
  right: 0;
  height: 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 24px;
  font-size: 0.75rem;
  font-weight: 700;
  position: absolute;
  z-index: 10;
}

.status-icons {
  display: flex;
  align-items: center;
  gap: 7px;
  padding-right: 4px;
}

.status-icons svg {
  display: block;
  flex-shrink: 0;
}

/* --- 7. Action Items (Sidebar) --- */
.reel-actions-stack {
  position: absolute;
  right: 12px;
  bottom: 80px; 
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
  z-index: 10;
}

.action-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.action-item span {
  font-size: 0.7rem;
  font-weight: 600;
  text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.icon-shadow {
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

.audio-disc-container {
  width: 32px;
  height: 32px;
  border: 2px solid #fff;
  border-radius: 50%;
  overflow: hidden;
}

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

/* --- 8. Footer & User Info --- */
.reel-footer {
  position: absolute;
  bottom: 60px; 
  left: 16px;
  right: 80px;
  text-align: left;
  z-index: 10;
}

.user-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.reel-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.5);
}

.reel-username {
  font-size: 0.75rem;
  font-weight: 700;
}

.follow-btn {
  background: transparent;
  border: 1px solid #fff;
  color: #fff;
  border-radius: 6px;
  padding: 3px 12px;
  font-size: 0.75rem;
  font-weight: 700;
}

.reel-caption {
  font-size: 0.85rem;
  line-height: 1.4;
  margin-bottom: 10px;
  color: #f7fafc;
}

.audio-track {
  font-size: 0.75rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 0.9;
}

/* --- 9. Bottom Navigation --- */
.bottom-nav.reel-nav {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 34px; 
  background-color: #000;
  z-index: 10;
}

.home-indicator.light {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%) translateZ(35px);
  width: 120px;
  height: 4px;
  background-color: #fff;
  border-radius: 10px;
  opacity: 0.8;
  z-index: 11;
}
