/* ==========================================================================
   doIwatch.it — app.css
   Single stylesheet. Design tokens defined at :root; all components follow.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Custom Properties (Design Tokens)
   -------------------------------------------------------------------------- */
:root {
  --bg:           #0f1117;
  --surface:      #1a1d27;
  --border:       #2a2d3a;
  --border-soft:  rgba(255, 255, 255, 0.06);
  --text-primary: #e8eaf0;
  --text:         #e8eaf0;
  --text-muted:   #8b8fa8;
  --text-dim:     #5c6070;
  --accent:       #00b4c8;
  --accent-hover: #00cce0;
  --danger:       #e05555;
}

/* --------------------------------------------------------------------------
   Reset & Base
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: 'Inter', system-ui, sans-serif;
  line-height: 1.6;
  font-size: 1rem;
  min-height: 100vh;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  display: block;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
}

h1 { font-size: 1.75rem; margin-bottom: 0.5rem; }
h2 { font-size: 1.25rem; margin-bottom: 0.5rem; }
h3 { font-size: 1.05rem; margin-bottom: 0.4rem; }

p { margin-bottom: 0.75rem; }
p:last-child { margin-bottom: 0; }

/* --------------------------------------------------------------------------
   Form Controls
   -------------------------------------------------------------------------- */
input[type=text],
input[type=email],
input[type=password],
input[type=search],
input[type=number],
select,
textarea {
  display: block;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-primary);
  border-radius: 6px;
  padding: 0.5rem 0.75rem;
  font-family: inherit;
  font-size: 0.9375rem;
  line-height: 1.5;
  transition: border-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
}

input[type=text]::placeholder,
input[type=email]::placeholder,
input[type=password]::placeholder,
input[type=search]::placeholder,
textarea::placeholder {
  color: var(--text-muted);
  opacity: 0.7;
}

input[type=text]:focus,
input[type=email]:focus,
input[type=password]:focus,
input[type=search]:focus,
input[type=number]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0, 180, 200, 0.15);
}

textarea {
  resize: vertical;
  min-height: 80px;
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */
button {
  font-family: inherit;
  font-size: 0.9375rem;
  cursor: pointer;
  border: none;
  background: none;
  line-height: 1.5;
}

/* Shared button shape */
.btn-primary, a.btn-primary,
.btn-ghost,   a.btn-ghost,
.btn-danger,  a.btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  border-radius: 6px;
  padding: 0.5rem 1.25rem;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  white-space: nowrap;
}

.btn-primary, a.btn-primary {
  background: var(--accent);
  color: #0f1117;
  border: none;
}
.btn-primary:hover, a.btn-primary:hover {
  background: var(--accent-hover);
  color: #0f1117;
  text-decoration: none;
}

.btn-ghost, a.btn-ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-primary);
}
.btn-ghost:hover, a.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
}

.btn-danger, a.btn-danger {
  background: var(--danger);
  color: #fff;
  border: none;
}
.btn-danger:hover, a.btn-danger:hover {
  background: #c84040;
  color: #fff;
  text-decoration: none;
}

.btn-sm {
  padding: 0.3rem 0.875rem;
  font-size: 0.8125rem;
}

.btn-ghost-sm, a.btn-ghost-sm {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 0 0.875rem;
  height: 32px;
  font-size: 0.82rem;
  font-weight: 500;
  border-radius: 6px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color 0.15s, color 0.15s;
}
.btn-ghost-sm:hover, a.btn-ghost-sm:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
}
.rating-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.btn-primary-sm, a.btn-primary-sm {
  background: var(--accent);
  color: #0f1117;
  padding: 0.3rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 600;
  border-radius: 6px;
  border: none;
  text-decoration: none;
  display: inline-block;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s;
}
.btn-primary-sm:hover, a.btn-primary-sm:hover {
  background: var(--accent-hover);
  color: #0f1117;
  text-decoration: none;
}

/* --------------------------------------------------------------------------
   Navigation
   -------------------------------------------------------------------------- */
.site-nav {
  background: var(--surface);
  border-bottom: 1px solid var(--border-soft);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(8px);
}

