/* ============================================================
   AI BookAgents — Split Auth Layout
   Left: dark purple illustration panel
   Right: clean white/light form panel
   ============================================================ */

/* ---- Reset auth-body ---- */
.auth-split-body {
    margin: 0; padding: 0;
    min-height: 100vh;
    background: #0f0720;
    display: flex;
    font-family: 'Inter', -apple-system, 'Segoe UI', sans-serif;
}

/* ---- Outer wrapper ---- */
.auth-split-wrap {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* ============================================================
   LEFT PANEL
   ============================================================ */
.auth-split-left {
    position: relative;
    flex: 0 0 45%;
    background: linear-gradient(155deg, #0d0726 0%, #1e0a4a 35%, #2d1265 65%, #1a0d50 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 48px 40px;
}

/* Grid / circuit overlay */
.auth-split-left::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(168,85,247,.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(168,85,247,.06) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
}

/* Glow orbs */
.auth-split-left::after {
    content: '';
    position: absolute;
    width: 400px; height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(99,102,241,.25) 0%, transparent 70%);
    bottom: -80px; right: -80px;
    pointer-events: none;
}

.auth-left-inner {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 440px;
}

/* Logo on left */
.auth-left-logo {
    margin-bottom: 36px;
}

/* Headline */
.auth-left-headline {
    font-size: clamp(1.6rem, 3vw, 2.3rem);
    font-weight: 800;
    color: #fff;
    line-height: 1.2;
    margin-bottom: 14px;
    letter-spacing: -.02em;
}

.auth-left-sub {
    font-size: .92rem;
    color: rgba(255,255,255,.6);
    line-height: 1.6;
    margin-bottom: 36px;
}

/* Floating sparkles */
.auth-sparkle {
    position: absolute;
    color: rgba(168,85,247,.6);
    font-size: 1.1rem;
    pointer-events: none;
    animation: sparkle-float 3s ease-in-out infinite;
}
.sp1 { top: 15%; left: 12%; animation-delay: 0s;   font-size: .9rem; }
.sp2 { top: 20%; right: 14%; animation-delay: .8s; font-size: 1.3rem; color: rgba(99,102,241,.7); }
.sp3 { bottom: 30%; left: 10%; animation-delay: 1.4s; font-size: 1.5rem; color: rgba(192,132,252,.5); }
.sp4 { bottom: 15%; right: 10%; animation-delay: .4s; }
@keyframes sparkle-float {
    0%,100% { transform: translateY(0) rotate(0deg); opacity: .6; }
    50%      { transform: translateY(-8px) rotate(15deg); opacity: 1; }
}

/* Book illustration card */
.auth-book-card {
    position: relative;
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(168,85,247,.2);
    border-radius: 20px;
    padding: 28px 24px 36px;
    backdrop-filter: blur(12px);
    box-shadow: 0 8px 40px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.08);
}

.auth-book-glow {
    position: absolute;
    top: -40px; left: 50%; transform: translateX(-50%);
    width: 200px; height: 80px;
    background: radial-gradient(ellipse, rgba(168,85,247,.35), transparent 70%);
    pointer-events: none;
}

.auth-book-visual {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
}

.auth-book-icon {
    font-size: 4.5rem;
    filter: drop-shadow(0 4px 20px rgba(168,85,247,.6));
    animation: book-float 3s ease-in-out infinite;
}
@keyframes book-float {
    0%,100% { transform: translateY(0); }
    50%      { transform: translateY(-8px); }
}

.auth-book-lines {
    display: flex; flex-direction: column; gap: 5px;
    margin-top: 10px; width: 60%;
}
.auth-book-lines span {
    height: 3px;
    border-radius: 2px;
    background: rgba(255,255,255,.15);
}
.auth-book-lines span:nth-child(1) { width: 100%; }
.auth-book-lines span:nth-child(2) { width: 75%; }
.auth-book-lines span:nth-child(3) { width: 55%; }

