/* ============================================================
   Bit News — Dark-first modern design system
   ============================================================ */

:root {
  color-scheme: dark;

  --font: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;

  /* Dark (default) palette */
  --bg: #0a0e17;
  --bg-glow: radial-gradient(1200px 500px at 50% -10%, rgba(45, 90, 170, 0.14), transparent 60%);
  --surface: #111826;
  --surface-2: #16202f;
  --surface-3: #1c2739;
  --border: #223047;
  --border-soft: #1a2436;

  --text: #e8eef7;
  --text-secondary: #9ba9c0;
  --text-tertiary: #6d7c96;

  --accent: #4da3ff;
  --accent-hover: #6fb4ff;
  --accent-soft: rgba(77, 163, 255, 0.14);
  --accent-border: rgba(77, 163, 255, 0.35);

  --success: #34d399;
  --success-bg: rgba(52, 211, 153, 0.12);
  --danger: #f87171;
  --danger-bg: rgba(248, 113, 113, 0.12);
  --warning: #fbbf24;
  --warning-bg: rgba(251, 191, 36, 0.12);

  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 18px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 6px 20px rgba(0, 0, 0, 0.28);
  --shadow-lg: 0 14px 40px rgba(0, 0, 0, 0.35);

  --header-h: 64px;
  --ease: 0.18s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  color-scheme: light;

  --bg: #f5f7fb;
  --bg-glow: radial-gradient(1200px 500px at 50% -10%, rgba(37, 99, 235, 0.08), transparent 60%);
  --surface: #ffffff;
  --surface-2: #f1f5fa;
  --surface-3: #e8eef6;
  --border: #dbe3ef;
  --border-soft: #e9eef6;

  --text: #0f172a;
  --text-secondary: #47566b;
  --text-tertiary: #8a99b0;

  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --accent-soft: rgba(37, 99, 235, 0.1);
  --accent-border: rgba(37, 99, 235, 0.3);

  --success: #059669;
  --success-bg: rgba(5, 150, 105, 0.1);
  --danger: #dc2626;
  --danger-bg: rgba(220, 38, 38, 0.08);
  --warning: #b45309;
  --warning-bg: rgba(245, 158, 11, 0.12);

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 6px 20px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 14px 40px rgba(15, 23, 42, 0.1);
}

/* ---------- Reset ---------- */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  transition: background var(--ease), color var(--ease);
}

::selection {
  background: var(--accent);
  color: #fff;
}

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

a:hover {
  color: var(--accent-hover);
}

button {
  font-family: inherit;
}

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

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---------- Shell / layout ---------- */

.page-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-image: var(--bg-glow);
  background-color: var(--bg);
  transition: background var(--ease);
}

.container {
  width: min(100%, 1200px);
  margin: 0 auto;
  padding: 20px 24px;
}

main {
  flex: 1;
  padding: 24px 0 56px;
}

/* ============================================================
   Header
   ============================================================ */

/* Top banner bar (above the nav) */
.top-banner {
  background: var(--accent-soft);
  border-bottom: 1px solid var(--accent-border);
}

.top-banner-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 36px;
  text-align: center;
}

.top-banner-message {
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
}

.top-banner-status {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: var(--radius-pill);
  background: var(--warning-bg);
  color: var(--warning);
  white-space: nowrap;
}

.top-banner.is-announce {
  background: var(--accent-soft);
  border-bottom-color: var(--accent-border);
}

.top-banner.is-announce .top-banner-message {
  color: var(--accent);
}

.top-banner.is-warning {
  background: var(--warning-bg);
  border-bottom-color: rgba(251, 191, 36, 0.35);
}

.top-banner.is-warning .top-banner-message {
  color: var(--warning);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(10, 14, 23, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-soft);
}

[data-theme="light"] .site-header {
  background: rgba(255, 255, 255, 0.82);
}

.header-inner {
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand-block {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
}

.brand-logo-img {
  height: 40px;
  width: auto;
  display: block;
}

.server-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text-secondary);
  white-space: nowrap;
  line-height: 1.4;
}

.server-status.online {
  color: #4ade80;
  border-color: #4ade80;
  background: rgba(74, 222, 128, 0.1);
}

