:root {
    color-scheme: light;
    font-family: "Manrope", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --ink: #1c1713;
    --muted: #6f675e;
    --line: #e6ddd1;
    --paper: #fffdf9;
    --accent: #9f3429;
    --accent-dark: #78251e;
    --accent-soft: rgba(159, 52, 41, .12);
    --soft: #f4eee5;
    --error: #a22626;
    --display: "Cormorant Garamond", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background:
        radial-gradient(circle at 10% 0%, rgba(159, 52, 41, .14), transparent 34%),
        radial-gradient(circle at 95% 8%, rgba(158, 119, 63, .18), transparent 28%),
        radial-gradient(circle at 80% 100%, rgba(159, 52, 41, .08), transparent 36%),
        linear-gradient(180deg, #f3ebe0 0%, #ebe2d4 100%);
}

button, input { font: inherit; }

.identity-shell {
    width: min(100%, 520px);
    min-height: 100vh;
    margin: 0 auto;
    padding: clamp(18px, 4vw, 42px) 16px 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.identity-card {
    position: relative;
    overflow: hidden;
    padding: clamp(26px, 6vw, 44px);
    border: 1px solid rgba(130, 104, 76, .18);
    border-radius: 28px;
    background:
        linear-gradient(180deg, rgba(255, 253, 249, .98), rgba(255, 250, 243, .96));
    box-shadow:
        0 28px 70px rgba(63, 45, 29, .14),
        inset 0 1px 0 rgba(255, 255, 255, .7);
}

.identity-card::before {
    content: "";
    position: absolute;
    inset: 0 auto auto 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #c45a4c, var(--accent) 45%, #b08a4a);
}

.identity-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    padding-bottom: 24px;
    margin-bottom: 26px;
    border-bottom: 1px solid var(--line);
}

.identity-brand__mark {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 16px;
    color: #fff;
    background: linear-gradient(145deg, #c45a4c, var(--accent) 55%, var(--accent-dark));
    font: 600 26px/1 var(--display);
    box-shadow: 0 10px 22px rgba(159, 52, 41, .28);
}

.identity-brand strong,
.identity-brand small { display: block; }

.identity-brand strong {
    font: 600 19px/1.15 var(--display);
    letter-spacing: .02em;
}

.identity-brand small {
    margin-top: 4px;
    color: var(--muted);
    font-size: 12px;
    letter-spacing: .01em;
}

.identity-steps {
    display: flex;
    gap: 6px;
    margin: 0 0 22px;
}

.identity-steps span {
    height: 4px;
    flex: 1;
    border-radius: 999px;
    background: var(--line);
    transition: background .2s;
}

.identity-steps span.is-active,
.identity-steps span.is-complete { background: var(--accent); }

.identity-eyebrow {
    margin: 0 0 8px;
    color: var(--accent);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
}

h1 {
    margin: 0;
    font: 500 clamp(30px, 8vw, 40px)/1.08 var(--display);
    letter-spacing: .01em;
}

.identity-lead {
    margin: 12px 0 24px;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.55;
}

.identity-perks {
    list-style: none;
    margin: 0 0 26px;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid rgba(159, 52, 41, .12);
    background: linear-gradient(180deg, rgba(159, 52, 41, .05), rgba(255, 255, 255, .4));
}

.identity-perks li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: var(--ink);
    font-size: 13px;
    line-height: 1.45;
}

.identity-perks li + li { margin-top: 10px; }

.identity-perks__dot {
    width: 8px;
    height: 8px;
    margin-top: 5px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
}

.identity-client {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 22px;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid rgba(159, 52, 41, .14);
    background: var(--soft);
}

.identity-client__mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 12px;
    color: #fff;
    background: var(--accent);
    font-weight: 700;
    font-size: 14px;
}

.identity-client strong,
.identity-client span { display: block; }

.identity-client strong {
    font-size: 15px;
    font-weight: 700;
}

.identity-client span {
    margin-top: 2px;
    color: var(--muted);
    font-size: 12px;
}

.identity-field { margin-top: 17px; }

.identity-field label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 650;
}

.identity-input {
    width: 100%;
    min-height: 54px;
    padding: 13px 15px;
    border: 1px solid #d2c5b5;
    border-radius: 14px;
    outline: none;
    color: var(--ink);
    background: #fff;
    transition: border-color .18s, box-shadow .18s;
}

.identity-input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(159, 52, 41, .12);
}

.identity-input--code {
    text-align: center;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: .42em;
}

.identity-button {
    width: 100%;
    min-height: 54px;
    margin-top: 22px;
    border: 0;
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(135deg, #c45a4c 0%, var(--accent) 48%, var(--accent-dark) 100%);
    font-weight: 700;
    letter-spacing: .02em;
    cursor: pointer;
    box-shadow: 0 14px 28px rgba(159, 52, 41, .24);
    transition: transform .15s, filter .15s, background .15s;
}

.identity-button:hover {
    filter: brightness(1.04);
    transform: translateY(-1px);
}

.identity-button:disabled {
    opacity: .58;
    cursor: wait;
    transform: none;
    filter: none;
    box-shadow: none;
}

.identity-button--secondary {
    color: var(--ink);
    background: var(--soft);
    box-shadow: none;
}

.identity-button--secondary:hover {
    background: #ebe1d4;
    filter: none;
}

.identity-link {
    display: inline;
    padding: 0;
    border: 0;
    color: var(--accent);
    background: none;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.identity-consent {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin-top: 18px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, .55);
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
}

.identity-consent input {
    margin-top: 3px;
    accent-color: var(--accent);
}

.identity-meta {
    margin: 16px 0 0;
    color: var(--muted);
    text-align: center;
    font-size: 13px;
}

.identity-error {
    min-height: 21px;
    margin-top: 14px;
    color: var(--error);
    font-size: 13px;
    line-height: 1.4;
}

.identity-success { color: #397142; }
.identity-hidden { display: none !important; }

.identity-security {
    margin: 18px 8px 0;
    color: #766e65;
    text-align: center;
    font-size: 11px;
    line-height: 1.45;
}

.identity-spinner {
    width: 17px;
    height: 17px;
    display: inline-block;
    margin-right: 8px;
    vertical-align: -3px;
    border: 2px solid rgba(255, 255, 255, .45);
    border-top-color: #fff;
    border-radius: 50%;
    animation: identity-spin .7s linear infinite;
}

@keyframes identity-spin { to { transform: rotate(360deg); } }

@media (max-width: 520px) {
    .identity-shell {
        padding: 0;
        justify-content: stretch;
    }

    .identity-card {
        min-height: calc(100vh - 34px);
        border: 0;
        border-radius: 0 0 26px 26px;
        box-shadow: none;
    }

    .identity-card::before {
        border-radius: 0;
    }
}

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