body {
    /* Font family handled by eBay CSS */
    margin: 0;
    padding: 0;
    background-color: #fff;
    color: #333;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

header.login-header {
    display: flex;
    flex-direction: column;
    width: 100%;
    padding: 0;
    max-width: 27.5rem;
    margin: 0 auto;
    box-sizing: border-box;
    position: relative; /* Ensure stacking context */
    min-height: auto; /* Override any global header min-height */
}

#SkSurvey {
    width: 100%;
    text-align: right;
    padding: 0.625rem 0 0;
    box-sizing: border-box;
    font-size: 0.75rem;
    background-color: transparent; /* Changed from white to avoid blocking */
    margin-bottom: 0.625rem;
    position: relative; /* Ensure visibility */
    z-index: 10;
}

#SkSurvey a {
    color: #000;
    text-decoration: underline;
}

.logo {
    align-self: center;
    padding: 0 0 1rem 0;
    display: block; /* Changed to block */
    line-height: 0; /* Remove extra space */
}

.ebay-logo-img {
    height: 3rem;
    width: auto;
    max-width: none; /* Prevent constraint */
    display: block; /* Remove inline-block spacing */
}

.login-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 0.625rem; /* 10px / 16 */
    width: 100%;
    max-width: 27.5rem; /* 440px / 16 */
    margin: 0 auto;
    padding-left: 1rem; /* 16px / 16 */
    padding-right: 1rem;
    box-sizing: border-box;
}

h1 {
    font-size: 1.5rem; /* Increased from 2rem to 36px/16 */
    font-weight: 800; /* Bolder */
    margin-bottom: 1.5rem;
    text-align: center;
    color: #191919;
    margin-top: 0;
}

/* New Register Prompt Styles */
.register-prompt {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    background-color: #f8f8f8;
    padding: 0.5rem; /* Increased padding */
    border-radius: 2rem; /* Increased radius */
    box-sizing: border-box;
    margin-bottom: 1.5rem;
    font-size: 0.825rem; /* Increased font size */
    font-weight: 500;
    color: #191919;
    min-height: 2rem; /* Ensure minimum height */
}

.btn-secondary {
    background-color: #fff;
    color: #191919;
    border: 1px solid #191919;
    padding: 0.425rem 1.25rem; /* Increased padding */
    border-radius: 1.5rem; /* Increased radius */
    text-decoration: none;
    font-weight: 500;
    font-size: 0.8rem;
    transition: background-color 0.2s;
    white-space: nowrap;
}

.btn-secondary:hover {
    background-color: #eee;
}

.form-group {
    width: 100%;
    margin-bottom: 1.5rem; /* 24px */
    position: relative;
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem; /* 12px 16px */
    font-size: 1rem; /* 16px */
    border: 1px solid #767676;
    border-radius: 0.5rem; /* 8px */
    box-sizing: border-box;
    height: 3rem; /* 48px */
    background-color: #f7f7f7;
    color: #707070;
}

.form-input:focus {
    border-color: #0654ba;
    outline: none;
    box-shadow: 0 0 0 0.125rem rgba(6, 84, 186, 0.2);
    background-color: #fff;
    color: #191919;
}

.input-error {
    border-color: #e0103a !important;
    background-color: #fdf0f2 !important;
}

.error-message {
    color: #e0103a;
    font-size: 0.875rem;
    margin-top: 0.5rem;
    display: none;
}

.user-email-display {
    font-size: 1rem;
    color: #191919;
    margin-bottom: 1.5rem;
    text-align: center;
}

.user-email-display a {
    color: #0654ba;
    text-decoration: underline;
    font-weight: 500;
}

.password-group {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
}

.toggle-password svg {
    width: 1.25rem;
    height: 1.25rem;
    fill: #767676;
}

#btn-signin {
    margin-top: 1rem;
    background-color: #3665f3 !important; /* Specific blue for sign in */
}

.btn-continue {
    width: 100%;
    background-color: #0968f6;
    color: white;
    border: none;
    border-radius: 1.5rem; /* 24px */
    padding: 0.75rem; /* 12px */
    font-size: 1rem; /* 16px */
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 1.5rem; /* 24px */
    height: 3rem; /* 48px */
    transition: background-color 0.2s;
}

.btn-continue:hover {
    background-color: #0968f6;
}

.divider {
    display: flex;
    align-items: center;
    width: 100%;
    margin: 0 0 1.5rem 0; /* 24px */
}

.divider::before,
.divider::after {
    content: "";
    flex: 1;
    border-bottom: 1px solid #c7c7c7;
}

.divider span {
    padding: 0 0.625rem; /* 10px */
    color: #191919;
    font-size: 0.875rem; /* 14px */
    font-weight: 500;
}

.social-btn {
    width: 100%;
    background-color: #fff;
    border: 1px solid #707070;
    border-radius: 1.5rem; /* 24px */
    padding: 0 1rem; /* 16px */
    font-size: 1rem; /* 16px */
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 0.75rem; /* 12px */
    display: flex;
    align-items: center;
    justify-content: center;
    color: #191919;
    position: relative;
    height: 3rem; /* 48px */
    box-sizing: border-box;
    transition: background-color 0.2s;
}

.social-btn:hover {
    background-color: #f5f5f5;
}

.social-btn img, .social-btn .icon {
    width: 1.25rem; /* 20px */
    height: 1.25rem; /* 20px */
    margin-right: 0.75rem; /* 12px */
    position: absolute;
    left: 1.25rem; /* 20px */
}

.checkbox-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: 1rem;
    font-size: 1rem;
    color: #191919;
    font-weight: 400;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.checkbox-label input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.cbx {
    display: inline-flex;
    align-items: center;
    margin-right: 0.625rem;
    width: 1.125rem;
    height: 1.125rem;
}

.cbx svg {
    width: 100%;
    height: 100%;
}

/* Logic to toggle icons based on checked state */
.checkbox-label input:checked ~ .cbx .icon-checkbox-unchecked-18 {
    display: none;
}

.checkbox-label input:checked ~ .cbx .icon-checkbox-checked-18 {
    display: block;
}

.checkbox-label input:not(:checked) ~ .cbx .icon-checkbox-checked-18 {
    display: none;
}

.checkbox-label input:not(:checked) ~ .cbx .icon-checkbox-unchecked-18 {
    display: block;
}

footer {
    padding: 1.5rem 1rem;
    margin-top: auto;
    font-size: 0.6875rem; /* 11px */
    color: #555;
    text-align: center;
    line-height: 1.4;
}

.gf-legal {
    font-size: 0.6875rem;
    color: #555;
}

.legal-link {
    color: #0654ba;
    text-decoration: underline;
    margin: 0 0.0625rem;
}

.legal-link:hover {
    text-decoration: none;
}

.gf-privacy-choises {
    color: #0654ba;
    text-decoration: underline;
    white-space: nowrap;
}

.gf-privacy-choises::before {
    content: "";
    display: inline-block;
    width: 29px;
    height: 14px;
    background: url("https://upload.wikimedia.org/wikipedia/commons/6/6d/Privacyoptions29x14.png") no-repeat center;
    background-size: contain;
    vertical-align: middle;
    margin-right: 4px;
}
