/* base styling and typography based on mobile-first */
:root {
    --primary-red: #db000b;
    --accent-red: #b30009;
    --bg-light: #f8f9fa;
    --card-shadow: 0 0.5rem 1.5rem rgba(0,0,0,0.08);
}

body {
    background: var(--bg-light);
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.auth-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: #fff;
}

/* On desktop, keep the split screen */
@media (min-width: 992px) {
    .auth-wrapper { flex-direction: row; }
}

/* Banner Side */
.auth-banner {
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.8)), url('https://images.unsplash.com/photo-1542838132-92c53300491e?q=80&w=2000&auto=format&fit=crop');
    background-size: cover;
    background-position: center bottom;
    color: #fff;
    padding: 3rem 1.5rem;
    position: relative;
    text-align: center;
    min-height: 30vh;
}
@media (min-width: 992px) {
    .auth-banner { flex: 1; padding: 4rem; text-align: left; min-height: 100vh; }
}

.auth-banner-content { max-width: 500px; z-index: 2; margin: 0 auto; }
@media (min-width: 992px) {
    .auth-banner-content { margin: 0; }
}

.auth-banner h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 800; margin-bottom: 1rem; text-transform: uppercase; line-height: 1.1; }
.auth-banner p { display: none; }
.feature-list { display: none; }

@media (min-width: 992px) {
    .auth-banner p { display: block; font-size: 1.2rem; margin-bottom: 2rem; opacity: 0.9; line-height: 1.6; }
    .feature-list { list-style: none; padding: 0; display: block; }
    .feature-list li { margin-bottom: 1rem; display: flex; align-items: center; gap: 1rem; font-size: 1.1rem; }
    .feature-list i { color: var(--primary-red); background: rgba(255,255,255,0.1); width: 3rem; height: 3rem; display: flex; align-items: center; justify-content: center; border-radius: 50%; font-size: 1.2rem; }
}

/* Form Container */
.auth-form-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    position: relative;
    background: var(--bg-light);
}

@media (min-width: 992px) {
    .auth-form-container { padding: 4rem; background: #fff; }
}

.form-card {
    width: 100%;
    max-width: 600px;
    background: #fff;
    padding: 1.5rem;
    border-radius: 1rem;
    box-shadow: var(--card-shadow);
}
@media (min-width: 992px) {
    .form-card { padding: 3rem; box-shadow: none; max-width: 550px; }
}

/* Visibility Utilities */
.mobile-only { display: flex !important; }
.desktop-only { display: none !important; }
@media (min-width: 992px) {
    .mobile-only { display: none !important; }
    .desktop-only { display: flex !important; }
}

/* Back Link */
.back-link {
    background: rgba(255,255,255,0.9);
    color: #333;
    text-decoration: none;
    font-weight: 600;
    padding: 0.6rem 1.2rem;
    border-radius: 2rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
@media (min-width: 992px) {
    .back-link { position: absolute; top: 2rem; right: 2rem; margin-bottom: 0; background: #f1f3f5; }
    .back-link:hover { background: var(--primary-red); color: #fff; transform: translateY(-2px); box-shadow: 0 6px 15px rgba(219, 0, 11, 0.2); }
}

/* Steps */
.step-container {
    display: none;
    animation: fadeIn 0.4s ease forwards;
}
.step-container.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* Selection Cards Step 1 */
.step-header { text-align: center; margin-bottom: 2rem; }
.step-header h2 { font-size: 1.8rem; margin-bottom: 0.5rem; color: #111; }
.step-header p { color: #666; font-size: 1rem; line-height: 1.5; }

.type-selection-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}
@media (min-width: 576px) {
    .type-selection-cards { grid-template-columns: 1fr 1fr; }
}

.type-card {
    background: #fff;
    border: 2px solid #e9ecef;
    border-radius: 1rem;
    padding: 2rem 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.02);
}
.type-card:hover { border-color: var(--primary-red); transform: translateY(-5px); box-shadow: var(--card-shadow); }
.type-card .icon-wrapper { 
    font-size: 2.5rem; 
    color: var(--primary-red); 
    background: rgba(219,0,11,0.05); 
    width: 5rem;
    height: 5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%; 
    transition: 0.3s ease;
}
.type-card:hover .icon-wrapper {
    background: var(--primary-red);
    color: #fff;
}

.type-card h3 { font-size: 1.25rem; margin: 0; color: #222; font-weight: 700; }
.type-card p { font-size: 0.9rem; color: #666; margin: 0; line-height: 1.5; }

/* Form Step 2 */
.form-header-row { display: flex; align-items: center; margin-bottom: 1.5rem; gap: 1rem; }
.form-header-row h2 { font-size: 1.6rem; color: #111; margin: 0; }
.btn-back-step { 
    background: #f1f3f5; 
    border: none; 
    font-size: 1rem; 
    font-weight: 600; 
    color: #444; 
    cursor: pointer; 
    display: flex; 
    align-items: center; 
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    transition: 0.3s;
}
.btn-back-step:hover { background: var(--primary-red); color: #fff; }

.form-row { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 1rem; }
@media (min-width: 768px) {
    .form-row { flex-direction: row; gap: 1.5rem; margin-bottom: 1.5rem; }
    .form-col { flex: 1; }
}

.form-group { margin-bottom: 1rem; }
@media (min-width: 768px) { .form-group { margin-bottom: 1.5rem; } }

.form-group label { display: block; margin-bottom: 0.4rem; font-weight: 600; color: #444; font-size: 0.95rem; }
.form-control {
    width: 100%;
    padding: 0.9rem 1rem;
    border: 2px solid #ced4da;
    border-radius: 0.75rem;
    font-size: 1rem;
    background: #f8f9fa;
    color: #333;
    transition: 0.3s;
    box-sizing: border-box;
}
.form-control:focus { outline: none; border-color: var(--primary-red); background: #fff; box-shadow: 0 0 0 4px rgba(219, 0, 11, 0.1); }

.btn-submit {
    width: 100%;
    padding: 1.1rem;
    background: var(--primary-red);
    color: #fff;
    border: none;
    border-radius: 0.75rem;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: 0.3s;
    margin-top: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 8px 15px rgba(219, 0, 11, 0.2);
}
.btn-submit:hover { background: var(--accent-red); transform: translateY(-2px); box-shadow: 0 12px 20px rgba(219, 0, 11, 0.3); }

.company-fields-group { display: none; margin-top: 1.5rem; padding-top: 1.5rem; border-top: 2px solid #f1f3f5; }
.company-fields-group h3 { font-size: 1.2rem; margin-bottom: 1rem; color: #222; }

.alert { padding: 1rem; border-radius: 0.5rem; margin-bottom: 1.5rem; font-weight: 500; display: flex; align-items: center; gap: 0.8rem; }
.alert-error { background: #ffe3e3; color: #e03131; border-left: 4px solid #e03131; }
.alert-success { background: #d3f9d8; color: #2b8a3e; border-left: 4px solid #2b8a3e; }