@font-face {
    font-family: "Moon Bold";
    src: url("assets/fonts/moon-bold.otf") format("opentype");
    font-style: normal;
    font-weight: 700;
    font-display: swap;
}

:root {
    --ink: #0f0f1e;
    --paper: #f2f1ed;
    --white: #ffffff;
    --line: rgba(15, 15, 30, 0.22);
    --muted: #696971;
    --accent: #d8ff43;
    --radius: 2px;
    --moon-gradient: radial-gradient(129.34% 153.45% at -2.37% 65.03%, rgba(254, 215, 202, 0.92) 0%, rgba(226, 218, 252, 0.86) 52%, rgba(211, 228, 255, 0.94) 100%);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@keyframes moon-gradient-drift {
    0% { background-position: 0% 35%; }
    50% { background-position: 70% 65%; }
    100% { background-position: 100% 25%; }
}

body {
    margin: 0;
    min-width: 320px;
    color: var(--ink);
    background: var(--moon-gradient), var(--paper);
    background-size: 165% 165%;
    animation: moon-gradient-drift 16s ease-in-out infinite alternate;
    font-family: "Rubik", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.skip-link {
    position: fixed;
    z-index: 20;
    top: 12px;
    left: 12px;
    padding: 10px 14px;
    background: var(--ink);
    color: var(--white);
    transform: translateY(-160%);
}

.skip-link:focus { transform: translateY(0); }

.shell {
    width: min(1440px, 100%);
    min-height: 100svh;
    margin: 0 auto;
    padding: 0 42px;
}

.brandbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 94px;
    border-bottom: 1px solid var(--ink);
}

.wordmark {
    display: flex;
    gap: 9px;
    font-family: "Raleway", sans-serif;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: -0.04em;
    text-decoration: none;
}

.wordmark span:last-child { font-weight: 400; }

.brandbar__label,
.eyebrow,
label,
.support,
footer {
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.brandbar__label { color: var(--muted); }

.hero {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(360px, 0.75fr);
    gap: clamp(54px, 8vw, 132px);
    align-items: center;
    min-height: calc(100svh - 166px);
    padding: 78px 4vw 92px;
    overflow: hidden;
}

.hero__copy { position: relative; z-index: 2; }

.eyebrow {
    margin: 0 0 24px;
    font-weight: 500;
}

h1, h2 {
    margin: 0;
    font-family: "Raleway", sans-serif;
    font-weight: 500;
    letter-spacing: -0.055em;
}

h1 {
    max-width: 850px;
    font-family: "Moon Bold", "Raleway", sans-serif;
    font-weight: 700;
    letter-spacing: -0.025em;
    font-size: clamp(58px, 7.5vw, 118px);
    line-height: 0.91;
}

.hero__subline {
    display: block;
    margin-top: 18px;
    font-family: "Raleway", sans-serif;
    font-size: clamp(27px, 3.2vw, 50px);
    font-weight: 500;
    line-height: 1.08;
    letter-spacing: -0.045em;
}

.intro {
    max-width: 590px;
    margin: 40px 0 0;
    font-family: "Raleway", sans-serif;
    font-size: clamp(17px, 1.45vw, 22px);
    line-height: 1.5;
}

.hero__visual {
    position: absolute;
    z-index: 0;
    inset: 0 auto auto 42%;
    width: 560px;
    height: 560px;
    transform: translate(-50%, -35%);
    opacity: 0.12;
    pointer-events: none;
}

.hero__visual img {
    position: absolute;
    inset: 50% auto auto 50%;
    width: 170px;
    height: 170px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    mix-blend-mode: multiply;
}

.orbit {
    position: absolute;
    inset: 50% auto auto 50%;
    border: 2px solid var(--ink);
    border-radius: 50%;
    transform-origin: center;
}

.orbit--one { width: 520px; height: 220px; transform: translate(-50%, -50%) rotate(17deg); }
.orbit--two { width: 280px; height: 540px; transform: translate(-50%, -50%) rotate(48deg); }
.orbit--three { width: 420px; height: 420px; transform: translate(-50%, -50%); }

.login-card {
    position: relative;
    z-index: 30;
    padding: clamp(28px, 3vw, 44px);
    background: var(--white);
    border: 1px solid var(--ink);
    box-shadow: 12px 12px 0 var(--ink);
}

.login-card__heading {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--line);
}

.login-card__heading .eyebrow { margin: 2px 0 7px; }

.step {
    display: grid;
    place-items: center;
    width: 42px;
    aspect-ratio: 1;
    flex: 0 0 auto;
    border: 1px solid var(--ink);
    border-radius: 50%;
    color: var(--ink);
}

.step svg { display: block; }

h2 { font-size: clamp(30px, 3vw, 46px); }

form { margin-top: 30px; }

label {
    display: block;
    margin: 0 0 9px;
    font-weight: 600;
}

input {
    width: 100%;
    height: 58px;
    margin: 0 0 24px;
    padding: 0 16px;
    color: var(--ink);
    background: transparent;
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    font: 16px "Rubik", sans-serif;
    outline: 0;
    transition: box-shadow 160ms ease, background 160ms ease;
}

input:focus {
    background: #fbfbf8;
    box-shadow: 0 0 0 3px rgba(15, 15, 30, 0.14);
}

.password-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
}