.server-status.offline {
  color: #f87171;
  border-color: #f87171;
  background: rgba(248, 113, 113, 0.1);
}

.server-status.maintenance {
  color: #facc15;
  border-color: #facc15;
  background: rgba(250, 204, 21, 0.1);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.desktop-nav a {
  color: var(--text-secondary);
  font-size: 0.92rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: color var(--ease), background var(--ease);
}

.desktop-nav a:hover {
  color: var(--text);
  background: var(--surface-2);
}

.desktop-nav a.active {
  color: var(--accent);
  background: var(--accent-soft);
}

/* Nav dropdown (ควบคุม) */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 0.92rem;
  font-weight: 600;
  font-family: inherit;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: color var(--ease), background var(--ease);
}

.nav-dropdown-toggle:hover {
  color: var(--text);
  background: var(--surface-2);
}

.nav-dropdown-toggle.active {
  color: var(--accent);
  background: var(--accent-soft);
}

.nav-caret {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  display: block;
  transition: transform var(--ease);
}

.nav-dropdown.open .nav-caret {
  transform: rotate(180deg);
}

.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 190px;
  padding: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 100;
  flex-direction: column;
  gap: 2px;
}

.nav-dropdown.open .nav-dropdown-menu {
  display: flex;
}

.desktop-nav .nav-dropdown-menu a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  transition: color var(--ease), background var(--ease);
}

.desktop-nav .nav-dropdown-menu a:hover {
  color: var(--text);
  background: var(--surface-2);
}

.desktop-nav .nav-dropdown-menu a.active {
  color: var(--accent);
  background: var(--accent-soft);
}

.mobile-nav .nav-dropdown-toggle {
  width: 100%;
  justify-content: flex-start;
  padding: 12px 10px;
  font-size: 0.95rem;
  border-radius: var(--radius-sm);
}

.mobile-nav .nav-dropdown-menu {
  position: static;
  width: 100%;
  min-width: 0;
  padding: 4px 0 4px 16px;
  border: none;
  box-shadow: none;
  background: transparent;
}

.mobile-nav .nav-dropdown-menu a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 10px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.95rem;
}

.mobile-nav .nav-dropdown-menu a:hover {
  background: var(--surface-2);
  color: var(--text);
}

.mobile-nav .nav-dropdown-menu a.active {
  color: var(--accent);
  background: var(--accent-soft);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-banner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 6px 12px;
  max-width: 260px;
}

.header-banner .banner-message {
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.header-banner .banner-status {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  background: var(--warning-bg);
  color: var(--warning);
  white-space: nowrap;
}

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
}

.user-chip::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
}

.user-chip svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  cursor: pointer;
  transition: color var(--ease), border-color var(--ease), background var(--ease);
}

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

.theme-toggle svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.theme-icon-dark {
  display: block;
}

.theme-icon-light {
  display: none;
}

[data-theme="light"] .theme-icon-dark {
  display: none;
}

[data-theme="light"] .theme-icon-light {
  display: block;
}

.mobile-menu-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.mobile-menu-toggle .menu-icon {
  width: 18px;
  height: 18px;
  display: block;
}

.mobile-menu-toggle .menu-icon line {
  transition: transform var(--ease), opacity var(--ease);
  transform-origin: center;
}

.mobile-menu-toggle.active .menu-icon line:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.mobile-menu-toggle.active .menu-icon line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.mobile-menu-toggle.active .menu-icon line:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* Mobile nav */
.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 12px 24px 20px;
  border-top: 1px solid var(--border-soft);
}

.mobile-nav.open {
  display: flex;
}

.mobile-nav a {
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 12px 10px;
  border-radius: var(--radius-sm);
}

.mobile-nav a:hover {
  background: var(--surface-2);
  color: var(--text);
}

.mobile-nav a.active {
  color: var(--accent);
  background: var(--accent-soft);
}

.mobile-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-bottom: 8px;
  color: var(--text-secondary);
  font-size: 0.82rem;
}

.mobile-banner .banner-status {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  background: var(--warning-bg);
  color: var(--warning);
}

/* ============================================================
   Typography / page heading
   ============================================================ */

.page-heading,
.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

