/* Password gate — matches ilhmkdocs modal / header tokens */
:root {
  --ilh-header-bg: #1a1410;
  --ilh-header-border: #5c4a32;
  --ilh-header-text: #e8dcc8;
  --ilh-header-muted: #a89880;
  --ilh-header-gold: #c9a227;
  --ilh-fantasy-bg: #0f0c09;
  --ilh-fantasy-surface: #1a1410;
  --ilh-fantasy-border: #5c4a32;
  --ilh-fantasy-text: #e8dcc8;
  --ilh-fantasy-muted: #a89880;
  --ilh-fantasy-gold: #c9a227;
  --ilh-fantasy-hover: rgba(201, 162, 39, 0.12);
  --ilh-fantasy-shadow: rgba(0, 0, 0, 0.45);
  --ilh-gate-font: "Cormorant Garamond", Georgia, "Times New Roman", serif;
}

html,
body.password-gate-login-page {
  margin: 0;
  min-height: 100vh;
  background: var(--ilh-fantasy-bg);
  color: var(--ilh-fantasy-text);
}

.password-gate-login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  box-sizing: border-box;
  font-family: var(--ilh-gate-font);
  position: relative;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

.password-gate-video-container {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  opacity: 1;
  pointer-events: none;
}

.password-gate-video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translate(-50%, -50%);
  object-fit: cover;
}

.password-gate-video-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      180deg,
      rgba(15, 12, 9, 0.35) 0%,
      rgba(15, 12, 9, 0.55) 100%
    ),
    rgba(8, 6, 4, 0.28);
}

.password-gate-actions {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 2;
}

.password-gate-action-btn {
  appearance: none;
  background: color-mix(in srgb, var(--ilh-fantasy-surface) 88%, transparent);
  border: 1px solid var(--ilh-fantasy-border);
  color: var(--ilh-fantasy-gold);
  cursor: pointer;
  padding: 0.45rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.2rem;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.password-gate-action-btn:hover {
  color: var(--ilh-header-gold);
  background: var(--ilh-fantasy-hover);
  border-color: var(--ilh-fantasy-gold);
}

.password-gate-action-btn:focus-visible {
  outline: 2px solid var(--ilh-header-gold);
  outline-offset: 2px;
}

.password-gate-action-btn.is-off {
  color: var(--ilh-fantasy-muted);
  opacity: 0.8;
}

.password-gate-action-btn svg {
  display: block;
  width: 1.3rem;
  height: 1.3rem;
}

.password-gate-box {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 28rem;
  padding: 0;
  overflow: hidden;
  color: var(--ilh-fantasy-text);
  background: var(--ilh-fantasy-surface);
  border: 1px solid var(--ilh-fantasy-border);
  border-radius: 0.35rem;
  box-shadow: 0 16px 48px var(--ilh-fantasy-shadow);
  box-sizing: border-box;
}

.password-gate-header {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1rem 0.75rem;
  border-bottom: 1px solid var(--ilh-fantasy-border);
  background: var(--ilh-fantasy-bg);
}

.password-gate-title {
  margin: 0;
  font-family: var(--ilh-gate-font);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  line-height: 1.3;
  text-align: center;
  color: var(--ilh-fantasy-gold);
}

.password-gate-body {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem 1.1rem 1.15rem;
}

.password-gate-countdown {
  display: flex;
  justify-content: center;
  gap: 0.4rem;
  margin: 0;
}

.password-gate-countdown-unit {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.55rem 0.2rem;
  background: var(--ilh-fantasy-bg);
  border: 1px solid var(--ilh-fantasy-border);
  border-radius: 0.25rem;
}

.password-gate-countdown-value {
  font-family: var(--ilh-gate-font);
  font-size: 1.35rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ilh-fantasy-gold);
  line-height: 1.2;
}

.password-gate-countdown-label {
  margin-top: 0.3rem;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ilh-fantasy-muted);
}

.password-gate-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.password-gate-input {
  width: 100%;
  padding: 0.55rem 0.7rem;
  font-family: inherit;
  font-size: 1.05rem;
  color: var(--ilh-fantasy-text);
  background: var(--ilh-fantasy-bg);
  border: 1px solid var(--ilh-fantasy-border);
  border-radius: 0.15rem;
  box-sizing: border-box;
}

.password-gate-input::placeholder {
  color: var(--ilh-fantasy-muted);
}

.password-gate-input:focus {
  outline: none;
  border-color: var(--ilh-fantasy-gold);
  box-shadow: 0 0 0 1px var(--ilh-fantasy-gold);
}

.password-gate-btn {
  appearance: none;
  padding: 0.6rem 1rem;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ilh-fantasy-bg);
  background: var(--ilh-fantasy-gold);
  border: 1px solid var(--ilh-fantasy-gold);
  border-radius: 0.15rem;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.password-gate-btn:hover {
  background: #d4b04a;
  border-color: #d4b04a;
}

.password-gate-btn:focus-visible {
  outline: 2px solid var(--ilh-header-gold);
  outline-offset: 2px;
}

.password-gate-error {
  margin: 0;
  font-size: 0.95rem;
  color: #d45c4a;
  text-align: center;
  min-height: 1.25em;
}
