:root {
  color-scheme: dark;
  --background: #131513;
  --surface: #1e241c;
  --surface-soft: #273125;
  --line: #3d4b38;
  --text: #f1f2e9;
  --muted: #a7b6a2;
  --accent: #f3a47c;
  --accent-ink: #2b261f;
  --art: #cedfba;
}

body.frame {
  --background: #111426;
  --surface: #1d233a;
  --surface-soft: #2c3657;
  --line: #475477;
  --text: #f1f2fa;
  --muted: #afbad5;
  --accent: #d8eb9d;
  --accent-ink: #242b28;
  --art: #c2c3ff;
}

body.parcel {
  color-scheme: light;
  --background: #f6f3ed;
  --surface: #fffcf6;
  --surface-soft: #e9eddf;
  --line: #d4deca;
  --text: #292f27;
  --muted: #737e6f;
  --accent: #b44d30;
  --accent-ink: #fff9ef;
  --art: #d3dfc3;
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
  text-decoration: none;
}
button,
input {
  font: inherit;
}
button {
  cursor: pointer;
}
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
[hidden] {
  display: none !important;
}
::selection {
  background: var(--accent);
  color: var(--accent-ink);
}

.auth-page {
  max-width: 1320px;
  min-height: 100svh;
  padding: 0 58px;
  margin: auto;
  display: flex;
  flex-direction: column;
}
.auth-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  height: 96px;
  border-bottom: 1px solid var(--line);
}
.brand {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -1.1px;
}
.brand-mark {
  color: var(--accent);
}
.home-link {
  color: var(--muted);
  font-size: 12px;
}
.home-link:hover {
  color: var(--text);
}
.home-link span {
  display: inline-block;
  margin-right: 8px;
  color: var(--accent);
}
.auth-main {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 0.9fr);
  align-items: center;
  gap: 80px;
  padding: 72px 0 84px;
  flex: 1;
}
.story {
  min-width: 0;
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--accent);
  font: 10px monospace;
  letter-spacing: 1.3px;
  text-transform: uppercase;
}
.eyebrow-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.story h1 {
  max-width: 680px;
  margin: 26px 0 19px;
  font-size: clamp(48px, 5vw, 72px);
  font-weight: 500;
  letter-spacing: -3.5px;
  line-height: 1.06;
}
.story h1 em {
  color: var(--accent);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
}
.story > p {
  max-width: 440px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.85;
}
.preview {
  position: relative;
  max-width: 520px;
  min-height: 240px;
  margin-top: 46px;
  padding: 24px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: 0 25px 70px #0002;
}
.preview-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
}
.preview-head span:last-child {
  color: var(--accent);
}
.preview-content {
  position: relative;
  z-index: 1;
  padding-top: 18px;
}
.preview-title {
  display: block;
  margin-bottom: 16px;
  font-size: 17px;
  font-weight: 500;
}
.preview-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
  color: var(--text);
  font-size: 10px;
}
.preview-row > i {
  display: grid;
  place-items: center;
  width: 19px;
  height: 19px;
  flex: none;
  border-radius: 5px;
  border: 1px solid var(--line);
  color: var(--accent);
  font-style: normal;
  font-size: 10px;
}
.preview-row > small {
  margin-left: auto;
  color: var(--muted);
  font-size: 9px;
}
.preview-film {
  position: relative;
  height: 145px;
  margin-top: 17px;
  overflow: hidden;
  border-radius: 8px;
  background: #677ab2;
}
.preview-film::before {
  content: "";
  position: absolute;
  top: 19px;
  right: 53px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #f0e3ad;
}
.preview-film::after {
  content: "";
  position: absolute;
  left: -14px;
  bottom: -110px;
  width: 520px;
  height: 180px;
  border-radius: 50%;
  background: #354f70;
  transform: rotate(-10deg);
}
.preview-film span {
  position: absolute;
  z-index: 1;
  left: 20px;
  top: 39px;
  color: #f7f3e8;
  font:
    italic 29px Georgia,
    serif;
}
.preview-film b {
  position: absolute;
  z-index: 2;
  right: 20px;
  bottom: 15px;
  color: #f1f2e9;
  font: 8px monospace;
}
.preview-assets {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 18px;
}
.preview-assets > span {
  display: flex;
  align-items: flex-end;
  height: 103px;
  padding: 12px;
  border-radius: 7px;
  color: #fff9ee;
  font: 8px monospace;
}
.preview-assets > span:nth-child(1) {
  background: #b96749;
}
.preview-assets > span:nth-child(2) {
  background: #5d8062;
}
.preview-assets > span:nth-child(3) {
  background: #485d9d;
}
.preview-foot {
  display: block;
  margin-top: 18px;
  color: var(--muted);
  font: 9px monospace;
}

