@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;500;700;900&display=swap');

/* =======================================
   CRITICAL FIX - FORCE WHITE BACKGROUND
======================================= */

/* IMPORTANT: Force white background for signin forms */
.signin-phone,
div.signin-phone,
.register__form .signin-phone,
body .register .register__form .signin-phone,
.signin-phone.signin-phone {
    background: #ffffff !important;
    background-color: #ffffff !important;
    border: 1px solid #E5E7EB !important;
}

.signin-phone::before,
.signin-phone::after {
    display: none !important;
    content: none !important;
    border: none !important;
    background: none !important;
}

/* Override any signup-phone styles that might affect signin-phone */
.signin-phone:not(.signup-phone) {
    background: #ffffff !important;
}

/* Remove blue top border if inherited */
.register .signin-phone {
    border-top: 1px solid #E5E7EB !important;
}

/* PREVENT BUTTON HOVER MOVEMENTS ON SIGNIN-PHONE */
html body .signin-phone button,
html body .signin-phone .primary-btn,
html body .signin-phone a.primary-btn,
html body .signin-phone button:hover,
html body .signin-phone .primary-btn:hover,
html body .signin-phone a.primary-btn:hover,
html body .signin-phone button:active,
html body .signin-phone .primary-btn:active,
html body .signin-phone a.primary-btn:active,
html body .signin-phone button:focus,
html body .signin-phone .primary-btn:focus,
html body .signin-phone a.primary-btn:focus {
    transform: none !important;
    -webkit-transform: none !important;
    -moz-transform: none !important;
    -ms-transform: none !important;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease !important;
}

/* Additional overrides for any theme conflicts */
html body .register .register__form .signin-phone,
html body div.signin-phone,
.signin-phone[class*="signin"],
.signin-phone.signin-phone.signin-phone {
    background: #ffffff !important;
    background-color: #ffffff !important;
    background-image: none !important;
    border: 1px solid #E5E7EB !important;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.1),
        0 8px 20px rgba(0, 0, 0, 0.06) !important;
}

/* Override dark theme classes if applied */
.dark .signin-phone,
.dark-mode .signin-phone,
.theme-dark .signin-phone,
body.dark .signin-phone,
html.dark .signin-phone {
    background: #ffffff !important;
    background-color: #ffffff !important;
    color: #1F2937 !important;
}

/* Force white with class */
.signin-phone-white,
.signin-phone.signin-phone-white {
    background: #ffffff !important;
    background-color: #ffffff !important;
    background-image: none !important;
    border: 1px solid #E5E7EB !important;
}

/* Remove ALL pseudo-elements from signin forms */
.signin-phone::before,
.signin-phone::after,
.signin-phone-white::before,
.signin-phone-white::after,
div.signin-phone::before,
div.signin-phone::after {
    display: none !important;
    content: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    width: 0 !important;
    height: 0 !important;
    border: none !important;
    background: none !important;
    background-color: transparent !important;
    background-image: none !important;
}

/* Prevent signup-phone styles from affecting signin-phone */
.signin-phone:not(.signup-phone) {
    background: #ffffff !important;
    background-color: #ffffff !important;
    background-image: none !important;
    border: 1px solid #E5E7EB !important;
}

.signin-phone:not(.signup-phone)::before,
.signin-phone:not(.signup-phone)::after {
    display: none !important;
}

/* Ensure text colors are correct */
.signin-phone .signin-phone__title span,
.signin-phone .signin-phone__form label,
.signin-phone .signin-phone__form input {
    color: #1F2937;
    background-image: none;
    background-clip: initial;
    -webkit-background-clip: initial;
}

.signin-phone .signin-phone__form input {
    background: #F9FAFB !important;
    border: 1px solid #E5E7EB !important;
}

.signin-phone .signin-phone__form input:focus {
    background: #FFFFFF !important;
    border-color: #12A4FF !important;
}

/* Ensure buttons are styled correctly */
.signin-phone .primary-btn--blue {
    background: #12A4FF;
    border-color: #12A4FF;
    color: #FFFFFF;
    transform: none;
}

.signin-phone .primary-btn--blue:hover {
    background: #0E8DD6;
    transform: none;
}

.signin-phone .primary-btn--blue:active {
    background: #0A7BC4;
    transform: none;
}

