/* DESARbook – Custom overrides for Clean Medical aesthetic */

/* Alpine.js cloak: hide elements until Alpine initialises (prevents FOUC) */
[x-cloak] {
    display: none !important;
}

/* Smooth transitions for interactive elements */
* {
    -webkit-tap-highlight-color: transparent;
}

/* Active nav link highlight */
.nav-link.active {
    color: #2563eb;
    background-color: #eff6ff;
}

/* FAB button pulse animation */
@keyframes pulse-ring {
    0% {
        transform: scale(0.9);
        opacity: 0.7;
    }

    50% {
        transform: scale(1.1);
        opacity: 0;
    }

    100% {
        transform: scale(0.9);
        opacity: 0;
    }
}

.fab-pulse::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: rgba(59, 130, 246, 0.3);
    animation: pulse-ring 2s ease-out infinite;
}

/* Modal backdrop animation */
.modal-backdrop {
    transition: opacity 0.2s ease;
}

/* Card hover lift */
.card-hover {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-hover:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px -5px rgba(0, 0, 0, 0.08);
}

/* Progress bar animation */
.progress-bar {
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Autonomy level badge colors */
.badge-observed {
    background: #fef3c7;
    color: #92400e;
}

.badge-assisted {
    background: #dbeafe;
    color: #1e40af;
}

.badge-capable {
    background: #d1fae5;
    color: #065f46;
}

.badge-autonomous {
    background: #dcfce7;
    color: #14532d;
    border: 1px solid #86efac;
}

/* Radio button as card (for touch-friendly autonomy selection) */
.radio-card {
    transition: all 0.15s ease;
    cursor: pointer;
    user-select: none;
}

.radio-card:active {
    transform: scale(0.98);
}

.radio-card.selected {
    border-color: #3b82f6;
    background-color: #eff6ff;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* ────────────────────────────────────────────
   Auth Split-Screen Layout
   ──────────────────────────────────────────── */

.auth-container {
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* ── Hero Panel (left) ── */
.auth-hero {
    flex: 1;
    background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 40%, #0f766e 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

/* ECG pattern background */
.auth-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='800' height='200' viewBox='0 0 800 200'%3E%3Cpath d='M0,100 L200,100 L220,60 L240,140 L260,30 L280,170 L300,100 L800,100' fill='none' stroke='rgba(255,255,255,0.04)' stroke-width='2'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 800px 200px;
}

/* Soft glow */
.auth-hero::after {
    content: '';
    position: absolute;
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.06) 0%, transparent 70%);
    border-radius: 50%;
    top: -80px;
    right: -100px;
    pointer-events: none;
}

.auth-hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 400px;
}

.auth-hero .logo-icon {
    width: 72px;
    height: 72px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.auth-hero .logo-icon svg {
    width: 36px;
    height: 36px;
    color: white;
}

.auth-hero h1 {
    color: white;
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}

.auth-hero .tagline {
    color: rgba(255, 255, 255, 0.75);
    font-size: 1.05rem;
    line-height: 1.6;
    margin-bottom: 2.5rem;
}

/* Value propositions */
.auth-value-props {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    text-align: left;
    margin-bottom: 3rem;
}

.auth-value-prop {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
}

.auth-value-prop .vp-icon {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.1rem;
}

/* Partner logos */
.auth-partners {
    position: relative;
    z-index: 1;
    text-align: center;
}

.auth-partners-label {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
}

.auth-partner-logos {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    align-items: center;
}

.auth-partner-logo {
    background: white;
    border-radius: 12px;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.auth-partner-logo img {
    height: 40px;
    width: auto;
    display: block;
}

/* ── Form Panel (right) ── */
.auth-form-panel {
    flex: 1;
    background: #f8fafc;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    overflow-y: auto;
}

.auth-form-container {
    width: 100%;
    max-width: 400px;
}

.auth-form-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05), 0 4px 16px rgba(0, 0, 0, 0.04);
    border: 1px solid #e2e8f0;
}

/* ── Responsive: mobile ── */
@media (max-width: 768px) {
    .auth-container {
        flex-direction: column;
        height: auto;
        min-height: 100vh;
    }

    .auth-hero {
        flex: none;
        padding: 2rem 1.5rem 1.5rem;
    }

    .auth-hero h1 {
        font-size: 1.75rem;
    }

    .auth-hero .tagline {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }

    .auth-value-props {
        display: none;
    }

    .auth-partners {
        margin-top: 0.5rem;
    }

    .auth-partner-logo img {
        height: 30px;
    }

    .auth-form-panel {
        flex: 1;
        padding: 1.5rem;
        justify-content: flex-start;
        padding-top: 1.5rem;
    }

    body.auth-page {
        overflow-y: auto;
        height: auto;
    }
}