@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600&display=swap');

:root {
  --bg-color: #0f1115;
  --bg-elevated: #181b22;
  --accent: #ffcc33;
  --accent-soft: rgba(255, 204, 51, 0.1);
  --text-main: #f5f5f5;
  --text-muted: #a0a4b0;
  --border-subtle: #2a2f3a;
  --danger: #ff6b6b;
  --radius-lg: 12px;
  --radius-md: 8px;
  --shadow-soft: 0 14px 30px rgba(0, 0, 0, 0.45);
  --page-max-width: 1680px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: 'Space Grotesk', 'Segoe UI', sans-serif;
  background: radial-gradient(circle at top, #102347 0%, #060910 55%, #05060d 100%);
  color: #f8fafc;
}

.page-shell {
  width: min(var(--page-max-width), calc(100vw - 2rem));
  max-width: 100%;
  margin: 0 auto;
  padding: 2.5rem clamp(1.5rem, 3vw, 3.5rem) 3.5rem;
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.2rem clamp(1.5rem, 4vw, 3rem);
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(3, 6, 16, 0.92);
  border-bottom: 1px solid var(--border-subtle);
  backdrop-filter: blur(14px);
  font-family: 'Space Grotesk', 'Segoe UI', sans-serif;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav-link {
  color: #94a3c6;
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.02em;
  transition: color 0.15s ease;
}

.nav-link:hover {
  color: #4fd1c5;
}

.nav-link-active {
  color: #f8fafc;
  font-weight: 600;
}

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

.titles h1 {
  margin: 0;
  font-size: 1.2rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.titles p {
  margin: 0.1rem 0 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.header-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.4rem;
  text-align: right;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.report-trigger-btn {
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(15, 23, 42, 0.6);
  color: #e5e7eb;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-size: 0.85rem;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.report-trigger-btn:hover {
  background: rgba(79, 209, 197, 0.15);
  color: #4fd1c5;
}

.nav-user-meta {
  font-size: 0.85rem;
  color: #94a3c6;
}

.view-toggle {
  display: inline-flex;
  padding: 0.15rem;
  background: rgba(6, 7, 14, 0.9);
  border-radius: 999px;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.55);
}

.view-toggle button {
  border: none;
  background: none;
  color: var(--text-muted);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.16s ease, color 0.16s ease, transform 0.12s ease;
}

.view-toggle button.active {
  background: var(--accent-soft);
  color: var(--accent);
  transform: translateY(-1px);
}

#gridView[hidden],
#listView[hidden] {
  display: none !important;
}

.controls {
  padding: 0.9rem 5vw 0.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
}

.search-box {
  flex: 1 1 240px;
  max-width: 380px;
}

.search-box label {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.search-box input {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: rgba(10, 12, 20, 0.95);
  color: var(--text-main);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.filter-group {
  min-width: 140px;
}

.filter-group label {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.filter-group select {
  width: 100%;
  padding: 0.5rem 0.7rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: rgba(10, 12, 20, 0.95);
  color: var(--text-main);
}

main {
  padding: 0.3rem 5vw 2.5rem;
}

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

.card {
  background: linear-gradient(145deg, rgba(18, 21, 30, 0.98), rgba(8, 10, 16, 0.98));
  border-radius: var(--radius-lg);
  padding: 0.6rem;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(255, 255, 255, 0.02);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.card:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.75);
  border-color: rgba(255, 204, 51, 0.4);
}

.card-image-wrapper {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  background: radial-gradient(circle at top, #444, #111);
}

.card-image-wrapper img {
  width: 100%;
  display: block;
}

.card-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.7rem;
  color: var(--text-muted);
}

.card-meta {
  margin-top: 0.55rem;
}

.card-title {
  margin: 0;
  font-size: 0.95rem;
}

.card-subtitle {
  margin: 0.12rem 0 0.1rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-top: 0.25rem;
}

.tag {
  font-size: 0.7rem;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
}

.gallery-list {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.5rem;
  background: rgba(10, 12, 20, 0.95);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}

.gallery-list th,
.gallery-list td {
  padding: 0.45rem 0.7rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  font-size: 0.82rem;
}

.gallery-list th {
  background: rgba(5, 6, 12, 0.9);
  text-align: left;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.7rem;
}

.list-thumb {
  width: 46px;
  height: 46px;
  border-radius: 8px;
  object-fit: cover;
  background: radial-gradient(circle at top, #555, #111);
}

tr.clickable-row {
  cursor: pointer;
}

tr.clickable-row:hover {
  background: rgba(255, 255, 255, 0.02);
}

.empty-state {
  margin-top: 2rem;
  text-align: center;
  color: var(--text-muted);
}

.lightbox {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 50;
}

.lightbox[hidden] {
  display: none !important;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top, rgba(0, 0, 0, 0.25), rgba(0, 0, 0, 0.95));
}

.lightbox-content {
  position: relative;
  max-width: min(960px, 92vw);
  max-height: min(90vh, 640px);
  background: linear-gradient(145deg, #121623, #070812);
  border-radius: 18px;
  padding: 1rem;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 1rem;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.lightbox-content img {
  width: 100%;
  border-radius: 12px;
  background: radial-gradient(circle at top, #555, #111);
}

.lightbox-close {
  position: absolute;
  top: 8px;
  right: 10px;
  border: none;
  background: none;
  color: var(--text-muted);
  font-size: 1.6rem;
  cursor: pointer;
}

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

.lightbox-meta h2 {
  margin-top: 0;
  margin-bottom: 0.4rem;
  color: var(--text-main);
}

.lightbox-meta p {
  margin: 0.15rem 0;
}

.jobs-dept-header td {
  background: rgba(255, 255, 255, 0.04);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  color: var(--text-muted);
  padding: 0.5rem 0.75rem;
}

.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 0.8rem 5vw 1.2rem;
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(5, 6, 12, 0.9);
}

@media (max-width: 720px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.9rem;
  }

  .header-right {
    align-items: flex-start;
    text-align: left;
    width: 100%;
  }

  .nav-links {
    flex-wrap: wrap;
  }

  .controls {
    flex-direction: column;
    align-items: stretch;
  }

  .filters {
    width: 100%;
  }

  .lightbox-content {
    grid-template-columns: 1fr;
    max-height: 90vh;
  }
}
.password-field { position:relative; display:flex; width:100%; }
.password-field input { width:100%; padding-right:2.75rem; }
.password-field .password-toggle { position:absolute; right:0.4rem; top:50%; transform:translateY(-50%); border:none; background:none; color:#94a3b8; cursor:pointer; padding:0.2rem; display:flex; align-items:center; justify-content:center; }
.password-field .password-toggle:focus-visible { outline:2px solid rgba(59,130,246,0.8); outline-offset:2px; }
.password-field .password-toggle-icon { width:1.25rem; height:0.75rem; border:2px solid currentColor; border-radius:999px / 70%; position:relative; display:block; }
.password-field .password-toggle-icon::after { content:""; position:absolute; width:0.35rem; height:0.35rem; border-radius:50%; background:currentColor; top:50%; left:50%; transform:translate(-50%,-50%); }
.password-field.is-revealed .password-toggle { color:#fcd34d; }
.password-field--static input {
  cursor: default;
  border: none;
  background: transparent;
  padding-left: 0;
  color: #f8fafc;
  font-size: 1.05rem;
  font-weight: 600;
  caret-color: transparent;
}
.password-field--static input:focus {
  outline: none;
  box-shadow: none;
}
.account-card-label { margin:0.75rem 0 0.2rem; font-size:0.78rem; letter-spacing:0.12em; text-transform:uppercase; color:#94a3b8; }
.account-card-hint { margin:0.35rem 0 0; font-size:0.8rem; color:#9ca3af; }
