/* PoAppIdea - Modern 2026 Design System */

:root {
    /* === Color System: Rich Neutrals with Sophisticated Palette === */
    --app-primary: #5B4FE8;
    --app-primary-light: #7B6FF5;
    --app-primary-dark: #4438C4;
    --app-secondary: #0A0A0B;
    --app-accent: #8B5CF6;
    --app-warning: #F59E0B;
    --app-success: #10B981;
    --app-error: #EF4444;
    
    /* Neutral Scale */
    --neutral-50: #F8F9FA;
    --neutral-100: #F1F3F5;
    --neutral-200: #E9ECEF;
    --neutral-300: #DEE2E6;
    --neutral-400: #CED4DA;
    --neutral-500: #ADB5BD;
    --neutral-600: #6C757D;
    --neutral-700: #495057;
    --neutral-800: #2D2D32;
    --neutral-900: #1A1A1E;
    --neutral-950: #0A0A0B;
    
    /* Text Colors */
    --text-primary: #0A0A0B;
    --text-secondary: #495057;
    --text-tertiary: #6C757D;
    --text-inverse: #FFFFFF;
    
    /* Background Colors */
    --bg-primary: #FFFFFF;
    --bg-secondary: #F8F9FA;
    --bg-tertiary: #F1F3F5;
    --bg-elevated: #FFFFFF;
    
    /* Border Colors */
    --border-color: #E9ECEF;
    --border-color-hover: #DEE2E6;
    --border-color-focus: var(--app-primary);
    
    /* Shadows */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 50px rgba(0, 0, 0, 0.12);
    --shadow-glow: 0 0 20px rgba(91, 79, 232, 0.3);
    
    /* === Spacing System === */
    --space-xs: 0.25rem;    /* 4px */
    --space-sm: 0.5rem;     /* 8px */
    --space-md: 1rem;       /* 16px */
    --space-lg: 1.5rem;     /* 24px */
    --space-xl: 2rem;       /* 32px */
    --space-2xl: 3rem;      /* 48px */
    --space-3xl: 4rem;      /* 64px */
    --space-4xl: 6rem;      /* 96px */
    
    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;
    
    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
}


/* === Base Styles === */
@supports (font-variation-settings: normal) {
    html {
        font-family: 'Inter Variable', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
        font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
    }
}

html, body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    min-height: 100vh;
    background: linear-gradient(135deg, #F8F9FA 0%, #FFFFFF 50%, #F1F3F5 100%);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

* {
    box-sizing: border-box;
}

/* === Modern Typography Scale === */
h1, h2, h3, h4, h5, h6 {
    margin: 0 0 var(--space-lg) 0;
    color: var(--text-primary);
    line-height: 1.1;
    letter-spacing: -0.02em;
    font-weight: 700;
}

h1 { 
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
}

h2 { 
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
}

h3 { 
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
}

h4 { 
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    font-weight: 600;
}

h5 {
    font-size: clamp(1.125rem, 2vw, 1.25rem);
    font-weight: 600;
}

h6 {
    font-size: 1rem;
    font-weight: 600;
}

p {
    margin: 0 0 var(--space-md) 0;
    line-height: 1.7;
    color: var(--text-secondary);
}

a {
    color: var(--app-primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--app-primary-dark);
}

strong {
    font-weight: 600;
    color: var(--text-primary);
}


/* === Layout === */
.rz-layout {
    background: transparent !important;
}

.rz-body {
    background: transparent !important;
    padding: var(--space-xl);
}

.rz-header {
    background: rgba(255, 255, 255, 0.9) !important;
    backdrop-filter: blur(12px) saturate(180%);
    border-bottom: 1px solid var(--border-color) !important;
    padding: var(--space-md) var(--space-xl) !important;
    box-shadow: var(--shadow-sm);
}

.rz-sidebar {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(12px) saturate(180%);
    border-right: 1px solid var(--border-color) !important;
}

.rz-footer {
    background: transparent !important;
    border-top: 1px solid var(--border-color);
    padding: var(--space-xl);
}

/* === Modern Button System === */
.rz-button, button {
    background: var(--app-primary);
    color: var(--text-inverse);
    border: none;
    padding: var(--space-sm) var(--space-lg);
    font-size: 0.9375rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-base);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}