.signin-phone .primary-btn--white {
    background: #FFFFFF;
    border: 1px solid #E5E7EB;
    color: #1F2937;
    transform: none;
}

.signin-phone .primary-btn--white:hover {
    background: #F9FAFB;
    border-color: #12A4FF;
    color: #333333;
    transform: none;
}

.signin-phone .primary-btn--white:active {
    background: #F3F4F6;
    transform: none;
}

/* CRITICAL: Remove ALL button movements on signin-phone page */
.signin-phone .primary-btn,
.signin-phone .primary-btn:hover,
.signin-phone .primary-btn:active,
.signin-phone .primary-btn:focus,
.signin-phone button,
.signin-phone button:hover,
.signin-phone button:active,
.signin-phone button:focus,
.signin-phone a.primary-btn,
.signin-phone a.primary-btn:hover,
.signin-phone a.primary-btn:active,
.signin-phone a.primary-btn:focus {
    transform: none;
    -webkit-transform: none;
    -moz-transform: none;
    -ms-transform: none;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* =======================================
   RESET & BASE STYLES
======================================= */

/* Hide header on signup page */
body.hide-header header,
body.hide-header .redmax-header,
body.hide-header .elementor-location-header,
body.hide-header #masthead,
body.hide-header .site-header,
body.hide-header .elementor-header,
body.hide-header [data-elementor-type="header"],
body.hide-header .elementor-edit-mode header,
body.hide-header .elementor-section-wrap header,
body.hide-header .elementor-top-section,
.page-template-signup header,
.page-template-signup .elementor-location-header,
.page-template-signup .redmax-header,
.page-template-signup [data-elementor-type="header"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
}

body.hide-header,
.page-template-signup {
    padding-top: 0 !important;
    margin-top: 0 !important;
}

/* Force hide all headers on auth pages */
body[class*="signup"] header,
body[class*="signup"] .elementor-location-header {
    display: none !important;
}

/* CSS Reset */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f5f7fa;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Remove default form styles */
input,
button,
textarea {
    font-family: inherit;
    font-size: inherit;
    border: none;
    outline: none;
    background: none;
}

/* Remove default link styles */
a {
    text-decoration: none;
    color: inherit;
}

/* Remove list styles */
ul,
ol {
    list-style: none;
}

/* =======================================
   UTILITY CLASSES
======================================= */

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.show-error {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
}

.signup .signup__form input[type="text"].error {
    border-color: #EF4444;
    background: #FEF2F2;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

/* =======================================
   BUTTON STYLES
======================================= */

.primary-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 32px;
    border-radius: 12px;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    min-height: 56px;
    position: relative;
    overflow: hidden;
    width: 100%;
    text-decoration: none;
    transform: none;
}

.primary-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

.primary-btn:focus-visible {
    outline: 2px solid #12A4FF;
    outline-offset: 2px;
}

.primary-btn--blue {
    background: linear-gradient(135deg, #12A4FF 0%, #0E8DD6 100%);
    color: #ffffff;
    box-shadow: 0 4px 20px rgba(18, 164, 255, 0.3);
}

.primary-btn--blue:hover {
    background: linear-gradient(135deg, #0E8DD6 0%, #0A7BC4 100%);
    box-shadow: 0 8px 30px rgba(18, 164, 255, 0.4);
    transform: none;
}

.primary-btn--blue:active {
    box-shadow: 0 4px 20px rgba(18, 164, 255, 0.3);
    transform: none;
}

.primary-btn--white {
    background: #ffffff;
    color: #333333;
    border: 2px solid #C8C8C8;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.primary-btn--white:hover {
    background: #F9FAFB;
    border-color: #12A4FF;
    color: #333333;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    transform: none;
}

.primary-btn--white:active {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transform: none;
}

/* Prevent button movement on hover/active states */
.primary-btn,
.primary-btn:hover,
.primary-btn:active,
.primary-btn:focus,
.primary-btn--blue,
.primary-btn--blue:hover,
.primary-btn--blue:active,
.primary-btn--blue:focus,
.primary-btn--white,
.primary-btn--white:hover,
.primary-btn--white:active,
.primary-btn--white:focus {
    transform: none;
    -webkit-transform: none;
    -moz-transform: none;
    -ms-transform: none;
}

/* =======================================
   MAIN LAYOUT
======================================= */

.register {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: 
        linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.05) 100%),
        url("../assets/images/main-bg.png");
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
}

.register::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(2px);
    z-index: 1;
}

