body {
    background: linear-gradient(135deg, #f5f5f5 60%, #fcf6ba 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Tajawal', Arial, sans-serif;
    margin: 0;
    padding: 0;
}

.register-page {
width: 100%;
display: flex;
align-items: center;
justify-content: center;
min-height: 100vh;
}

.register-container {
background: #fff;
border-radius: 22px;
box-shadow: 0 4px 32px rgba(0,51,102,0.10), 0 1.5px 0 #fff;
padding: 2.7rem 2.2rem 2.2rem 2.2rem;
max-width: 450px;
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
gap: 1.7rem;
position: relative;
overflow: hidden;
margin: 0 auto;
}

.register-container:before {
content: "";
position: absolute;
top: -60px; left: -60px;
width: 120px; height: 120px;
background: linear-gradient(135deg, #e67e22 0%, #f39c12 100%);
opacity: 0.13;
border-radius: 50%;
z-index: 0;
}

.register-container:after {
content: "";
position: absolute;
bottom: -50px; right: -50px;
width: 100px; height: 100px;
background: linear-gradient(135deg, #e67e22 0%, #f39c12 100%);
opacity: 0.10;
border-radius: 50%;
z-index: 0;
}

.register-container h2 {
color: #2176ff !important;
font-size: 1.7rem;
margin-bottom: 0.7rem;
font-weight: bold;
background: linear-gradient(135deg, #2176ff 0%, #1e5bb8 100%);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
z-index: 1;
}

.register-form {
width: 100%;
display: flex;
flex-direction: column;
gap: 1.2rem;
z-index: 1;
}

.student-fields,
.broker-fields {
display: none;
flex-direction: column;
gap: 1.2rem;
width: 100%;
}

.register-form label {
font-weight: bold;
color: #2176ff;
margin-bottom: 0.3rem;
font-size: 1rem;
display: flex;
align-items: center;
gap: 0.4rem;
}

.input-group {
position: relative;
width: 100%;
}

.password-field {
position: relative;
width: 100%;
}

.register-form .password-field input {
padding-left: 3rem;
}

.password-toggle {
position: absolute;
left: 0.65rem;
top: 50%;
transform: translateY(-50%);
width: 2rem;
height: 2rem;
border: 0;
border-radius: 8px;
background: transparent;
color: #777;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: color 0.2s, background-color 0.2s;
}

.password-toggle:hover,
.password-toggle:focus {
background: rgba(33, 118, 255, 0.08);
color: #2176ff;
outline: none;
}

.register-terms {
display: flex;
flex-direction: column;
gap: 0.75rem;
padding: 1rem;
border: 1.5px solid #eee;
border-radius: 10px;
background: #fafbfc;
}

.register-terms h4 {
margin: 0;
color: #2176ff;
font-size: 1rem;
}

.register-terms .form-check {
display: flex;
align-items: flex-start;
gap: 0.65rem;
}

.register-terms input[type="checkbox"] {
width: auto;
min-width: 1rem;
margin-top: 0.25rem;
box-shadow: none;
}

.register-terms label {
margin: 0;
color: #495057;
font-size: 0.95rem;
line-height: 1.6;
}

.important-field-note {
display: flex;
align-items: flex-start;
gap: 0.5rem;
margin-top: 0.55rem;
padding: 0.65rem 0.75rem;
border: 1px solid #fbbf24;
border-radius: 10px;
background: #fffbeb;
color: #92400e;
font-size: 0.9rem;
font-weight: 700;
line-height: 1.5;
}

.important-field-note i {
margin-top: 0.15rem;
color: #d97706;
}

.register-form input,
.register-form select {
padding: 0.8rem 1rem;
border: 1.5px solid #eee;
border-radius: 10px;
font-size: 1rem;
outline: none;
transition: border 0.2s, box-shadow 0.2s;
font-family: 'Tajawal', sans-serif;
background: #fafbfc;
box-shadow: 0 1px 4px rgba(0,51,102,0.03);
width: 100%;
box-sizing: border-box;
}

.register-form input:focus,
.register-form select:focus {
border: 1.5px solid #2176ff;
box-shadow: 0 2px 8px rgba(0,51,102,0.08);
}

.user-type-selection {
display: flex;
gap: 0.5rem;
margin-bottom: 1rem;
}

.user-type-option {
flex: 1;
position: relative;
}

.user-type-option input[type="radio"] {
display: none;
}

.user-type-option label {
display: flex;
flex-direction: column;
align-items: center;
padding: 1rem 0.5rem;
border: 2px solid #eee;
border-radius: 12px;
cursor: pointer;
transition: all 0.3s ease;
background: #fafbfc;
text-align: center;
font-weight: 600;
color: #666;
}

.user-type-option input[type="radio"]:checked + label {
border-color: #2176ff;
background: linear-gradient(135deg, rgba(33, 118, 255, 0.1) 0%, rgba(30, 91, 184, 0.1) 100%);
color: #2176ff;
transform: translateY(-2px);
box-shadow: 0 4px 12px rgba(33, 118, 255, 0.2);
}

.user-type-option label i {
font-size: 1.5rem;
margin-bottom: 0.5rem;
}

.user-type-option label span {
font-size: 0.9rem;
}

.register-btn {
background: linear-gradient(135deg, #2176ff 0%, #1e5bb8 100%);
color: white;
border: none;
padding: 1rem 2rem;
border-radius: 12px;
font-size: 1.1rem;
font-weight: 600;
cursor: pointer;
transition: all 0.3s ease;
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
width: 100%;
margin-top: 1rem;
}

.register-btn:hover {
transform: translateY(-2px);
box-shadow: 0 10px 25px rgba(33, 118, 255, 0.3);
}

.register-footer {
text-align: center;
color: #666;
font-size: 0.9rem;
z-index: 1;
}

.register-footer a {
color: #2176ff;
text-decoration: none;
font-weight: 600;
}

.register-footer a:hover {
text-decoration: underline;
}

.alert {
padding: 1rem;
border-radius: 8px;
margin-bottom: 1rem;
width: 100%;
z-index: 1;
}

.alert-danger {
background: #fee;
border: 1px solid #fcc;
color: #c33;
}

.alert-success {
background: #efe;
border: 1px solid #cfc;
color: #3c3;
}

.alert ul {
margin: 0;
padding-right: 1rem;
}

.form-row {
display: flex;
gap: 1rem;
}

.form-row .input-group {
flex: 1;
}

@media (max-width: 600px) {
.register-container {
    margin: 1rem;
    padding: 2rem 1.5rem;
    max-width: 100%;
}

.register-container h2 {
    font-size: 1.5rem;
}

.register-btn {
    padding: 0.9rem 1.5rem;
    font-size: 1rem;
}

.form-row {
    flex-direction: column;
    gap: 0;
}

.user-type-selection {
    flex-direction: column;
}
}

@media (max-width: 400px) {
.register-container {
    margin: 0.5rem;
    padding: 1.5rem 1rem;
}
}
