*, *::before, *::after { box-sizing: border-box; }

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* ── Left Panel (image) ── */
.left-panel {
    flex: 1;
    background-image: linear-gradient(rgba(37, 99, 235, 0.2), rgba(37, 99, 235, 0.55)), url('./images/Background\ Image.png');
    background-size: cover;
    background-position: center;
    display: none;
}

@media (min-width: 768px) {
    .left-panel { display: block; }
}

/* ── Right Panel ── */
.right-panel {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    overflow-y: auto;
    padding: 40px 20px;
    box-sizing: border-box;
    height: 100vh;
}

@media (min-width: 768px) {
    .right-panel { width: 50%; }
}

/* ── Mobile: stack image header on top ── */
@media (max-width: 767px) {
    body {
        flex-direction: column;
        height: auto;
        min-height: 100vh;
        overflow-y: auto;
    }

    .left-panel {
        display: none;
    }

    .right-panel {
        flex: none;
        width: 100%;
        height: auto;
        align-items: flex-start;
        padding: 32px 24px 48px;
    }

    .logo {
        margin-bottom: 20px;
    }

    .logo img {
        width: 130px;
    }
}

/* ── Form Card ── */
.signup-container {
    width: 100%;
    max-width: 440px;
}

/* ── Logo ── */
.logo {
    display: flex;
    justify-content: center;
    margin-bottom: 28px;
}

.logo img {
    width: 160px;
    height: auto;
    filter: hue-rotate(195deg);
}

/* ── Heading ── */
.signup-container h1 {
    margin: 0 0 6px;
    font-size: 1.35rem;
    font-weight: 700;
    color: #101928;
    text-align: center;
}

.subtitle {
    margin: 0 0 28px;
    font-size: 0.875rem;
    color: #6B7280;
    text-align: center;
}

/* ── Input Groups ── */
.input-group {
    margin-bottom: 16px;
}

.input-group label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

.input-group label .required {
    color: #DC2626;
    margin-left: 2px;
}

.input-group input[type="text"],
.input-group input[type="email"],
.input-group input[type="password"] {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #D1D5DB;
    border-radius: 8px;
    font-size: 0.9rem;
    color: #111827;
    background: #fff;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.input-group input:focus {
    border-color: #2563EB;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.input-error {
    border-color: #DC2626 !important;
}

.input-error:focus {
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15) !important;
}

/* ── Password wrapper with eye icon ── */
.password-wrapper {
    position: relative;
}

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

.toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #9CA3AF;
    padding: 0;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-password:hover { color: #6B7280; }

/* ── Error message ── */
.error-msg {
    color: #DC2626;
    font-size: 0.775rem;
    margin-top: 5px;
    display: block;
    min-height: 16px;
}

/* ── Submit button ── */
.signup-button {
    width: 100%;
    padding: 12px;
    background-color: #2563EB;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease;
    margin-top: 8px;
    margin-bottom: 20px;
}

.signup-button:hover { background-color: #1D4ED8; }
.signup-button:active { background-color: #1E40AF; }
.signup-button:disabled { background-color: #93C5FD; cursor: not-allowed; }

/* ── Alternative link ── */
.alternative {
    text-align: center;
    font-size: 0.875rem;
    color: #6B7280;
    margin: 0;
}

.alternative a {
    color: #2563EB;
    font-weight: 600;
    text-decoration: none;
}

.alternative a:hover { text-decoration: underline; }

/* ── Form-level error ── */
#form-error {
    display: block;
    text-align: center;
    margin-bottom: 8px;
}