.register > * {
    position: relative;
    z-index: 2;
}

.register__container {
    width: 100%;
    max-width: 1200px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.register__logo {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.register__logo img {
    max-width: 400px;
    width: 100%;
    height: auto;
    filter: drop-shadow(0 10px 40px rgba(0, 0, 0, 0.1));
    transition: transform 0.3s ease;
}

.register__logo img:hover {
    transform: scale(1.02);
}

.register__form {
    display: flex;
    justify-content: center;
}

/* =======================================
   SIGNUP FORM STYLES
======================================= */

.signup {
    background: #ffffff;
    border-radius: 24px;
    padding: 48px;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.1),
        0 8px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid #495e89;
    width: 100%;
    max-width: 520px;
    position: relative;
}

/* Multi-step visibility states */
.signup--message,
.signup--done {
    display: none;
}

.signup--message.active,
.signup--done.active {
    display: block;
}

.signup__title {
    margin-bottom: 32px;
    text-align: center;
}

.signup__title span {
    font-size: 28px;
    font-weight: 900;
    line-height: 1.3;
    letter-spacing: -0.01em;
    color: #1F2937;
}

.signup__form {
    margin-bottom: 32px;
}

.signup__form-login,
.signup__form-password {
    margin-bottom: 24px;
}

.signup__form-login label,
.signup__form-password label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 14px;
    color: #1F2937;
    letter-spacing: 0.01em;
}

.signup .signup__form .signup__form-login input[type="text"],
.signup .signup__form .signup__form-password input[type="text"],
.signup .signup__form .signup__form-password input[type="tel"] {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    background: #F9FAFB;
    font-size: 16px;
    font-weight: 400;
    color: #1F2937;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-sizing: border-box;
}

.signup .signup__form .signup__form-login input[type="text"]::placeholder,
.signup .signup__form .signup__form-password input[type="text"]::placeholder,
.signup .signup__form .signup__form-password input[type="tel"]::placeholder {
    color: #9CA3AF;
}

.signup .signup__form .signup__form-login input[type="text"]:focus,
.signup .signup__form .signup__form-password input[type="text"]:focus,
.signup .signup__form .signup__form-password input[type="tel"]:focus {
    border-color: #12A4FF;
    background: #FFFFFF;
    box-shadow: 
        0 0 0 3px rgba(18, 164, 255, 0.1),
        0 4px 20px rgba(18, 164, 255, 0.15);
    outline: none;
}

/* Error messages */
.signup__form-login p,
.signup__form-password p {
    margin-top: 8px;
    font-size: 14px;
    color: #EF4444;
    font-weight: 500;
    display: none;
    opacity: 0;
    transition: all 0.3s ease;
}

.signup__form-login p.show-error,
.signup__form-password p.show-error {
    display: block;
    opacity: 1;
}

.signup__agreement {
    margin-bottom: 32px;
    padding: 16px;
    background: rgba(18, 164, 255, 0.05);
    border-radius: 12px;
}

.signup__agreement p {
    font-size: 14px;
    color: #374151;
    line-height: 1.5;
    margin: 0;
}

