/* Optiora studio auth — one-screen register, login, and team login. */

*, *::before, *::after { box-sizing: border-box; }

html:has(body.studio-auth) {
    height: 100%;
    overflow: hidden;
}

html, body.studio-auth {
    height: 100%;
}

body.studio-auth {
    margin: 0;
    height: 100dvh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    color: #25251f;
    background: #fff;
    font-family: "DM Sans", sans-serif;
    font-size: 16px;
    line-height: 1.45;
    -webkit-font-smoothing: antialiased;
}

.studio-auth a { color: inherit; text-decoration: none; }
.studio-auth button, .studio-auth input { font: inherit; }
.studio-auth button { color: inherit; border: 0; cursor: pointer; }
.studio-auth button:disabled { cursor: wait; opacity: 0.7; }
.studio-auth img { display: block; max-width: 100%; height: auto; }

.studio-auth a:focus-visible,
.studio-auth button:focus-visible,
.studio-auth input:focus-visible {
    outline: 3px solid #cf4300;
    outline-offset: 3px;
}

.studio-skip {
    position: fixed;
    top: -80px;
    left: 16px;
    z-index: 100;
    background: #fff;
    padding: 12px 16px;
    border: 1px solid #e9e1d4;
    border-radius: 10px;
    font-weight: 600;
}
.studio-skip:focus { top: 12px; }