.rz-button:hover, button:hover {
    background: var(--app-primary-dark);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.rz-button:active, button:active {
    transform: translateY(0);
    box-shadow: var(--shadow-xs);
}

.rz-button.rz-button-lg, button.large {
    padding: var(--space-md) var(--space-2xl);
    font-size: 1.0625rem;
    font-weight: 600;
}

.rz-button.rz-button-secondary {
    background: var(--bg-primary);
    color: var(--text-primary);
    border: 1.5px solid var(--border-color);
    box-shadow: var(--shadow-xs);
}

.rz-button.rz-button-secondary:hover {
    background: var(--bg-secondary);
    border-color: var(--border-color-hover);
}

/* Ensure Radzen secondary/danger/light buttons follow new design system */
.rz-button.rz-secondary,
.rz-button.rz-button-style-secondary {
    background: var(--bg-primary) !important;
    color: var(--text-primary) !important;
    border: 1.5px solid var(--border-color) !important;
    box-shadow: var(--shadow-xs);
}

.rz-button.rz-secondary:hover,
.rz-button.rz-button-style-secondary:hover {
    background: var(--bg-secondary) !important;
    border-color: var(--app-primary) !important;
    color: var(--app-primary) !important;
}

.rz-button.rz-light,
.rz-button.rz-button-style-light {
    background: transparent !important;
    color: var(--app-primary) !important;
    border: none !important;
    box-shadow: none;
}

.rz-button.rz-light:hover,
.rz-button.rz-button-style-light:hover {
    background: rgba(91, 79, 232, 0.08) !important;
}

/* Override Radzen's default primary button color */
.rz-button.rz-primary,
.rz-button.rz-button-style-primary {
    background: var(--app-primary) !important;
    border-color: var(--app-primary) !important;
}

.rz-button.rz-primary:hover,
.rz-button.rz-button-style-primary:hover {
    background: var(--app-primary-dark) !important;
    border-color: var(--app-primary-dark) !important;
}

/* Override Radzen badge colors */
.rz-badge.rz-secondary {
    background: var(--neutral-200) !important;
    color: var(--text-secondary) !important;
}

/* Override Radzen progressbar */
.rz-progressbar .rz-progressbar-value {
    background: var(--app-primary) !important;
}

/* Override Radzen slider */
.rz-slider .rz-slider-range {
    background: var(--app-primary) !important;
}

.rz-slider .rz-slider-handle {
    background: var(--app-primary) !important;
    border-color: var(--app-primary) !important;
}

.glow-button {
    animation: pulse-glow 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(91, 79, 232, 0.4);
    }
    50% {
        box-shadow: 0 0 20px 5px rgba(91, 79, 232, 0.2);
    }
}

/* === Glassmorphism Cards === */
.glass-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-slow);
}

.glass-card:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-2px);
    border-color: rgba(255, 255, 255, 0.4);
}