.page-heading h1,
.section-header h2 {
  margin: 0;
  font-size: clamp(1.6rem, 2.6vw, 2.1rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.page-heading p,
.section-header p {
  margin: 6px 0 0;
  color: var(--text-secondary);
}

.eyebrow {
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--accent);
}

/* ============================================================
   Cards (shared)
   ============================================================ */

.panel-card,
.page-card,
.form-card,
.info-card,
.sign-in-card,
.news-item {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.panel-card,
.page-card,
.form-card,
.info-card,
.sign-in-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.panel-card span {
  color: var(--text-tertiary);
  font-size: 0.85rem;
}

.panel-card strong {
  font-size: 1.05rem;
  color: var(--text);
}

.panel-card.warning strong {
  color: var(--danger);
}

.page-card h1,
.form-card h2,
.info-card h2 {
  margin: 0;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
}

.page-card p,
.form-card p,
.info-card p {
  margin: 0;
  color: var(--text-secondary);
}

/* ============================================================
   Hero (home)
   ============================================================ */

.hero {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 32px;
  align-items: center;
  background:
    radial-gradient(800px 300px at 0% 0%, var(--accent-soft), transparent 60%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px;
  margin-bottom: 32px;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hero .eyebrow {
  margin-bottom: 2px;
}

.hero h1 {
  margin: 0;
  font-size: clamp(2rem, 3.6vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.hero p {
  margin: 0;
  max-width: 620px;
  color: var(--text-secondary);
  font-size: 1.02rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.hero-panel {
  display: grid;
  gap: 14px;
}

/* ============================================================
   Buttons
   ============================================================ */

button,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--accent);
  color: #fff;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: 11px 18px;
  cursor: pointer;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1;
  transition: background var(--ease), transform var(--ease), border-color var(--ease), color var(--ease);
}

button:hover,
.button:hover {
  background: var(--accent-hover);
}

button:active,
.button:active {
  transform: translateY(1px);
}

button:disabled,
.button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.button svg,
.btn svg,
svg.btn-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  display: block;
}

.nav-icon,
.admin-nav-icon,
.user-chip-icon,
.flash-icon,
.icon-search,
.top-banner-icon,
.theme-icon,
.menu-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  display: block;
}

.button.secondary {
  background: var(--surface-2);
  color: var(--text-secondary);
  border-color: var(--border);
}

.button.secondary:hover {
  background: var(--surface-3);
  color: var(--text);
}

.link-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: var(--radius-sm);
  padding: 10px 16px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: background var(--ease), color var(--ease);
}

.link-button:hover {
  background: var(--accent-border);
  color: var(--accent);
}

.link-button .icon {
  font-size: 1.05em;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}

/* ============================================================
   News grid / items
   ============================================================ */

.news-grid,
.admin-grid,
.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}

.news-item {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  overflow: hidden;
  transition: border-color var(--ease), box-shadow var(--ease), transform var(--ease);
}

.news-item:hover {
  border-color: var(--border);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.news-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0.8;
}

.news-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: var(--radius);
  margin: 4px 0;
  background: var(--surface-2);
}

.news-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px;
}

.news-gallery .news-image {
  height: 140px;
  margin: 0;
}

.news-item h2,
.news-item h3 {
  margin: 0;
  font-size: 1.2rem;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.news-item p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.93rem;
}

.news-excerpt {
  font-size: 0.93rem;
}

.meta {
  margin-top: 4px;
  color: var(--text-tertiary);
  font-size: 0.82rem;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.meta .dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--text-tertiary);
}

.read-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.88rem;
  margin-top: auto;
  transition: gap var(--ease);
}

.read-more:hover {
  gap: 10px;
}

.read-more svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
  transition: transform var(--ease);
}

.read-more:hover svg {
  transform: translateX(2px);
}

/* ============================================================
   News detail
   ============================================================ */

.detail-card {
  max-width: 760px;
  margin: 0 auto;
  padding: 32px;
}

.detail-card::before {
  display: none;
}

.detail-card:hover {
  transform: none;
  box-shadow: var(--shadow-sm);
  border-color: var(--border-soft);
}

.detail-card .news-image {
  height: 300px;
}

.detail-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.detail-content {
  margin-top: 16px;
  color: var(--text-secondary);
  line-height: 1.85;
  white-space: pre-line;
}