/* Agent chip */
.auth-agent-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(15,7,32,.7);
    border: 1px solid rgba(168,85,247,.35);
    border-radius: 999px;
    padding: 8px 14px 8px 10px;
    font-size: .78rem;
    color: rgba(255,255,255,.85);
    backdrop-filter: blur(8px);
    box-shadow: 0 4px 16px rgba(0,0,0,.3);
    text-align: left;
}
.auth-agent-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: #34d399;
    box-shadow: 0 0 6px rgba(52,211,153,.8);
    flex-shrink: 0;
    animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
    0%,100% { box-shadow: 0 0 6px rgba(52,211,153,.8); }
    50%      { box-shadow: 0 0 12px rgba(52,211,153,1); }
}
.auth-chip-icon { font-size: 1.1rem; }
.auth-chip-title { font-weight: 700; font-size: .75rem; color: #fff; line-height: 1.1; }
.auth-chip-sub   { font-size: .7rem;  color: rgba(255,255,255,.55); line-height: 1.1; }
.auth-chip-spark { color: #fbbf24; font-size: .85rem; }

/* Bottom ring glow */
.auth-ring-glow {
    position: absolute;
    bottom: -2px; left: 50%; transform: translateX(-50%);
    width: 140px; height: 14px;
    background: radial-gradient(ellipse, rgba(99,102,241,.55), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

/* ============================================================
   RIGHT PANEL — dark
   ============================================================ */
.auth-split-right {
    flex: 1;
    background: linear-gradient(155deg, #130824 0%, #1e0a4a 60%, #0d1550 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 40px;
    position: relative;
}

/* subtle right panel glow */
.auth-split-right::before {
    content: '';
    position: absolute;
    top: -60px; right: -60px;
    width: 300px; height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(99,102,241,.2), transparent 70%);
    pointer-events: none;
}

.auth-form-wrap {
    width: 100%;
    max-width: 400px;
    position: relative;
    z-index: 1;
}

/* Logo on right */
.auth-form-logo {
    display: flex;
    justify-content: center;
    margin-bottom: 28px;
}

/* Form title */
.auth-form-title {
    font-size: 1.65rem;
    font-weight: 800;
    color: #ffffff;
    text-align: center;
    margin-bottom: 6px;
    letter-spacing: -.02em;
}
.auth-form-sub {
    font-size: .875rem;
    color: rgba(255,255,255,.5);
    text-align: center;
    margin-bottom: 28px;
}

/* Input fields */
.auth-field-wrap {
    position: relative;
}
.auth-field-icon {
    position: absolute;
    left: 14px;
    top: 50%; transform: translateY(-50%);
    color: rgba(255,255,255,.35);
    font-size: .95rem;
    pointer-events: none;
}
.auth-field {
    width: 100%;
    border: 1.5px solid rgba(255,255,255,.1);
    border-radius: 10px;
    padding: 13px 44px;
    font-size: .9rem;
    color: #f3f0ff;
    background: rgba(255,255,255,.07);
    outline: none;
    transition: border-color .2s, box-shadow .2s, background .2s;
    backdrop-filter: blur(6px);
}
.auth-field:focus {
    border-color: #a855f7;
    background: rgba(255,255,255,.1);
    box-shadow: 0 0 0 3px rgba(168,85,247,.2);
}
.auth-field::placeholder { color: rgba(255,255,255,.3); }
.auth-field-eye {
    position: absolute;
    right: 12px;
    top: 50%; transform: translateY(-50%);
    background: none; border: none;
    color: rgba(255,255,255,.35); font-size: .95rem;
    cursor: pointer; padding: 4px;
}
.auth-field-eye:hover { color: rgba(255,255,255,.7); }

/* Remember / forgot row */
.auth-row-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.auth-remember {
    display: flex; align-items: center; gap: 6px;
    font-size: .83rem; color: rgba(255,255,255,.5); cursor: pointer;
}
.auth-remember input { accent-color: #a855f7; cursor: pointer; }
.auth-forgot {
    font-size: .83rem;
    color: rgba(255,255,255,.45);
    text-decoration: none;
    transition: color .15s;
}
.auth-forgot:hover { color: #c084fc; }

/* Primary button */
.auth-btn-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #5b21b6, #a855f7, #6366f1);
    background-size: 200% 100%;
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: .95rem;
    font-weight: 700;
    cursor: pointer;
    transition: background-position .3s ease, box-shadow .2s;
    box-shadow: 0 4px 24px rgba(99,102,241,.45);
}
.auth-btn-primary:hover {
    background-position: 100% 0;
    box-shadow: 0 6px 32px rgba(99,102,241,.6);
    color: #fff;
}
.auth-btn-primary:disabled {
    opacity: .7; cursor: not-allowed;
}

/* Divider */
.auth-divider {
    display: flex; align-items: center; gap: 12px;
    margin: 20px 0; color: rgba(255,255,255,.2); font-size: .8rem;
}
.auth-divider::before, .auth-divider::after {
    content: ''; flex: 1; height: 1px; background: rgba(255,255,255,.1);
}

/* Signup link */
.auth-signup-link {
    text-align: center;
    font-size: .875rem;
    color: rgba(255,255,255,.4);
    margin-top: 24px;
    margin-bottom: 0;
}
.auth-signup-link a { color: #c084fc; font-weight: 600; text-decoration: none; }
.auth-signup-link a:hover { color: #e9d5ff; text-decoration: underline; }

/* Footer copy */
.auth-footer-copy {
    text-align: center;
    font-size: .75rem;
    color: rgba(255,255,255,.2);
    margin-top: 32px;
    margin-bottom: 0;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 768px) {
    .auth-split-wrap { flex-direction: column; }
    .auth-split-left  { flex: 0 0 auto; padding: 36px 24px; }
    .auth-left-headline { font-size: 1.5rem; }
    .auth-split-right { padding: 36px 20px; }
    .auth-book-card { padding: 20px 16px 28px; }
}