.rz-card, .card {
    background: var(--bg-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    box-shadow: var(--shadow-md);
    margin-bottom: var(--space-lg);
    transition: all var(--transition-base);
}

.rz-card:hover, .card:hover {
    box-shadow: var(--shadow-lg);
}

/* === Modern Navigation === */
.nav-item-pill {
    position: relative;
    margin: var(--space-xs) var(--space-md);
    border-radius: var(--radius-full);
    transition: all var(--transition-base);
}

.rz-navigation-item-link {
    color: var(--text-secondary) !important;
    padding: var(--space-sm) var(--space-lg) !important;
    border-radius: var(--radius-full) !important;
    transition: all var(--transition-base) !important;
    font-weight: 500 !important;
    display: flex !important;
    align-items: center !important;
    gap: var(--space-sm) !important;
}

.rz-navigation-item-link:hover {
    background: var(--bg-secondary) !important;
    color: var(--text-primary) !important;
    transform: translateX(4px);
}

.rz-navigation-item-link.rz-state-active {
    background: var(--app-primary) !important;
    color: var(--text-inverse) !important;
    font-weight: 600 !important;
    box-shadow: var(--shadow-md);
}

.rz-navigation-item-link.rz-state-active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 24px;
    background: var(--app-primary-light);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* Icon animations */
.rz-navigation-item-link .rz-icon {
    transition: transform var(--transition-bounce);
}

.rz-navigation-item-link:hover .rz-icon {
    transform: scale(1.1);
}

.rz-navigation-item-link.rz-state-active .rz-icon {
    animation: icon-bounce 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes icon-bounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}


/* === Modern Form Inputs with Floating Labels === */
.form-field {
    position: relative;
    margin-bottom: var(--space-xl);
}

.form-field .floating-label {
    position: absolute;
    left: var(--space-md);
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-tertiary);
    font-size: 1rem;
    pointer-events: none;
    transition: all var(--transition-base);
    background: var(--bg-primary);
    padding: 0 var(--space-xs);
}

.rz-textbox, .rz-dropdown, .rz-textarea, input, textarea, select {
    background: var(--bg-primary);
    border: 1.5px solid var(--border-color);
    padding: var(--space-md) var(--space-lg);
    font-size: 1rem;
    color: var(--text-primary);
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
    width: 100%;
    font-weight: 400;
}

.rz-textbox:hover, input:hover, textarea:hover, select:hover {
    border-color: var(--border-color-hover);
    box-shadow: var(--shadow-sm);
}

.rz-textbox:focus, input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--border-color-focus);
    box-shadow: 0 0 0 4px rgba(91, 79, 232, 0.1), var(--shadow-sm);
}

.rz-textbox:focus + .floating-label,
input:focus + .floating-label,
.rz-textbox:not(:placeholder-shown) + .floating-label,
input:not(:placeholder-shown) + .floating-label {
    top: 0;
    font-size: 0.75rem;
    color: var(--app-primary);
    font-weight: 500;
}

/* Filled input variant */
.rz-textbox.filled, input.filled {
    background: var(--neutral-50);
    border: none;
    border-bottom: 2px solid var(--border-color);
    border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.rz-textbox.filled:focus, input.filled:focus {
    background: var(--bg-primary);
    border-bottom-color: var(--app-primary);
    box-shadow: none;
}

/* Validation states */
.rz-textbox.error, input.error {
    border-color: var(--app-error);
}

.rz-textbox.success, input.success {
    border-color: var(--app-success);
}

.form-error {
    color: var(--app-error);
    font-size: 0.875rem;
    margin-top: var(--space-xs);
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    animation: shake 0.3s;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-4px); }
    75% { transform: translateX(4px); }
}


/* === Interactive Bento Grid === */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-lg);
    margin-top: var(--space-2xl);
}

.bento-item {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-2xl);
    padding: var(--space-2xl);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-slow);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.bento-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--app-primary), var(--app-accent));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-slow);
}

.bento-item:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: var(--shadow-xl);
    border-color: rgba(91, 79, 232, 0.3);
}

.bento-item:hover::before {
    transform: scaleX(1);
}

.bento-item.large {
    grid-column: span 2;
    background: linear-gradient(135deg, rgba(91, 79, 232, 0.05), rgba(139, 92, 246, 0.05));
}

.bento-item.tall {
    grid-row: span 2;
}

.bento-item.wide {
    grid-column: span 2;
}

.bento-icon {
    font-size: 2.5rem !important;
    color: var(--app-primary);
    margin-bottom: var(--space-md);
    transition: transform var(--transition-bounce);
}

.bento-item:hover .bento-icon {
    transform: scale(1.1) rotate(5deg);
}