.nav-row-top {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 1.5rem;
  height: 56px;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav-row-search {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 1.5rem 0.625rem;
  display: flex;
  justify-content: center;
}

.nav-row-search .nav-search {
  width: 100%;
  max-width: 480px;
}

.nav-logo {
  font-family: 'DM Serif Display', serif;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
  flex-shrink: 0;
}

.nav-logo:hover { text-decoration: none; }

.nav-logo-I {
  font-family: 'Libre Baskerville', serif;
  font-style: italic;
  color: var(--accent);
  font-size: 1.4rem;
  line-height: 1;
}

.nav-logo-dot {
  color: var(--text-muted);
}

.nav-search input[type=search] {
  width: 100%;
  height: 34px;
  padding: 0.25rem 0.875rem;
  font-size: 0.875rem;
  border-radius: 20px;
  box-sizing: border-box;
}

.nav-links {
  margin-left: auto;
  display: flex;
  gap: 0.875rem;
  align-items: center;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.15s;
}
.nav-links a:hover {
  color: var(--text-primary);
  text-decoration: none;
}
.nav-links a.active {
  color: var(--text-primary);
  font-weight: 600;
}

.nav-username {
  color: var(--accent) !important;
  font-weight: 600 !important;
}

.nav-link--username {
  margin-left: 0.5rem;
  padding-left: 0.75rem !important;
  border-left: 1px solid var(--border-soft);
}

.nav-link--username:hover {
  opacity: 0.8;
}

/* btn-primary-sm inside nav: override the generic .nav-links a color rule */
.nav-links a.btn-primary-sm,
.nav-links a.btn-primary-sm:hover {
  color: #0f1117;
}

.nav-links form {
  display: flex;
  align-items: center;
  margin: 0;
}

.nav-logout-form {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin: 0;
}

.nav-link--logout {
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  color: var(--text-dim);
  font-size: 0.78rem;
  font-weight: 500;
  padding: 0.25rem 0.4rem;
  transition: color 0.15s;
}
.nav-link--logout:hover {
  color: var(--error, #ee0055);
}

.nav-links-desktop { display: none; }

.nav-links--primary,
.nav-links--account {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-links--account {
  margin-left: 0.5rem;
  padding-left: 0.5rem;
  border-left: 1px solid var(--border-soft);
}

/* --------------------------------------------------------------------------
   Flash Messages
   -------------------------------------------------------------------------- */
.flash-success {
  background: #0d3d2e;
  border-left: 3px solid #00c896;
  color: #a8f0d8;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.flash-error {
  background: #3d0d0d;
  border-left: 3px solid var(--danger);
  color: #f0a8a8;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.flash-notice {
  background: #1a2a3d;
  border-left: 3px solid #4a9eff;
  color: #a8cfff;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.report-data-link {
  font-size: 0.72rem;
  color: var(--text-dim);
  text-decoration: none;
  display: inline-block;
  margin-top: 2rem;
}
.report-data-link:hover { color: var(--accent); }

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem;
}

.page-header {
  margin-bottom: 2rem;
}
.page-header h1 {
  margin-bottom: 0.25rem;
}
.page-header p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 0;
}

.two-col {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2rem;
  align-items: start;
}
@media (max-width: 700px) {
  .two-col { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------------
   Card
   -------------------------------------------------------------------------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.5rem;
}
.card + .card {
  margin-top: 1.5rem;
}
.card h2 {
  margin-bottom: 1.25rem;
}

/* --------------------------------------------------------------------------
   Title Item  (used in feed, profile, search, following)
   -------------------------------------------------------------------------- */
.title-item {
  display: flex;
  gap: 0.875rem;
  align-items: flex-start;
  padding: 0.875rem 0;
  border-bottom: 1px solid var(--border);
}
.title-item:last-child {
  border-bottom: none;
}

.title-poster {
  width: 130px;
  height: 196px;
  object-fit: contain;
  border-radius: 4px;
  background: var(--border);
  flex-shrink: 0;
}

.title-poster-placeholder {
  width: 45px;
  height: 68px;
  border-radius: 4px;
  background: var(--border);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* Larger poster for the title detail page */
.title-poster-lg {
  width: 200px;
  height: 300px;
  object-fit: cover;
  border-radius: 8px;
  background: var(--border);
  flex-shrink: 0;
}
.title-poster-lg-placeholder {
  width: 200px;
  height: 300px;
  border-radius: 8px;
  background: var(--border);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  color: var(--text-muted);
}

.title-poster--placeholder {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  color: var(--text-dim);
  font-size: 0.55rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: center;
  padding: 0.25rem;
}
.title-poster--placeholder::before {
  content: '🎬';
  font-size: 1rem;
  opacity: 0.4;
}
.title-poster--placeholder::after {
  content: 'No image';
  opacity: 0.5;
}

.title-poster-lg--placeholder {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: var(--text-dim);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: center;
}
.title-poster-lg--placeholder::before {
  content: '🎬';
  font-size: 2rem;
  opacity: 0.3;
}
.title-poster-lg--placeholder::after {
  content: 'No poster available';
  opacity: 0.5;
}

.title-info {
  flex: 1;
  min-width: 0;
}

.title-name {
  font-weight: 600;
  color: var(--text-primary);
}
.title-name a {
  color: var(--text-primary);
  text-decoration: none;
}
.title-name a:hover {
  color: var(--accent);
}

.title-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

.title-overview {
  font-size: 0.9rem;
  color: var(--text-dim);
  line-height: 1.7;
  max-width: 600px;
  margin-top: 0.75rem;
  margin-bottom: 1.5rem;
}

.rating-badge {
  display: inline-flex;
  align-items: center;
  background: rgba(0, 180, 200, 0.12);
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  margin-top: 0.35rem;
}

.btn-edit-rating {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-dim);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.15rem 0.5rem;
  text-decoration: none;
  transition: all 0.15s;
  margin-left: auto;
  flex-shrink: 0;
}
.btn-edit-rating:hover {
  color: var(--accent);
  border-color: var(--accent);
  text-decoration: none;
}

.btn-rate {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 4px;
  padding: 0.15rem 0.5rem;
  text-decoration: none;
  transition: all 0.15s;
  white-space: nowrap;
}
.btn-rate:hover {
  background: var(--accent-dim);
  text-decoration: none;
}

.feed-season {
  font-size: 0.72rem;
  color: var(--accent);
  font-weight: 500;
  display: block;
  margin-bottom: 0.15rem;
}

.rating-season {
  color: var(--accent);
  font-weight: 500;
}

.rating-comment {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
  font-style: italic;
}

.rating-date {
  display: block;
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-top: 0.2rem;
}

.network-season {
  font-size: 0.72rem;
  color: var(--accent);
  font-weight: 600;
  background: var(--accent-dim);
  border: 1px solid rgba(0,180,200,0.2);
  border-radius: 3px;
  padding: 0.1rem 0.35rem;
  margin-right: 0.25rem;
}

.show-all-ratings {
  display: block;
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 1rem;
  padding: 0.5rem;
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  transition: all 0.15s;
}
.show-all-ratings:hover {
  color: var(--accent);
  border-color: var(--accent);
  text-decoration: none;
}

/* --------------------------------------------------------------------------
   Sidebar card — recently joined widget
   -------------------------------------------------------------------------- */
/* --------------------------------------------------------------------------
   Feed Header  (title + toggle button row above feed items)
   -------------------------------------------------------------------------- */
.feed-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.feed-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
}

.feed-toggle {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 0.25rem 0.75rem;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s;
  white-space: nowrap;
}

.feed-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.feed-toggle--active {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
}

/* --------------------------------------------------------------------------
   Seasons Section  (TV show title page — rate by season)
   -------------------------------------------------------------------------- */
.seasons-section {
  margin-top: 2.5rem;
  border-top: 1px solid var(--border-soft);
  padding-top: 1.25rem;
  margin-bottom: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
}

.network-section {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-soft);
}

.network-aggregate {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border-soft);
}

.network-avg-score {
  font-family: 'DM Serif Display', serif;
  font-size: 2.2rem;
  color: var(--accent);
  line-height: 1;
}

.network-avg-score .sl {
  font-size: 1rem;
  color: var(--text-dim);
}

.network-avg-label {
  font-size: 0.8rem;
  color: var(--text-dim);
}

.seasons-intro {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 1rem;
}

.seasons-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.season-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--border-soft);
  gap: 1rem;
}
.season-row:last-child { border-bottom: none; }

.season-info {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex: 1;
  min-width: 0;
}

.season-num {
  font-family: 'DM Serif Display', serif;
  font-size: 0.9rem;
  color: var(--accent);
  flex-shrink: 0;
  width: 2rem;
}

.season-name {
  font-size: 0.875rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.season-eps {
  font-size: 0.72rem;
  color: var(--text-dim);
  flex-shrink: 0;
}

.season-rating {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.season-not-aired {
  font-size: 0.72rem;
  color: var(--text-dim);
  font-style: italic;
}

/* --------------------------------------------------------------------------
   Feed Item  (extends title-item, adds who-rated header row)
   -------------------------------------------------------------------------- */
.feed-item {
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}
.feed-item:last-child {
  border-bottom: none;
}

.feed-user {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.6rem;
}

.feed-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(0, 180, 200, 0.2);
  color: var(--accent);
  font-weight: 700;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.feed-meta {
  flex: 1;
  font-size: 0.875rem;
  color: var(--text-muted);
}
.feed-meta a {
  color: var(--text-primary);
  font-weight: 600;
}

.feed-time {
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.feed-body {
  display: flex;
  flex-direction: row;
  gap: 0.875rem;
  align-items: flex-start;
}

.feed-body .title-poster {
  width: 130px;
  height: 196px;
  object-fit: contain;
}

/* --------------------------------------------------------------------------
   Search & Filters
   -------------------------------------------------------------------------- */
.search-bar {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  align-items: flex-end;
}
.search-bar input[type=search] {
  flex: 1;
  min-width: 180px;
  max-width: 480px;
}

.search-filters {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.filter-btn, a.filter-btn {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 1rem;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.875rem;
  font-family: inherit;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
.filter-btn:hover, a.filter-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
}
.filter-btn.active, a.filter-btn.active {
  background: var(--accent);
  color: #0f1117;
  border-color: var(--accent);
  font-weight: 600;
}
.filter-btn.active:hover, a.filter-btn.active:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: #0f1117;
}
.year-filter {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 20px;
  padding: 0.3rem 0.875rem;
  font-size: 0.82rem;
  font-family: inherit;
  width: 90px;
  outline: none;
  transition: border-color 0.15s;
  -moz-appearance: textfield;
}
.year-filter:focus { border-color: var(--accent); }
.year-filter::placeholder { color: var(--text-dim); }
.year-filter::-webkit-outer-spin-button,
.year-filter::-webkit-inner-spin-button { -webkit-appearance: none; }

.user-filter-input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 6px;
  padding: 0.5rem 0.875rem;
  font-size: 0.875rem;
  font-family: inherit;
  outline: none;
  margin-bottom: 1.25rem;
  transition: border-color 0.2s;
}
.user-filter-input:focus { border-color: var(--accent); }
.filter-page-hint {
  margin-top: -0.875rem;
  margin-bottom: 1rem;
  color: var(--text-dim);
  font-size: 0.72rem;
}

/* --------------------------------------------------------------------------
   Forms  (auth pages, settings)
   -------------------------------------------------------------------------- */
.form-wrap {
  max-width: 420px;
  margin: 3rem auto;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.375rem;
}

.captcha-question {
  display: block;
  font-family: 'DM Serif Display', serif;
  font-size: 1.1rem;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.form-check { display: flex; align-items: center; gap: 0.5rem; }
.check-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  cursor: pointer;
}
.check-label input[type=checkbox] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  cursor: pointer;
  flex-shrink: 0;
}

.form-error {
  font-size: 0.8rem;
  color: var(--danger);
  margin-top: 0.25rem;
}

.form-footer {
  margin-top: 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  text-align: center;
}

.form-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 1.5rem 0;
}

