:root {
    --brand-primary: #00FF66;
    --brand-dark: #00CC52;
    --bg-main: #021204;
    --input-bg: #052109;
    --border-color: rgba(0, 255, 102, 0.2);
    --text-primary: #FFFFFF;
    --text-secondary: #B0C4B1;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Tajawal', sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    display: flex;
    justify-content: center;
    min-height: 100vh;
    animation: smoothFadeIn 0.4s ease forwards;
    transition: opacity 0.3s ease;
    /* Starry background and top glow simulation */
    background-image: 
        radial-gradient(circle at 50% -10%, rgba(0, 255, 102, 0.2) 0%, transparent 40%),
        radial-gradient(1px 1px at 20px 30px, rgba(255,255,255,0.8), rgba(0,0,0,0)),
        radial-gradient(1.5px 1.5px at 150px 80px, rgba(255,255,255,0.6), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 300px 40px, rgba(255,255,255,0.9), rgba(0,0,0,0)),
        radial-gradient(2px 2px at 80px 200px, rgba(255,255,255,0.5), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 400px 300px, rgba(255,255,255,0.8), rgba(0,0,0,0)),
        radial-gradient(1.5px 1.5px at 200px 450px, rgba(255,255,255,0.7), rgba(0,0,0,0));
    background-repeat: no-repeat;
    background-size: 100% 100%, 100% 100%, 100% 100%, 100% 100%, 100% 100%, 100% 100%, 100% 100%;
}

@keyframes smoothFadeIn {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Add curved top glow similar to image */
body::before {
    content: '';
    position: absolute;
    top: -50px;
    left: -50%;
    width: 200%;
    height: 150px;
    border-radius: 50%;
    box-shadow: 0 50px 100px rgba(0, 255, 102, 0.15);
    pointer-events: none;
}

.register-container {
    width: 100%;
    max-width: 480px;
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

.top-header {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    margin-bottom: 40px;
    margin-top: 15px;
}

.back-btn {
    position: absolute;
    left: 0;
    color: var(--text-primary);
    font-size: 22px;
    text-decoration: none;
    padding: 5px;
}

.top-header h2 {
    font-size: 20px;
    font-weight: 500;
}

form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

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

.form-group label {
    font-size: 15px;
    color: var(--text-secondary);
}

input, select {
    width: 100%;
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px 15px;
    color: var(--text-primary);
    font-size: 14px;
    outline: none;
    transition: all 0.3s;
    appearance: none;
}

select {
    cursor: pointer;
}

select option {
    background: var(--bg-main);
    color: var(--text-primary);
}

input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

input:focus {
    border-color: var(--brand-primary);
    box-shadow: 0 0 10px rgba(0, 255, 102, 0.1);
}

.input-with-btn, .input-icon-wrapper {
    position: relative;
}

.send-code-btn {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    color: var(--text-secondary);
    border: none;
    font-size: 15px;
    cursor: pointer;
    font-weight: bold;
}

.send-code-btn:hover {
    color: var(--brand-primary);
}

.input-with-btn input {
    padding-right: 70px;
}

.input-icon-wrapper .toggle-pwd {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 18px;
    cursor: pointer;
    opacity: 0.8;
}

.mt-10 {
    margin-top: 10px;
}

.register-btn {
    width: 100%;
    background: linear-gradient(90deg, #66FF99 0%, #00CC52 100%);
    color: #000;
    border: none;
    border-radius: 8px;
    padding: 16px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(0, 255, 102, 0.3);
    margin-top: 10px;
    transition: all 0.3s;
}

.register-btn:hover {
    box-shadow: 0 0 30px rgba(0, 255, 102, 0.6);
    transform: translateY(-2px);
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--brand-primary);
    color: #000;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: bold;
    font-size: 14px;
    transition: bottom 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 1000;
    box-shadow: 0 5px 15px rgba(0, 255, 102, 0.4);
    white-space: nowrap;
}

.toast.show {
    bottom: 40px;
}

/* Elegant Success Modal */
.success-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(2, 18, 4, 0.8);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s ease;
}

.success-modal-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.success-modal {
    background: linear-gradient(145deg, #052109, #021204);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 40px 30px;
    width: 85%;
    max-width: 320px;
    text-align: center;
    transform: translateY(30px) scale(0.9);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 20px 50px rgba(0, 255, 102, 0.15);
}

.success-modal-overlay.show .success-modal {
    transform: translateY(0) scale(1);
}

.success-icon {
    width: 80px;
    height: 80px;
    background: rgba(0, 255, 102, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 0 20px rgba(0, 255, 102, 0.3);
    animation: pulseGlow 2s infinite;
}

.success-icon i {
    font-size: 36px;
    color: var(--brand-primary);
}

.success-modal h3 {
    color: var(--text-primary);
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 12px;
    letter-spacing: 2px;
}

.success-modal p {
    color: var(--text-secondary);
    font-size: 16px;
    line-height: 1.5;
}

@keyframes pulseGlow {
    0% { box-shadow: 0 0 20px rgba(0, 255, 102, 0.2); }
    50% { box-shadow: 0 0 40px rgba(0, 255, 102, 0.6); }
    100% { box-shadow: 0 0 20px rgba(0, 255, 102, 0.2); }
}