.caption {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Staggered entrance animation */
@keyframes slide-up {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.bento-item {
    animation: slide-up 0.6s ease-out backwards;
}

.bento-item:nth-child(1) { animation-delay: 0.1s; }
.bento-item:nth-child(2) { animation-delay: 0.2s; }
.bento-item:nth-child(3) { animation-delay: 0.3s; }
.bento-item:nth-child(4) { animation-delay: 0.4s; }
.bento-item:nth-child(5) { animation-delay: 0.5s; }

/* === Enhanced Empty States === */
.empty-state {
    text-align: center;
    padding: var(--space-4xl) var(--space-xl);
    animation: fade-in 0.6s ease-out;
}

.empty-icon {
    font-size: 4rem !important;
    color: var(--neutral-400);
    margin-bottom: var(--space-lg);
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

@keyframes fade-in {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.empty-state h3 {
    color: var(--text-primary);
    margin-bottom: var(--space-md);
}

.empty-state p {
    color: var(--text-tertiary);
    max-width: 480px;
    margin: 0 auto var(--space-xl);
}

/* === Modern Authentication Page === */
.login-container {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}

.login-visual {
    background: linear-gradient(135deg, var(--app-primary), var(--app-accent));
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-4xl);
    position: relative;
    overflow: hidden;
}

.login-visual::before {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation: pulse-circle 4s ease-in-out infinite;
}

@keyframes pulse-circle {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.2); opacity: 0.3; }
}

.login-card {
    max-width: 480px;
    margin: auto;
    padding: var(--space-3xl);
    animation: slide-in-right 0.6s ease-out;
}

@keyframes slide-in-right {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.login-header h1 {
    margin-bottom: var(--space-sm);
}

.login-header p {
    color: var(--text-tertiary);
    margin-bottom: var(--space-3xl);
}

.login-body h2 {
    font-size: 1.5rem;
    margin-bottom: var(--space-md);
}

.login-subtitle {
    color: var(--text-tertiary);
    margin-bottom: var(--space-2xl);
}

.provider-buttons {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.provider-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-md);
    padding: var(--space-md) var(--space-xl);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-lg);
    background: var(--bg-primary);
    color: var(--text-primary);
    font-weight: 500;
    transition: all var(--transition-base);
    cursor: pointer;
    text-decoration: none;
}

.provider-btn:hover {
    border-color: var(--app-primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.provider-btn svg {
    width: 24px;
    height: 24px;
}

.login-footer {
    margin-top: var(--space-3xl);
    padding-top: var(--space-xl);
    border-top: 1px solid var(--border-color);
}

.login-footer p {
    font-size: 0.875rem;
    color: var(--text-tertiary);
    text-align: center;
}

@media (max-width: 768px) {
    .login-container {
        grid-template-columns: 1fr;
    }
    
    .login-visual {
        display: none;
    }
}


/* === Enhanced Progress Indicators === */
.progress-ring {
    position: relative;
    width: 120px;
    height: 120px;
}

.progress-ring circle {
    transition: stroke-dashoffset 0.35s;
    transform: rotate(-90deg);
    transform-origin: 50% 50%;
    stroke: var(--app-primary);
    stroke-width: 8;
    stroke-linecap: round;
    fill: none;
}

.progress-steps {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: var(--space-2xl) 0;
    position: relative;
}

.progress-steps::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--border-color);
    z-index: 0;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
    position: relative;
    z-index: 1;
    flex: 1;
}

.progress-step-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: var(--text-tertiary);
    transition: all var(--transition-base);
}

.progress-step.completed .progress-step-circle {
    background: var(--app-primary);
    border-color: var(--app-primary);
    color: var(--text-inverse);
}

.progress-step.active .progress-step-circle {
    border-color: var(--app-primary);
    color: var(--app-primary);
    animation: pulse-border 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse-border {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(91, 79, 232, 0.4);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(91, 79, 232, 0);
    }
}

.progress-step-label {
    font-size: 0.875rem;
    color: var(--text-tertiary);
    font-weight: 500;
}

.progress-step.completed .progress-step-label,
.progress-step.active .progress-step-label {
    color: var(--text-primary);
}

/* Confetti celebration animation */
@keyframes confetti-fall {
    0% {
        transform: translateY(-100vh) rotate(0deg);
    }
    100% {
        transform: translateY(100vh) rotate(360deg);
    }
}

