/**
 * Custom Bootstrap Theme - Divorce Case Management SaaS
 * Color palette based on design specifications
 */

:root {
    /* Primary Colors - Deep Navy for trust and authority */
    --bs-primary-rgb: 30, 58, 95; /* #1E3A5F - primary-900 */
    --bs-primary: #1E3A5F;
    --bs-primary-bg-subtle: #4A90C5; /* primary-500 for lighter backgrounds */
    --bs-primary-border-subtle: #3182CE; /* primary-600 */
    --bs-primary-text-emphasis: #2C5282; /* primary-800 */

    /* Secondary/Accent Colors - Muted Gold for prestige */
    --bs-secondary-rgb: 166, 124, 82; /* #A67C52 - accent-gold-700 */
    --bs-secondary: #A67C52;
    --bs-secondary-bg-subtle: #D4B87B; /* accent-gold-400 */
    --bs-secondary-border-subtle: #C9A961; /* accent-gold-500 */
    --bs-secondary-text-emphasis: #B8936D; /* accent-gold-600 */

    /* Success Colors */
    --bs-success-rgb: 5, 150, 105; /* #059669 - success-600 */
    --bs-success: #059669;
    --bs-success-bg-subtle: #10B981; /* success-500 */
    --bs-success-border-subtle: #059669;
    --bs-success-text-emphasis: #047857;

    /* Warning Colors */
    --bs-warning-rgb: 217, 119, 6; /* #D97706 - warning-600 */
    --bs-warning: #D97706;
    --bs-warning-bg-subtle: #F59E0B; /* warning-500 */
    --bs-warning-border-subtle: #D97706;
    --bs-warning-text-emphasis: #B45309;

    /* Danger Colors */
    --bs-danger-rgb: 220, 38, 38; /* #DC2626 - danger-600 */
    --bs-danger: #DC2626;
    --bs-danger-bg-subtle: #EF4444; /* danger-500 */
    --bs-danger-border-subtle: #DC2626;
    --bs-danger-text-emphasis: #B91C1C;

    /* Info Colors */
    --bs-info-rgb: 37, 99, 235; /* #2563EB - info-600 */
    --bs-info: #2563EB;
    --bs-info-bg-subtle: #3B82F6; /* info-500 */
    --bs-info-border-subtle: #2563EB;
    --bs-info-text-emphasis: #1D4ED8;

    /* Neutral Colors */
    --bs-dark-rgb: 26, 32, 44; /* #1A202C - neutral-900 */
    --bs-dark: #1A202C;
    --bs-body-color: #2D3748; /* neutral-800 - Charcoal for text */
    --bs-body-color-rgb: 45, 55, 72;

    --bs-light-rgb: 247, 250, 252; /* #F7FAFC - neutral-100 */
    --bs-light: #F7FAFC;
    --bs-body-bg: #F7FAFC;
    --bs-body-bg-rgb: 247, 250, 252;

    /* Additional neutral shades for borders, backgrounds, etc */
    --bs-gray-100: #F7FAFC; /* neutral-100 */
    --bs-gray-200: #EDF2F7; /* neutral-200 */
    --bs-gray-300: #E2E8F0; /* neutral-300 */
    --bs-gray-400: #CBD5E0; /* neutral-400 */
    --bs-gray-500: #A0AEC0; /* neutral-500 */
    --bs-gray-600: #718096; /* neutral-600 */
    --bs-gray-700: #4A5568; /* neutral-700 */
    --bs-gray-800: #2D3748; /* neutral-800 */
    --bs-gray-900: #1A202C; /* neutral-900 */

    /* Border colors */
    --bs-border-color: #E2E8F0; /* neutral-300 */
    --bs-border-color-translucent: rgba(226, 232, 240, 0.5);

    /* Border radius from design specs */
    --bs-border-radius: 0.5rem; /* 8px for cards */
    --bs-border-radius-sm: 0.375rem; /* 6px for buttons */
    --bs-border-radius-lg: 1rem;
    --bs-border-radius-xl: 1.5rem;
    --bs-border-radius-pill: 50rem;

    /* Shadows */
    --bs-box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05); /* shadow-sm */
    --bs-box-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --bs-box-shadow-lg: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06); /* shadow-md */

    /* Links */
    --bs-link-color: #2B6CB0; /* primary-700 */
    --bs-link-color-rgb: 43, 108, 176;
    --bs-link-hover-color: #1E3A5F; /* primary-900 */
    --bs-link-hover-color-rgb: 30, 58, 95;

    /* Typography - Inter font family */
    --bs-font-sans-serif: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --bs-font-monospace: "JetBrains Mono", "Fira Code", Consolas, Monaco, "Courier New", monospace;

    /* Font sizes from design specs */
    --bs-body-font-size: 1rem; /* 16px - text-base */
    --bs-body-font-weight: 400;
    --bs-body-line-height: 1.5;

    /* Headings */
    --bs-heading-color: #1A202C; /* neutral-900 */

    /* Transitions from design specs */
    --bs-transition: all 0.15s ease-in-out;
}

