:root {
  --bg-color: #121212;
  /* Slightly darker */
  --card-bg: #1e1e1e;
  --text-color: #e0e0e0;
  --text-muted: #a0a0a0;
  --primary-color: #3b82f6;
  --primary-hover: #2563eb;
  --border-color: #333333;
  --input-bg: #2d2d2d;
  --danger-color: #ef4444;
  --success-color: #22c55e;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.2s;
}

/* Layout utilities */
.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 1.5rem 1rem;
  width: 100%;
  flex: 1;
}

.center-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 80vh;
  text-align: center;
}

/* Typography */
h1,
h2,
h3 {
  margin-top: 0;
  color: #fff;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 0.75rem;
}

h1 {
  font-size: 1.8rem;
}

h2 {
  font-size: 1.5rem;
}

h3 {
  font-size: 1.2rem;
}

p {
  margin-bottom: 0.75rem;
}

/* Cards/Panels */
.panel {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
  width: 100%;
}

/* Forms */
.form-group {
  margin-bottom: 1rem;
  text-align: left;
}

label {
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 600;
  color: #fff;
  font-size: 0.9rem;
}

input[type="text"],
textarea {
  width: 100%;
  padding: 0.6rem 0.8rem;
  background-color: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  color: #fff;
  font-size: 0.95rem;
  font-family: inherit;
  transition: all 0.2s ease;
}

input[type="text"]:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
  background-color: #333;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.2rem;
  background-color: var(--primary-color);
  color: white;
  border: 1px solid transparent;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.btn:hover {
  background-color: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.btn:active {
  transform: translateY(0);
}

.btn-secondary {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-color);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.05);
  border-color: #555;
  color: #fff;
}

.btn-danger {
  background-color: var(--danger-color);
}

.btn-danger:hover {
  background-color: #dc2626;
}

.btn-full {
  width: 100%;
}

/* Navigation */
.navbar {
  background-color: rgba(30, 30, 30, 0.8);
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1rem;
}

.nav-brand {
  font-weight: 800;
  font-size: 1.25rem;
  color: #fff;
  letter-spacing: -0.05em;
  background: linear-gradient(135deg, #fff 0%, #a0a0a0 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.nav-links {
  display: flex;
  gap: 1.25rem;
}

.nav-link {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.4rem 0;
  position: relative;
}

.nav-link:hover {
  color: white;
}

.nav-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0px;
  left: 0;
  background-color: var(--primary-color);
  transition: width 0.2s ease;
}

.nav-link:hover::after {
  width: 100%;
}

/* Footer */
footer {
  margin-top: auto;
  padding: 1.5rem 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.8rem;
  border-top: 1px solid var(--border-color);
  background-color: var(--bg-color);
}

/* Utilities */
.mb-2 {
  margin-bottom: 0.5rem;
}

.mb-4 {
  margin-bottom: 1rem;
}

.mt-4 {
  margin-top: 1rem;
}

.text-center {
  text-align: center;
}

/* Image styling for previews */
img.preview-poster {
  max-width: 150px;
  border-radius: 8px;
  box-shadow: var(--shadow-lg);
  transition: transform 0.2s;
}

img.preview-poster:hover {
  transform: scale(1.02);
}

/* BBCode Textarea specific */
.bbcode-area {
  font-family: 'JetBrains Mono', 'Consolas', monospace;
  font-size: 0.85rem;
  white-space: pre;
  color: #a5d6ff;
  /* Slight syntax highlight color feel */
}