/* Sign Up Page Redesign */
.signup-page-wrapper {
    min-height: calc(100vh - 5.5rem);
    /* Adjust for navbar height */
    background-color: #fff;
    display: flex;
    flex-wrap: wrap;
}

.signup-content-row {
    display: flex;
    width: 100%;
    flex-wrap: wrap;
}

.signup-form-side {
    flex: 1;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-color: #fff;
    min-width: 320px;
    color: #212529;
    /* Enforce dark text */
}

.signup-image-side {
    flex: 1;
    background-color: #7ecfc7;
    /* Brand Teal */
    background-image: url("../images/signup_bg.png");
    background-size: cover;
    background-position: center;
    position: relative;
    min-height: 500px;
    display: flex;
    align-items: flex-end;
    color: white;
    min-width: 320px;
}

/* Gradient Overlay for text readability */
.signup-image-side::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* Gradient from Brand Dark to Brand Teal */
    background: linear-gradient(to bottom, rgba(45, 58, 58, 0.4), rgba(126, 207, 199, 0.9));
    z-index: 1;
}

.signup-image-side video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.signup-overlay-content {
    position: relative;
    z-index: 2;
    padding: 3rem;
    width: 100%;
}

.signup-quote {
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 1.5rem;
}

.signup-author {
    display: flex;
    align-items: center;
}

.signup-author img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    margin-right: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

/* RTL Support via generic Bootstrap/flexbox behavior + specific overrides if needed */
html[dir="rtl"] .signup-author img {
    margin-right: 0;
    margin-left: 1rem;
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
    .signup-page-wrapper {
        height: auto;
    }

    .signup-image-side {
        min-height: 300px;
        order: -1;
        display: none;
    }
}

/* Form Styles refined */
.signup-form-side .card {
    border: none;
    box-shadow: none;
}

.signup-form-side h4 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #333;
}

.form-label {
    font-weight: 600;
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 0.4rem;
}

.text-primary {
    color: #7ecfc7 !important;
    /* Force Brand Color for primary text in this scope */
}

.form-control,
.form-select {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    border: 1px solid #e0e0e0;
    background-color: #f8f9fa;
    color: #212529;
    /* Enforce dark text */
}

.form-control:focus,
.form-select:focus {
    background-color: #fff;
    border-color: #7ecfc7;
    box-shadow: 0 0 0 4px rgba(126, 207, 199, 0.1);
}

.input-group-text {
    background: transparent;
    border: none;
    padding-left: 0;
}

.input-group .form-control {
    border-left: 0;
}

/* Custom Input Group styling to look like one block */
.input-group {
    background-color: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 0.5rem;
    padding: 0.1rem 0.5rem;
    transition: all 0.2s;
}

.input-group:focus-within {
    border-color: #7ecfc7;
    box-shadow: 0 0 0 4px rgba(126, 207, 199, 0.1);
    background-color: #fff;
}

.input-group .input-group-text {
    border: none;
    background: transparent;
    color: #aaa;
}

/* Brand Button */
.btn-brand {
    background-color: #7ecfc7;
    border-color: #7ecfc7;
    color: #fff;
}

.btn-brand:hover {
    background-color: #6bbeb6;
    /* Slightly darker teal */
    border-color: #6bbeb6;
    color: #fff;
}

.input-group .form-control,
.input-group .form-select {
    border: none;
    background: transparent;
    padding-left: 0.5rem;
    box-shadow: none !important;
}

/* --- Dark Mode Support --- */
[data-bs-theme="dark"] .signup-page-wrapper {
    background-color: #212529;
}

[data-bs-theme="dark"] .signup-form-side {
    background-color: #2b3035;
    color: #f8f9fa;
}

[data-bs-theme="dark"] .signup-form-side .text-dark,
[data-bs-theme="dark"] .signup-form-side h1,
[data-bs-theme="dark"] .signup-form-side h2,
[data-bs-theme="dark"] .signup-form-side h3,
[data-bs-theme="dark"] .signup-form-side h4,
[data-bs-theme="dark"] .signup-form-side h5,
[data-bs-theme="dark"] .signup-form-side h6 {
    color: #f8f9fa !important;
}

[data-bs-theme="dark"] .signup-form-side .text-secondary {
    color: #adb5bd !important;
}

[data-bs-theme="dark"] .form-label {
    color: #adb5bd;
}

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select {
    background-color: #212529;
    border-color: #495057;
    color: #f8f9fa;
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background-color: #2b3035;
    border-color: #7ecfc7;
    color: #fff;
}

[data-bs-theme="dark"] .input-group,
[data-bs-theme="dark"] .input-group-text {
    background-color: #212529;
    border-color: #495057;
    color: #adb5bd;
}

[data-bs-theme="dark"] .input-group:focus-within {
    background-color: #2b3035;
    border-color: #7ecfc7;
}

[data-bs-theme="dark"] .input-group .form-control,
[data-bs-theme="dark"] .input-group .form-select {
    background-color: transparent;
    border: none;
    color: #f8f9fa;
}

/* Dark Mode Support for Select Options */
[data-bs-theme="dark"] select option {
    background-color: #2b3035;
    color: #f8f9fa;
}

/* Dark Mode Support for intl-tel-input */
[data-bs-theme="dark"] .iti__country-list {
    background-color: #2b3035;
    border: 1px solid #495057;
    color: #f8f9fa;
    z-index: 1050;
    /* Ensure it stays on top of other elements like eye icons */
}

/* Global z-index fix for intl-tel-input dropdown */
.iti__country-list {
    z-index: 1050;
}

[data-bs-theme="dark"] .iti__country:hover,
[data-bs-theme="dark"] .iti__country.iti__highlight {
    background-color: #3d4248;
}

[data-bs-theme="dark"] .iti__divider {
    border-bottom: 1px solid #495057;
}