.studio-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
    background: linear-gradient(180deg, #fff 40%, #fff8ef 100%);
}
.studio-bg__grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(#f26b2a0f 1px, transparent 1px),
        linear-gradient(90deg, #f26b2a0f 1px, transparent 1px);
    background-size: 58px 58px;
    mask-image: linear-gradient(to bottom, #000 0%, transparent 82%);
    animation: studio-grid 22s linear infinite;
}
.studio-bg__glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(12px);
    opacity: 0.85;
}
.studio-bg__glow--one {
    width: 420px;
    height: 420px;
    left: -180px;
    top: -120px;
    background: radial-gradient(circle, #ffca6766 0%, #ff964238 48%, transparent 72%);
}
.studio-bg__glow--two {
    width: 520px;
    height: 520px;
    right: -220px;
    top: 40px;
    background: radial-gradient(circle, #ffab6c55 0%, #ffd86629 50%, transparent 72%);
}
.studio-bg__orbit {
    position: absolute;
    border: 1px solid #f1884828;
    border-radius: 50%;
    animation: studio-spin 28s linear infinite;
}
.studio-bg__orbit--one { width: 280px; height: 280px; left: 5%; top: 70px; }
.studio-bg__orbit--two {
    width: 460px;
    height: 460px;
    right: -140px;
    top: -100px;
    animation-direction: reverse;
}
.studio-bg__orbit::after {
    content: "";
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ff7a32;
    top: 8%;
    left: 18%;
}

.studio-top {
    position: relative;
    z-index: 20;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 14px 4.5% 6px;
}

.studio-brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: Manrope, sans-serif;
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -1.4px;
}
.studio-brand__period { color: #f65b20; margin-left: -7px; }
.studio-brand-mark {
    width: 22px;
    height: 22px;
    display: inline-block;
    border: 5px solid #f65b20;
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
}
.studio-brand-mark::after {
    content: "";
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ffce45;
    top: -5px;
    right: -4px;
}

.studio-top__link {
    font-size: 14px;
    font-weight: 600;
    color: #675f54;
    transition: color 0.2s;
}
.studio-top__link:hover { color: #e55018; }

.studio-shell {
    position: relative;
    z-index: 10;
    flex: 1 1 auto;
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(320px, 0.92fr) minmax(0, 1.08fr);
    gap: 28px;
    align-items: stretch;
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 8px 4.5% 18px;
}

.studio-card {
    min-height: 0;
    overflow: auto;
    background: #fffffff2;
    border: 1px solid #e9e1d4;
    border-radius: 22px;
    box-shadow: 0 16px 40px #52311012;
    padding: 22px 24px 18px;
    backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.studio-eyebrow {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    gap: 8px;
    background: #fff5e9;
    color: #945324;
    border: 1px solid #ffe5c6;
    border-radius: 30px;
    padding: 5px 11px;
    font-size: 10px;
    font-weight: 650;
    letter-spacing: 1px;
    margin-bottom: 12px;
}
.studio-eyebrow svg { color: #f55e23; }

.studio-card h1 {
    margin: 0 0 8px;
    font-family: Manrope, sans-serif;
    font-size: clamp(26px, 3vw, 34px);
    font-weight: 600;
    letter-spacing: -1.3px;
    line-height: 1.12;
}
.studio-card h1 .accent { color: #f65b20; }

.studio-lead {
    margin: 0 0 14px;
    color: #75756d;
    font-size: 14px;
    line-height: 1.5;
    max-width: 40ch;
}

.studio-alert {
    margin-bottom: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.45;
}
.studio-alert--error {
    background: #fff1ee;
    border: 1px solid #f6c7bb;
    color: #9b2c1a;
}
.studio-alert--success {
    background: #eef8ee;
    border: 1px solid #c6e4c6;
    color: #27633a;
}

.studio-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.studio-field__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 6px;
}
.studio-field__row label { margin-bottom: 0; }
.studio-forgot {
    font-size: 12px;
    font-weight: 650;
    color: #d45620;
}
.studio-forgot:hover { color: #b44718; }

.studio-field label {
    display: block;
    margin-bottom: 5px;
    font-size: 13px;
    font-weight: 650;
    color: #3b362f;
}

.studio-field__wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.studio-field__icon {
    position: absolute;
    left: 14px;
    color: #9a9184;
    pointer-events: none;
    display: grid;
    place-items: center;
}

.studio-field input {
    width: 100%;
    min-height: 46px;
    padding: 0 44px 0 42px;
    border: 1px solid #d8d2c6;
    border-radius: 12px;
    background: #fff;
    font-size: 16px;
    color: #25251f;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.studio-field input::placeholder { color: #a8a194; }
.studio-field input:hover { border-color: #c9c2b4; }
.studio-field input:focus {
    outline: none;
    border-color: #f36b2c;
    box-shadow: 0 0 0 4px #fff0e4;
}

.studio-field__toggle {
    position: absolute;
    right: 6px;
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: transparent;
    color: #8a8171;
}
.studio-field__toggle:hover {
    color: #d45620;
    background: #fff6ee;
}

.studio-submit {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 48px;
    margin-top: 4px;
    padding: 10px 14px 10px 20px;
    border-radius: 999px;
    background: #fa6224;
    color: #fff;
    font-size: 15px;
    font-weight: 650;
    box-shadow: 0 8px 20px #eb5e2628;
    transition: transform 0.25s, background 0.2s, box-shadow 0.2s;
}
.studio-submit:hover {
    transform: translateY(-2px);
    background: #ed541a;
}
.studio-submit:disabled { transform: none; box-shadow: none; }
.studio-submit span:last-child {
    display: grid;
    place-items: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #ffffff24;
    font-size: 15px;
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 10px 0 8px;
    color: #9a9184;
    font-size: 12px;
    font-weight: 500;
}
.auth-divider::before,
.auth-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #ece7dc;
}

.studio-auth a.auth-google,
.studio-auth button.auth-google {
    width: 100%;
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 2px solid #8f8778;
    border-radius: 999px;
    background: #fff;
    color: #34342b;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    box-sizing: border-box;
    transition: transform 0.2s, background 0.2s, border-color 0.2s;
}
.studio-auth a.auth-google:hover,
.studio-auth button.auth-google:hover {
    transform: translateY(-1px);
    background: #faf9f5;
    border-color: #5f584c;
}
.studio-auth button.auth-google:disabled {
    opacity: 0.65;
    cursor: wait;
    transform: none;
}
.auth-google svg { flex-shrink: 0; }

.auth-alert {
    margin: 10px 0 0;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 500;
}
.auth-alert--error {
    background: #fff1ee;
    border: 1px solid #f6c7bb;
    color: #9b2c1a;
}

.auth-platforms {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #eee8dc;
}
.auth-platforms__title {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    font-size: 12px;
    font-weight: 600;
    color: #675f54;
}
.auth-platforms__logo {
    width: 52px;
    height: auto;
    filter: none;
}

.studio-switch,
.studio-terms {
    margin: 10px 0 0;
    font-size: 13px;
    color: #75756d;
}
.studio-switch a,
.studio-terms a {
    color: #d45620;
    font-weight: 650;
}
.studio-terms { font-size: 12px; }

.studio-stage {
    min-height: 0;
    display: flex;
    flex-direction: column;
}
.studio-stage__kicker {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
    font-size: 10px;
    letter-spacing: 1.1px;
    color: #8a8174;
    font-weight: 600;
}
.studio-window {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #e4e2d7;
    border-radius: 16px;
    box-shadow: 0 14px 36px #6b4c1512;
    overflow: hidden;
}
.studio-window__bar,
.studio-window__footer {
    flex: 0 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    font-size: 11px;
    font-weight: 650;
}
.studio-window__bar { border-bottom: 1px solid #efeee8; }
.studio-window__footer {
    border-top: 1px solid #efeee8;
    font-weight: 500;
    color: #8a8174;
}
.studio-window__ready {
    font-size: 10px;
    font-weight: 500;
    color: #5f7a62;
    background: #f2f6ee;
    border-radius: 20px;
    padding: 4px 8px;
}
.studio-mosaic {
    flex: 1 1 auto;
    min-height: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 7px;
    padding: 10px;
}
.studio-mosaic figure {
    margin: 0;
    min-height: 0;
    border-radius: 8px;
    overflow: hidden;
    background: #f7eee5;
}
.studio-mosaic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.studio-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
    flex: 0 0 auto;
}
.studio-chips span {
    font-size: 11px;
    color: #85715d;
    background: #f5f0e7;
    border: 1px solid #e9e1d4;
    border-radius: 999px;
    padding: 6px 10px;
}

@keyframes studio-grid { to { background-position: 58px 58px; } }
@keyframes studio-spin { to { transform: rotate(360deg); } }

@media (max-width: 980px) {
    .studio-stage { display: none; }
    .studio-shell {
        grid-template-columns: 1fr;
        padding-bottom: 16px;
    }
    .studio-card { justify-content: flex-start; }
}

@media (max-width: 640px) {
    .studio-top { padding: 12px 18px 4px; }
    .studio-shell { padding: 6px 16px 14px; }
    .studio-card { padding: 18px 16px; border-radius: 18px; }
    .studio-card h1 { font-size: 26px; }
}

@media (max-height: 820px) {
    .studio-chips { display: none; }
}

@media (max-height: 760px) {
    .studio-lead { display: none; }
    .auth-platforms { display: none; }
    .studio-window__footer { display: none; }
}

@media (max-height: 680px) {
    .studio-terms { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .studio-bg__grid,
    .studio-bg__orbit { animation: none !important; }
}