/* ============================================================
   Search
   ============================================================ */

.search-wrap {
  position: relative;
  margin-bottom: 24px;
  max-width: 560px;
}

.search-wrap .icon-search {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 14px;
  height: 14px;
  fill: var(--text-tertiary);
  pointer-events: none;
}

#news-search {
  width: 100%;
  padding: 12px 16px 12px 42px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.95rem;
  transition: border-color var(--ease), box-shadow var(--ease);
}

#news-search::placeholder {
  color: var(--text-tertiary);
}

#news-search:focus {
  outline: none;
  border-color: var(--accent-border);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

/* ============================================================
   Forms
   ============================================================ */

label {
  display: block;
  margin-top: 16px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
}

input[type="text"],
input[type="password"],
textarea,
select {
  width: 100%;
  padding: 12px 14px;
  margin-top: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color var(--ease), box-shadow var(--ease), background var(--ease);
}

input[type="text"]::placeholder,
input[type="password"]::placeholder,
textarea::placeholder {
  color: var(--text-tertiary);
}

input[type="text"]:focus,
input[type="password"]:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent-border);
  box-shadow: 0 0 0 3px var(--accent-soft);
  background: var(--surface);
}

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

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  cursor: pointer;
  color: var(--text);
}

input[type="checkbox"] {
  width: 17px;
  height: 17px;
  accent-color: var(--accent);
  cursor: pointer;
}

/* ============================================================
   Auth / centered pages
   ============================================================ */

.auth-page,
.staff-new-page {
  display: grid;
  place-items: center;
  min-height: calc(100vh - 240px);
  padding: 40px 0;
}

.sign-in-card,
.page-card {
  width: 100%;
  max-width: 480px;
}

/* ============================================================
   Admin dashboard
   ============================================================ */

.admin-grid {
  grid-template-columns: 1.2fr 0.9fr;
}

.form-card h2 {
  margin-bottom: 2px;
}

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

.section-highlight {
  display: grid;
  gap: 14px;
  margin-bottom: 32px;
}

.section-highlight .panel-card {
  padding: 22px;
}

/* ============================================================
   Badges
   ============================================================ */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
}

.badge.ok {
  background: var(--success-bg);
  color: var(--success);
}

.badge.warning {
  background: var(--warning-bg);
  color: var(--warning);
}

.badge.role-admin {
  background: var(--accent-soft);
  color: var(--accent);
}

.badge.role-staff {
  background: var(--surface-3);
  color: var(--text-secondary);
}

.badge.suspended {
  background: var(--danger-bg);
  color: var(--danger);
}

/* ============================================================
   Admin backend
   ============================================================ */

.admin-nav {
  display: flex;
  gap: 6px;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 6px;
  margin-bottom: 24px;
  overflow-x: auto;
}

.admin-nav a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  transition: color var(--ease), background var(--ease);
}

.admin-nav a:hover {
  color: var(--text);
  background: var(--surface-2);
}

.admin-nav a.active {
  color: var(--accent);
  background: var(--accent-soft);
}

/* Stats */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-label {
  color: var(--text-tertiary);
  font-size: 0.8rem;
  font-weight: 600;
}

.stat-value {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--accent);
}

.stat-card.is-warn .stat-value {
  color: var(--warning);
}

/* Quick links */
.quick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}

.quick-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  color: var(--text);
  transition: border-color var(--ease), transform var(--ease);
}

.quick-card:hover {
  border-color: var(--accent-border);
  transform: translateY(-2px);
  color: var(--text);
}

.quick-card strong {
  font-size: 1rem;
}

.quick-card span {
  color: var(--text-tertiary);
  font-size: 0.82rem;
}

/* Tables */
.table-wrap {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  overflow: hidden;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.data-table thead th {
  text-align: left;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-tertiary);
  font-weight: 700;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-soft);
  background: var(--surface-2);
  white-space: nowrap;
}

.data-table tbody td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: middle;
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

.data-table tbody tr:hover {
  background: var(--surface-2);
}

.data-table .ta-r {
  text-align: right;
}

.cell-title {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
}

