@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');

:root {
    /* Muted & Professional Palette - Slate & Indigo */
    --primary: #334155;
    /* Slate 700 */
    --primary-dark: #1e293b;
    /* Slate 800 */
    --secondary: #64748b;
    /* Slate 500 */
    --accent: #6366f1;
    /* Indigo 500 (Subdued pop) */

    --success: #2d7a5b;
    /* Muted Forest/Sage */
    --info: #475569;
    /* Slate 600 */
    --warning: #d97706;
    /* Muted Amber */
    --danger: #9f1239;
    /* Desaturated Wine Red */

    --light: #f8fafc;
    /* Slate 50 */
    --dark: #0f172a;
    /* Slate 900 */

    --body-bg: #f8fafc;
    /* Slate 50 - Cleaner look */
    --card-bg: #ffffff;

    /* Subtle Shadows for Depth */
    --card-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --card-shadow-hover: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --btn-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
}

/* Bootstrap Overrides to match variables */
.bg-primary {
    background-color: var(--primary) !important;
}

.bg-success {
    background-color: var(--success) !important;
}

.bg-info {
    background-color: var(--info) !important;
}

.bg-danger {
    background-color: var(--danger) !important;
}

.bg-warning {
    background-color: var(--warning) !important;
}

.text-primary {
    color: var(--primary) !important;
}

.text-success {
    color: var(--success) !important;
}

.text-danger {
    color: var(--danger) !important;
}

.border-primary {
    border-color: var(--primary) !important;
}

.border-info {
    border-color: var(--info) !important;
}


html,
body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--body-bg);
    color: var(--dark);
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    color: var(--primary);
    /* Use Primary Slate for Headings */
    letter-spacing: -0.025em;
    /* Tight blocking for modern feel */
}

/* Ensure headings inside text-white containers (like cards with bg-primary) are actually white */
.text-white h1,
.text-white h2,
.text-white h3,
.text-white h4,
.text-white h5,
.text-white h6 {
    color: #ffffff !important;
}

.card {
    background-color: var(--card-bg);
    border: 1px solid rgba(226, 232, 240, 0.8);
    /* Slate 200 */
    border-radius: 1rem;
    /* More rounded */
    box-shadow: var(--card-shadow);
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.card:hover {
    box-shadow: var(--card-shadow-hover);
    border-color: rgba(148, 163, 184, 0.5);
    /* Slate 400 */
}

.btn {
    border-radius: 0.5rem;
    font-weight: 600;
    padding: 0.6rem 1.2rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border-width: 2px;
}

.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
    box-shadow: var(--btn-shadow);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}

.form-control,
.form-select {
    border-radius: 0.5rem;
    border: 1px solid #dee2e6;
    padding: 0.75rem 1rem;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.1);
}

.nav-pills .nav-link.active {
    background-color: var(--accent);
    /* Use Accent for active pills */
    color: white;
}

.sidebar {
    background-color: var(--primary);
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.1);
}

.oi {
    margin-right: 0.5rem;
}

/* Ensure Bootstrap Icons are visible and not overridden */
.bi::before {
    display: inline-block;
    font-family: 'bootstrap-icons' !important;
    font-style: normal;
    font-weight: normal !important;
    font-variant: normal;
    text-transform: none;
    line-height: 1;
    vertical-align: -.125em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}


/* Custom dimensions for forms */
.form-section-header {
    margin-top: 2rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary);
    display: inline-block;
}

input[type=checkbox] {
    appearance: auto !important;
    width: 1.2rem;
    height: 1.2rem;
    margin-top: 0.3rem;
    cursor: pointer;
}

.nav-item .nav-link {
    border-radius: 0.5rem;
    margin: 0.25rem 0.5rem;
    transition: all 0.2s ease;
}

.nav-item .nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.nav-item .nav-link.active {
    background-color: rgba(255, 255, 255, 0.15);
    /* More subtle */
    color: var(--accent) !important;
    /* Pop with accent color */
    font-weight: 600;
    border-left: 3px solid var(--accent);
    /* Left border indicator */
    border-radius: 0 0.5rem 0.5rem 0;
    /* Only round right side */
    margin-left: 0;
    /* flush with left */
}

#blazor-error-ui {
    background: #fff3cd;
    color: #856404;
}