/*
Theme Name: Movie16 Theme
Author: Antigravity
Description: Custom theme matching the React UI
Version: 1.0
*/
:root {
  --bg-color: #f8f9fa;
  --surface-color: #ffffff;
  --text-primary: #111827;
  --text-secondary: #6b7280;
  --header-bg: #1e5dd6;
  --header-bg-gradient: linear-gradient(to right, #154eb5, #1e5dd6, #2a73ef);
  --btn-blue: #2563eb;
  --btn-blue-hover: #1d4ed8;
  --font-main: 'Inter', system-ui, -apple-system, sans-serif;
  --transition: all 0.2s ease-in-out;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-color);
  color: var(--text-primary);
  font-family: var(--font-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

#root {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header & Hero Area */
.site-header {
  background: var(--header-bg-gradient);
  color: white;
  padding: 1.5rem 5% 3rem 5%;
  text-align: center;
  border-bottom-left-radius: 24px;
  border-bottom-right-radius: 24px;
}

.header-nav {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 2rem;
}

.header-nav a {
  color: white;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.header-nav a:hover {
  opacity: 0.8;
}

.hero-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 2rem;
  letter-spacing: -0.5px;
}

.search-container {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  display: flex;
  align-items: center;
}

.search-input {
  width: 100%;
  padding: 1rem 1.5rem 1rem 3rem;
  border-radius: 50px;
  border: none;
  font-size: 1rem;
  outline: none;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.search-icon {
  position: absolute;
  left: 1.25rem;
  color: #9ca3af;
  width: 20px;
  height: 20px;
}

.search-button {
  position: absolute;
  right: 0.5rem;
  background-color: var(--btn-blue);
  color: white;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.search-button:hover {
  background-color: var(--btn-blue-hover);
}

/* Main Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 5%;
  flex: 1;
  width: 100%;
}

/* Section Header (What's Hot) */
.section-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.flame-icon {
  color: #ef4444; /* Red/Orange */
  width: 24px;
  height: 24px;
}

.tabs {
  display: flex;
  gap: 0.5rem;
}

.tab {
  padding: 0.4rem 1rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid #e5e7eb;
  background: transparent;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.tab.active {
  background-color: var(--btn-blue);
  color: white;
  border-color: var(--btn-blue);
}

/* Article List / Grid */
.article-list {
  display: grid;
  grid-template-columns: repeat(var(--cols-desktop, 6), 1fr);
  gap: 1.5rem;
}

/* Article Card */
.article-card {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
  cursor: pointer;
}

.article-card:hover {
  transform: translateY(-4px);
}

.card-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 0.75rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.article-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.article-card:hover .article-card-image {
  transform: scale(1.05);
}

.badge {
  position: absolute;
  bottom: 0.5rem;
  left: 0.5rem;
  background-color: rgba(0, 0, 0, 0.7);
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

.card-title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.25rem;
  color: var(--text-primary);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Single Article View */
.article-header {
  max-width: 800px;
  margin: 0 auto 2rem auto;
}

.article-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.article-meta-large {
  font-size: 1rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.article-main-image {
  width: 100%;
  max-width: 800px;
  max-height: 600px;
  display: block;
  margin: 0 auto 3rem auto;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.article-body {
  max-width: 800px;
  margin: 0 auto;
  font-size: 1.125rem;
  line-height: 1.8;
  color: #374151; /* Gray 700 */
}

.article-body p {
  margin-bottom: 1.5rem;
}

.back-link {
  display: inline-flex;
  align-items: center;
  color: var(--btn-blue);
  text-decoration: none;
  font-weight: 600;
  margin-bottom: 2rem;
  transition: var(--transition);
}

.back-link:hover {
  text-decoration: underline;
}

.back-link svg {
  margin-right: 0.5rem;
  width: 20px;
  height: 20px;
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  margin-top: 3rem;
}

.pagination-btn {
  background-color: var(--btn-blue);
  color: white;
  border: none;
  padding: 0.5rem 1.5rem;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.pagination-btn:hover:not(:disabled) {
  background-color: var(--btn-blue-hover);
  transform: translateY(-2px);
}

.pagination-btn:disabled {
  background-color: #d1d5db; /* Gray 300 */
  cursor: not-allowed;
  opacity: 0.7;
}

.pagination-info {
  font-weight: 600;
  color: var(--text-secondary);
}

/* Breadcrumbs */
.breadcrumb-nav {
  display: flex;
  align-items: center;
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.breadcrumb-nav a {
  color: var(--btn-blue);
  text-decoration: none;
  font-weight: 500;
}

.breadcrumb-nav a:hover {
  text-decoration: underline;
}

.breadcrumb-nav .separator {
  margin: 0 0.5rem;
  color: #9ca3af;
}

.breadcrumb-nav .current {
  color: var(--text-primary);
  font-weight: 600;
}

/* FAQ Section */
.faq-section {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid #e5e7eb;
}

.faq-section h2 {
  font-size: 1.5rem;
  margin-bottom: 2rem;
  color: var(--text-primary);
}

.faq-item {
  margin-bottom: 1rem;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background-color: var(--surface-color);
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:last-child {
  margin-bottom: 0;
}

.faq-item summary {
  padding: 1.25rem 1.5rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  list-style: none;
  position: relative;
  transition: background-color 0.2s;
  user-select: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: '+';
  position: absolute;
  right: 1.5rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--text-secondary);
  transition: transform 0.3s ease;
}

.faq-item[open] summary::after {
  content: '−';
  transform: translateY(-50%) rotate(180deg);
}

.faq-item summary:hover {
  background-color: #f9fafb;
}

.faq-item p {
  padding: 0 1.5rem 1.25rem 1.5rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
  border-top: 1px solid #e5e7eb;
  margin-top: 0;
  padding-top: 1rem;
}

/* 404 Page */
.not-found-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 60vh;
  padding: 2rem;
}

.not-found-title {
  font-size: 6rem;
  font-weight: 800;
  color: var(--header-bg);
  margin: 0;
  line-height: 1;
}

.not-found-subtitle {
  font-size: 2rem;
  font-weight: 600;
  margin: 1rem 0;
  color: var(--text-primary);
}

.not-found-text {
  color: var(--text-secondary);
  max-width: 500px;
  margin-bottom: 2rem;
  font-size: 1.1rem;
}

.btn-primary {
  display: inline-block;
  background-color: var(--btn-blue);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition);
}

.btn-primary:hover {
  background-color: var(--btn-blue-hover);
  transform: translateY(-2px);
}

/* Footer */
.site-footer {
  background-color: #111827;
  color: #9ca3af;
  padding: 4rem 5% 2rem 5%;
  margin-top: auto;
  font-size: 0.9rem;
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto;
  margin-bottom: 3rem;
}

.footer-brand {
  flex: 1;
  min-width: 300px;
  max-width: 500px;
  text-align: left;
}

.footer-brand h2 {
  color: white;
  font-size: 1.8rem;
  margin-bottom: 1rem;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.footer-brand p {
  line-height: 1.6;
}

.footer-links-group {
  display: flex;
  gap: 4rem;
  flex-wrap: wrap;
  text-align: left;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links h3 {
  color: white;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.footer-links a {
  color: #9ca3af;
  text-decoration: none;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--btn-blue);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid #374151;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 1.75rem;
  }
  .article-list {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  }
}
/* ==============================================
   ADMIN DASHBOARD (CMS)
   ============================================== */
.admin-dashboard {
  display: flex;
  min-height: 100vh;
  background-color: #0f1115;
  color: #e5e7eb;
}

.admin-sidebar {
  width: 300px;
  background-color: #1a1d24;
  border-right: 1px solid #2d3748;
  display: flex;
  flex-direction: column;
}

.admin-header {
  padding: 1.5rem;
  border-bottom: 1px solid #2d3748;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-header h2 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--accent-primary);
  margin: 0;
}

.btn-view-site {
  font-size: 0.8rem;
  padding: 0.4rem 0.8rem;
  background-color: transparent;
  border: 1px solid var(--accent-primary);
  color: var(--accent-primary);
  border-radius: 4px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-view-site:hover {
  background-color: var(--accent-primary);
  color: white;
}

.admin-article-list {
  flex-grow: 1;
  overflow-y: auto;
  padding: 1rem 0;
}

.admin-article-list h3 {
  padding: 0 1.5rem 0.5rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  color: #9ca3af;
  letter-spacing: 1px;
}

.admin-article-list ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.admin-article-list li {
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  font-size: 0.95rem;
  border-left: 3px solid transparent;
  transition: all 0.2s ease;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-article-list li:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

.admin-article-list li.active {
  background-color: rgba(229, 9, 20, 0.1);
  border-left-color: var(--accent-primary);
  color: white;
  font-weight: 500;
}

.admin-main {
  flex-grow: 1;
  padding: 2rem 3rem;
  overflow-y: auto;
  height: 100vh;
}

.admin-editor {
  max-width: 900px;
  margin: 0 auto;
  background-color: #1a1d24;
  border-radius: 8px;
  padding: 2rem;
  border: 1px solid #2d3748;
  box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.admin-editor-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #2d3748;
}

.admin-editor-header h2 {
  margin: 0;
  font-size: 1.5rem;
}

.btn-save {
  background-color: var(--accent-primary);
  color: white;
  border: none;
  padding: 0.6rem 1.5rem;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.btn-save:hover {
  background-color: #f40612;
}

.btn-save:disabled {
  background-color: #4b5563;
  cursor: not-allowed;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #d1d5db;
}

.form-group input,
.form-group textarea {
  width: 100%;
  background-color: #0f1115;
  border: 1px solid #374151;
  border-radius: 4px;
  padding: 0.75rem;
  color: white;
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-primary);
}

.form-group textarea {
  resize: vertical;
}

.admin-empty-state {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #9ca3af;
  font-size: 1.2rem;
}


@media (max-width: 1024px) { .article-list { grid-template-columns: repeat(var(--cols-tablet, 4), 1fr); } }
@media (max-width: 640px) { .article-list { grid-template-columns: repeat(var(--cols-mobile, 2), 1fr); } }