.reveal {
    padding: 0;
    color: var(--muted);
    background: none;
    border: 0;
    font: 12px "Rubik", sans-serif;
    text-decoration: underline;
    cursor: pointer;
}

.submit {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 60px;
    padding: 0 18px;
    color: var(--white);
    background: var(--ink);
    border: 1px solid var(--ink);
    border-radius: var(--radius);
    font: 600 14px "Raleway", sans-serif;
    cursor: pointer;
    transition: color 160ms ease, background 160ms ease, transform 160ms ease;
}

.submit:hover, .submit:focus-visible {
    color: var(--ink);
    background: var(--accent);
}

.submit:active { transform: translateY(2px); }

.support {
    margin: 22px 0 0;
    color: var(--muted);
    line-height: 1.6;
    text-transform: none;
    letter-spacing: 0;
}

.support a { color: var(--ink); }

.alert {
    margin: 24px 0 -8px;
    padding: 13px 15px;
    background: #fff0eb;
    border-left: 3px solid #b93820;
    font-size: 14px;
    line-height: 1.4;
}

footer {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 24px;
    align-items: center;
    min-height: 72px;
    border-top: 1px solid var(--ink);
}

footer span:nth-child(2) { text-align: center; }
footer a { justify-self: end; }

/* Decorative cursor rocket. It only exists for precise pointing devices. */
.cursor-rocket {
    --rocket-size: 64px;
    position: fixed;
    z-index: 12;
    top: 0;
    left: 0;
    width: var(--rocket-size);
    height: var(--rocket-size);
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transform: translate3d(-200px, -200px, 0);
    transition: opacity 280ms ease;
    will-change: transform;
    contain: layout paint style;
}

.cursor-rocket.is-ready { opacity: 0.88; }

.cursor-rocket__heading,
.cursor-rocket__vehicle {
    width: 100%;
    height: 100%;
    transform-origin: 50% 50%;
    will-change: transform;
}

.cursor-rocket__vehicle img {
    position: relative;
    z-index: 2;
    display: block;
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 3px 2px rgba(15, 15, 30, 0.18));
}

.cursor-rocket__flame {
    position: absolute;
    z-index: 1;
    top: 87%;
    left: 50%;
    width: 20%;
    height: 44%;
    opacity: var(--thrust, 0);
    transform: translateX(-50%) scaleY(calc(0.55 + var(--thrust, 0) * 0.75));
    transform-origin: 50% 0;
    filter: drop-shadow(0 0 5px rgba(255, 126, 36, 0.7));
    transition: opacity 100ms linear;
}

.cursor-rocket__flame-outer,
.cursor-rocket__flame-core {
    position: absolute;
    inset: 0;
    border-radius: 50% 50% 68% 68%;
    clip-path: polygon(10% 0, 90% 0, 74% 68%, 50% 100%, 26% 68%);
    background: linear-gradient(#ffcf3d, #ff6a2b 58%, rgba(214, 31, 30, 0));
}

.cursor-rocket__flame-core {
    inset: 0 28% 22%;
    background: linear-gradient(#fff, #fff4a8 45%, rgba(255, 178, 45, 0));
}

.cursor-rocket__particle {
    position: absolute;
    z-index: 0;
    top: 98%;
    left: 50%;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #ff8a2b;
    opacity: 0;
}

@media (hover: hover) and (pointer: fine) {
    .cursor-rocket { visibility: visible; }
}

@media (max-width: 900px) {
    .shell { padding: 0 22px; }
    .hero { grid-template-columns: 1fr; gap: 48px; padding: 62px 0 80px; }
    .hero__copy { max-width: 720px; }
    .login-card { max-width: 620px; }
    .hero__visual { left: 72%; }
    footer { grid-template-columns: 1fr 1fr; padding: 20px 0; }
    footer span:nth-child(2) { display: none; }
}

@media (max-width: 560px) {
    .brandbar { min-height: 74px; }
    .brandbar__label { font-size: 10px; }
    .hero { padding-top: 44px; }
    h1 { font-size: clamp(48px, 15vw, 72px); }
    .intro { margin-top: 28px; }
    .login-card { padding: 24px 20px; box-shadow: 7px 7px 0 var(--ink); }
    .login-card__heading { gap: 14px; }
    .hero__visual { display: none; }
    .cursor-rocket { --rocket-size: 52px; }
}

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