.cell-title > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.cell-title strong {
  font-size: 0.93rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cell-sub {
  color: var(--text-tertiary);
  font-size: 0.8rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cell-thumb {
  width: 48px;
  height: 36px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  background: var(--surface-2);
}

.cell-date {
  color: var(--text-tertiary);
  font-size: 0.82rem;
  white-space: nowrap;
}

.cell-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.cell-actions form {
  margin: 0;
}

.avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
  flex-shrink: 0;
}

.cell-thumb {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

/* Small / tonal buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--accent);
  color: #fff;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: 11px 18px;
  cursor: pointer;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1;
  transition: background var(--ease), border-color var(--ease), color var(--ease), transform var(--ease);
}

.btn:hover {
  background: var(--accent-hover);
}

.btn:active {
  transform: translateY(1px);
}

.btn-sm {
  padding: 7px 12px;
  font-size: 0.8rem;
}

.btn-danger {
  background: transparent;
  color: var(--danger);
  border-color: rgba(248, 113, 113, 0.4);
}

.btn-danger:hover {
  background: var(--danger-bg);
  color: var(--danger);
}

.btn-warn {
  background: transparent;
  color: var(--warning);
  border-color: rgba(251, 191, 36, 0.4);
}

.btn-warn:hover {
  background: var(--warning-bg);
  color: var(--warning);
}

.btn-ok {
  background: transparent;
  color: var(--success);
  border-color: rgba(52, 211, 153, 0.4);
}

.btn-ok:hover {
  background: var(--success-bg);
  color: var(--success);
}

/* ============================================================
   Flash messages
   ============================================================ */

.flash {
  padding: 14px 18px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  margin-bottom: 20px;
  font-weight: 600;
  font-size: 0.92rem;
  animation: slideDown 0.3s ease;
}

.flash.success {
  background: var(--success-bg);
  border-color: rgba(52, 211, 153, 0.3);
  color: var(--success);
}

.flash.error {
  background: var(--danger-bg);
  border-color: rgba(248, 113, 113, 0.3);
  color: var(--danger);
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.delete-form {
  margin-top: 14px;
}

/* ============================================================
   Footer
   ============================================================ */

.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border-soft);
  margin-top: auto;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  flex-wrap: wrap;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text);
}

.footer-brand svg {
  width: 16px;
  height: 16px;
  fill: var(--accent);
}

.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-weight: 500;
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-note {
  color: var(--text-tertiary);
  font-size: 0.82rem;
  text-align: center;
  width: 100%;
  padding: 0 24px 20px;
}

/* Server Status */
.status-page {
  max-width: 900px;
  margin: 0 auto;
}

.status-overview {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.status-hero {
  background: linear-gradient(135deg, var(--surface-2), var(--surface-3));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  box-shadow: var(--shadow-sm);
}

.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 12px 24px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 2px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.status-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 12px currentColor;
}

.status-indicator.online .status-dot {
  background: #4ade80;
  box-shadow: 0 0 16px #4ade80;
  animation: pulse-green 2s infinite;
}

.status-indicator.offline .status-dot {
  background: #f87171;
  box-shadow: 0 0 16px #f87171;
}

.status-indicator.maintenance .status-dot {
  background: #facc15;
  box-shadow: 0 0 16px #facc15;
  animation: pulse-yellow 1.5s infinite;
}