.confetti {
    position: fixed;
    width: 10px;
    height: 10px;
    background: var(--app-primary);
    animation: confetti-fall 3s linear;
    pointer-events: none;
}

/* === Tables === */
.rz-datatable, table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.rz-datatable th, .rz-datatable td, th, td {
    padding: var(--space-md) var(--space-lg);
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.rz-datatable th, th {
    background: var(--bg-secondary);
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.rz-datatable tr:last-child td, tr:last-child td {
    border-bottom: none;
}

.rz-datatable tr:hover, tr:hover {
    background: var(--bg-secondary);
}

/* === Updated Swipe Card Component === */
.swipe-card {
    position: relative;
    width: 100%;
    max-width: 400px;
    cursor: grab;
    user-select: none;
    touch-action: pan-y;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease;
}

.swipe-card:active {
    cursor: grabbing;
}

.swipe-card-inner {
    min-height: 300px;
    background: var(--bg-elevated);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-2xl);
    padding: var(--space-2xl);
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-base);
}

.swipe-card:hover .swipe-card-inner {
    border-color: var(--app-primary);
    box-shadow: var(--shadow-xl);
}

.swipe-indicator {
    position: absolute;
    top: 20px;
    padding: var(--space-sm) var(--space-lg);
    border-radius: var(--radius-lg);
    font-size: 1.5rem;
    font-weight: bold;
    backdrop-filter: blur(8px);
}

.swipe-indicator.like {
    right: 20px;
    background: rgba(16, 185, 129, 0.9);
    color: var(--text-inverse);
    box-shadow: var(--shadow-md);
}

.swipe-indicator.nope {
    left: 20px;
    background: rgba(107, 114, 128, 0.9);
    color: var(--text-inverse);
    box-shadow: var(--shadow-md);
}

.swipe-container {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    position: relative;
}

.swipe-button {
    border-radius: 50%;
    width: 56px;
    height: 56px;
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-base);
}

.swipe-button:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-xl);
}

/* === Mutation/Feature/Selection Cards === */
.mutation-card, .feature-card, .selection-card {
    transition: all var(--transition-base);
    border-radius: var(--radius-xl);
}

.mutation-card {
    border-left: 4px solid var(--app-primary);
    background: var(--bg-elevated);
}

.mutation-card:hover, .feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--app-primary-light);
}

.selection-card {
    cursor: pointer;
    border: 2px solid var(--border-color);
    background: var(--bg-primary);
}

.selection-card:hover {
    border-color: var(--app-primary);
    box-shadow: var(--shadow-md);
}

.selection-card.selected {
    border-color: var(--app-primary);
    background: rgba(91, 79, 232, 0.05);
    box-shadow: var(--shadow-md);
}

/* === Animations === */
@keyframes swipeRight {
    to { 
        transform: translateX(150%) rotate(15deg); 
        opacity: 0; 
    }
}

@keyframes swipeLeft {
    to { 
        transform: translateX(-150%) rotate(-15deg); 
        opacity: 0; 
    }
}

@keyframes swipeUp {
    to { 
        transform: translateY(-150%); 
        opacity: 0; 
    }
}

