:root {
  color-scheme: dark;
  --bg: #0b0c10;
  --bg-accent: #151821;
  --panel: rgba(17, 20, 28, 0.9);
  --panel-strong: rgba(22, 27, 38, 0.96);
  --text: #f6f3ec;
  --muted: #a3aab8;
  --line: rgba(255, 255, 255, 0.09);
  --accent: #d09241;
  --accent-strong: #f1bd70;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(circle at top, rgba(209, 144, 60, 0.18), transparent 35%),
    linear-gradient(180deg, #12151d 0%, #090a0d 100%);
  color: var(--text);
  font-family: Inter, "Segoe UI", system-ui, sans-serif;
}

body {
  line-height: 1.5;
}

button,
input {
  font: inherit;
}

.shell,
.gallery-shell {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
}

.login-page {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 32px 0;
}

.login-card {
  width: min(560px, 100%);
  padding: 40px;
  background: linear-gradient(180deg, rgba(22, 27, 38, 0.96), rgba(12, 15, 21, 0.96));
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.brand-lockup,
.header-copy {
  display: grid;
  gap: 12px;
}

.brand-lockup {
  margin-bottom: 28px;
}

.brand-inline {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo-mark {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border-radius: 26px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.logo-mark--small {
  width: 64px;
  height: 64px;
  border-radius: 20px;
}

.eyebrow {
  margin: 0;
  color: var(--accent-strong);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.76rem;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: clamp(2rem, 4vw, 3.25rem);
  line-height: 1.08;
}

.subtle-copy,
.header-copy p,
.empty-state p {
  color: var(--muted);
}

.login-form {
  display: grid;
  gap: 14px;
}

.field-label {
  color: var(--muted);
  font-size: 0.95rem;
}

.field-input {
  width: 100%;
  padding: 15px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(6, 8, 12, 0.75);
  color: var(--text);
  outline: none;
}

.field-input:focus {
  border-color: rgba(208, 146, 65, 0.75);
  box-shadow: 0 0 0 4px rgba(208, 146, 65, 0.18);
}

.primary-button,
.video-card,
.video-modal__close,
.text-link {
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease, opacity 150ms ease;
}

.primary-button {
  padding: 15px 18px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #c9802b, #f1bd70);
  color: #1c1308;
  font-weight: 700;
  cursor: pointer;
}

.primary-button:hover,
.primary-button:focus-visible,
.video-card:hover,
.video-card:focus-visible,
.video-modal__close:hover,
.video-modal__close:focus-visible,
.text-link:hover,
.text-link:focus-visible {
  transform: translateY(-1px);
}

.form-error {
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(237, 103, 103, 0.35);
  background: rgba(117, 25, 25, 0.28);
  color: #ffd4d4;
}

.site-header {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 32px 0 18px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: end;
}

.gallery-shell {
  padding-bottom: 40px;
}

.text-link {
  color: var(--accent-strong);
  text-decoration: none;
}

.video-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.video-card {
  width: 100%;
  padding: 14px;
  display: grid;
  gap: 14px;
  background: linear-gradient(180deg, rgba(21, 24, 33, 0.94), rgba(12, 14, 19, 0.98));
  border: 1px solid var(--line);
  border-radius: 22px;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.2);
}

.video-card__media {
  aspect-ratio: 25 / 14;
  border-radius: 16px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: #090b10;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.video-card__media img,
.video-card__placeholder {
  width: 100%;
  height: 100%;
  display: block;
}

.video-card__media img {
  object-fit: contain;
}

.video-card__placeholder {
  display: grid;
  place-items: center;
  color: var(--muted);
  background:
    radial-gradient(circle at top, rgba(208, 146, 65, 0.12), transparent 40%),
    rgba(9, 11, 16, 0.96);
}

.video-card__title {
  font-size: 1rem;
  font-weight: 600;
}

.video-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 0.88rem;
}

.empty-state {
  padding: 38px;
  background: var(--panel-strong);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.empty-state code {
  padding: 0.18rem 0.45rem;
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.08);
}

.video-modal[hidden] {
  display: none;
}

.video-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
}

.video-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
}

.video-modal__dialog {
  position: relative;
  z-index: 1;
  width: min(1100px, calc(100vw - 24px));
  margin: 4vh auto;
  padding: 18px 18px 14px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(10, 12, 17, 0.96);
  box-shadow: var(--shadow);
}

.video-modal__header {
  margin: 0 48px 14px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.video-modal__dialog h2 {
  margin: 0;
}

.video-modal__download {
  padding: 10px 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  text-decoration: none;
}

.video-modal__dialog video {
  width: 100%;
  max-height: 78vh;
  display: block;
  background: #000;
  border-radius: 16px;
}

.video-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  cursor: pointer;
}

@media (max-width: 760px) {
  .login-card,
  .empty-state {
    padding: 26px;
  }

  .site-header {
    padding-top: 22px;
    flex-direction: column;
    align-items: stretch;
  }

  .brand-inline {
    align-items: flex-start;
  }

  .video-modal__header {
    margin-right: 0;
    align-items: flex-start;
    flex-direction: column;
  }
}