.signup__agreement a {
    color: #12A4FF;
    font-weight: 500;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.signup__agreement a:hover {
    color: #0E8DD6;
    text-decoration: none;
}

.signup__btns {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.signup__btns .primary-btn {
    width: 100%;
}

/* Success state styles */
.signup--done {
    text-align: center;
}

.signup--done__img {
    margin-bottom: 32px;
    display: flex;
    justify-content: center;
}

.signup--done__img-container {
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, #12A4FF 0%, #0E8DD6 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 2s infinite;
}

.signup--done__img img {
    width: 60px;
    height: 60px;
    filter: brightness(0) invert(1);
}

.signup--done__text-title {
    margin-bottom: 16px;
}

.signup--done__text-title p {
    font-size: 24px;
    font-weight: 700;
    color: #1F2937;
    margin: 0;
}

.signup--done__text-subtitle {
    margin-bottom: 32px;
}

.signup--done__text-subtitle span {
    font-size: 16px;
    color: #4B5563;
    line-height: 1.5;
}

.signup--done__btn {
    margin-top: 32px;
}

.signup__resend {
    margin-top: 16px;
    text-align: center;
}

.signup__resend a {
    color: #12A4FF;
    font-size: 14px;
    font-weight: 500;
    text-decoration: underline;
    transition: all 0.3s ease;
    padding: 8px 16px;
    border-radius: 8px;
}

.signup__resend a:hover {
    background: rgba(18, 164, 255, 0.1);
    text-decoration: none;
}

/* Confirmation step styles */
.signup.signup--message .signup__form .signup__form-login label {
    font-weight: 600;
    color: #1F2937;
}

.signup.signup--message .signup__form .signup__form-login input[type="text"] {
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    letter-spacing: 0.1em;
    padding: 20px;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    background: #F9FAFB;
    box-sizing: border-box;
}

.signup.signup--message .signup__form .signup__form-login input[type="text"]:focus {
    border-color: #12A4FF;
    background: #FFFFFF;
    outline: none;
}

/* Loading state */
.loading {
    pointer-events: none;
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top: 2px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* =======================================
   RESPONSIVE DESIGN
======================================= */

/* Large screens (1440px+) */
@media (min-width: 1440px) {
    .register__container {
        max-width: 1400px;
        gap: 80px;
    }
    
    .register__logo img {
        max-width: 450px;
    }
    
    .signup {
        max-width: 560px;
        padding: 56px;
    }
    
    .signup__title span {
        font-size: 32px;
    }
}

/* Medium-large screens (1200px) */
@media (max-width: 1200px) {
    .register__container {
        gap: 40px;
    }
    
    .register__logo img {
        max-width: 350px;
    }
}

/* Medium screens (1024px) */
@media (max-width: 1024px) {
    .register {
        padding: 16px;
    }
    
    .register__container {
        grid-template-columns: 1fr;
        gap: 40px;
        max-width: 600px;
    }
    
    .signup {
        max-width: 100%;
    }
    
    .signup__title span {
        font-size: 26px;
    }
}

/* Small-medium screens (768px) */
@media (max-width: 768px) {
    .register {
        padding: 12px;
        background-attachment: scroll;
    }
    
    .register__container {
        gap: 32px;
        max-width: 500px;
    }
    
    .register__logo {
        order: 1;
    }
    
    .register__logo img {
        max-width: 280px;
    }
    
    .register__form {
        order: 2;
    }
    
    .signup {
        padding: 32px 24px;
        border-radius: 20px;
    }
    
    .signup__title {
        margin-bottom: 24px;
    }
    
    .signup__title span {
        font-size: 24px;
    }
    
    .signup__form {
        margin-bottom: 24px;
    }
    
    .signup__agreement {
        padding: 12px;
    }
    
    .primary-btn {
        min-height: 52px;
        font-size: 15px;
        padding: 14px 24px;
    }
}

/* Small screens (640px) */
@media (max-width: 640px) {
    .register {
        min-height: 100vh;
        align-items: flex-start;
        padding: 8px;
    }
    
    .register__container {
        padding-top: 20px;
        gap: 24px;
    }
    
    .register__logo img {
        max-width: 240px;
    }
    
    .signup {
        padding: 24px 16px;
        border-radius: 16px;
    }
    
    .signup__title {
        margin-bottom: 20px;
    }
    
    .signup__title span {
        font-size: 22px;
    }
    
    .signup__form {
        margin-bottom: 20px;
    }
    
    .signup__form-login,
    .signup__form-password {
        margin-bottom: 20px;
    }
    
    .signup .signup__form .signup__form-login input[type="text"],
    .signup .signup__form .signup__form-password input[type="text"] {
        padding: 14px 16px;
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    .signup__agreement {
        padding: 10px;
        margin-bottom: 20px;
    }
    
    .signup__agreement p {
        font-size: 13px;
    }
    
    .primary-btn {
        min-height: 48px;
        font-size: 14px;
        padding: 12px 20px;
    }
    
    .signup.signup--message .signup__form .signup__form-login input[type="text"] {
        font-size: 20px;
        padding: 16px;
    }
    
    .signup--done__img-container {
        width: 100px;
        height: 100px;
    }
    
    .signup--done__img img {
        width: 50px;
        height: 50px;
    }
    
    .signup--done__text-title p {
        font-size: 20px;
    }
    
    .signup--done__text-subtitle span {
        font-size: 14px;
    }
}

/* Extra small screens (480px) */
@media (max-width: 480px) {
    .register {
        padding: 4px;
    }
    
    .register__container {
        padding-top: 16px;
        gap: 20px;
    }
    
    .register__logo img {
        max-width: 200px;
    }
    
    .signup {
        padding: 20px 12px;
    }
    
    .signup__title span {
        font-size: 20px;
    }
    
    .signup__agreement {
        padding: 8px;
    }
    
    .signup__agreement p {
        font-size: 12px;
    }
}

/* Ultra small screens (360px) */
@media (max-width: 360px) {
    .register {
        padding: 2px;
    }
    
    .signup {
        padding: 16px 8px;
    }
    
    .primary-btn {
        min-height: 44px;
        font-size: 13px;
        padding: 10px 16px;
    }
}

/* =======================================
   ACCESSIBILITY & PREFERENCES
======================================= */

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .signup {
        background: #ffffff;
        border: 2px solid #000000;
    }
    
    .primary-btn--blue {
        background: #0000ff;
        color: #ffffff;
    }
    
    .primary-btn--white {
        background: #ffffff;
        color: #000000;
        border: 2px solid #000000;
    }
    
    .signup__agreement {
        background: #f0f0f0;
        border: 1px solid #000000;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    body {
        background: #1a1a1a;
        color: #ffffff;
    }
    
    .signup {
        background: #ffffff;
        border: 1px solid #E5E7EB;
    }
    
    .signup__title span {
        color: #1F2937;
    }
    
    .signup__form-login label,
    .signup__form-password label {
        color: #1F2937;
    }
    
    .signup .signup__form .signup__form-login input[type="text"],
    .signup .signup__form .signup__form-password input[type="text"] {
        background: #F9FAFB;
        border: 1px solid #E5E7EB;
        color: #1F2937;
    }
    
    .signup .signup__form .signup__form-login input[type="text"]:focus,
    .signup .signup__form .signup__form-password input[type="text"]:focus {
        border-color: #12A4FF;
        background: #ffffff;
    }
    
    .signup .signup__form .signup__form-login input[type="text"]::placeholder,
    .signup .signup__form .signup__form-password input[type="text"]::placeholder {
        color: #9CA3AF;
    }
    
    .signup__agreement {
        background: rgba(18, 164, 255, 0.05);
    }
    
    .signup__agreement p {
        color: #374151;
    }
    
    .signup--done__text-title p {
        color: #1F2937;
    }
    
    .signup--done__text-subtitle span {
        color: #4B5563;
    }
    
    .signup.signup--message .signup__form .signup__form-login input[type="text"] {
        background: #F9FAFB;
        border: 1px solid #E5E7EB;
        color: #1F2937;
    }
    
    .signup.signup--message .signup__form .signup__form-login input[type="text"]:focus {
        background: #ffffff;
        border-color: #12A4FF;
    }
}

/* Print styles */
@media print {
    .register {
        background: none !important;
        min-height: auto;
    }
    
    .signup,
    .signin-phone {
        box-shadow: none !important;
        border: 1px solid #000000;
        background: #ffffff !important;
    }
    
    .primary-btn {
        border: 1px solid #000000 !important;
        background: #ffffff !important;
        color: #000000 !important;
    }
    
    .signup__agreement,
    .signin-phone__agreement {
        border: 1px solid #000000;
        background: #f5f5f5 !important;
    }
    
    .signin {
        box-shadow: none !important;
        border: 1px solid #000000;
        background: #ffffff !important;
    }
}

/* =======================================
   SIGNIN-PHONE STYLES
======================================= */

.signin-phone {
    background: #ffffff !important;
    border-radius: 24px;
    padding: 48px;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.1),
        0 8px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid #E5E7EB;
    width: 100%;
    max-width: 520px;
    position: relative;
}

.signin-phone::before,
.signin-phone::after {
    display: none !important;
}

/* Force white background for signin-phone */
.register__form .signin-phone,
div.signin-phone,
.signin-phone.signin-phone {
    background: #ffffff !important;
    background-color: #ffffff !important;
    border: 1px solid #E5E7EB !important;
}

/* Remove any inherited dark backgrounds */
.signin-phone * {
    background: transparent;
}

/* Override any theme dark styles */
body .register .register__form .signin-phone {
    background: #ffffff !important;
    background-color: #ffffff !important;
    color: #1F2937 !important;
}

.signin-phone .signin-phone__title,
.signin-phone .signin-phone__title span {
    background: transparent;
    color: #1F2937;
    background-image: none;
    background-clip: initial;
    -webkit-background-clip: initial;
}

/* Multi-step visibility states */
.signin-phone--confirm {
    display: none;
}

.signin-phone--confirm.active {
    display: block;
}

.signin-phone__title {
    margin-bottom: 32px;
    text-align: center;
}

.signin-phone__title span {
    font-size: 28px;
    font-weight: 900;
    line-height: 1.3;
    letter-spacing: -0.01em;
    color: #1F2937;
    background: transparent;
    background-image: none;
    background-clip: initial;
    -webkit-background-clip: initial;
    -webkit-text-fill-color: #1F2937;
}

/* High specificity to override any gradient inheritance */
.signin-phone .signin-phone__title span.signin-phone__title span,
div.signin-phone .signin-phone__title span,
.register .signin-phone .signin-phone__title span,
body .signin-phone .signin-phone__title span {
    color: #1F2937;
    background: transparent;
    background-image: none;
    background-clip: initial;
    -webkit-background-clip: initial;
    -webkit-text-fill-color: #1F2937;
}

.signin-phone__form {
    margin-bottom: 32px;
}

.signin-phone__form-phone,
.signin-phone__form-code {
    margin-bottom: 24px;
}

.signin-phone__form-phone label,
.signin-phone__form-code label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 14px;
    color: #1F2937;
    letter-spacing: 0.01em;
}

.signin-phone .signin-phone__form .signin-phone__form-phone input[type="text"],
.signin-phone .signin-phone__form .signin-phone__form-code input[type="text"] {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    background: #F9FAFB;
    font-size: 16px;
    font-weight: 400;
    color: #1F2937;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-sizing: border-box;
}

.signin-phone .signin-phone__form .signin-phone__form-phone input[type="text"]::placeholder,
.signin-phone .signin-phone__form .signin-phone__form-code input[type="text"]::placeholder {
    color: #9CA3AF;
}

.signin-phone .signin-phone__form .signin-phone__form-phone input[type="text"]:focus,
.signin-phone .signin-phone__form .signin-phone__form-code input[type="text"]:focus {
    border-color: #12A4FF;
    background: #FFFFFF;
    box-shadow: 
        0 0 0 3px rgba(18, 164, 255, 0.1),
        0 4px 20px rgba(18, 164, 255, 0.15);
    outline: none;
}

/* Error messages */
.signin-phone__form-phone p,
.signin-phone__form-code p {
    margin-top: 8px;
    font-size: 14px;
    color: #EF4444;
    font-weight: 500;
    display: none;
    opacity: 0;
    transition: all 0.3s ease;
}

.signin-phone__form-phone p.show-error,
.signin-phone__form-code p.show-error {
    display: block;
    opacity: 1;
}

.signin-phone .signin-phone__form input[type="text"].error {
    border-color: #EF4444;
    background: #FEF2F2;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.signin-phone__btns {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.signin-phone__btns .primary-btn {
    width: 100%;
    transform: none;
}

.signin-phone__btns .primary-btn:hover,
.signin-phone__btns .primary-btn:active,
.signin-phone__btns .primary-btn:focus {
    transform: none;
}

.signin-phone__resend {
    margin-top: 16px;
    text-align: center;
}

.signin-phone__resend a {
    color: #12A4FF;
    font-size: 14px;
    font-weight: 500;
    text-decoration: underline;
    transition: all 0.3s ease;
    padding: 8px 16px;
    border-radius: 8px;
}

.signin-phone__resend a:hover {
    background: rgba(18, 164, 255, 0.1);
    text-decoration: none;
}

/* Confirmation step styles */
.signin-phone.signin-phone--confirm .signin-phone__form .signin-phone__form-code label {
    font-weight: 600;
    color: #1F2937;
}

.signin-phone.signin-phone--confirm .signin-phone__form .signin-phone__form-code input[type="text"] {
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    letter-spacing: 0.1em;
    padding: 20px;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    background: #F9FAFB;
    box-sizing: border-box;
}

.signin-phone.signin-phone--confirm .signin-phone__form .signin-phone__form-code input[type="text"]:focus {
    border-color: #12A4FF;
    background: #FFFFFF;
    outline: none;
}

/* =======================================
   SIGNIN-PHONE RESPONSIVE DESIGN
======================================= */

/* Large screens (1440px+) */
@media (min-width: 1440px) {
    .signin-phone {
        max-width: 560px;
        padding: 56px;
    }
    
    .signin-phone__title span {
        font-size: 32px;
    }
}

/* Medium screens (1024px) */
@media (max-width: 1024px) {
    .signin-phone {
        max-width: 100%;
    }
    
    .signin-phone__title span {
        font-size: 26px;
    }
}

/* Small-medium screens (768px) */
@media (max-width: 768px) {
    .signin-phone {
        padding: 32px 24px;
        border-radius: 20px;
    }
    
    .signin-phone__title {
        margin-bottom: 24px;
    }
    
    .signin-phone__title span {
        font-size: 24px;
    }
    
    .signin-phone__form {
        margin-bottom: 24px;
    }
}

/* Small screens (640px) */
@media (max-width: 640px) {
    .signin-phone {
        padding: 24px 16px;
        border-radius: 16px;
    }
    
    .signin-phone__title {
        margin-bottom: 20px;
    }
    
    .signin-phone__title span {
        font-size: 22px;
    }
    
    .signin-phone__form {
        margin-bottom: 20px;
    }
    
    .signin-phone__form-phone,
    .signin-phone__form-code {
        margin-bottom: 20px;
    }
    
    .signin-phone .signin-phone__form .signin-phone__form-phone input[type="text"],
    .signin-phone .signin-phone__form .signin-phone__form-code input[type="text"] {
        padding: 14px 16px;
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    .signin-phone.signin-phone--confirm .signin-phone__form .signin-phone__form-code input[type="text"] {
        font-size: 20px;
        padding: 16px;
    }
}

/* Extra small screens (480px) */
@media (max-width: 480px) {
    .signin-phone {
        padding: 20px 12px;
    }
    
    .signin-phone__title span {
        font-size: 20px;
    }
    
    .signin-phone .signin-phone__form .signin-phone__form-phone input[type="text"],
    .signin-phone .signin-phone__form .signin-phone__form-code input[type="text"] {
        padding: 14px 16px;
        font-size: 16px;
    }
}

/* Ultra small screens (360px) */
@media (max-width: 360px) {
    .signin-phone {
        padding: 16px 8px;
    }
}

/* =======================================
   SIGNIN-PHONE DARK MODE SUPPORT
======================================= */

@media (prefers-color-scheme: dark) {
    .signin-phone,
    div.signin-phone,
    .register__form .signin-phone,
    body .register .register__form .signin-phone {
        background: #ffffff !important;
        background-color: #ffffff !important;
        border: 1px solid #E5E7EB !important;
    }
    
    .signin-phone__title span {
        color: #1F2937;
        background-image: none;
        background-clip: initial;
        -webkit-background-clip: initial;
    }
    
    .signin-phone__form-phone label,
    .signin-phone__form-code label {
        color: #1F2937;
    }
    
    .signin-phone .signin-phone__form .signin-phone__form-phone input[type="text"],
    .signin-phone .signin-phone__form .signin-phone__form-code input[type="text"] {
        background: #F9FAFB;
        border: 1px solid #E5E7EB;
        color: #1F2937;
    }
    
    .signin-phone .signin-phone__form .signin-phone__form-phone input[type="text"]:focus,
    .signin-phone .signin-phone__form .signin-phone__form-code input[type="text"]:focus {
        border-color: #12A4FF;
        background: #ffffff;
    }
    
    .signin-phone .signin-phone__form .signin-phone__form-phone input[type="text"]::placeholder,
    .signin-phone .signin-phone__form .signin-phone__form-code input[type="text"]::placeholder {
        color: #9CA3AF;
    }
    
    .signin-phone.signin-phone--confirm .signin-phone__form .signin-phone__form-code input[type="text"] {
        background: #F9FAFB;
        border: 1px solid #E5E7EB;
        color: #1F2937;
    }
    
    .signin-phone.signin-phone--confirm .signin-phone__form .signin-phone__form-code input[type="text"]:focus {
        background: #ffffff;
        border-color: #12A4FF;
    }
}
