/* Apple / Steve Jobs Minimalist Theme */
:root {
  --apple-black: #000000;
  --apple-dark: #0d0d0e;
  --apple-card: #161618;
  --apple-hover: #222226;
  
  --apple-white: #f5f5f7;
  --apple-grey: #86868b;
  --apple-dim: #424245;
  
  --apple-accent: #ffffff;
  --apple-blue: #2997ff;
  
  --border-light: rgba(255, 255, 255, 0.08);
  --border-active: rgba(255, 255, 255, 0.3);
  
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  
  --font-apple: 'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Prompt', sans-serif;
  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-apple);
  background-color: var(--apple-black);
  color: var(--apple-white);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--apple-black);
}
::-webkit-scrollbar-thumb {
  background: var(--apple-dim);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--apple-grey);
}

/* Apple Navbar */
.apple-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-light);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 2px;
}

.logo-mark {
  color: var(--apple-blue);
  font-size: 0.6rem;
}

.nav-btn {
  background: rgba(255, 255, 255, 0.08);
  color: var(--apple-white);
  border: 1px solid var(--border-light);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-family: var(--font-apple);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: var(--transition);
}

.nav-btn:hover {
  background: var(--apple-white);
  color: var(--apple-black);
}

/* App Viewport */
.app-viewport {
  flex: 1;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
}

/* Theater Stage */
.theater-stage {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.screen-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-light);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9);
}

.cinema-iframe, .cinema-video {
  width: 100%;
  height: 100%;
  border: none;
  background: #000;
}

.theater-details {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 0.5rem 0.25rem;
}

.meta-sub {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.4rem;
}

.tag-ep {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--apple-blue);
  text-transform: uppercase;
}

.tag-format {
  font-size: 0.7rem;
  color: var(--apple-grey);
  border: 1px solid var(--border-light);
  padding: 1px 6px;
  border-radius: 4px;
}

.video-heading {
  font-size: 1.75rem;
  font-weight: 600;
  letter-spacing: -0.5px;
  color: var(--apple-white);
}

/* Episodes Grid Section */
.episodes-section {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.section-title-bar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 0.75rem;
}

.section-title-bar h2 {
  font-size: 1.25rem;
  font-weight: 500;
  letter-spacing: -0.3px;
}

.ep-count-text {
  font-size: 0.85rem;
  color: var(--apple-grey);
}

.episodes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

/* Episode Card */
.ep-card {
  background: var(--apple-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.ep-card:hover {
  background: var(--apple-hover);
  border-color: var(--border-active);
  transform: translateY(-2px);
}

.ep-card.active {
  border-color: var(--apple-blue);
  background: rgba(41, 151, 255, 0.08);
}

.ep-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ep-number {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--apple-grey);
}

.ep-card.active .ep-number {
  color: var(--apple-blue);
}

.play-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--apple-grey);
}

.ep-card.active .play-dot {
  background: var(--apple-blue);
  box-shadow: 0 0 8px var(--apple-blue);
}

.ep-card-title {
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--apple-white);
  line-height: 1.4;
}

.ep-card-desc {
  font-size: 0.8rem;
  color: var(--apple-grey);
}

/* Admin Modal */
.admin-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(24px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 1.5rem;
}

.admin-card {
  background: #1c1c1e;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 520px;
  padding: 2rem;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.9);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.admin-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.admin-card-header h3 {
  font-size: 1.2rem;
  font-weight: 600;
}

.icon-close {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: var(--apple-grey);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  transition: var(--transition);
}

.icon-close:hover {
  background: rgba(255, 255, 255, 0.2);
  color: white;
}

.admin-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-size: 0.85rem;
  color: var(--apple-grey);
}

.form-group input {
  background: #2c2c2e;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  color: white;
  font-family: var(--font-apple);
  font-size: 0.9rem;
  transition: var(--transition);
}

.form-group input:focus {
  outline: none;
  border-color: var(--apple-blue);
  background: #3a3a3c;
}

.field-hint {
  font-size: 0.75rem;
  color: var(--apple-grey);
}

.btn-apple-primary {
  background: var(--apple-white);
  color: var(--apple-black);
  border: none;
  padding: 0.85rem;
  border-radius: 30px;
  font-family: var(--font-apple);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: var(--transition);
  margin-top: 0.5rem;
}

.btn-apple-primary:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.admin-json-export {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  border-top: 1px solid var(--border-light);
  padding-top: 1rem;
}

.json-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--apple-grey);
}

.btn-copy-code {
  background: none;
  border: none;
  color: var(--apple-blue);
  font-family: var(--font-apple);
  font-size: 0.8rem;
  cursor: pointer;
}

.admin-json-export textarea {
  background: #000;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 0.5rem;
  color: #a1a1a6;
  font-family: monospace;
  font-size: 0.75rem;
  resize: none;
}

.apple-footer {
  text-align: center;
  padding: 2.5rem;
  color: var(--apple-grey);
  font-size: 0.8rem;
  border-top: 1px solid var(--border-light);
}

.hidden {
  display: none !important;
}