.status-indicator.online { color: #4ade80; border-color: #4ade80; }
.status-indicator.offline { color: #f87171; border-color: #f87171; }
.status-indicator.maintenance { color: #facc15; border-color: #facc15; }

.status-text {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.status-meta {
  display: flex;
  gap: 24px;
}

.meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.meta-label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.meta-value {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text);
}

.staff-panel {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.staff-panel > h2 {
  margin: 0 0 18px;
  font-size: 1.1rem;
  font-weight: 800;
}

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

.working-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  transition: transform var(--ease), border-color var(--ease), box-shadow var(--ease);
}

.working-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.working-avatar {
  position: relative;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  overflow: visible;
  background: var(--surface-2);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.working-avatar img,
.avatar-fallback {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.avatar-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--accent);
  background: var(--accent-soft);
}

.online-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #4ade80;
  border: 2px solid var(--surface-3);
  box-shadow: 0 0 8px #4ade80;
  animation: pulse-green 2s infinite;
}

.working-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.working-name {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.working-role {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.working-since {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-top: 2px;
}

.working-since b {
  color: var(--accent);
  font-weight: 800;
}

.working-since-icon {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
  opacity: 0.8;
}

.stat-value--hours {
  font-size: 1.35rem;
  line-height: 1.2;
  align-self: center;
  padding-top: 8px;
  white-space: nowrap;
}

.work-session {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.work-session strong {
  color: var(--accent);
  font-weight: 800;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
  color: var(--text-secondary);
  gap: 8px;
}

.empty-state p {
  margin: 0;
  font-weight: 700;
  font-size: 1rem;
}

.empty-state span {
  font-size: 0.88rem;
  opacity: 0.8;
}

@keyframes pulse-green {
  0%,
  100% {
    box-shadow: 0 0 8px #4ade80;
  }
  50% {
    box-shadow: 0 0 22px #4ade80, 0 0 6px #4ade80;
  }
}

@keyframes pulse-yellow {
  0%,
  100% {
    box-shadow: 0 0 8px #facc15;
  }
  50% {
    box-shadow: 0 0 18px #facc15, 0 0 4px #facc15;
  }
}

@media (max-width: 640px) {
  .status-hero {
    flex-direction: column;
    align-items: flex-start;
    padding: 22px;
  }
  .status-meta {
    width: 100%;
    justify-content: space-between;
  }
}

.refresh-hint {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 7px 14px;
  white-space: nowrap;
}

.status-note {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface-2);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.status-note-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.status-note.online {
  border-color: rgba(74, 222, 128, 0.4);
  background: rgba(74, 222, 128, 0.08);
  color: #4ade80;
}

.status-note.offline {
  border-color: rgba(248, 113, 113, 0.4);
  background: rgba(248, 113, 113, 0.08);
  color: #f87171;
}

.status-note.maintenance {
  border-color: rgba(250, 204, 21, 0.4);
  background: rgba(250, 204, 21, 0.08);
  color: #facc15;
}

.meta-unit {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-left: 2px;
}

.stat-value--time {
  font-size: 1.5rem;
  line-height: 1.2;
  align-self: center;
  padding-top: 8px;
}

.staff-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.staff-panel-head h2 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 800;
}

.staff-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  height: 30px;
  padding: 0 10px;
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 800;
}

/* ============================================================
   News Report
   ============================================================ */

.report-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.report-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  border: 1px solid var(--border);
  background: var(--surface-2);
  transition: color var(--ease), border-color var(--ease), background var(--ease);
}

.report-btn:hover {
  color: #f87171;
  border-color: #f87171;
  background: rgba(248, 113, 113, 0.08);
}

.report-page {
  max-width: 760px;
  margin: 0 auto;
}

.report-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-sm);
}

.report-target {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px 18px;
  border-radius: var(--radius);
  background: var(--surface-2);
  border: 1px solid var(--border);
  margin-bottom: 18px;
}

.report-target-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.report-target-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text);
}

.report-target .badge {
  align-self: flex-start;
}

.report-identity {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  border-radius: var(--radius);
  background: rgba(88, 101, 242, 0.1);
  border: 1px solid rgba(88, 101, 242, 0.35);
  margin-bottom: 22px;
}

.report-identity-icon {
  width: 34px;
  height: 34px;
  color: #5865f2;
  flex-shrink: 0;
}

.report-identity-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}

.report-identity-name {
  display: block;
  font-size: 0.98rem;
  font-weight: 800;
  color: var(--text);
}

.report-identity-id {
  display: block;
  font-size: 0.76rem;
  color: var(--text-secondary);
}

.report-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.report-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}

.report-item.is-resolved {
  opacity: 0.65;
}

.report-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.report-item-head-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.report-code {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  color: var(--text-secondary);
}