/* Rating picker */
.rating-picker {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.rating-btn {
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
  padding: 0;
}
.rating-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.rating-btn.selected {
  background: var(--accent);
  color: #0f1117;
  border-color: var(--accent);
}

/* --------------------------------------------------------------------------
   Profile
   -------------------------------------------------------------------------- */
.profile-header {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(0, 180, 200, 0.15);
  color: var(--accent);
  font-size: 1.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.profile-info {
  flex: 1;
  min-width: 0;
}
.profile-info h1 {
  margin-bottom: 0.125rem;
}

.profile-join {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  white-space: nowrap;
}

.profile-stats {
  display: flex;
  gap: 1.5rem;
  margin-top: 0.5rem;
  flex-wrap: wrap;
  align-items: flex-start;
}

.profile-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: flex-start;
}

@media (max-width: 600px) {
  .profile-header {
    flex-wrap: wrap;
  }
  .profile-info {
    flex: 1 1 auto;
    min-width: 0;
  }
  .profile-actions {
    flex-direction: row;
    flex-wrap: wrap;
    width: 100%;
    margin-top: 0.5rem;
  }
}

.stat {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.stat-value {
  font-weight: 700;
  color: var(--text-primary);
  display: block;
  font-size: 1.1rem;
  line-height: 1.2;
}

/* --------------------------------------------------------------------------
   Profile stats section (own-profile only)
   -------------------------------------------------------------------------- */

.user-stats {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-soft);
}

.user-stats-heading {
  font-family: 'DM Serif Display', serif;
  font-size: 1.2rem;
  margin-bottom: 1.25rem;
  color: var(--text);
}

/* Tighter grid than admin dashboard */
.user-stats .stats-grid {
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 0.75rem;
  margin-bottom: 2rem;
}

/* Lighter card style for profile context */
.user-stats .stat-card {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  padding: 0.9rem 0.75rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  text-align: center;
}

.user-stats .stat-card--accent {
  border-color: var(--accent);
}

/* Slightly smaller than admin (2rem) */
.user-stats .stat-value {
  font-size: 1.8rem;
}

.user-stats .stat-card--accent .stat-value {
  color: var(--accent);
}

.user-stats-section {
  margin-bottom: 2rem;
}

.stats-toggle {
  background: none;
  border: none;
  padding: 0;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}

.stats-toggle:hover { color: var(--text); }

.toggle-arrow {
  font-size: 0.7rem;
  transition: transform 0.15s;
}

.stats-collapsible {
  margin-bottom: 0.5rem;
}

.user-stats-subheading {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  margin-bottom: 0.75rem;
  font-weight: 600;
}

/* Score distribution bar chart */
.dist-chart {
  display: flex;
  align-items: flex-end;
  gap: 0.4rem;
  height: 100px;
}

.dist-bar-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  gap: 0.2rem;
  height: 100%;
}

.dist-bar-track {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: flex-end;
}

.dist-bar {
  width: 100%;
  background: var(--accent);
  border-radius: 3px 3px 0 0;
  min-height: 2px;
  opacity: 0.75;
  transition: opacity 0.15s;
}

.dist-bar:hover { opacity: 1; }

.dist-label {
  font-size: 0.65rem;
  color: var(--text-dim);
}

.dist-count {
  font-size: 0.6rem;
  color: var(--text-dim);
}

/* Genre / decade list */
.genre-list {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}

.genre-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.82rem;
}

.genre-name {
  flex: 1;
  color: var(--text);
}

.genre-count {
  color: var(--text-dim);
  font-size: 0.75rem;
}

.genre-avg {
  font-family: 'DM Serif Display', serif;
  font-size: 1rem;
  color: var(--accent);
  min-width: 2.5rem;
  text-align: right;
}

.genre-insight {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 0.5rem;
  line-height: 1.6;
}

.genre-insight strong { color: var(--text); }

.user-stats-member-since {
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 1rem;
}

/* --------------------------------------------------------------------------
   Marketing — Hero, How It Works, Product Preview, Statements
   -------------------------------------------------------------------------- */