.swipe-card.swiping-right {
    animation: swipeRight 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.swipe-card.swiping-left {
    animation: swipeLeft 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.swipe-card.swiping-up {
    animation: swipeUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.animate-fade-in {
    animation: fade-in 0.6s ease-out;
}

.animate-scale-in {
    animation: scale-in 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes scale-in {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* === Utility Classes === */
.text-center { text-align: center; }
.flex { display: flex; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: var(--space-md); }
.gap-4 { gap: var(--space-xl); }

/* Spacing utilities */
.p-0 { padding: 0; }
.p-2 { padding: var(--space-md); }
.p-4 { padding: var(--space-xl); }
.m-0 { margin: 0; }
.m-2 { margin: var(--space-md); }
.m-4 { margin: var(--space-xl); }
.mt-2 { margin-top: var(--space-md); }
.mt-4 { margin-top: var(--space-xl); }
.mb-2 { margin-bottom: var(--space-md); }
.mb-4 { margin-bottom: var(--space-xl); }

/* === Responsive Design === */
@media (max-width: 768px) {
    .rz-body {
        padding: var(--space-lg);
    }
    
    h1 { font-size: 2rem; }
    
    .bento-grid {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }
    
    .bento-item.large,
    .bento-item.wide,
    .bento-item.tall {
        grid-column: span 1;
        grid-row: span 1;
    }
}

@media (max-width: 480px) {
    :root {
        --space-xl: 1.5rem;
        --space-2xl: 2rem;
    }
    
    .rz-body {
        padding: var(--space-md);
    }
}

/* === Aurora Background Effect === */
.aurora-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
    overflow: hidden;
}

.aurora-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.15;
    animation: aurora-drift 20s ease-in-out infinite;
}

.aurora-blob:nth-child(1) {
    width: 600px;
    height: 600px;
    background: var(--app-primary);
    top: -200px;
    right: -100px;
    animation-delay: 0s;
}

.aurora-blob:nth-child(2) {
    width: 500px;
    height: 500px;
    background: var(--app-accent);
    bottom: -150px;
    left: -100px;
    animation-delay: -7s;
}

.aurora-blob:nth-child(3) {
    width: 400px;
    height: 400px;
    background: var(--app-primary-light);
    top: 40%;
    left: 40%;
    animation-delay: -14s;
}

@keyframes aurora-drift {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    25% {
        transform: translate(30px, -30px) scale(1.05);
    }
    50% {
        transform: translate(-20px, 20px) scale(0.95);
    }
    75% {
        transform: translate(15px, 15px) scale(1.02);
    }
}

/* === Page Transitions === */
.rz-body > div {
    animation: page-enter 0.4s ease-out;
}

@keyframes page-enter {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* === Loading Skeleton Shimmer Upgrade === */
.skeleton-line, .skeleton-circle, .skeleton-badge, .skeleton-card {
    background: linear-gradient(
        90deg,
        var(--neutral-100) 0%,
        var(--neutral-200) 50%,
        var(--neutral-100) 100%
    );
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius-md);
}

@keyframes skeleton-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* === Focus Mode Optimization === */
.focus-container {
    max-width: 800px;
    margin: 0 auto;
    padding: var(--space-2xl);
}

/* === Radzen Component Overrides (Global) === */
.rz-panelmenu .rz-navigation-item {
    margin: var(--space-xs) 0;
}

.rz-alert {
    border-radius: var(--radius-lg);
    border: none;
    box-shadow: var(--shadow-sm);
}

.rz-dialog-content {
    border-radius: var(--radius-xl);
}

.rz-notification {
    border-radius: var(--radius-lg) !important;
    box-shadow: var(--shadow-xl) !important;
}

/* Tooltip styling */
.rz-tooltip {
    border-radius: var(--radius-md) !important;
    font-size: 0.875rem;
    padding: var(--space-sm) var(--space-md) !important;
    box-shadow: var(--shadow-lg) !important;
}

/* Dropdown overlay */
.rz-dropdown-panel {
    border-radius: var(--radius-lg) !important;
    box-shadow: var(--shadow-xl) !important;
    border: 1px solid var(--border-color) !important;
}

.rz-dropdown-item {
    border-radius: var(--radius-md);
    margin: var(--space-xs);
    transition: all var(--transition-fast);
}

.rz-dropdown-item:hover {
    background: var(--bg-secondary) !important;
}

.app-type-dropdown {
    padding: 0 !important;
}

.app-type-dropdown .rz-dropdown-label {
    display: block;
    max-width: none;
    white-space: nowrap;
    overflow: visible;
    text-overflow: clip;
}

/* === Phase Rail (#2 & #3 — replaces SessionBreadcrumb + SessionProgress) === */
.phase-rail {
    margin-bottom: var(--space-lg);
    padding: 0 !important;
}

.phase-rail-back {
    display: flex;
    align-items: center;
    color: var(--text-tertiary);
    text-decoration: none;
    flex-shrink: 0;
    transition: color var(--transition-fast);
}
.phase-rail-back:hover { color: var(--app-primary); }
.phase-rail-sep { opacity: 0.3; color: var(--neutral-400); flex-shrink: 0; }

.phase-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    min-width: 48px;
    flex-shrink: 0;
}
.phase-step-circle {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    transition: all var(--transition-fast);
    text-decoration: none;
}
.phase-step-circle--active  { background: var(--app-primary); color: white; box-shadow: 0 0 0 3px rgba(91,33,182,0.25); }
.phase-step-circle--completed { background: rgba(16,124,16,0.15); color: #107c10; border: 1.5px solid #107c10; }
.phase-step-circle--completed:hover { background: #107c10; color: white; }
.phase-step-circle--pending  { background: var(--bg-secondary); color: var(--text-tertiary); border: 1.5px solid var(--border-color); }

.phase-step-label {
    font-size: 0.625rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    white-space: nowrap;
}
.phase-step--active .phase-step-label  { color: var(--app-primary); }
.phase-step--completed .phase-step-label { color: #107c10; }

.phase-step-connector { flex: 1; height: 2px; min-width: 12px; border-radius: 1px; margin-bottom: 14px; }
.phase-step-connector--completed { background: #107c10; }
.phase-step-connector--pending   { background: var(--border-color); }

/* === Modal Overlay (replaces RadzenDialog inline usage) === */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
}

.modal-card {
    border-radius: var(--radius-xl) !important;
    box-shadow: var(--shadow-xl);
    animation: scale-in 0.15s ease-out;
}

/* ─── Sessions card grid ─────────────────────────────── */
.sessions-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
    padding: 0.25rem;
}

.session-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.25rem;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.session-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.session-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.session-app-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--app-primary-alpha, rgba(99,102,241,.15));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.session-card-phase {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.session-card-footer {
    margin-top: auto;
    display: flex;
    justify-content: flex-end;
}

/* ─── Artifacts 3-tab layout ─────────────────────────── */
.artifacts-tabs { margin-top: 1rem; }

.artifact-tab-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0 0.75rem;
    border-bottom: 1px solid var(--neutral-200, rgba(255,255,255,.08));
    margin-bottom: 1rem;
}

.artifact-tab-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 4rem;
    opacity: 0.5;
}

/* ─── Home hero app-type tiles ───────────────────────── */
.app-type-tiles {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
    width: 100%;
}

.app-type-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 0.5rem;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, transform 0.15s;
    color: inherit;
    font-family: inherit;
}

.app-type-tile:hover {
    background: rgba(var(--rz-primary-rgb, 99,102,241),.18);
    border-color: var(--app-primary);
    transform: translateY(-2px);
}

.tile-emoji { font-size: 1.75rem; line-height: 1; }
.tile-label { font-size: 0.8rem; font-weight: 500; text-align: center; color: var(--text-secondary); }

@media (max-width: 480px) {
    .app-type-tiles { grid-template-columns: repeat(2, 1fr); }
}

/* ─── Gallery showcase card ──────────────────────────── */
.gallery-showcase-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
    padding: 0;
}

.gallery-showcase-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl, 0 20px 60px rgba(0,0,0,.45));
}

.gallery-card-hero {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: var(--surface-2, rgba(255,255,255,.06));
}

.gallery-card-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.gallery-showcase-card:hover .gallery-card-hero img { transform: scale(1.04); }

.gallery-card-hero--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--surface-2, rgba(255,255,255,.04)), rgba(99,102,241,.08));
}

.gallery-card-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    padding: 0.75rem;
    background: linear-gradient(to top, rgba(0,0,0,.5) 0%, transparent 60%);
}

.hero-badge { backdrop-filter: blur(6px); }

.gallery-card-body {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    padding: 1rem 1rem 0.5rem;
    flex: 1;
}

.gallery-card-desc {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gallery-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 1rem 1rem;
}
