:root {
    --color-bg: #F8FAFC;
    --color-sidebar: #0F172A;
    --color-accent: #2563EB;
    --color-accent-hover: #1D4ED8;
    --color-surface: #FFFFFF;
    --color-border: #E2E8F0;
    --color-text-main: #1E293B;
    --color-text-muted: #64748B;
    
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;
    
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
    
    --transition-standard: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@media print {
    .no-print {
        display: none !important;
    }
    body {
        background: white !important;
        padding: 0 !important;
    }
    main {
        margin-left: 0 !important;
        padding: 0 !important;
    }
    .perspective-card {
        break-inside: avoid;
        margin-bottom: 2rem;
        border: 1px solid #E2E8F0 !important;
        box-shadow: none !important;
    }
    .no-print-margin {
        margin: 0 !important;
        padding: 0 !important;
    }
    header {
        border: 1px solid #E2E8F0 !important;
        box-shadow: none !important;
        margin-bottom: 2rem !important;
    }
    input, select, textarea {
        border: none !important;
        padding: 0 !important;
        background: transparent !important;
    }
}

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

body {
    background-color: var(--color-bg);
    color: var(--color-text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
}

::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

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

::-webkit-scrollbar-thumb {
    background: #CBD5E1;
    border-radius: 20px;
}

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

#loading-overlay {
    position: fixed;
    inset: 0;
    background: var(--color-sidebar);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    transition: opacity 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.spinner {
    width: 70px;
    height: 70px;
    border: 3px solid rgba(37, 99, 235, 0.1);
    border-top: 3px solid var(--color-accent);
    border-radius: 50%;
    animation: spin 1.2s cubic-bezier(0.4, 0.1, 0.3, 1) infinite;
    filter: drop-shadow(0 0 15px rgba(37, 99, 235, 0.6));
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.branding-text {
    font-family: var(--font-heading);
    color: white;
    font-weight: 900;
    letter-spacing: 0.5em;
    font-size: 1.4rem;
    margin-top: 2.5rem;
}

.status-text {
    color: var(--color-accent);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3em;
    margin-top: 0.6rem;
}

@keyframes phasePulse {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.5); }
  70% { transform: scale(1.08); box-shadow: 0 0 0 15px rgba(37, 99, 235, 0); }
  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0); }
}

.animate-pulse-accent {
  animation: phasePulse 2.5s infinite cubic-bezier(0.4, 0, 0.6, 1);
}

.animate-in {
    animation: slideUp 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

input, select, textarea {
    background: #F8FAFC !important;
    border: 2px solid #F1F5F9 !important;
    transition: var(--transition-standard) !important;
}

input:focus, select:focus, textarea:focus {
    background: #FFFFFF !important;
    border-color: var(--color-accent) !important;
    box-shadow: 0 10px 20px -10px rgba(37, 99, 235, 0.1) !important;
}

.modal-backdrop {
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(15px);
}

.btn-primary {
    background: var(--color-sidebar);
    color: white;
    padding: 1.25rem 2.5rem;
    border-radius: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-size: 0.75rem;
    transition: var(--transition-standard);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
}

.btn-primary:hover {
    background: var(--color-accent);
    transform: translateY(-3px);
    box-shadow: 0 20px 25px -5px rgba(37, 99, 235, 0.4);
}

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