/* Hero */
.hero { position:relative; padding:9rem 1.5rem 5rem; text-align:center; overflow:hidden; }
.hero { margin-left:-1.5rem; margin-right:-1.5rem; }
.contrast-block,
.statements-section,
.how-section,
.standalone-tagline,
.url-section { margin-left:-1.5rem; margin-right:-1.5rem; padding-left:1.5rem; padding-right:1.5rem; }
.hero::before { content:''; position:absolute; top:-10%; left:50%; transform:translateX(-50%); width:900px; height:500px; background:radial-gradient(ellipse, rgba(0,180,200,0.08) 0%, transparent 65%); pointer-events:none; }
.hero-noise { position:absolute; inset:0; opacity:0.02; background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E"); background-size:200px; pointer-events:none; }
.hero-content { position:relative; z-index:1; max-width:620px; margin:0 auto; }
.hero-eyebrow { display:inline-flex; align-items:center; gap:0.5rem; font-size:0.72rem; font-weight:600; letter-spacing:0.12em; text-transform:uppercase; color:var(--accent); margin-bottom:1.5rem; padding:0.3rem 0.9rem; border:1px solid rgba(0,180,200,0.25); border-radius:20px; background:rgba(0,180,200,0.07); }
.hero-eyebrow::before { content:''; width:6px; height:6px; border-radius:50%; background:var(--accent); animation:pulse-dot 2s infinite; }
@keyframes pulse-dot { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.4;transform:scale(0.7)} }
.hero-headline { font-family:'DM Serif Display',serif; font-size:clamp(2.8rem,7vw,4.5rem); font-weight:400; letter-spacing:-0.03em; line-height:1.05; margin-bottom:1.25rem; }
.hero-headline em { font-style:italic; color:var(--accent); }
.hero-sub { font-size:1.1rem; color:var(--text-muted); line-height:1.75; max-width:460px; margin:0 auto 2.5rem; }
.hero-cta-group { display:flex; gap:0.75rem; justify-content:center; align-items:center; margin-bottom:1rem; }
.hero-note { font-size:0.78rem; color:var(--text-dim); }
.hero-note a { color:var(--text-muted); }
.hero-note a:hover { color:var(--accent); }
.hero-tagline { font-family:'DM Serif Display',serif; font-size:1.1rem; color:var(--text-dim); font-style:italic; margin-bottom:1.25rem; letter-spacing:0.01em; }
.btn-ghost-lg { background:transparent; border:1px solid var(--border); color:var(--text-muted); font-size:0.95rem; font-weight:500; padding:0.7rem 1.5rem; border-radius:24px; cursor:pointer; font-family:inherit; text-decoration:none; transition:all 0.15s; display:inline-block; }
.btn-ghost-lg:hover { border-color:var(--accent); color:var(--accent); text-decoration:none; }
.btn-primary-lg { background:var(--accent); color:#0f1117; font-size:0.95rem; font-weight:700; padding:0.7rem 1.75rem; border-radius:24px; border:none; cursor:pointer; font-family:inherit; text-decoration:none; transition:filter 0.15s,transform 0.15s; display:inline-block; box-shadow:0 0 24px rgba(0,180,200,0.2); }
.btn-primary-lg:hover { filter:brightness(1.1); transform:translateY(-1px); text-decoration:none; color:#0f1117; }

/* How it works */
.how-section { padding:5rem 1.5rem; max-width:860px; margin:0 auto; border-top:1px solid var(--border-soft); overflow-x:hidden; }
.how-label { text-align:center; font-size:0.7rem; font-weight:600; letter-spacing:0.1em; text-transform:uppercase; color:var(--text-dim); margin-bottom:3rem; }
.how-steps { display:grid; grid-template-columns:repeat(3,1fr); gap:0; position:relative; }
.how-steps::before { content:''; position:absolute; top:28px; left:calc(16.66% + 28px); right:calc(16.66% + 28px); height:1px; background:linear-gradient(90deg,var(--accent),rgba(0,180,200,0.3),var(--accent)); opacity:0.3; }
.how-step { text-align:center; padding:0 1.5rem; }
.how-step-num { width:56px; height:56px; border-radius:50%; background:var(--surface); border:1px solid var(--border); color:var(--accent); font-family:'DM Serif Display',serif; font-size:1.3rem; display:flex; align-items:center; justify-content:center; margin:0 auto 1.25rem; position:relative; z-index:1; transition:border-color 0.2s,background 0.2s; }
.how-step:hover .how-step-num { border-color:var(--accent); background:rgba(0,180,200,0.07); }
.how-step-title { font-family:'DM Serif Display',serif; font-size:1.2rem; font-weight:400; color:var(--text); margin-bottom:0.5rem; }
.how-step-body { font-size:0.85rem; color:var(--text-muted); line-height:1.65; }
.how-step-body strong { color:var(--text); font-weight:500; }
.how-steps--vertical { display:flex; flex-direction:column; gap:0; }
.how-steps--vertical .how-step { display:grid; grid-template-columns:3rem 1fr; gap:0 1.25rem; padding:1.75rem 0; border-bottom:1px solid var(--border); text-align:left; }
.how-steps--vertical .how-step:last-child { border-bottom:none; }
.how-steps--vertical .how-step > div:last-child { min-width:0; }
.step-num-col { display:flex; flex-direction:column; align-items:center; }
.how-steps--vertical .how-step-num { margin:0; }
.step-line { width:1px; flex:1; min-height:1.5rem; background:var(--border); margin:0.4rem auto 0; }

/* Four-step how-it-works variant */
.how-steps--four { grid-template-columns:repeat(4,1fr); }
.how-steps--four::before { left:calc(12.5% + 28px); right:calc(12.5% + 28px); }

.welcome-aside { font-size:0.95rem; color:var(--text-muted); font-style:italic; line-height:1.7; margin:2.5rem 0; padding:0; }
.welcome-aside em { color:var(--accent); font-style:normal; }
/* Product preview */
.preview-section { padding:2rem 1.5rem 5rem; }
.preview-label { text-align:center; font-size:0.72rem; font-weight:600; letter-spacing:0.1em; text-transform:uppercase; color:var(--text-dim); margin-bottom:2.5rem; }
.preview-label span { color:var(--accent); }
.preview-window { max-width:640px; margin:0 auto; position:relative; }
.preview-window::after { content:''; position:absolute; bottom:0; left:0; right:0; height:180px; background:linear-gradient(to bottom,transparent,var(--bg)); pointer-events:none; z-index:2; border-radius:0 0 14px 14px; }
.preview-frame { background:var(--surface); border:1px solid var(--border); border-radius:14px; overflow:hidden; box-shadow:0 32px 80px rgba(0,0,0,0.5); }
.preview-titlebar { background:rgba(0,0,0,0.3); padding:0.6rem 1rem; display:flex; align-items:center; border-bottom:1px solid var(--border-soft); }
.traffic-lights { display:flex; gap:0.35rem; }
.tl { width:10px; height:10px; border-radius:50%; }
.tl-r { background:#ff5f57; } .tl-y { background:#ffbd2e; } .tl-g { background:#28c840; }
.preview-url { flex:1; background:rgba(0,0,0,0.2); border-radius:4px; padding:0.2rem 0.6rem; font-size:0.72rem; color:var(--text-dim); font-family:monospace; margin:0 0.75rem; text-align:center; }
.preview-body { padding:1.25rem; }
.preview-section-label { font-size:0.65rem; font-weight:600; letter-spacing:0.1em; text-transform:uppercase; color:var(--text-dim); margin-bottom:1rem; }
.pv-item { display:flex; gap:0.875rem; padding:0.875rem 0; border-bottom:1px solid var(--border-soft); }
.pv-item:last-child { border-bottom:none; }
.pv-poster { width:40px; height:60px; border-radius:4px; flex-shrink:0; }
.pg-a { background:linear-gradient(160deg,#2d3561,#c05c7e); }
.pg-b { background:linear-gradient(160deg,#1a1a2e,#e94560); }
.pg-c { background:linear-gradient(160deg,#0f3460,#533483); }
.pv-body { flex:1; min-width:0; }
.pv-meta { display:flex; align-items:center; gap:0.35rem; margin-bottom:0.2rem; }
.pv-user { font-size:0.78rem; font-weight:600; color:var(--text); }
.pv-action { font-size:0.75rem; color:var(--text-dim); }
.pv-time { font-size:0.7rem; color:var(--text-dim); margin-left:auto; }
.pv-title { font-family:'DM Serif Display',serif; font-size:0.95rem; color:var(--text); display:block; margin-bottom:0.15rem; }
.pv-year { font-size:0.72rem; color:var(--text-dim); margin-bottom:0.35rem; }
.pv-badge { display:inline-flex; align-items:center; background:rgba(0,180,200,0.07); border:1px solid rgba(0,180,200,0.2); color:var(--accent); font-size:0.75rem; font-weight:700; padding:0.1rem 0.4rem; border-radius:3px; }
.pv-badge .sl { opacity:0.4; font-weight:400; font-size:0.65rem; }
.pv-comment { font-size:0.78rem; color:var(--text-muted); font-style:italic; margin-top:0.25rem; }
.preview-overlay { position:absolute; bottom:0; left:0; right:0; height:200px; display:flex; align-items:flex-end; justify-content:center; padding-bottom:1.75rem; z-index:3; }
.preview-cta-box { text-align:center; background:rgba(15,17,23,0.92); border:1px solid var(--border); border-radius:12px; padding:1.1rem 2rem; backdrop-filter:blur(8px); }
.preview-cta-box p { font-size:0.82rem; color:var(--text-muted); margin-bottom:0.75rem; }

/* Statements */
.statements-section { padding:4rem 1.5rem; max-width:600px; margin:0 auto; border-top:1px solid var(--border-soft); text-align:center; }
.statement { font-family:'DM Serif Display',serif; font-size:clamp(1.2rem,2.8vw,1.55rem); font-style:italic; color:var(--text-dim); line-height:1.45; padding:1rem 0; border-bottom:1px solid var(--border-soft); transition:color 0.25s; }
.statement:hover { color:var(--text-muted); }
.statement:last-child, .statement--accent { border-bottom:none; font-style:normal; color:var(--text); font-size:clamp(1.3rem,3vw,1.7rem); padding-top:1.5rem; }
.statement.statement--light { font-size:0.9em; font-style:italic; opacity:0.65; }
.statement.statement--light:hover { opacity:1; }

/* Contrast block */
.contrast-block { display:flex; align-items:center; justify-content:center; gap:2.5rem; padding:5rem 1.5rem; max-width:760px; margin:0 auto; border-top:1px solid var(--border-soft); }
.contrast-side { flex:1; text-align:center; }
.contrast-label { font-size:0.7rem; font-weight:600; letter-spacing:0.1em; text-transform:uppercase; color:var(--text-dim); margin-bottom:0.5rem; }
.contrast-site { font-size:0.82rem; color:var(--text-muted); margin-bottom:1rem; }
.contrast-score { font-family:'DM Serif Display',serif; font-size:clamp(4rem,10vw,6rem); line-height:1; margin-bottom:0.75rem; }
.contrast-score--them { color:var(--text-dim); }
.contrast-score--us { color:var(--accent); }
.contrast-caption { font-size:0.78rem; color:var(--text-muted); line-height:1.5; }
.contrast-vs { font-family:'DM Serif Display',serif; font-size:1.5rem; font-style:italic; color:var(--text-dim); flex-shrink:0; }

/* Standalone tagline */
.standalone-tagline { text-align:center; padding:4rem 1.5rem; max-width:680px; margin:0 auto; border-top:1px solid var(--border-soft); }
.standalone-tagline p { font-family:'DM Serif Display',serif; font-size:clamp(1.1rem,2.5vw,1.4rem); font-style:italic; color:var(--text-muted); line-height:1.6; }
.standalone-tagline em { color:var(--accent); font-style:normal; }

/* --------------------------------------------------------------------------
   Empty state
   -------------------------------------------------------------------------- */
.empty-state {
  padding: 3rem 1rem;
  text-align: center;
  color: var(--text-muted);
}
.empty-state .empty-icon {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
}
.empty-state h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}
.empty-state p {
  max-width: 380px;
  margin: 0 auto 1rem;
}

/* --------------------------------------------------------------------------
   Watchlist
   -------------------------------------------------------------------------- */
.btn-watchlist {
  font-size: 0.72rem;
  padding: 0.25rem 0.6rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, color 0.15s;
  white-space: nowrap;
}
.btn-watchlist:hover { border-color: var(--accent); color: var(--accent); }
.btn-watchlist--active { border-color: var(--accent); color: var(--accent); background: var(--accent-dim); }

.btn-remove-watchlist {
  font-size: 0.7rem;
  color: var(--text-dim);
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
  margin-top: 0.25rem;
}
.btn-remove-watchlist:hover { color: var(--error); }

.profile-watchlist-link {
  font-size: 0.78rem;
  color: var(--text-dim);
  text-decoration: none;
  padding: 0.2rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 4px;
}
.profile-watchlist-link:hover { color: var(--accent); border-color: var(--accent); }

.watchlist-page { max-width: 1100px; margin: 0 auto; padding: 1.5rem 1rem; }
.watchlist-header {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.watchlist-count { font-size: 0.8rem; color: var(--text-dim); }

.watchlist-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1.25rem;
}
.watchlist-card { display: flex; flex-direction: column; gap: 0.5rem; }

.watchlist-poster {
  width: 100%;
  aspect-ratio: 2/3;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--border-soft);
  display: block;
}
.watchlist-poster--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  font-size: 2rem;
}

.watchlist-card-info { display: flex; flex-direction: column; gap: 0.15rem; }
.watchlist-card-title {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  line-height: 1.3;
}
.watchlist-card-title:hover { color: var(--accent); }
.watchlist-card-year,
.watchlist-card-type { font-size: 0.72rem; color: var(--text-dim); }

.settings-hint { font-size: 0.75rem; color: var(--text-dim); margin: 0.1rem 0 0.5rem; }
.check-label { display: flex; align-items: center; gap: 0.4rem; font-size: 0.85rem; cursor: pointer; }

@media (max-width: 640px) {
  .watchlist-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); }
}

/* --------------------------------------------------------------------------
   Load more
   -------------------------------------------------------------------------- */
.load-more-wrap {
  text-align: center;
  margin-top: 1.5rem;
  padding-bottom: 2rem;
}
.load-more-btn { min-width: 140px; }
.load-more-btn:disabled { opacity: 0.6; cursor: default; }

/* --------------------------------------------------------------------------
   Section label
   -------------------------------------------------------------------------- */
.section-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.875rem;
}

/* --------------------------------------------------------------------------
   Notifications — nav badge + inbox page
   -------------------------------------------------------------------------- */
.nav-link--notif {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.notif-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: var(--bg);
  font-size: 0.65rem;
  font-weight: 700;
  min-width: 1.1rem;
  height: 1.1rem;
  border-radius: 999px;
  padding: 0 0.25rem;
  line-height: 1;
}

.notif-page {
  max-width: 600px;
  margin: 0 auto;
  padding: 1.5rem 1rem;
}

.notif-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.notif-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 0.75rem;
  border-bottom: 1px solid var(--border-soft);
  border-radius: 6px;
  transition: background 0.1s;
}

.notif-item:hover {
  background: var(--surface);
}

.notif-item--unread {
  background: var(--surface);
}

.notif-item--unread .notif-body {
  font-weight: 500;
  color: var(--text);
}

.notif-avatar {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: white;
  text-decoration: none;
  flex-shrink: 0;
}

.notif-body {
  font-size: 0.875rem;
  color: var(--text-dim);
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.notif-actor {
  color: var(--text);
  font-weight: 600;
  text-decoration: none;
}

.notif-actor:hover { color: var(--accent); }

.notif-time {
  font-size: 0.75rem;
  color: var(--text-dim);
  opacity: 0.7;
}

.empty-hint {
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-top: 0.5rem;
}

/* --------------------------------------------------------------------------
   Contact form
   -------------------------------------------------------------------------- */
.contact-form { max-width: 520px; }

.form-textarea {
  resize: vertical;
  min-height: 120px;
  font-family: inherit;
}

.form-input--short { max-width: 100px; }

.form-hint {
  font-size: 0.75rem;
  color: var(--text-dim);
  font-weight: 400;
  margin-left: 0.25rem;
}

.form-select {
  appearance: none;
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   Admin inbox
   -------------------------------------------------------------------------- */
.admin-inbox-list {
  display: flex;
  flex-direction: column;
}

.admin-inbox-item {
  padding: 1rem 0.75rem;
  border-bottom: 1px solid var(--border-soft);
  border-radius: 4px;
}

.admin-inbox-item--unread {
  background: var(--surface);
}

.admin-inbox-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.admin-inbox-type {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 0.15rem 0.5rem;
  border-radius: 3px;
  letter-spacing: 0.05em;
}

.admin-inbox-type--contact {
  background: rgba(0, 180, 200, 0.12);
  color: var(--accent);
}

.admin-inbox-type--suggestion {
  background: #2a3a2a;
  color: #6abf6a;
}

.admin-inbox-type--report {
  background: #3a2a2a;
  color: #bf6a6a;
}

.admin-inbox-email,
.admin-inbox-time {
  font-size: 0.78rem;
  color: var(--text-dim);
}

.admin-inbox-message {
  font-size: 0.875rem;
  color: var(--text);
  line-height: 1.6;
  white-space: pre-wrap;
}

.admin-inbox-hint {
  margin-top: 0.5rem;
  padding: 0.4rem 0.65rem;
  background: rgba(0, 180, 200, 0.08);
  border-left: 3px solid var(--accent);
  border-radius: 0 4px 4px 0;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.admin-inbox-hint code {
  font-family: monospace;
  background: var(--surface-2);
  padding: 0.1rem 0.35rem;
  border-radius: 3px;
  font-size: 0.78rem;
}

/* --------------------------------------------------------------------------
   Verify notice (shown on login page after registration)
   -------------------------------------------------------------------------- */

.verify-notice {
  max-width: 420px;
  margin: 1rem auto 0;
  padding: 1rem 1.25rem;
  background: rgba(0, 180, 200, 0.07);
  border: 1px solid rgba(0, 180, 200, 0.25);
  border-radius: 8px;
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.verify-notice p { margin: 0; }
.verify-notice p + p { margin-top: 0.5rem; }
.verify-notice a { color: var(--accent); }

/* --------------------------------------------------------------------------
   Email help page
   -------------------------------------------------------------------------- */

.static-subtitle {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.65;
}

.email-provider-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.email-provider {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  background: var(--surface-2);
  border-radius: 6px;
  flex-wrap: wrap;
}

.provider-name {
  font-weight: 500;
  color: var(--text);
  min-width: 9rem;
}

.provider-status {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.provider-status--good {
  background: rgba(52, 211, 153, 0.12);
  color: #6ee7b7;
}

.provider-status--bad {
  background: rgba(248, 113, 113, 0.12);
  color: #fca5a5;
}

.provider-note {
  font-size: 0.82rem;
  color: var(--text-muted);
  flex: 1;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
footer {
  border-top: 1px solid var(--border);
  margin-top: 3rem;
  padding: 1.5rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-muted);
}
footer a {
  color: var(--text-muted);
}
footer a:hover {
  color: var(--text-primary);
}

/* --------------------------------------------------------------------------
   Utility helpers
   -------------------------------------------------------------------------- */
.text-muted  { color: var(--text-muted); }
.text-accent { color: var(--accent); }
.text-danger { color: var(--danger); }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-0 { margin-bottom: 0 !important; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.gap-1 { gap: 0.5rem; }

/* --------------------------------------------------------------------------
   Stat links (profile follower/following/ratings counts)
   -------------------------------------------------------------------------- */
.stat-link {
  text-decoration: none;
  color: inherit;
  transition: color 0.15s;
}
.stat-link:hover .stat-value { color: var(--accent); }
.stat-link:hover .stat-label { color: var(--text-muted); }

/* --------------------------------------------------------------------------
   URL showcase — marketing homepage personal-URL pitch
   -------------------------------------------------------------------------- */
.url-section { padding:5rem 1.5rem; text-align:center; border-top:1px solid var(--border-soft); position:relative; overflow:hidden; }
.url-section::before { content:''; position:absolute; top:50%; left:50%; transform:translate(-50%,-50%); width:700px; height:300px; background:radial-gradient(ellipse,rgba(0,180,200,0.05) 0%,transparent 65%); pointer-events:none; }
.url-label { font-size:0.7rem; font-weight:600; letter-spacing:0.1em; text-transform:uppercase; color:var(--text-dim); margin-bottom:1.5rem; }
.url-display { font-family:'DM Serif Display',serif; font-size:clamp(2rem,6vw,3.5rem); letter-spacing:-0.03em; line-height:1; margin-bottom:1.25rem; display:inline-block; }
.url-base { color:var(--text-dim); }
.url-question { color:var(--accent); font-style:italic; }
.url-subtext { font-size:0.9rem; color:var(--text-muted); max-width:380px; margin:0 auto 2rem; line-height:1.75; }
.url-subtext strong { color:var(--text); font-weight:500; }

/* --------------------------------------------------------------------------
   Cycling username animation in the marketing url-display
   -------------------------------------------------------------------------- */
.url-username-cycle { display:inline-block; position:relative; color:var(--text); width:240px; height:1em; vertical-align:bottom; }
.url-username-cycle > span { position:absolute; left:0; top:0; opacity:0; white-space:nowrap; animation:cycle-name 10s infinite; }
.url-username-cycle > span:nth-child(1) { animation-delay:0s; }
.url-username-cycle > span:nth-child(2) { animation-delay:2s; }
.url-username-cycle > span:nth-child(3) { animation-delay:4s; }
.url-username-cycle > span:nth-child(4) { animation-delay:6s; }
.url-username-cycle > span:nth-child(5) { animation-delay:8s; }
@keyframes cycle-name { 0%{opacity:0;transform:translateY(10px)} 6%{opacity:1;transform:translateY(0)} 20%{opacity:1;transform:translateY(0)} 26%{opacity:0;transform:translateY(-10px)} 100%{opacity:0} }

/* ==========================================================================
   Responsive breakpoints
   ========================================================================== */

/* Tablet (≤ 860px) */
@media (max-width: 860px) {
  .how-steps { grid-template-columns: 1fr; max-width: 380px; margin-inline: auto; }
  .how-steps--four { grid-template-columns: repeat(2, 1fr); max-width: none; }
  .preview-frame { transform: none; }
  .statements-section { grid-template-columns: 1fr 1fr; }
  .contrast-block { gap: 1.5rem; padding: 3.5rem 1.5rem; }
}

/* Desktop nav: single row with separator dots */
@media (min-width: 768px) {
  .nav-links-desktop {
    display: flex;
    align-items: center;
    gap: 0.1rem;
    margin-left: auto;
  }
  .nav-links--primary,
  .nav-links--account,
  .nav-logout-form {
    display: none;
  }
  .nav-links-desktop .nav-link {
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    padding: 0.3rem 0.5rem;
    border-radius: 4px;
    white-space: nowrap;
    transition: color 0.15s;
  }
  .nav-links-desktop a.nav-link:hover {
    color: var(--text-primary);
    text-decoration: none;
  }
  .nav-links-desktop a.nav-link.active {
    color: var(--text-primary);
    font-weight: 600;
  }
  .nav-links-desktop .nav-link--username {
    color: var(--accent);
    font-weight: 600;
    border-left: none;
    margin-left: 0;
    padding-left: 0.5rem !important;
  }
  .nav-links-desktop .nav-link--username:hover {
    opacity: 0.8;
    color: var(--accent);
  }
  .nav-sep {
    color: var(--text-dim);
    opacity: 0.5;
    padding: 0 0.15rem;
    user-select: none;
    font-size: 0.875rem;
  }
  .nav-links-desktop form {
    display: inline-flex;
    align-items: center;
    margin: 0;
  }
}

/* Mobile (≤ 767px) */
@media (max-width: 767px) {
  /* Nav — row 1: logo · primary links · logout */
  .nav-row-top {
    flex-wrap: wrap;
    height: auto;
    padding: 0.6rem 1rem 0;
    gap: 0.25rem;
  }

  /* Logged-out nav has only logo + buttons — no wrapping needed */
  .nav-row-top--guest {
    flex-wrap: nowrap;
    align-items: center;
    padding: 0.5rem 1rem;
    gap: 0.5rem;
  }
  .nav-logo { flex-shrink: 0; margin-right: 0.25rem; }
  .nav-links--primary {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.1rem;
    flex: 1;
  }
  .nav-links--primary .nav-link {
    font-size: 0.78rem;
    padding: 0.25rem 0.4rem;
    white-space: nowrap;
  }
  .nav-logout-form { flex-shrink: 0; margin-left: auto; }
  /* Nav — row 2: account links */
  .nav-links--account {
    width: 100%;
    flex-wrap: wrap;
    gap: 0.1rem;
    margin-left: 0;
    padding-left: 0;
    border-left: none;
    border-top: 1px solid var(--border-soft);
    padding-top: 0.3rem;
    margin-top: 0.2rem;
    padding-bottom: 0.4rem;
  }
  .nav-links--account .nav-link {
    font-size: 0.7rem;
    padding: 0.2rem 0.35rem;
    color: var(--text-dim);
    white-space: nowrap;
  }
  .nav-link--logout {
    border: none;
    padding: 0.25rem 0.4rem;
    font-size: 0.78rem;
  }
  .nav-row-search { padding: 0 1rem 0.75rem; }
  .nav-search-input { width: 100%; }

  /* Hero */
  .hero { padding: 4rem 1.25rem 3rem; }
  .hero-headline { font-size: clamp(2.2rem, 10vw, 3.5rem); }
  .hero-cta-group { flex-direction: column; align-items: center; }
  .btn-primary-lg, .btn-ghost-lg { width: 100%; max-width: 320px; text-align: center; }

  /* How */
  .how-section { padding: 3rem 1.25rem; }

  /* Preview */
  .preview-section { padding: 3rem 1rem; }
  .preview-frame { font-size: 0.72rem; }
  .pv-poster { width: 36px; height: 54px; }

  /* Statements */
  .statements-section { grid-template-columns: 1fr; padding: 3rem 1.25rem; }

  /* URL showcase */
  .url-section { padding: 3rem 1.25rem; }
  .url-display { font-size: clamp(1.6rem, 7vw, 2.5rem); }
  .url-username-cycle { width: 180px; }

  /* Feed / ratings list */
  .feed-entry { flex-wrap: wrap; gap: 0.5rem; }
  .feed-poster { width: 42px; height: 63px; }

  /* Title page */
  .title-hero { flex-direction: column; align-items: flex-start; }
  .title-poster { width: 120px; }

  /* Tables → readable on small screens */
  .ratings-table th,
  .ratings-table td { padding: 0.5rem 0.6rem; font-size: 0.8rem; }
}

/* Small mobile (≤ 400px) */
@media (max-width: 400px) {
  .nav-links--primary .nav-link { font-size: 0.68rem; padding: 0.2rem 0.3rem; }
}

/* Nav login/register buttons — compact on mobile */
@media (max-width: 600px) {
  .nav-row-top--guest {
    align-items: center;
  }
  .nav-links .btn-ghost-sm,
  .nav-links .btn-primary-sm {
    font-size: 0.78rem;
    padding: 0.3rem 0.7rem;
    height: auto;
    border-radius: 6px;
  }
}

/* Narrow mobile (≤ 480px) — profile stats tighten */
@media (max-width: 480px) {
  .feed-body {
    flex-direction: column;
  }
  .feed-body .title-poster {
    width: 100%;
    height: auto;
    max-height: 288px;
    object-fit: contain;
    border-radius: 6px;
    background: transparent;
  }
  #rating-items .title-poster {
    background: transparent;
  }
  .contrast-block { display:flex; flex-direction: column; align-items: center; gap: 2rem; padding: 2.5rem 1.5rem; }
  .contrast-side { text-align: center; }
  .contrast-label { white-space: nowrap; letter-spacing: 0.08em; }
  .contrast-vs { font-size: 1.1rem; }
  .how-steps--four { grid-template-columns: 1fr; max-width: 380px; margin-inline: auto; }
  .standalone-tagline { padding: 2.5rem 1.25rem; }
  .profile-stats { gap: 1rem; }
  .doiwatch-poster {
    width: 100%;
    height: auto;
    max-height: none;
    object-fit: contain;
    max-width: 260px;
    margin: 0 auto;
  }
}

/* ==========================================================================
   Modal
   ========================================================================== */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-overlay[hidden] { display: none; }

.modal-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 2rem;
  max-width: 320px;
  width: 90%;
  text-align: center;
}

.modal-message {
  font-size: 1rem;
  margin-bottom: 1.5rem;
  color: var(--text);
}

.modal-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
}

/* ==========================================================================
   Admin UI
   ========================================================================== */

.admin-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem 0;
}

.admin-header {
  display: flex;
  align-items: center;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.admin-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.admin-nav {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.75rem;
}

.admin-nav a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
  transition: background 0.15s, color 0.15s;
}

.admin-nav a:hover { background: var(--surface-2); color: var(--text-primary); }
.admin-nav a.active { background: var(--surface-2); color: var(--text-primary); font-weight: 600; }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  background: var(--surface-1);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.25rem 1rem;
  text-align: center;
}

.stat-value {
  font-family: 'DM Serif Display', serif;
  font-size: 2rem;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 0.35rem;
}

.stat-label {
  font-size: 0.78rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.admin-table th {
  text-align: left;
  padding: 0.5rem 0.75rem;
  border-bottom: 2px solid var(--border);
  color: var(--text-dim);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 600;
}

.admin-table td {
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: var(--surface-1); }

.badge-verified {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  background: #14532d22;
  color: #4ade80;
  border: 1px solid #4ade8044;
}

.badge-unverified {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  background: #78350f22;
  color: #fb923c;
  border: 1px solid #fb923c44;
}

.btn-danger-sm {
  display: inline-flex;
  align-items: center;
  padding: 0 0.875rem;
  height: 32px;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 500;
  background: transparent;
  color: #f87171;
  border: 1px solid #f8717155;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}

.btn-danger-sm:hover {
  background: #f8717120;
  color: #fca5a5;
  border-color: #f87171;
}

.pagination {
  display: flex;
  gap: 0.5rem;
  margin-top: 1.5rem;
  align-items: center;
}

.pagination a {
  padding: 0.3rem 0.65rem;
  border-radius: 5px;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
}

.pagination a:hover { background: var(--surface-2); }
.pagination strong {
  padding: 0.3rem 0.65rem;
  border-radius: 5px;
  background: var(--surface-2);
  color: var(--text-primary);
  font-size: 0.85rem;
}
.pagination-ellipsis {
  padding: 0.3rem 0.25rem;
  font-size: 0.85rem;
  color: var(--text-dim);
  user-select: none;
}
.email-obf { unicode-bidi: bidi-override; }

/* Admin filter bar -------------------------------------------------------- */

.admin-filter-bar {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.admin-filter-input {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 6px;
  padding: 0.4rem 0.75rem;
  font-size: 0.85rem;
  font-family: inherit;
  flex: 1;
  min-width: 200px;
  outline: none;
  transition: border-color 0.15s;
}

.admin-filter-input:focus { border-color: var(--accent); }

.admin-filter-select {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 6px;
  padding: 0.4rem 0.75rem;
  font-size: 0.85rem;
  font-family: inherit;
  outline: none;
  cursor: pointer;
}

/* Discover page ------------------------------------------------------------ */

.discover-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem 1rem;
}

.discover-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.discover-title {
  font-family: 'DM Serif Display', serif;
  font-size: 1.8rem;
}

.type-tabs {
  display: flex;
  gap: 0.25rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.25rem;
}

.type-tab {
  padding: 0.35rem 1rem;
  border-radius: 6px;
  font-size: 0.85rem;
  color: var(--text-dim);
  text-decoration: none;
  transition: all 0.15s;
}

.type-tab--active {
  background: var(--accent);
  color: #0f1117;
  font-weight: 600;
}

.type-tab:hover:not(.type-tab--active) { color: var(--accent); }

.discover-section { margin-bottom: 3rem; }

.discover-section-title {
  font-family: 'DM Serif Display', serif;
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
  color: var(--text);
}

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

.discover-card { display: flex; flex-direction: column; gap: 0.5rem; }

.discover-poster {
  width: 100%;
  aspect-ratio: 2/3;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--border-soft);
  display: block;
  transition: opacity 0.15s;
}

.discover-poster:hover { opacity: 0.85; }

.discover-poster--placeholder {
  background: var(--surface);
}

.discover-card-info {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.discover-card-title {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  line-height: 1.3;
}

.discover-card-title:hover { color: var(--accent); }

.discover-card-year {
  font-size: 0.72rem;
  color: var(--text-dim);
}

.discover-card-overview {
  font-size: 0.72rem;
  color: var(--text-dim);
  line-height: 1.5;
  margin-top: 0.2rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.discover-card-score {
  font-size: 0.78rem;
  color: var(--accent);
  font-weight: 600;
}

.discover-card-denom {
  font-size: 0.7rem;
  font-weight: 400;
  color: var(--text-dim);
}

.discover-card-count {
  font-size: 0.7rem;
  color: var(--text-dim);
  font-weight: 400;
}

.discover-card-watchers {
  font-size: 0.72rem;
  color: var(--text-dim);
}

@media (max-width: 640px) {
  .discover-grid {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 0.875rem;
  }
}

/* Site footer -------------------------------------------------------------- */

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.35rem 0.5rem;
  padding: 1.5rem 1rem 2rem;
  border-top: 1px solid var(--border-soft);
  margin-top: 3rem;
}

.footer-sep {
  color: var(--text-dim);
  opacity: 0.4;
}

.site-footer a,
.footer-copy {
  white-space: nowrap;
  font-size: 0.78rem;
  color: var(--text-dim);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--text);
  text-decoration: none;
}

@media (max-width: 380px) {
  .footer-sep { display: none; }
  .site-footer { gap: 0.4rem 0.75rem; }
}

/* Static pages (privacy policy, etc.) ------------------------------------- */

.static-page {
  max-width: 680px;
  margin: 0 auto;
  padding: 2rem 1rem 4rem;
}

.static-title {
  font-family: 'DM Serif Display', serif;
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.static-meta {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 2.5rem;
}

.static-page h2 {
  font-family: 'DM Serif Display', serif;
  font-size: 1.2rem;
  margin-top: 2rem;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.static-page p,
.static-page li {
  font-size: 0.9rem;
  color: var(--text-dim);
  line-height: 1.7;
}

.static-page ul {
  padding-left: 1.25rem;
  margin-bottom: 1rem;
}

.static-page a { color: var(--accent); }

/* Changelog ----------------------------------------------------------------- */

.changelog-entry {
  margin-bottom: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--border-soft);
}

.changelog-entry:last-child {
  border-bottom: none;
}

.changelog-version-row {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.changelog-version {
  font-family: 'DM Serif Display', serif;
  font-size: 1.2rem;
  color: var(--text);
}

.changelog-date {
  font-size: 0.78rem;
  color: var(--text-dim);
}

.changelog-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.changelog-list li {
  font-size: 0.875rem;
  color: var(--text-dim);
  line-height: 1.6;
  padding-left: 1rem;
  position: relative;
}

.changelog-list li::before {
  content: '\00b7';
  position: absolute;
  left: 0;
  color: var(--accent);
}

.changelog-list strong {
  color: var(--text);
  font-weight: 600;
}

.changelog-entry--coming .changelog-version {
  color: var(--accent);
}

.changelog-entry--coming .changelog-list li::before {
  content: '\2192';
}

/* Original title (foreign language) ---------------------------------------- */

.title-original {
  font-size: 0.75em;
  color: var(--text-muted);
  font-style: italic;
  font-weight: 400;
  margin-left: 0.25rem;
}

.feed-title .title-original,
.rating-title .title-original {
  font-size: 0.8rem;
}

/* ==========================================================================
   doIwatch page (/doiwatch)
   ========================================================================== */

.doiwatch-page {
  max-width: 860px;
  margin: 0 auto;
  padding: 1.5rem 1rem;
}

.page-intro {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
  max-width: 520px;
}

/* Filter bar */
.doiwatch-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  margin-bottom: 1.5rem;
  align-items: center;
}

.doiwatch-filter-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.doiwatch-filter-label {
  font-size: 0.75rem;
  color: var(--text-dim);
  white-space: nowrap;
  font-weight: 500;
}

.doiwatch-filter-pills {
  display: flex;
  gap: 0.2rem;
}

.pill {
  font-size: 0.78rem;
  padding: 0.25rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s;
  white-space: nowrap;
}

.pill:hover { border-color: var(--accent); color: var(--accent); }

.pill--active {
  border-color: var(--accent);
  background: rgba(0, 180, 200, 0.12);
  color: var(--accent);
}

/* Card */
.doiwatch-card {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  overflow: hidden;
  margin-top: 1rem;
}

.doiwatch-card-inner {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  min-height: 330px;
}

/* Poster */
.doiwatch-poster-wrap {
  flex-shrink: 0;
  width: 220px;
}

.doiwatch-poster {
  width: 220px;
  height: 330px;
  object-fit: cover;
  object-position: center top;
  display: block;
  border-radius: 8px 0 0 8px;
}

.doiwatch-poster--placeholder {
  width: 220px;
  height: 330px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  font-size: 3rem;
  border-radius: 8px 0 0 8px;
}

/* Info panel */
.doiwatch-info {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
  min-width: 0;
}

.doiwatch-title {
  font-family: 'DM Serif Display', serif;
  font-size: 1.8rem;
  color: var(--text);
  text-decoration: none;
  line-height: 1.2;
  margin-bottom: 0.1rem;
}

.doiwatch-title:hover { color: var(--accent); }

.doiwatch-meta {
  font-size: 0.78rem;
  color: var(--text-dim);
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.doiwatch-overview {
  font-size: 0.82rem;
  color: var(--text-dim);
  line-height: 1.6;
  margin: 0.25rem 0 0.5rem;
}

.doiwatch-question {
  font-family: 'DM Serif Display', serif;
  font-size: 1rem;
  color: var(--accent);
  margin: 0.5rem 0 0.25rem;
}

/* Network split */
.doiwatch-split {
  display: flex;
  gap: 0;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  overflow: hidden;
  margin-top: 0.25rem;
}

.doiwatch-split-col {
  flex: 1;
  padding: 0.75rem;
}

.doiwatch-split-col--yes {
  border-right: 1px solid var(--border-soft);
}

.doiwatch-split-header {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  margin-bottom: 0.5rem;
}

.doiwatch-split-label {
  font-weight: 700;
  font-size: 0.85rem;
}

.doiwatch-split-label--yes { color: #6abf6a; }
.doiwatch-split-label--no  { color: #bf6a6a; }

.doiwatch-split-sub {
  font-size: 0.7rem;
  color: var(--text-dim);
}

.doiwatch-split-ratings {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.doiwatch-split-rating {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.doiwatch-avatar {
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: white;
  text-decoration: none;
  flex-shrink: 0;
  line-height: 1;
}

.doiwatch-split-user {
  font-size: 0.78rem;
  color: var(--text);
  flex: 1;
}

.doiwatch-split-score {
  font-size: 0.82rem;
  font-weight: 700;
}

.doiwatch-split-score--yes { color: #6abf6a; }
.doiwatch-split-score--no  { color: #bf6a6a; }

.doiwatch-split-empty {
  font-size: 0.75rem;
  color: var(--text-dim);
  font-style: italic;
}

.doiwatch-no-network {
  font-size: 0.82rem;
  color: var(--text-dim);
  font-style: italic;
}

/* Actions */
.doiwatch-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: auto;
  padding-top: 1rem;
  flex-wrap: wrap;
}

/* Empty state */
.doiwatch-empty {
  text-align: center;
  padding: 3rem 1rem;
}

.doiwatch-empty-title {
  font-size: 1.1rem;
  color: var(--text);
  margin-bottom: 0.75rem;
}

.doiwatch-empty-hint {
  font-size: 0.875rem;
  color: var(--text-dim);
  margin-bottom: 0.35rem;
}

/* Mobile */
@media (max-width: 640px) {
  .doiwatch-card-inner {
    flex-direction: column;
  }

  .doiwatch-poster-wrap { width: 100%; }

  .doiwatch-poster {
    width: 100%;
    height: 260px;
    object-position: center top;
    border-radius: 12px 12px 0 0;
  }

  .doiwatch-poster--placeholder {
    width: 100%;
    height: 180px;
    border-radius: 12px 12px 0 0;
  }

  .doiwatch-title { font-size: 1.3rem; }

  .doiwatch-split {
    flex-direction: column;
  }

  .doiwatch-split-col--yes {
    border-right: none;
    border-bottom: 1px solid var(--border-soft);
  }
}

/* Admin — mobile */
@media (max-width: 640px) {
  .admin-nav {
    flex-wrap: wrap;
  }

  .admin-filter-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .admin-filter-input,
  .admin-filter-select {
    min-width: 0;
    width: 100%;
  }
}

/* --------------------------------------------------------------------------
   Terms of Service
   -------------------------------------------------------------------------- */
.terms-body {
  margin-top: 1.5rem;
}

.terms-section {
  margin-bottom: 1.75rem;
}

.terms-section h2 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.terms-section p {
  color: var(--text-muted);
  line-height: 1.65;
}

.terms-section a {
  color: var(--accent);
  text-decoration: none;
}

.terms-section a:hover {
  text-decoration: underline;
}

.terms-link {
  color: var(--accent);
  text-decoration: none;
}

.terms-link:hover {
  text-decoration: underline;
}

.terms-check-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  cursor: pointer;
}

/* ---------------------------------------------------------------------------
   Welcome page
   --------------------------------------------------------------------------- */
.welcome-banner {
  background: rgba(88, 166, 255, 0.08);
  border: 1px solid rgba(88, 166, 255, 0.2);
  border-radius: 0.75rem;
  padding: 0.65rem 1rem;
  font-size: 0.88rem;
  color: var(--muted);
  margin-bottom: 1.25rem;
}
.welcome-banner a {
  color: var(--accent);
  text-decoration: none;
}
.welcome-banner a:hover {
  text-decoration: underline;
}

/* ---------------------------------------------------------------------------
   Share link row (shared/_share_link partial)
   --------------------------------------------------------------------------- */
.share-link-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: nowrap;
  margin: 0.5rem 0;
  min-width: 0;
}
.share-link-url {
  font-family: monospace;
  font-size: 0.88rem;
  word-break: break-all;
  overflow-wrap: break-word;
  min-width: 0;
  color: var(--text);
  text-decoration: none;
}
.share-link-url:hover {
  text-decoration: underline;
}
