/* ============================================
   Page-Specific Styles
   ============================================ */

/* ---- Landing Page ---- */

.landing-hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.hero-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 120px 24px 80px;
  position: relative;
  z-index: 2;
}

.hero-title {
  background: linear-gradient(135deg, var(--cream) 0%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 20px;
}

.hero-sub {
  font-size: clamp(1rem, 2.2vw, 1.3rem);
  color: var(--cream-dim);
  max-width: 600px;
  margin-bottom: 36px;
}

.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

.hero-float {
  position: absolute;
  font-size: 2rem;
  opacity: 0.15;
  animation: float-drift 8s ease-in-out infinite;
  z-index: 1;
}

.hero-float-1 { top: 20%; left: 10%; animation-delay: 0s; }
.hero-float-2 { top: 40%; right: 8%; animation-delay: 2s; }
.hero-float-3 { bottom: 20%; left: 30%; animation-delay: 4s; }

@keyframes float-drift {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(5deg); }
}

/* How It Works */
.landing-how {
  padding: 100px 24px;
}

.how-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.how-card {
  text-align: center;
  padding: 40px 28px;
}

.how-icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.how-card h3 {
  margin-bottom: 8px;
}

/* Use Cases */
.landing-uses {
  padding: 60px 24px 100px;
}

.uses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.use-card {
  padding: 32px 24px;
}

.use-emoji {
  font-size: 2.5rem;
  margin-bottom: 12px;
}

.use-card h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

/* Footer */
.landing-footer {
  padding: 60px 24px;
  border-top: 1px solid var(--glass-border);
}

.footer-logo {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.footer-tagline {
  color: var(--cream-dim);
  font-style: italic;
  font-family: var(--font-display);
  margin-bottom: 20px;
}

.footer-links {
  display: flex;
  gap: 24px;
  justify-content: center;
  margin-bottom: 20px;
}

.footer-links a {
  color: var(--cream-dim);
  font-size: 0.85rem;
}

.footer-copy {
  color: rgba(200, 195, 187, 0.5);
  font-size: 0.8rem;
}

/* ---- Login Page ---- */

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  z-index: 1;
}

.login-card {
  max-width: 420px;
  width: 100%;
  padding: 48px 36px;
  text-align: center;
}

.login-logo {
  display: flex;
  justify-content: center;
}

/* ---- Dashboard ---- */

.dashboard-page {
  min-height: 100vh;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.dashboard-card {
  padding: 0;
  overflow: hidden;
  position: relative;
}

.dashboard-card-thumb {
  height: 160px;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 12px;
}

.dashboard-card-body {
  padding: 16px;
}

.dashboard-card-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dashboard-card-menu {
  position: absolute;
  top: 12px;
  left: 12px;
}

.dashboard-menu-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(8px);
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.dashboard-menu-btn:hover { background: rgba(0,0,0,0.7); }

.dashboard-menu-dropdown {
  position: absolute;
  top: 40px;
  left: 0;
  background: var(--navy-light);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 6px;
  min-width: 160px;
  box-shadow: var(--shadow-lg);
  z-index: 50;
}

/* ---- Creator Flow ---- */

.creator-page {
  min-height: 100vh;
  padding-bottom: 80px;
}

/* Avatar options */
.avatar-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 8px;
}

.avatar-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 20px 12px;
  background: var(--glass);
  border: 2px solid var(--glass-border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition);
  font-size: 0.85rem;
}

.avatar-option:hover { background: var(--glass-hover); }

.avatar-option.selected {
  border-color: var(--coral);
  background: rgba(255, 77, 109, 0.1);
}

.avatar-option-icon { font-size: 2rem; }

/* Storyboard frames */
.storyboard-frames {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding: 4px 0 16px;
  -webkit-overflow-scrolling: touch;
}

.storyboard-card {
  min-width: 200px;
  max-width: 220px;
  flex-shrink: 0;
}

.storyboard-add-frame {
  min-width: 120px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 2px dashed var(--glass-border);
  background: transparent;
  cursor: pointer;
  color: var(--cream-dim);
  transition: all var(--transition);
}

.storyboard-add-frame:hover {
  border-color: var(--coral);
  color: var(--coral);
}

/* Generation progress */
.gen-frame-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}

.gen-frame-card {
  padding: 16px;
}

/* Frame editor drawer */
.frame-editor-drawer {
  background: var(--navy-light);
  width: 100%;
  max-width: 480px;
  height: 100vh;
  overflow-y: auto;
  padding: 32px 24px;
  border-left: 1px solid var(--glass-border);
  animation: slide-in-right 0.3s ease;
}

@keyframes slide-in-right {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

/* Preview layout */
.preview-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 24px;
  align-items: start;
}

.preview-panel {
  padding: 16px;
}

.preview-frame {
  max-width: 375px;
  margin: 0 auto;
  height: 667px;
  background: var(--navy);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--glass-border);
}

.share-panel .card {
  padding: 20px;
}

@media (max-width: 900px) {
  .preview-layout {
    grid-template-columns: 1fr;
  }
  .preview-frame {
    max-width: 100%;
    height: 70vh;
    max-height: 667px;
  }
  .avatar-options {
    grid-template-columns: 1fr;
  }
  .storyboard-frames {
    flex-direction: column;
  }
  .storyboard-card {
    min-width: auto;
    max-width: none;
  }
  .frame-editor-drawer {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}
