
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #7464ff;
    --primary-hover: #5a49ed;
    --text: #191b38;
    --muted: #858ba6;
    --border: #e6e8f2;
    --white: #ffffff;
    --success: #14b887;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    padding: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-x: hidden;
    font-family: 'DM Sans', sans-serif;
    color: var(--text);
    background:
        radial-gradient(ellipse at 10% 15%, #322b91 0%, transparent 36%),
        radial-gradient(ellipse at 90% 85%, #6021a9 0%, transparent 35%),
        linear-gradient(135deg, #080b20, #15113d 50%, #0c102a);
    background-attachment: fixed;
}

/* ===== Main Card ===== */
.register-container {
    display: grid;
    grid-template-columns: 0.95fr 1.05fr;
    width: 100%;
    max-width: 1150px;
    min-height: 760px;
    overflow: hidden;
    border: 1px solid rgb(255 255 255 / 18%);
    border-radius: 26px;
    background: rgb(255 255 255 / 96%);
    box-shadow:
        0 30px 100px rgb(0 0 0 / 30%),
        0 0 70px rgb(105 83 255 / 12%);
    animation: cardEnter 0.75s ease both;
}

@keyframes cardEnter {
    from {
        opacity: 0;
        transform: translateY(25px) scale(0.985);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ===== Left Branding Panel ===== */
.register-brand {
    position: relative;
    isolation: isolate;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
    padding: 54px 45px;
    color: #fff;
    background:
        radial-gradient(ellipse at 75% 80%, rgb(110 78 255 / 40%), transparent 35%),
        radial-gradient(ellipse at 5% 0%, rgb(48 59 173 / 35%), transparent 45%),
        linear-gradient(145deg, #090d25, #15133c 58%, #25145d);
}

.register-brand::before,
.register-brand::after {
    content: "";
    position: absolute;
    z-index: -1;
    border: 1px solid rgb(153 133 255 / 25%);
    border-radius: 50%;
    pointer-events: none;
}

.register-brand::before {
    width: 400px;
    height: 400px;
    top: -120px;
    right: -190px;
    box-shadow: 0 0 80px rgb(110 78 255 / 12%);
    animation: floatOrb 9s ease-in-out infinite;
}

.register-brand::after {
    width: 290px;
    height: 290px;
    bottom: -140px;
    left: -110px;
    background: rgb(114 79 255 / 9%);
    animation: floatOrb 11s ease-in-out infinite reverse;
}

@keyframes floatOrb {
    0%, 100% {
        transform: translate(0, 0);
    }
    50% {
        transform: translate(18px, -22px);
    }
}

/* ===== Brand Logo ===== */
.brand-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 55px;
    height: 55px;
    margin-bottom: 35px;
    border: 1px solid rgb(255 255 255 / 20%);
    border-radius: 17px;
    background: linear-gradient(135deg, #8877ff, #5340ec);
    box-shadow: 0 8px 28px rgb(101 79 255 / 40%);
    color: white;
    text-decoration: none;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 22px;
    font-weight: 800;
    transition: transform 0.25s, box-shadow 0.25s;
}

.brand-logo:hover {
    transform: translateY(-3px) rotate(-4deg);
    box-shadow: 0 12px 35px rgb(101 79 255 / 55%);
}

.brand-tagline {
    margin-bottom: 17px;
    color: #a9a4ff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 3px;
}

.register-brand h1 {
    max-width: 440px;
    margin-bottom: 20px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: clamp(32px, 3vw, 43px);
    font-weight: 800;
    line-height: 1.22;
    letter-spacing: -1.5px;
}

.register-brand h1 span {
    color: #9a8cff;
    text-shadow: 0 0 25px rgb(136 113 255 / 30%);
}

.brand-description {
    max-width: 400px;
    color: #c2c7e8;
    font-size: 14px;
    line-height: 1.9;
}

/* ===== Feature Items ===== */
.brand-features {
    display: grid;
    gap: 25px;
    margin-top: 38px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.feature-icon {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid rgb(255 255 255 / 15%);
    border-radius: 14px;
    background: linear-gradient(135deg, #7868ff, #4936d6);
    box-shadow: 0 5px 20px rgb(89 67 242 / 20%);
    color: white;
    font-size: 22px;
    transition: transform 0.25s, box-shadow 0.25s;
}

.feature-item:hover .feature-icon {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgb(105 80 255 / 35%);
}

.feature-item h3 {
    margin-bottom: 5px;
    font-size: 13px;
    font-weight: 700;
}

.feature-item p {
    color: #aeb5d7;
    font-size: 12px;
    line-height: 1.6;
}

.brand-footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgb(255 255 255 / 12%);
    color: #aeb5d7;
    font-size: 12px;
}

/* ===== Right Registration Panel ===== */
.register-form-section {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 45px 52px;
    background:
        radial-gradient(ellipse at 100% 0%, rgb(126 103 255 / 6%), transparent 35%),
        #fff;
}

.register-form-wrapper {
    width: 100%;
    max-width: 405px;
}

.welcome-badge {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 19px;
    padding: 9px 13px;
    border: 1px solid #e9e5ff;
    border-radius: 30px;
    background: #f3f0ff;
    color: #6455e9;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.8px;
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #7464ff;
    box-shadow: 0 0 10px rgb(116 100 255 / 55%);
    animation: pulseDot 1.8s ease-in-out infinite;
}

@keyframes pulseDot {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.55;
        transform: scale(1.3);
    }
}

.register-form-wrapper h2 {
    margin-bottom: 10px;
    color: #171a35;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 29px;
    font-weight: 800;
    letter-spacing: -1px;
}

.form-subtitle {
    margin-bottom: 25px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.8;
}

/* ===== Google Registration Button ===== */
.google-register-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    min-height: 47px;
    padding: 11px 15px;
    border: 1px solid #e1e4ee;
    border-radius: 10px;
    background: white;
    color: #282b42;
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.google-register-button:hover {
    border-color: #c9c1ff;
    background: #faf9ff;
    box-shadow: 0 5px 18px rgb(75 66 160 / 7%);
}

.google-icon {
    font-family: Arial, sans-serif;
    font-size: 20px;
    font-weight: 800;
    background: conic-gradient(
        from -45deg,
        #4285f4 0deg 90deg,
        #34a853 90deg 180deg,
        #fbbc05 180deg 250deg,
        #ea4335 250deg 310deg,
        #4285f4 310deg
    );
    color: transparent;
    background-clip: text;
    -webkit-background-clip: text;
}

/* ===== Divider ===== */
.divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
}

.divider span {
    flex: 1;
    height: 1px;
    background: #e9eaf2;
}

.divider p {
    flex-shrink: 0;
    color: #9398af;
    font-size: 11px;
}

/* ===== Form Fields ===== */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 7px;
    color: #343750;
    font-size: 12px;
    font-weight: 700;
}

.form-group input {
    width: 100%;
    height: 45px;
    padding: 0 13px;
    border: 1px solid var(--border);
    border-radius: 9px;
    outline: none;
    background: #fdfdff;
    color: var(--text);
    font-family: inherit;
    font-size: 12px;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.form-group input::placeholder {
    color: #a5abc0;
}

.form-group input:hover {
    border-color: #c9c1ff;
}

.form-group input:focus {
    border-color: var(--primary);
    background: white;
    box-shadow: 0 0 0 3px rgb(116 100 255 / 11%);
}

.password-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-wrapper input {
    padding-right: 60px;
}

.toggle-password {
    position: absolute;
    right: 12px;
    padding: 4px;
    border: none;
    background: transparent;
    color: var(--primary);
    font-family: inherit;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
}

.field-hint {
    margin-top: 6px;
    color: #969bb0;
    font-size: 10px;
}

/* ===== Terms ===== */
.terms-option {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin: 5px 0 17px;
    color: #777e98;
    font-size: 11px;
    line-height: 1.8;
    cursor: pointer;
}

.terms-option input {
    flex-shrink: 0;
    width: 14px;
    height: 14px;
    margin-top: 3px;
    accent-color: var(--primary);
}

.terms-option a,
.login-link a {
    color: var(--primary);
    font-weight: 700;
    text-decoration: none;
}

.terms-option a:hover,
.login-link a:hover {
    text-decoration: underline;
}

/* ===== Submit Button ===== */
.register-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    min-height: 47px;
    padding: 12px 16px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(110deg, #7867ff, #5142dc);
    color: white;
    font-family: inherit;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 7px 20px rgb(101 82 245 / 23%);
    transition: transform 0.2s, box-shadow 0.2s, filter 0.2s;
}

.register-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 11px 25px rgb(101 82 245 / 32%);
    filter: brightness(1.05);
}

.register-button:active {
    transform: translateY(0);
}

.register-button span {
    font-size: 18px;
    transition: transform 0.2s;
}

.register-button:hover span {
    transform: translateX(4px);
}

.form-message {
    margin-bottom: 12px;
    color: #b42318;
    font-size: 11px;
    line-height: 1.6;
}

.form-message:empty {
    display: none;
}

/* ===== Bottom Links ===== */
.login-link {
    margin-top: 22px;
    color: var(--muted);
    font-size: 12px;
    text-align: center;
}

.security-note {
    margin-top: 19px;
    color: #a0a5b9;
    font-size: 10px;
    text-align: center;
}

/* ===== Focus Accessibility ===== */
button:focus-visible,
a:focus-visible,
input:focus-visible {
    outline: 3px solid rgb(116 100 255 / 35%);
    outline-offset: 3px;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    body {
        padding: 20px;
    }

    .register-container {
        grid-template-columns: 1fr;
        max-width: 540px;
        min-height: auto;
    }

    .register-brand {
        padding: 35px;
    }

    .register-brand h1 {
        font-size: 34px;
    }

    .brand-logo {
        margin-bottom: 24px;
    }

    .brand-features {
        gap: 18px;
        margin-top: 26px;
    }

    .brand-footer {
        margin-top: 25px;
    }

    .register-form-section {
        padding: 38px 35px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }

    .register-container {
        border-radius: 18px;
    }

    .register-brand {
        padding: 27px 23px;
    }

    .register-brand h1 {
        font-size: 29px;
    }

    .brand-description {
        font-size: 13px;
    }

    .register-form-section {
        padding: 30px 22px;
    }

    .register-form-wrapper h2 {
        font-size: 25px;
    }

    .brand-features {
        gap: 16px;
    }
}

/* Respect accessibility preferences */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Google Sign-In button hover effect */
.google-login-button,
.google-register-button,
#googleLoginButton,
#googleRegisterButton {
    border-radius: 10px;
    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        border-color 0.25s ease,
        background-color 0.25s ease;
}

/* Hover effect */
.google-login-button:hover,
.google-register-button:hover,
#googleLoginButton:hover,
#googleRegisterButton:hover {
    transform: translateY(-3px);
    border-color: #a78bfa;
    box-shadow: 0 8px 22px rgba(124, 58, 237, 0.18);
}

/* Keyboard accessibility */
.google-login-button:focus-within,
.google-register-button:focus-within,
#googleLoginButton:focus-within,
#googleRegisterButton:focus-within {
    outline: 2px solid #a78bfa;
    outline-offset: 3px;
}

/* Click effect */
.google-login-button:active,
.google-register-button:active,
#googleLoginButton:active,
#googleRegisterButton:active {
    transform: translateY(0);
    box-shadow: 0 3px 10px rgba(124, 58, 237, 0.12);
}

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {
    .google-login-button,
    .google-register-button,
    #googleLoginButton,
    #googleRegisterButton {
        transition: none;
    }

    .google-login-button:hover,
    .google-register-button:hover,
    #googleLoginButton:hover,
    #googleRegisterButton:hover {
        transform: none;
    }
}

