:root {
  color-scheme: dark;
  --access-bg: #1a1b1d;
  --access-panel: #111214;
  --access-panel-raised: #151618;
  --access-rule: #323438;
  --access-rule-bright: #56595e;
  --access-text: #f0f0ef;
  --access-muted: #a2a3a5;
  --access-muted-strong: #c8c9ca;
  --access-accent: #9bb8ca;
  --access-accent-strong: #c3d5df;
  --access-danger: #e4a09c;
}

* { box-sizing: border-box; }

html, body { min-width: 320px; min-height: 100%; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 47% 40%, rgba(255, 255, 255, .025), transparent 38%),
    linear-gradient(145deg, #1c1d1f 0%, #141517 52%, #191a1c 100%);
  color: var(--access-text);
  font-family: Inter, "Avenir Next", "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

.access-stage {
  position: relative;
  isolation: isolate;
  display: grid;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  place-items: center;
  overflow: hidden;
  padding: 128px 32px 112px;
  background:
    radial-gradient(circle at 50% 44%, rgba(255, 255, 255, .017), transparent 40%),
    linear-gradient(150deg, #141517, #0f1012);
}

.access-grid {
  position: absolute;
  z-index: -2;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.02) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,.78), rgba(0,0,0,.42));
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.78), rgba(0,0,0,.42));
}

.access-construction { position: absolute; z-index: -1; inset: 0; pointer-events: none; }
.access-construction i { position: absolute; display: block; opacity: .28; background: var(--access-rule-bright); }
.access-construction i:nth-child(1) { top: 14%; left: 5%; width: 31%; height: 1px; }
.access-construction i:nth-child(2) { top: 8%; bottom: 8%; left: 24%; width: 1px; }
.access-construction i:nth-child(3) { top: 8%; bottom: 8%; right: 17%; width: 1px; }
.access-construction i:nth-child(4) { right: 5%; bottom: 16%; width: 28%; height: 1px; }
.access-construction::before,.access-construction::after { position:absolute;width:28px;height:28px;background:linear-gradient(var(--access-rule-bright),var(--access-rule-bright)) center/1px 28px no-repeat,linear-gradient(90deg,var(--access-rule-bright),var(--access-rule-bright)) center/28px 1px no-repeat;opacity:.36;content:""; }.access-construction::before{top:27%;left:14%}.access-construction::after{right:11%;bottom:22%}

