:root {
    --ck-black: #111111;
    --ck-charcoal: #1f2937;
    --ck-blue: #2563eb;
    --ck-blue-dark: #1d4ed8;
    --ck-gray: #f3f4f6;
    --ck-white: #ffffff;
    --ck-font: "Söhne", "Sohne", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

html {
    background: var(--ck-black);
}

body {
    font-family: var(--ck-font);
    color: var(--ck-black);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

button,
input,
select,
textarea {
    font: inherit;
}

::selection {
    color: var(--ck-white);
    background: var(--ck-blue);
}

.ck-auth-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(420px, 1.08fr) minmax(440px, 0.92fr);
    background: var(--ck-black);
}

.ck-auth-story {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    padding: clamp(36px, 5vw, 72px);
    color: var(--ck-white);
    background:
        radial-gradient(circle at 72% 68%, rgba(37, 99, 235, 0.34), transparent 30%),
        radial-gradient(circle at 28% 88%, rgba(37, 99, 235, 0.16), transparent 36%),
        linear-gradient(145deg, #111111 0%, #121826 58%, #0b1220 100%);
}

.ck-auth-story::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.18;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: linear-gradient(to bottom, transparent, black 18%, black 78%, transparent);
    pointer-events: none;
}

.ck-auth-story::after {
    content: "";
    position: absolute;
    width: 78vw;
    height: 260px;
    left: -12vw;
    bottom: 4vh;
    border: 1px solid rgba(37, 99, 235, 0.42);
    border-radius: 50%;
    transform: rotate(-8deg);
    box-shadow:
        0 -18px 60px rgba(37, 99, 235, 0.16),
        inset 0 10px 48px rgba(37, 99, 235, 0.12);
    pointer-events: none;
}

.ck-auth-story-logo,
.ck-auth-story-copy,
.ck-auth-proof {
    position: relative;
    z-index: 1;
}

.ck-auth-story-logo {
    width: 190px;
    height: auto;
}

.ck-auth-story-copy {
    max-width: 660px;
    margin: auto 0;
    padding: 10vh 0 18vh;
}

.ck-auth-kicker {
    margin: 0 0 18px;
    color: #60a5fa;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.ck-auth-story h2 {
    max-width: 680px;
    margin: 0;
    color: var(--ck-white);
    font-size: clamp(42px, 5.1vw, 76px);
    font-weight: 600;
    letter-spacing: -0.055em;
    line-height: 0.98;
}

.ck-auth-story h2 span {
    color: var(--ck-blue);
}

.ck-auth-story-copy > p:last-child {
    max-width: 510px;
    margin: 24px 0 0;
    color: rgba(255, 255, 255, 0.66);
    font-size: 16px;
    line-height: 1.65;
}

.ck-auth-proof {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.54);
    font-size: 12px;
    letter-spacing: 0.04em;
}

.ck-auth-proof::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--ck-blue);
    box-shadow: 0 0 18px rgba(37, 99, 235, 0.9);
}

.ck-auth-panel {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(28px, 6vw, 88px);
    background: var(--ck-gray);
}

.ck-auth-card {
    width: min(100%, 470px);
    padding: clamp(30px, 4vw, 48px);
    border: 1px solid rgba(31, 41, 55, 0.1);
    border-radius: 24px;
    background: var(--ck-white);
    box-shadow: 0 24px 72px rgba(17, 17, 17, 0.12);
}

.ck-auth-logo {
    display: block;
    width: 168px;
    height: auto;
    margin: 0 0 40px;
}

.ck-auth-card h1 {
    margin: 0;
    color: var(--ck-black);
    font-size: 30px;
    font-weight: 600;
    letter-spacing: -0.04em;
    line-height: 1.12;
}

.ck-auth-subtitle {
    margin: 10px 0 30px;
    color: rgba(31, 41, 55, 0.68);
    font-size: 15px;
    line-height: 1.55;
}

.ck-auth-form {
    display: grid;
    gap: 20px;
}

.ck-field {
    display: grid;
    gap: 8px;
}

.ck-field label {
    color: var(--ck-charcoal);
    font-size: 13px;
    font-weight: 600;
}

.ck-field input {
    width: 100%;
    min-height: 50px;
    padding: 12px 14px;
    border: 1px solid rgba(31, 41, 55, 0.2);
    border-radius: 10px;
    outline: none;
    color: var(--ck-black);
    background: var(--ck-white);
    transition: border-color 150ms ease, box-shadow 150ms ease, background 150ms ease;
}

.ck-field input::placeholder {
    color: rgba(31, 41, 55, 0.42);
}

.ck-field input:hover {
    border-color: rgba(31, 41, 55, 0.36);
}

.ck-field input:focus {
    border-color: var(--ck-blue);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.ck-auth-meta {
    display: flex;
    justify-content: flex-end;
    margin-top: -8px;
}

.ck-link {
    color: var(--ck-blue);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
}

.ck-link:hover {
    color: var(--ck-blue-dark);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.ck-primary-button {
    min-height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 12px 18px;
    border: 0;
    border-radius: 10px;
    color: var(--ck-white);
    background: var(--ck-blue);
    box-shadow: 0 10px 24px rgba(37, 99, 235, 0.25);
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.ck-primary-button:hover {
    background: var(--ck-blue-dark);
    box-shadow: 0 14px 30px rgba(37, 99, 235, 0.3);
    transform: translateY(-1px);
}

.ck-primary-button:focus-visible,
.ck-link:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.28);
    outline-offset: 3px;
}

.ck-auth-footer {
    margin: 26px 0 0;
    color: rgba(31, 41, 55, 0.58);
    font-size: 12px;
    line-height: 1.5;
    text-align: center;
}

.ck-alert {
    margin-bottom: 22px;
    padding: 12px 14px;
    border: 1px solid;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.45;
    transition: opacity 300ms ease;
}

.ck-alert-error {
    color: #991b1b;
    border-color: #fecaca;
    background: #fef2f2;
}

.ck-alert-success {
    color: #166534;
    border-color: #bbf7d0;
    background: #f0fdf4;
}

@media (max-width: 920px) {
    .ck-auth-shell {
        display: block;
        background:
            radial-gradient(circle at 50% 10%, rgba(37, 99, 235, 0.24), transparent 28%),
            var(--ck-black);
    }

    .ck-auth-story {
        display: none;
    }

    .ck-auth-panel {
        min-height: 100vh;
        padding: 24px;
        background: transparent;
    }
}

@media (max-width: 520px) {
    .ck-auth-panel {
        align-items: flex-start;
        padding: 18px;
    }

    .ck-auth-card {
        margin-top: 18px;
        padding: 28px 22px;
        border-radius: 18px;
    }

    .ck-auth-logo {
        width: 150px;
        margin-bottom: 34px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