.auth-card {
  width: 100%;
  padding: 38px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 28px 80px #0002;
}
.card-top {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 31px;
  color: var(--muted);
  font-size: 11px;
}
.workspace-icon {
  display: grid;
  place-items: center;
  width: 33px;
  height: 33px;
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--accent);
  font-size: 16px;
  font-weight: 700;
}
.auth-card h2 {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: 500;
  letter-spacing: -1px;
}
.card-description {
  margin: 0 0 30px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}
.field {
  display: block;
  margin-top: 19px;
}
.field > span {
  display: block;
  margin-bottom: 9px;
  font-size: 11px;
  font-weight: 600;
}
.field input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 7px;
  outline: none;
  background: var(--background);
  color: var(--text);
  font-size: 13px;
}
.field input::placeholder {
  color: var(--muted);
  opacity: 0.7;
}
.field input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 15%, transparent);
}
.error {
  margin: 19px 0 0;
  padding: 13px 14px;
  border: 1px solid color-mix(in srgb, var(--accent) 50%, var(--line));
  border-radius: 7px;
  background: color-mix(in srgb, var(--accent) 9%, var(--surface));
  color: var(--text);
  font-size: 11px;
  line-height: 1.5;
}
.submit {
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 25px;
  padding: 0 17px;
  border: 0;
  border-radius: 7px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 12px;
  font-weight: 700;
  transition:
    transform 0.2s,
    filter 0.2s;
}
.submit:hover:not(:disabled) {
  transform: translateY(-2px);
  filter: brightness(1.08);
}
.submit:disabled {
  cursor: wait;
  opacity: 0.7;
}
.card-foot {
  margin: 22px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
}
.auth-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 26px 0 35px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font: 9px monospace;
}
.auth-footer a {
  color: var(--text);
}

@media (max-width: 1000px) {
  .auth-page {
    padding: 0 32px;
  }
  .auth-main {
    gap: 35px;
  }
  .story h1 {
    font-size: 55px;
  }
  .auth-card {
    padding: 29px;
  }
}
@media (max-width: 760px) {
  .auth-page {
    padding: 0 23px;
  }
  .auth-header {
    height: 78px;
  }
  .brand {
    font-size: 21px;
  }
  .auth-main {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 31px;
    padding: 52px 0 46px;
  }
  .story h1 {
    max-width: 510px;
    font-size: clamp(44px, 9vw, 62px);
  }
  .story > p {
    font-size: 13px;
  }
  .preview {
    min-height: 205px;
    margin-top: 29px;
    padding: 18px;
  }
  .preview-assets > span {
    height: 88px;
  }
  .auth-card {
    padding: 25px;
  }
  .auth-footer {
    font-size: 8px;
  }
}
@media (max-width: 370px) {
  .auth-page {
    padding: 0 18px;
  }
  .story h1 {
    font-size: 43px;
  }
  .preview {
    padding: 16px;
  }
  .preview-row {
    font-size: 9px;
  }
  .preview-row > small {
    font-size: 8px;
  }
  .auth-card {
    padding: 22px;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    transition: none !important;
  }
}