.access-brand {
  position: absolute;
  z-index: 2;
  top: 28px;
  left: 48px;
  display: flex;
  min-height: 56px;
  align-items: center;
  gap: 12px;
}
.access-brand img { width: 30px; height: 30px; filter: grayscale(1) brightness(1.22); }
.access-brand span { font-family: Georgia, "Times New Roman", serif; font-size: 1.42rem; letter-spacing: -.055em; }
.access-return {
  position: absolute;
  z-index: 2;
  top: 34px;
  right: 48px;
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 8px;
  padding: 0 17px;
  border: 1px solid var(--access-rule);
  border-radius: 999px;
  background: rgba(16, 17, 19, .42);
  color: var(--access-muted-strong);
  font-size: .76rem;
  font-weight: 620;
  text-decoration: none;
  transition: border-color .16s ease, background .16s ease, color .16s ease;
}
.access-return svg { color: #858b8f; transition: transform .16s ease; }
.access-return:hover { border-color: var(--access-rule-bright); background: rgba(255, 255, 255, .025); color: var(--access-text); }
.access-return:hover svg { transform: translateX(-2px); }
.access-return:focus-visible { outline: 2px solid var(--access-accent-strong); outline-offset: 3px; }

.access-stage::after {
  position: absolute;
  z-index: -1;
  top: 11%;
  right: 10%;
  width: 108px;
  height: 64px;
  opacity: .32;
  background-image: radial-gradient(circle, var(--access-muted-strong) 1px, transparent 1.2px);
  background-size: 22px 22px;
  content: "";
}

.access-card {
  position: relative;
  width: min(100%, 510px);
  padding: clamp(30px, 5vw, 46px);
  border: 1px solid var(--access-rule);
  border-radius: 9px;
  background: rgba(16, 17, 19, .78);
  box-shadow: 0 28px 70px rgba(0, 0, 0, .22);
  backdrop-filter: blur(10px);
}

.access-heading { margin-bottom: 30px; }
.access-title { margin: 0; font-family: "Avenir Next", Avenir, "Segoe UI", sans-serif; font-size: clamp(2.05rem, 5vw, 2.55rem); font-weight: 360; letter-spacing: -.05em; line-height: 1; }
.access-heading p { margin: 14px 0 0; color: var(--access-muted); font-size: .88rem; line-height: 1.5; }
[data-access-view][hidden] { display: none; }

.access-error {
  margin-top: 24px;
  padding: 11px 13px;
  border-left: 2px solid var(--access-danger);
  background: rgba(228, 160, 156, .08);
  color: #f1c0bd;
  font-size: .82rem;
  line-height: 1.45;
}

.access-form { display: grid; gap: 18px; }
.access-field { display: grid; gap: 9px; }
.access-field > span { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.access-field strong { font-size: .8rem; font-weight: 680; }
.access-field small { color: var(--access-muted); font-size: .69rem; letter-spacing: .025em; }
.access-field input {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border: 1px solid var(--access-rule);
  border-radius: 8px;
  outline: 0;
  background: var(--access-panel-raised);
  color: var(--access-text);
  font: inherit;
  transition: border-color .16s ease, box-shadow .16s ease;
}
.access-field input:focus { border-color: #617987; box-shadow: 0 0 0 3px rgba(155, 184, 202, .075); }
.access-divider { display: flex; align-items: center; gap: 12px; color: #68736f; font-size: .66rem; letter-spacing: .1em; text-transform: uppercase; }
.access-divider::before, .access-divider::after { height: 1px; flex: 1; background: var(--access-rule); content: ""; }
.access-form > button[type="submit"] {
  min-height: 48px;
  border: 1px solid var(--access-rule-bright);
  border-radius: 999px;
  background: rgba(19, 20, 22, .58);
  color: var(--access-muted-strong);
  font: 720 .82rem/1 inherit;
  cursor: pointer;
  transition: background .16s ease, transform .16s ease;
}
.access-form > button[type="submit"]:hover { border-color: #617987; background: rgba(155, 184, 202, .055); color: var(--access-accent-strong); }
.access-form > button[type="submit"]:active { transform: translateY(1px); }
.access-form > button[type="submit"]:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
.access-alternative { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--access-rule); color: #777a7e; font-size: .73rem; line-height: 1.5; }
.access-view-switch { display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: transparent; color: var(--access-accent-strong); font: inherit; cursor: pointer; }
.access-view-switch svg { transition: transform .16s ease; }
.access-view-switch:hover { color: var(--access-text); }
.access-view-switch[data-access-switch="personal"]:hover svg { transform: translateX(2px); }
.access-view-switch[data-access-switch="guest"]:hover svg { transform: translateX(-2px); }
.access-view-switch:focus-visible { outline: 2px solid var(--access-accent-strong); outline-offset: 4px; }

.site-footer {
  position: absolute;
  z-index: 2;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  min-height: 74px;
  align-items: center;
  justify-content: space-between;
  padding: 20px 48px;
  border-top: 1px solid var(--access-rule);
  color: var(--access-muted-strong);
  font-size: .85rem;
}
.site-footer p { margin: 0; }
.footer-identity { display: flex; align-items: center; gap: 11px; }
.footer-identity > span,
.footer-location { color: var(--access-muted); }
.footer-identity > span { opacity: .48; }
.footer-location { font-size: .78rem; letter-spacing: .06em; opacity: .68; }
.site-footer nav { display: flex; align-items: center; gap: 24px; }
.site-footer a { color: inherit; text-decoration: none; transition: color .16s ease; }
.site-footer a:hover { color: var(--access-text); }
.site-footer a:focus-visible { outline: 2px solid var(--access-accent-strong); outline-offset: 4px; }

@media (max-width: 560px) {
  .access-stage { align-items: start; min-height: 100vh; min-height: 100dvh; padding: 112px 14px 136px; }
  .access-brand { top: 25px; left: 24px; }
  .access-return { top: 31px; right: 20px; min-height: 42px; padding: 0 13px; }
  .access-construction i:nth-child(2) { left: 12%; }.access-construction i:nth-child(3) { right: 10%; }
  .access-card { padding: 28px 22px; }
  .site-footer { flex-direction: column; justify-content: center; gap: 13px; min-height: 110px; padding: 22px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
