* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    height: 100vh;
    overflow: hidden;
}

.container {
    display: flex;
    height: 100vh;
}

/* Left Panel - Branding */
.branding-panel {
    flex: 1;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #764ba2 100%);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 3rem 4rem;
    color: white;
}

.branding-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    opacity: 0.3;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
    position: relative;
    z-index: 1;
}

.tagline {
    position: relative;
    z-index: 1;
    margin-top: auto;
    margin-bottom: auto;
}

.tagline h1 {
    font-size: 2.8rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.tagline .gradient-text-1 {
    background: linear-gradient(135deg, #0B1768 0%, #1127ab 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tagline .gradient-text-2 {
    background: linear-gradient(135deg, #fff 0%, #fff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.word-rotator {
    display: inline-block;
    position: relative;
    overflow: hidden;
    height: 1.1em;
    vertical-align: bottom;
    /* Adjust width to your longest word or use JS to calculate */
    min-width: 140px; 
}

.word-rotator-inner {
    display: inline-flex;
    flex-direction: column;
    /* Changed to ease-in-out for a smoother snap */
    animation: word-swipe-up 8s infinite ease-in-out;
}

.word-rotator-inner > span {
    line-height: 1.1;
}

.trusted-section {
    position: relative;
    z-index: 1;
    margin-top: auto;
}

.trusted-section p {
    font-size: 0.875rem;
    opacity: 0.9;
    margin-bottom: 1.5rem;
}

.company-logos {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    align-items: center;
}

.company-logo {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Right Panel - Form */
.form-panel {
    flex: 1;
    background: #0f172a;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3rem 4rem;
    overflow-y: auto;
}

.form-container {
    max-width: 420px;
    width: 100%;
    margin: 0 auto;
}

.form-title {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.5rem;
}

.form-subtitle {
    color: #94a3b8;
    margin-bottom: 2.5rem;
    font-size: 0.9375rem;
}

.google-btn {
    width: 100%;
    background: white;
    color: #1e293b;
    border: none;
    padding: 0.875rem 1.5rem;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    transition: all 0.2s;
}

.google-btn:hover {
    background: #f1f5f9;
    transform: translateY(-1px);
}

.google-icon {
    width: 20px;
    height: 20px;
}

.divider {
    display: flex;
    align-items: center;
    margin: 1.5rem 0;
    color: #475569;
    font-size: 0.875rem;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #334155;
}

.divider span {
    padding: 0 1rem;
}

.helper-text {
    color: #94a3b8;
    font-size: 0.8125rem;
    line-height: 1.4;
    margin-top: 0.5rem;
}

.row {
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 0.75rem;
}

.select-field {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 0.875rem 0.875rem;
    color: white;
    font-size: 0.9375rem;
    transition: all 0.2s;
    appearance: none;
}

.select-field:focus {
    outline: none;
    border-color: #3b82f6;
    background: rgba(255, 255, 255, 0.08);
}

.select-wrap {
    position: relative;
}

.select-wrap::after {
    content: '';
    position: absolute;
    right: 0.95rem;
    top: 50%;
    width: 10px;
    height: 10px;
    border-right: 2px solid #94a3b8;
    border-bottom: 2px solid #94a3b8;
    transform: translateY(-60%) rotate(45deg);
    pointer-events: none;
    opacity: 0.9;
}

.channel-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.channel-btn {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid #334155;
    color: #e2e8f0;
    padding: 0.75rem 0.875rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.channel-btn:hover {
    border-color: #475569;
    transform: translateY(-1px);
}

.channel-btn.active {
    border-color: #3b82f6;
    background: rgba(59, 130, 246, 0.15);
    color: white;
}

.otp-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.75rem;
    align-items: center;
}

.secondary-btn {
    background: transparent;
    border: 1px solid #334155;
    color: #cbd5e1;
    padding: 0.875rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.secondary-btn:hover {
    border-color: #475569;
    color: white;
    transform: translateY(-1px);
}

.status {
    margin-top: 1rem;
    padding: 0.875rem 1rem;
    border-radius: 10px;
    border: 1px solid rgba(59, 130, 246, 0.35);
    background: rgba(59, 130, 246, 0.12);
    color: #dbeafe;
    font-size: 0.875rem;
    line-height: 1.4;
    display: none;
}

.status.show {
    display: block;
}

.error {
    border-color: rgba(239, 68, 68, 0.5) !important;
}

.muted-link {
    display: block;
    text-align: center;
    color: #94a3b8;
    font-size: 0.875rem;
    text-decoration: none;
    margin-top: 1.25rem;
}

.muted-link:hover {
    color: #cbd5e1;
}

.input-group {
    margin-bottom: 1.5rem;
}

.input-label {
    display: block;
    color: #cbd5e1;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.input-wrapper {
    position: relative;
}

.input-field {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 0.875rem 1rem;
    color: white;
    font-size: 0.9375rem;
    transition: all 0.2s;
}

.input-field:focus {
    outline: none;
    border-color: #3b82f6;
    background: rgba(255, 255, 255, 0.08);
}

.input-field::placeholder {
    color: #64748b;
}

.continue-btn {
    width: 100%;
    background: #3b82f6;
    color: white;
    border: none;
    padding: 0.875rem 1.5rem;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    transition: all 0.2s;
}

.continue-btn:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.continue-btn:active {
    transform: translateY(0);
}

.arrow-icon {
    width: 18px;
    height: 18px;
}

.passkey-link {
    display: block;
    text-align: center;
    color: #3b82f6;
    font-size: 0.875rem;
    text-decoration: none;
    margin-bottom: 2rem;
}

.passkey-link:hover {
    color: #60a5fa;
}

.signup-link {
    text-align: center;
    color: #94a3b8;
    font-size: 0.875rem;
}

.signup-link a {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
}

.signup-link a:hover {
    color: #60a5fa;
}

@keyframes word-swipe-up {
    /* Word 1: Women */
    0%, 20% { transform: translateY(0); }
    
    /* Word 2: Mothers */
    25%, 45% { transform: translateY(-25%); }
    
    /* Word 3: Midwives */
    50%, 70% { transform: translateY(-50%); }
    
    /* Word 4: Clinicians */
    75%, 95% { transform: translateY(-75%); }
    
    /* Loop back to start */
    100% { transform: translateY(-100); }
}

/* Responsive */
@media (max-width: 1024px) {
    .container {
        flex-direction: column;
    }

    .branding-panel {
        padding: 2rem;
        min-height: 40vh;
    }

    .tagline h1 {
        font-size: 2.5rem;
    }

    .form-panel {
        padding: 2rem;
    }

    .company-logos {
        gap: 1rem;
    }

    .company-logo {
        padding: 0.5rem 1rem;
        font-size: 0.75rem;
    }
}

@media (max-width: 640px) {
    .tagline h1 {
        font-size: 2rem;
    }

    .form-title {
        font-size: 1.5rem;
    }

    .row {
        grid-template-columns: 1fr;
    }

    .channel-group {
        grid-template-columns: 1fr;
    }
}