/* Button customizations with design spec border-radius */
.btn {
    border-radius: 0.375rem; /* 6px for buttons */
    font-weight: 500;
    transition: var(--bs-transition);
}

/* Card customizations with design spec border-radius */
.card {
    border-radius: 0.5rem; /* 8px for cards */
    box-shadow: var(--bs-box-shadow-sm);
    border-color: var(--bs-border-color);
}

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

/* Form inputs with design spec border-radius */
.form-control,
.form-select {
    border-radius: 0.25rem; /* 4px for inputs */
    border-color: var(--bs-gray-300);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.2rem rgba(30, 58, 95, 0.25);
}

/* Typography improvements */
body {
    font-family: var(--bs-font-sans-serif);
    color: var(--bs-body-color);
    background-color: var(--bs-body-bg);
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-weight: 600;
    color: var(--bs-heading-color);
}

/* Professional table styling */
.table {
    color: var(--bs-body-color);
}

.table > :not(caption) > * > * {
    border-bottom-color: var(--bs-gray-200);
}

.table-hover > tbody > tr:hover {
    background-color: var(--bs-gray-100);
}

/* Badge customizations */
.badge {
    font-weight: 500;
    padding: 0.25rem 0.75rem;
}

/* Modal customizations */
.modal-content {
    border-radius: 0.5rem;
    border: none;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* Navbar styling for professional look */
.navbar {
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

/* Sidebar styling (fixed 240px as per specs) */
.sidebar {
    width: 240px;
    background-color: var(--bs-dark);
    color: white;
    min-height: 100vh;
}

.sidebar .nav-link {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--bs-transition);
}

.sidebar .nav-link:hover,
.sidebar .nav-link.active {
    color: white;
    background-color: rgba(255, 255, 255, 0.1);
}

/* Custom utilities for the design system */
.text-primary-900 { color: #1E3A5F !important; }
.text-primary-800 { color: #2C5282 !important; }
.text-primary-700 { color: #2B6CB0 !important; }

.bg-primary-900 { background-color: #1E3A5F !important; }
.bg-primary-800 { background-color: #2C5282 !important; }

.text-neutral-600 { color: #718096 !important; }
.text-neutral-700 { color: #4A5568 !important; }
.text-neutral-800 { color: #2D3748 !important; }

/* Professional toast notifications */
.toast {
    border-radius: 0.5rem;
    box-shadow: var(--bs-box-shadow-lg);
}

/* Loading states */
.spinner-border {
    color: var(--bs-primary);
}

/* Status badges color-coded */
.badge-status-new { background-color: #3B82F6; }
.badge-status-in-progress { background-color: #F59E0B; }
.badge-status-hearing { background-color: #8B5CF6; }
.badge-status-closed { background-color: #059669; }
.badge-status-archived { background-color: #6B7280; }

/* Priority badges */
.badge-priority-low { background-color: #10B981; }
.badge-priority-normal { background-color: #3B82F6; }
.badge-priority-high { background-color: #F59E0B; }
.badge-priority-urgent { background-color: #DC2626; }
