/* ==========================================================
   AILEARNIST — REGISTER PAGE
   Additions on top of login.css (the shared auth theme).
   login.css MUST be loaded first.
   ========================================================== */

/* Slightly taller card — more fields than login */
.auth-panel { padding-top: 56px; padding-bottom: 56px; }
.auth-card  { max-width: 418px; }

/* ==========================================================
   LEFT PANEL EXTRAS
   ========================================================== */

.ai-console__code .num { color: #fbbf24; }

/* "1 row inserted" success line */
.res-ok {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 12.5px;
    color: var(--secondary);
    opacity: 0;
    animation: rowIn .5s ease forwards .6s;
}
.res-ok i { font-size: 13px; }

/* Perk list replaces the stats row */
.perk-list {
    list-style: none;
    margin-top: 36px;
    display: flex;
    flex-direction: column;
    gap: 13px;
}
.perk-list li {
    display: flex;
    align-items: center;
    gap: 11px;
    font-size: 14px;
    font-weight: 300;
    color: rgba(255, 255, 255, .74);
    opacity: 0;
    animation: perkIn .55s cubic-bezier(.16,1,.3,1) forwards;
}
.perk-list li:nth-child(1) { animation-delay: .45s; }
.perk-list li:nth-child(2) { animation-delay: .58s; }
.perk-list li:nth-child(3) { animation-delay: .71s; }

@keyframes perkIn {
    from { opacity: 0; transform: translateX(-10px); }
    to   { opacity: 1; transform: translateX(0); }
}

.perk-list i {
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    border-radius: 50%;
    font-size: 9px;
    color: #6ee7b7;
    background: rgba(16, 185, 129, .18);
    border: 1px solid rgba(16, 185, 129, .30);
}

/* ==========================================================
   PASSWORD REQUIREMENT CHECKLIST
   ========================================================== */

.pw-rules {
    list-style: none;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 12px;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height .3s ease, opacity .3s ease, margin-top .3s ease;
}
.pw-rules.is-visible {
    max-height: 60px;
    opacity: 1;
    margin-top: 10px;
}

.pw-rules li {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 11.5px;
    font-weight: 500;
    color: var(--text-muted);
    transition: color .25s ease;
}
.pw-rules li i {
    font-size: 10px;
    width: 11px;
    text-align: center;
    transition: color .25s ease, transform .25s cubic-bezier(.34,1.56,.64,1);
}
.pw-rules li.is-met {
    color: var(--success);
}
.pw-rules li.is-met i {
    color: var(--success);
    transform: scale(1.15);
}

/* ==========================================================
   TERMS CHECKBOX
   ========================================================== */

.checkbox--terms {
    align-items: flex-start;
    margin: 18px 0 6px;
    font-size: 12.8px;
    line-height: 1.6;
    color: var(--text-secondary);
}
.checkbox--terms .checkbox__box { margin-top: 1px; }
.checkbox--terms a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}
.checkbox--terms a:hover { text-decoration: underline; }

/* Error shown under the checkbox (no .field wrapper) */
.field__error--standalone {
    display: block;
    max-height: 0;
    overflow: hidden;
    font-size: 12.5px;
    font-weight: 500;
    color: var(--error);
    transition: max-height .25s ease, margin-bottom .25s ease;
}
.field__error--standalone.is-visible {
    max-height: 40px;
    margin-bottom: 4px;
}

/* Space above the submit button */
#registerForm .btn-primary { margin-top: 16px; }

/* ==========================================================
   SUCCESS STATE
   ========================================================== */

.signup-done[hidden] { display: none !important; }

.signup-done {
    display: none;
    text-align: center;
    padding: 8px 0 4px;
    animation: doneIn .55s cubic-bezier(.16,1,.3,1) both;
}
.signup-done.is-visible { display: block; }

@keyframes doneIn {
    from { opacity: 0; transform: scale(.96) translateY(10px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}

.signup-done__icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    font-size: 25px;
    color: var(--secondary);
    background: rgba(16, 185, 129, .12);
    border: 1.5px solid rgba(16, 185, 129, .28);
    animation: pulseRing 2.4s ease-in-out infinite;
}

@keyframes pulseRing {
    0%, 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, .28); }
    50%      { box-shadow: 0 0 0 12px rgba(16, 185, 129, 0); }
}

.signup-done h3 {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.03em;
    margin-bottom: 10px;
    color: var(--text-primary);
}
.signup-done p {
    font-size: 14.5px;
    font-weight: 300;
    line-height: 1.65;
    color: var(--text-secondary);
    margin-bottom: 24px;
}
.signup-done p strong {
    font-weight: 600;
    color: var(--text-primary);
    word-break: break-all;
}
.signup-done .btn-google { justify-content: center; }
.signup-done__hint {
    margin-top: 16px !important;
    margin-bottom: 0 !important;
    font-size: 12px;
    color: var(--text-muted);
}

/* Hide the form furniture once signup succeeds */
.auth-card.is-done #registerForm,
.auth-card.is-done #regDivider,
.auth-card.is-done #googleBtn,
.auth-card.is-done #regFoot,
.auth-card.is-done #regHead { display: none; }

/* ==========================================================
   RESPONSIVE
   ========================================================== */

@media (max-width: 900px) {
    .auth-panel { padding: 40px 22px 56px; }
}

@media (max-width: 420px) {
    .pw-rules { grid-template-columns: 1fr; }
    .pw-rules.is-visible { max-height: 110px; }
    .auth-panel { padding: 32px 18px 44px; }
}