.report-item-date {
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.report-item-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.report-item-news {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.report-item-news a {
  color: var(--text);
  text-decoration: none;
}

.report-item-news a:hover {
  color: var(--accent);
}

.report-reason {
  align-self: flex-start;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: var(--radius-pill);
  padding: 3px 10px;
}

.report-reporter {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.report-reporter-icon {
  width: 16px;
  height: 16px;
  color: #5865f2;
}

.report-details {
  margin: 4px 0 0;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}

.report-item-actions {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.report-status-form {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.report-status-form input {
  flex: 1;
}

/* ============================================================
   Report Tracking / Progress
   ============================================================ */

.track-page {
  max-width: 760px;
  margin: 0 auto;
}

.track-form {
  margin-bottom: 4px;
}

.track-hint {
  margin: 12px 0 0;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.track-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  border: 1px solid var(--border);
  background: var(--surface-2);
}

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

.page-heading-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.discord-login-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.discord-identity {
  display: flex;
  align-items: center;
  gap: 12px;
}

.discord-identity > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.discord-identity strong {
  font-size: 0.95rem;
}

.discord-identity span {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.discord-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
  font-size: 1rem;
  flex-shrink: 0;
}

.discord-logo {
  color: #5865f2;
  flex-shrink: 0;
}

.discord-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.button-outline {
  background: var(--surface-2);
  color: var(--text-secondary);
  border-color: var(--border);
}

.button-outline:hover {
  background: var(--surface-3);
  color: var(--text);
  border-color: var(--border);
}

.discord-button {
  background: #5865f2;
}

.discord-button:hover {
  background: #4752c4;
}

.track-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 18px;
  color: var(--text-secondary);
  font-size: 0.82rem;
}

.track-divider::before,
.track-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.progress-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.progress-head > div {
  display: flex;
  align-items: center;
  gap: 12px;
}

.progress-code {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  border-radius: var(--radius-sm);
  padding: 5px 12px;
}

.progress-status {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface-2);
  margin-bottom: 18px;
}

.progress-status strong {
  display: block;
  font-size: 0.98rem;
  font-weight: 800;
}

.progress-status span {
  display: block;
  font-size: 0.84rem;
  color: var(--text-secondary);
  margin-top: 2px;
}

.progress-status-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  flex-shrink: 0;
  background: #facc15;
  box-shadow: 0 0 10px #facc15;
  animation: pulse-yellow 1.5s infinite;
}

.progress-status.open {
  border-color: rgba(250, 204, 21, 0.4);
  background: rgba(250, 204, 21, 0.06);
}

.progress-status.resolved {
  border-color: rgba(74, 222, 128, 0.4);
  background: rgba(74, 222, 128, 0.06);
}

.progress-status.resolved .progress-status-dot {
  background: #4ade80;
  box-shadow: 0 0 10px #4ade80;
  animation: pulse-green 2s infinite;
}

.progress-status.resolved strong {
  color: #4ade80;
}

.report-target-link {
  color: var(--text);
  text-decoration: none;
}

.report-target-link:hover {
  color: var(--accent);
}

.progress-timeline-title {
  margin: 22px 0 14px;
  font-size: 1rem;
  font-weight: 800;
}

.progress-timeline {
  position: relative;
  padding-left: 26px;
}

.progress-timeline::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--border);
}

.timeline-item {
  position: relative;
  padding-bottom: 20px;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: -26px;
  top: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 3px solid #facc15;
}

.timeline-item.is-resolved .timeline-dot {
  border-color: #4ade80;
}

.timeline-content {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
}

.timeline-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 4px;
}

.timeline-head strong {
  font-size: 0.9rem;
  font-weight: 800;
}

.timeline-head span {
  font-size: 0.76rem;
  color: var(--text-secondary);
}

.timeline-content p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

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

@media (max-width: 920px) {
  .desktop-nav {
    display: none;
  }
  .mobile-menu-toggle {
    display: inline-flex;
  }
  .hero {
    grid-template-columns: 1fr;
    padding: 28px;
  }
  .admin-grid {
    grid-template-columns: 1fr;
  }
  .header-banner {
    display: none;
  }
  .footer-inner {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 560px) {
  .container {
    padding: 14px 16px;
  }
  .page-heading,
  .section-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .hero {
    padding: 22px;
  }
  .user-chip {
    display: none;
  }
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--ease);
}

.lightbox.open {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 90vh;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.lightbox-close {
  position: absolute;
  top: 18px;
  right: 24px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 36px;
  cursor: pointer;
  line-height: 1;
}

.news-image {
  cursor: zoom-in;
}
