:root {
  --auth-bg-a: #0c1219;
  --auth-bg-b: #121a24;
  --auth-surface: rgba(20, 28, 39, 0.92);
  --auth-border: #2f3f55;
  --auth-text: #e6edf7;
  --auth-muted: #a7b6cc;
  --auth-accent: #7de0ff;
  --auth-danger: #ff9ca8;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  color: var(--auth-text);
  background:
    radial-gradient(1200px 700px at 8% 8%, #253449 0%, transparent 55%),
    radial-gradient(800px 560px at 92% 18%, #1a2c3f 0%, transparent 60%),
    linear-gradient(170deg, var(--auth-bg-a), var(--auth-bg-b));
  position: relative;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: url("/bak/images/mac10.png") center / cover no-repeat;
  opacity: 0.34;
  pointer-events: none;
  z-index: 0;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 50% 20%, rgba(103, 232, 249, 0.18), transparent 58%);
  pointer-events: none;
  z-index: 0;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1rem;
  position: relative;
  z-index: 1;
}

.auth-card {
  width: min(520px, 100%);
  border: 1px solid var(--auth-border);
  border-radius: 20px;
  padding: 1.5rem;
  background: var(--auth-surface);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.35);
  position: relative;
  overflow: hidden;
}

.cinematic-auth-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: url("/bak/images/mac12.png") center / cover no-repeat;
  opacity: 0.48;
  pointer-events: none;
}

.cinematic-auth-card::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  background: linear-gradient(160deg, rgba(13, 22, 35, 0.55), rgba(11, 19, 31, 0.78));
  pointer-events: none;
}

.cinematic-auth-card > * {
  position: relative;
  z-index: 1;
}

.kicker {
  margin: 0;
  color: var(--auth-accent);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1 {
  margin: 0.35rem 0 0.35rem;
  font-size: clamp(1.35rem, 2.8vw, 1.95rem);
}

.sub {
  margin: 0 0 1rem;
  color: var(--auth-muted);
  line-height: 1.5;
}

.auth-mode-toggle {
  display: flex;
  gap: 0.5rem;
  margin: 0 0 0.9rem;
}

.auth-mode-btn {
  flex: 1;
  margin-top: 0;
  border-radius: 10px;
  border: 1px solid var(--auth-border);
  background: #131d2a;
  color: var(--auth-muted);
  font-weight: 600;
  padding: 0.6rem 0.8rem;
}

.auth-mode-btn.active {
  border-color: #3a86a5;
  color: var(--auth-text);
  background: linear-gradient(180deg, #1e5f79, #184d63);
}

.register-fields {
  margin-bottom: 0.2rem;
}

select {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--auth-border);
  background: #101821;
  color: var(--auth-text);
  padding: 0.78rem 0.86rem;
}

label {
  display: block;
  margin: 0.85rem 0 0.35rem;
  font-size: 0.9rem;
}

input {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--auth-border);
  background: #101821;
  color: var(--auth-text);
  padding: 0.78rem 0.86rem;
}

input:focus {
  outline: 2px solid #2f8cb1;
  outline-offset: 1px;
}

button {
  width: 100%;
  margin-top: 1rem;
  border-radius: 12px;
  border: 1px solid #3a86a5;
  background: linear-gradient(180deg, #1e5f79, #184d63);
  color: white;
  font-weight: 700;
  padding: 0.82rem 1rem;
  cursor: pointer;
}

button:hover {
  filter: brightness(1.08);
}

.message {
  min-height: 1.4rem;
  margin: 0.75rem 0 0;
  color: var(--auth-muted);
}

.message.error {
  color: var(--auth-danger);
}
