/* ==========================================================================
   Gem Events PNR - Luxury Aero Glassmorphism & macOS Elegance Theme
   WCAG AAA Compliant Light & Dark Dual-Mode Styling
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

:root {
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

    /* Light Mode - Alabaster Glass & Crisp Slate Tokens */
    --aero-glass-bg: rgba(255, 255, 255, 0.90);
    --aero-glass-border: rgba(226, 232, 240, 0.95);
    --aero-glass-highlight: inset 0 1px 0 0 rgba(255, 255, 255, 1);
    --aero-glass-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.06), 0 8px 10px -6px rgba(15, 23, 42, 0.04);
    --macos-sidebar-bg: rgba(255, 255, 255, 0.92);
    --macos-sidebar-border: rgba(226, 232, 240, 0.90);
    --macos-card-radius: 14px;
    --macos-pill-radius: 9999px;
    --glass-blur: blur(20px) saturate(180%);

    --input-bg: #ffffff;
    --input-border: #cbd5e1;
    --input-text: #0f172a;
    --text-primary: #0f172a;
    --text-secondary: #475569;
}

.dark {
    /* Dark Mode - Obsidian Glass & Emerald Luxury Tokens */
    --aero-glass-bg: rgba(15, 23, 42, 0.78);
    --aero-glass-border: rgba(255, 255, 255, 0.12);
    --aero-glass-highlight: inset 0 1px 0 0 rgba(255, 255, 255, 0.22);
    --aero-glass-shadow: 0 20px 40px -8px rgba(0, 0, 0, 0.5), 0 4px 16px -2px rgba(0, 0, 0, 0.35);
    --macos-sidebar-bg: rgba(10, 15, 29, 0.78);
    --macos-sidebar-border: rgba(255, 255, 255, 0.10);

    --input-bg: rgba(15, 23, 42, 0.65);
    --input-border: rgba(255, 255, 255, 0.14);
    --input-text: #f1f5f9;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
}

/* Global Font & Smooth Rendering */
body, .fi-body {
    font-family: var(--font-sans) !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
}

/* Light Mode Background Canvas */
body.fi-body {
    background-color: #f8fafc !important;
    background-image: 
        radial-gradient(at 0% 0%, rgba(16, 185, 129, 0.08) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(56, 189, 248, 0.08) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(139, 92, 246, 0.05) 0px, transparent 50%),
        radial-gradient(at 0% 100%, rgba(245, 158, 11, 0.04) 0px, transparent 50%) !important;
    background-attachment: fixed !important;
    color: var(--text-primary) !important;
}

/* Dark Mode Background Canvas */
.dark body.fi-body {
    background-color: #0b0f19 !important;
    background-image: 
        radial-gradient(at 0% 0%, rgba(16, 185, 129, 0.12) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(56, 189, 248, 0.10) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(139, 92, 246, 0.08) 0px, transparent 50%),
        radial-gradient(at 0% 100%, rgba(245, 158, 11, 0.06) 0px, transparent 50%) !important;
    background-attachment: fixed !important;
    color: var(--text-primary) !important;
}

/* ==========================================================================
   macOS Vibrancy Sidebar - Smooth Fluid Retraction Motion
   ========================================================================== */
aside.fi-sidebar,
.fi-main-sidebar {
    background: var(--macos-sidebar-bg) !important;
    backdrop-filter: var(--glass-blur) !important;
    -webkit-backdrop-filter: var(--glass-blur) !important;
    border-right: 1px solid var(--macos-sidebar-border) !important;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.04) !important;
    transition: width 0.38s cubic-bezier(0.16, 1, 0.3, 1),
                max-width 0.38s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.38s cubic-bezier(0.16, 1, 0.3, 1),
                box-shadow 0.38s cubic-bezier(0.16, 1, 0.3, 1),
                background-color 0.38s ease !important;
    will-change: width, transform;
}

.dark aside.fi-sidebar,
.dark .fi-main-sidebar {
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.22) !important;
}

/* Fluid Content Glide when sidebar retracts/expands */
.fi-main-ctn {
    transition: margin-left 0.38s cubic-bezier(0.16, 1, 0.3, 1),
                padding-left 0.38s cubic-bezier(0.16, 1, 0.3, 1) !important;
    will-change: margin-left, padding-left;
}

header.fi-topbar {
    transition: margin-left 0.38s cubic-bezier(0.16, 1, 0.3, 1),
                padding-left 0.38s cubic-bezier(0.16, 1, 0.3, 1),
                width 0.38s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

/* Smooth text fade and slide when collapsing to icon rail */
.fi-sidebar-item-label,
.fi-sidebar-group-label,
.fi-sidebar-header .fi-logo {
    transition: opacity 0.24s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.24s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

/* Retract button cool elastic micro-interaction */
.fi-topbar-open-collapse-sidebar-btn,
.fi-topbar-close-sidebar-btn,
.fi-sidebar-open-collapse-sidebar-btn {
    transition: transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1),
                background-color 0.2s ease,
                color 0.2s ease !important;
}

.fi-topbar-open-collapse-sidebar-btn:hover,
.fi-topbar-close-sidebar-btn:hover,
.fi-sidebar-open-collapse-sidebar-btn:hover {
    transform: scale(1.12) rotate(6deg) !important;
}

.fi-topbar-open-collapse-sidebar-btn:active,
.fi-topbar-close-sidebar-btn:active {
    transform: scale(0.92) !important;
}

/* Retracted Icon Rail Glow & Tooltip Elevation */
.fi-sidebar:not(.fi-sidebar-open) .fi-sidebar-nav-item a {
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1),
                background 0.2s ease,
                box-shadow 0.2s ease !important;
}

.fi-sidebar:not(.fi-sidebar-open) .fi-sidebar-nav-item a:hover {
    transform: scale(1.08) !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2) !important;
}

.fi-sidebar-nav-item a {
    border-radius: 10px !important;
    transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1) !important;
    font-weight: 500 !important;
}

/* Light Mode Sidebar Items */
html:not(.dark) .fi-sidebar-nav-item a {
    color: #334155 !important;
}

html:not(.dark) .fi-sidebar-nav-item a:hover {
    background: rgba(15, 23, 42, 0.05) !important;
    color: #0f172a !important;
    transform: translateX(2px) !important;
}

html:not(.dark) .fi-sidebar-nav-item.fi-active a {
    background: #ecfdf5 !important;
    border: 1px solid #a7f3d0 !important;
    color: #047857 !important;
    font-weight: 600 !important;
    box-shadow: 0 1px 3px rgba(16, 185, 129, 0.12) !important;
}

/* Dark Mode Sidebar Items */
.dark .fi-sidebar-nav-item a:hover {
    background: rgba(255, 255, 255, 0.08) !important;
    transform: translateX(2px) !important;
}

.dark .fi-sidebar-nav-item.fi-active a {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.25) 0%, rgba(5, 150, 105, 0.18) 100%) !important;
    border: 1px solid rgba(16, 185, 129, 0.35) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 4px 12px rgba(16, 185, 129, 0.15) !important;
    color: #34d399 !important;
}

/* ==========================================================================
   macOS Topbar & Pill Search
   ========================================================================== */
header.fi-topbar {
    background: var(--aero-glass-bg) !important;
    backdrop-filter: var(--glass-blur) !important;
    -webkit-backdrop-filter: var(--glass-blur) !important;
    border-bottom: 1px solid var(--aero-glass-border) !important;
    box-shadow: var(--aero-glass-highlight), var(--aero-glass-shadow) !important;
}

/* ==========================================================================
   Windows Aero Glass Panels & Cards
   ========================================================================== */
.fi-section, 
.fi-ta-ctn, 
.fi-modal-window, 
.fi-wi-stats-overview-stat,
.fi-card {
    background: var(--aero-glass-bg) !important;
    backdrop-filter: var(--glass-blur) !important;
    -webkit-backdrop-filter: var(--glass-blur) !important;
    border: 1px solid var(--aero-glass-border) !important;
    border-radius: var(--macos-card-radius) !important;
    box-shadow: var(--aero-glass-highlight), var(--aero-glass-shadow) !important;
}

html:not(.dark) .fi-section-header, 
html:not(.dark) .fi-ta-header-ctn {
    border-bottom: 1px solid rgba(226, 232, 240, 0.9) !important;
}

.dark .fi-section-header, 
.dark .fi-ta-header-ctn {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

/* ==========================================================================
   High Contrast Typography (WCAG AAA Compliant)
   ========================================================================== */

/* Light Mode Typography */
html:not(.dark) .fi-ta-cell,
html:not(.dark) .fi-in-entry,
html:not(.dark) .fi-section-content,
html:not(.dark) .fi-fo-field-wrp {
    color: #0f172a !important;
}

html:not(.dark) .fi-header-heading,
html:not(.dark) .fi-section-header-heading {
    color: #0f172a !important;
    font-weight: 700 !important;
}

html:not(.dark) .fi-section-header-description,
html:not(.dark) .fi-ta-header-description {
    color: #475569 !important;
}

html:not(.dark) .text-gray-500,
html:not(.dark) .text-gray-600 {
    color: #475569 !important;
}

html:not(.dark) .text-gray-700,
html:not(.dark) .text-gray-800 {
    color: #1e293b !important;
}

/* Dark Mode Typography */
.dark .fi-ta-cell,
.dark .fi-in-entry,
.dark .fi-section-content,
.dark .fi-fo-field-wrp {
    color: #f1f5f9 !important;
}

.dark .text-gray-500,
.dark .text-gray-600 {
    color: #94a3b8 !important;
}

.dark .text-gray-700,
.dark .text-gray-800 {
    color: #e2e8f0 !important;
}

/* ==========================================================================
   Form Inputs with High-Contrast Legibility
   ========================================================================== */
.fi-input-wrp {
    background: var(--input-bg) !important;
    border: 1px solid var(--input-border) !important;
    border-radius: 9px !important;
    transition: all 0.2s ease !important;
}

.fi-input-wrp input, 
.fi-input-wrp select, 
.fi-input-wrp textarea,
.fi-input {
    color: var(--input-text) !important;
}

.fi-input-wrp:not(.fi-invalid):focus-within {
    border-color: #10b981 !important;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.22) !important;
}

.fi-input-wrp.fi-invalid,
.fi-input-wrp.fi-error {
    border-color: #ef4444 !important;
}

.fi-input-wrp.fi-invalid:focus-within,
.fi-input-wrp.fi-error:focus-within {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.25) !important;
}

/* Disabled & Read-only Input Styling */
.fi-input-wrp:has(input:disabled),
.fi-input-wrp:has(select:disabled),
.fi-input-wrp:has(textarea:disabled),
.fi-input-wrp.fi-disabled {
    background: rgba(148, 163, 184, 0.12) !important;
    border-color: rgba(148, 163, 184, 0.25) !important;
    cursor: not-allowed !important;
    opacity: 0.85 !important;
}

.fi-input-wrp:has(input:disabled) input,
.fi-input-wrp:has(select:disabled) select,
.fi-input-wrp:has(textarea:disabled) textarea,
.fi-input-wrp.fi-disabled input {
    color: var(--text-secondary) !important;
    cursor: not-allowed !important;
}

.dark .fi-input-wrp:has(input:disabled),
.dark .fi-input-wrp:has(select:disabled),
.dark .fi-input-wrp:has(textarea:disabled),
.dark .fi-input-wrp.fi-disabled {
    background: rgba(15, 23, 42, 0.4) !important;
    border-color: rgba(255, 255, 255, 0.06) !important;
}

/* ==========================================================================
   Buttons with Aero Sheen
   ========================================================================== */
.fi-btn-primary,
.fi-btn.fi-color-primary,
.fi-btn[data-color="primary"],
.fi-btn-color-primary {
    background: linear-gradient(180deg, #10b981 0%, #059669 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.35), 0 4px 14px rgba(16, 185, 129, 0.35) !important;
    border-radius: 9px !important;
    font-weight: 600 !important;
    color: #ffffff !important;
    transition: all 0.16s ease !important;
}

.fi-btn-primary:hover,
.fi-btn.fi-color-primary:hover,
.fi-btn[data-color="primary"]:hover,
.fi-btn-color-primary:hover {
    transform: translateY(-1px) !important;
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.45), 0 6px 20px rgba(16, 185, 129, 0.45) !important;
}

/* ==========================================================================
   Table Design with Delicate Glass Rows
   ========================================================================== */
.fi-ta-row {
    transition: background-color 0.15s ease !important;
}

html:not(.dark) .fi-ta-row:hover {
    background: rgba(15, 23, 42, 0.025) !important;
}

.dark .fi-ta-row:hover {
    background: rgba(255, 255, 255, 0.04) !important;
}

/* PNR Tag / Badge styling */
.fi-badge {
    border-radius: var(--macos-pill-radius) !important;
    font-weight: 600 !important;
    letter-spacing: 0.02em !important;
}

/* Stats Overview Cards */
.fi-wi-stats-overview-stat {
    position: relative;
    overflow: hidden;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease !important;
}

.fi-wi-stats-overview-stat:hover {
    transform: translateY(-2px) !important;
}

.fi-wi-stats-overview-stat::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #10b981, #38bdf8, #8b5cf6);
}

/* ==========================================================================
   Chart Widgets Styling
   ========================================================================== */
.fi-wi-chart {
    background: var(--macos-card-bg) !important;
    backdrop-filter: var(--glass-blur) !important;
    -webkit-backdrop-filter: var(--glass-blur) !important;
    border: 1px solid var(--macos-card-border) !important;
    border-radius: var(--macos-card-radius) !important;
    box-shadow: var(--macos-card-shadow) !important;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease !important;
}

.fi-wi-chart:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 16px 36px -10px rgba(0, 0, 0, 0.08) !important;
}

.dark .fi-wi-chart:hover {
    box-shadow: 0 16px 36px -10px rgba(0, 0, 0, 0.45) !important;
}

/* ==========================================================================
   Modern Tabs Navigation (.fi-tabs)
   ========================================================================== */
.fi-tabs {
    padding: 4px !important;
    background: rgba(148, 163, 184, 0.08) !important;
    border-radius: 12px !important;
    border: 1px solid rgba(148, 163, 184, 0.15) !important;
    gap: 4px !important;
}

.dark .fi-tabs {
    background: rgba(15, 23, 42, 0.5) !important;
    border-color: rgba(255, 255, 255, 0.07) !important;
}

.fi-tabs-item {
    border-radius: 9px !important;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
    font-weight: 500 !important;
}

.fi-tabs-item[aria-selected="true"],
.fi-tabs-item.fi-active {
    background: #ffffff !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04) !important;
    color: var(--text-primary) !important;
}

.dark .fi-tabs-item[aria-selected="true"],
.dark .fi-tabs-item.fi-active {
    background: rgba(30, 41, 59, 0.95) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
    color: #ffffff !important;
}

/* ==========================================================================
   Repeater Items Hover & Expansion Motion
   ========================================================================== */
.fi-fo-repeater-item {
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1),
                border-color 0.2s ease,
                box-shadow 0.2s ease !important;
}

.fi-fo-repeater-item:hover {
    border-color: rgba(16, 185, 129, 0.35) !important;
    box-shadow: 0 6px 20px -6px rgba(16, 185, 129, 0.12) !important;
}

.dark .fi-fo-repeater-item:hover {
    border-color: rgba(16, 185, 129, 0.3) !important;
    box-shadow: 0 6px 20px -6px rgba(16, 185, 129, 0.25) !important;
}

/* Monospace Currency Figures for Tabular Precision */
.font-mono,
.fi-ta-text-item.font-mono {
    font-feature-settings: "tnum" 1, "zero" 1 !important;
    letter-spacing: -0.02em !important;
}

/* ==========================================================================
   Invoice Gallery & Document Thumbnail Constraints
   ========================================================================== */
.fi-invoice-thumb,
.fi-invoice-thumb-img {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    max-width: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    object-fit: cover !important;
    border-radius: 8px !important;
}

.fi-invoice-svg-icon {
    width: 14px !important;
    height: 14px !important;
    min-width: 14px !important;
    max-width: 14px !important;
    min-height: 14px !important;
    max-height: 14px !important;
    display: inline-block !important;
    vertical-align: middle !important;
}

/* ==========================================================================
   FilePond PDF & Document Luxury Thumbnail Cards
   Replaces lifeless #555 grey boxes with rich visual document cards.
   Zero-interference with FilePond layout & drag-and-drop physics.
   ========================================================================== */

/* Panel Background Card - styled without altering item transform */
.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--item-panel {
    background: linear-gradient(150deg, #ffffff 0%, #f8fafc 55%, #f1f5f9 100%) !important;
    border: 1px solid rgba(203, 213, 225, 0.95) !important;
    box-shadow: 0 4px 12px -2px rgba(15, 23, 42, 0.08), 0 2px 4px -2px rgba(15, 23, 42, 0.04) !important;
    border-radius: 12px !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)):hover .filepond--item-panel {
    border-color: rgba(225, 29, 72, 0.45) !important;
    box-shadow: 0 8px 18px -4px rgba(225, 29, 72, 0.12), 0 2px 6px -2px rgba(0, 0, 0, 0.05) !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--item-panel {
    background: linear-gradient(150deg, #1e293b 0%, #0f172a 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.5) !important;
    border-radius: 12px !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)):hover .filepond--item-panel {
    border-color: rgba(244, 63, 94, 0.5) !important;
    box-shadow: 0 10px 24px -4px rgba(244, 63, 94, 0.22), 0 4px 8px -2px rgba(0, 0, 0, 0.4) !important;
}

/* Central PDF Document Emblem - strictly pointer-events: none, no transform shifting */
.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file::before {
    content: "" !important;
    position: absolute !important;
    top: 48% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    width: 58px !important;
    height: 70px !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-size: contain !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 74' fill='none'%3E%3Cpath d='M8 2 C4.686 2 2 4.686 2 8 V66 C2 69.314 4.686 72 8 72 H56 C59.314 72 62 69.314 62 66 V20 L44 2 H8 Z' fill='%23ffffff' stroke='%23cbd5e1' stroke-width='2'/%3E%3Cpath d='M44 2 V16 C44 18.209 45.791 20 48 20 H62' fill='%23f1f5f9' stroke='%23cbd5e1' stroke-width='1.5'/%3E%3Crect x='10' y='28' width='44' height='20' rx='4' fill='%23e11d48'/%3E%3Ctext x='32' y='42.5' font-family='system-ui, -apple-system, sans-serif' font-size='11' font-weight='800' fill='%23ffffff' text-anchor='middle' letter-spacing='0.5'%3EPDF%3C/text%3E%3Cline x1='14' y1='55' x2='50' y2='55' stroke='%23cbd5e1' stroke-width='2' stroke-linecap='round'/%3E%3Cline x1='14' y1='61' x2='38' y2='61' stroke='%23e2e8f0' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") !important;
    pointer-events: none !important;
    z-index: 1 !important;
    filter: drop-shadow(0 3px 6px rgba(15, 23, 42, 0.08)) !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 74' fill='none'%3E%3Cpath d='M8 2 C4.686 2 2 4.686 2 8 V66 C2 69.314 4.686 72 8 72 H56 C59.314 72 62 69.314 62 66 V20 L44 2 H8 Z' fill='%231e293b' stroke='%23334155' stroke-width='2'/%3E%3Cpath d='M44 2 V16 C44 18.209 45.791 20 48 20 H62' fill='%230f172a' stroke='%23334155' stroke-width='1.5'/%3E%3Crect x='10' y='28' width='44' height='20' rx='4' fill='%23f43f5e'/%3E%3Ctext x='32' y='42.5' font-family='system-ui, -apple-system, sans-serif' font-size='11' font-weight='800' fill='%23ffffff' text-anchor='middle' letter-spacing='0.5'%3EPDF%3C/text%3E%3Cline x1='14' y1='55' x2='50' y2='55' stroke='%23475569' stroke-width='2' stroke-linecap='round'/%3E%3Cline x1='14' y1='61' x2='38' y2='61' stroke='%23334155' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") !important;
    filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.45)) !important;
}

/* Bottom Format Pill & Action Hint - static position, pure color hover */
.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file::after {
    content: "PDF DOCUMENT • ↗ TO VIEW" !important;
    position: absolute !important;
    bottom: 8px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    font-size: 8.5px !important;
    font-weight: 700 !important;
    letter-spacing: 0.05em !important;
    padding: 3px 8px !important;
    border-radius: 9999px !important;
    background: rgba(225, 29, 72, 0.08) !important;
    color: #e11d48 !important;
    border: 1px solid rgba(225, 29, 72, 0.22) !important;
    pointer-events: none !important;
    white-space: nowrap !important;
    z-index: 2 !important;
    transition: background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file::after {
    background: rgba(244, 63, 94, 0.15) !important;
    color: #fda4af !important;
    border-color: rgba(244, 63, 94, 0.35) !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)):hover .filepond--file::after {
    background: #e11d48 !important;
    color: #ffffff !important;
    border-color: #e11d48 !important;
    box-shadow: 0 2px 8px rgba(225, 29, 72, 0.35) !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)):hover .filepond--file::after {
    background: #f43f5e !important;
    color: #ffffff !important;
    border-color: #f43f5e !important;
    box-shadow: 0 2px 8px rgba(244, 63, 94, 0.45) !important;
}

/* File Info Typography & Contrast */
.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file-info {
    position: relative !important;
    z-index: 5 !important;
    width: 100% !important;
    padding-right: 28px !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file-info .filepond--file-info-main {
    color: #0f172a !important;
    font-weight: 700 !important;
    font-size: 0.75rem !important;
    letter-spacing: -0.01em !important;
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file-info .filepond--file-info-main {
    color: #f8fafc !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file-info .filepond--file-info-sub {
    color: #64748b !important;
    opacity: 1 !important;
    font-size: 0.65rem !important;
    font-weight: 600 !important;
    margin-top: 2px !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--file-info .filepond--file-info-sub {
    color: #94a3b8 !important;
}

/* Openable and Downloadable Action Buttons */
.filepond--root .filepond--open-icon,
.filepond--root .filepond--download-icon {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    min-height: 18px !important;
    border-radius: 5px !important;
    margin-right: 3px !important;
    cursor: pointer !important;
    transition: background-color 0.15s ease !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--open-icon {
    background-color: #0284c7 !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--open-icon:hover {
    background-color: #0369a1 !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--download-icon {
    background-color: #059669 !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--download-icon:hover {
    background-color: #047857 !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--open-icon {
    background-color: #38bdf8 !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--open-icon:hover {
    background-color: #0ea5e9 !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--download-icon {
    background-color: #34d399 !important;
}

.dark .filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--download-icon:hover {
    background-color: #10b981 !important;
}

/* Remove 'X' Button on Document Cards */
.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--action-remove-item {
    background-color: rgba(239, 68, 68, 0.88) !important;
    color: #ffffff !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15) !important;
    transition: background-color 0.15s ease !important;
    z-index: 20 !important;
}

.filepond--root .filepond--item:not(:has(.filepond--image-preview-wrapper)) .filepond--action-remove-item:hover {
    background-color: #dc2626 !important;
}

/* Drag State Isolation - ensures zero animation fight during drag operations */
.filepond--root .filepond--item[data-drag-state="drag"] *,
.filepond--root[data-hopper-state="drag-over"] .filepond--item * {
    transition: none !important;
}

/* ==========================================================================
   Executive Fieldsets & Semantic Visual Color Coding
   ========================================================================== */
.fi-fieldset-supplier {
    border-top: 3px solid #10b981 !important;
    border-radius: 12px !important;
    background: rgba(16, 185, 129, 0.02) !important;
}

.fi-fieldset-schedule {
    border-top: 3px solid #0284c7 !important;
    border-radius: 12px !important;
    background: rgba(2, 132, 199, 0.02) !important;
}

.fi-fieldset-costing {
    border-top: 3px solid #f59e0b !important;
    border-radius: 12px !important;
    background: rgba(245, 158, 11, 0.02) !important;
}

.fi-fieldset-pricing {
    border-top: 3px solid #059669 !important;
    border-radius: 12px !important;
    background: linear-gradient(180deg, rgba(16, 185, 129, 0.05) 0%, transparent 100%) !important;
}

.dark .fi-fieldset-supplier {
    border-top-color: #34d399 !important;
    background: rgba(16, 185, 129, 0.04) !important;
}

.dark .fi-fieldset-schedule {
    border-top-color: #38bdf8 !important;
    background: rgba(56, 189, 248, 0.04) !important;
}

.dark .fi-fieldset-costing {
    border-top-color: #fbbf24 !important;
    background: rgba(251, 191, 36, 0.04) !important;
}

.dark .fi-fieldset-pricing {
    border-top-color: #10b981 !important;
    background: linear-gradient(180deg, rgba(16, 185, 129, 0.08) 0%, transparent 100%) !important;
}

/* ==========================================================================
   Real-Time Financial Profitability HUD Card
   ========================================================================== */
.fi-hud-stat {
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, border-color 0.2s ease;
}

.fi-hud-stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(16, 185, 129, 0.12), 0 8px 10px -6px rgba(15, 23, 42, 0.04);
}

.dark .fi-hud-stat:hover {
    box-shadow: 0 14px 28px -6px rgba(0, 0, 0, 0.5), 0 4px 12px rgba(16, 185, 129, 0.2);
}

/* ==========================================================================
   Badge Pulsing Micro-Animations & Status Elevation
   ========================================================================== */
.fi-badge[data-color="primary"] .fi-badge-label,
.fi-badge.fi-color-primary .fi-badge-label {
    position: relative;
    padding-left: 2px;
}

.fi-badge[data-color="primary"]::before,
.fi-badge.fi-color-primary::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #10b981;
    margin-right: 5px;
    animation: statusPulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    box-shadow: 0 0 6px rgba(16, 185, 129, 0.8);
}

.fi-badge[data-color="success"]::before,
.fi-badge.fi-color-success::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #059669;
    margin-right: 5px;
}

@keyframes statusPulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.4;
        transform: scale(1.25);
    }
}

/* ==========================================================================
   Brand Logo Constraints
   ========================================================================== */
.fi-logo {
    display: inline-flex !important;
    align-items: center !important;
    height: auto !important;
    max-height: 48px !important;
    overflow: visible !important;
}

.fi-simple-header .fi-logo {
    justify-content: center !important;
    margin: 0 auto 0.75rem auto !important;
}

.fi-gem-logo {
    display: inline-flex !important;
    align-items: center !important;
    gap: 10px !important;
    height: 40px !important;
    max-height: 40px !important;
}

.fi-gem-logo svg {
    width: 22px !important;
    height: 22px !important;
    min-width: 22px !important;
    max-width: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    flex-shrink: 0 !important;
}

.fi-gem-brand-title {
    color: #0f172a;
}

.dark .fi-gem-brand-title {
    color: #f8fafc !important;
}

.fi-gem-brand-sub {
    color: #64748b;
}

.dark .fi-gem-brand-sub {
    color: #94a3b8 !important;
}

/* ==========================================================================
   Luxury Authentication & Login Portal Theme (Dual-Mode)
   ========================================================================== */
.fi-simple-layout {
    background-color: #f8fafc !important;
    background-image: 
        radial-gradient(at 0% 0%, rgba(16, 185, 129, 0.12) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(56, 189, 248, 0.10) 0px, transparent 50%),
        radial-gradient(at 50% 100%, rgba(139, 92, 246, 0.06) 0px, transparent 60%) !important;
    background-attachment: fixed !important;
    min-height: 100vh;
}

.dark .fi-simple-layout {
    background-color: #060911 !important;
    background-image: 
        radial-gradient(at 0% 0%, rgba(16, 185, 129, 0.22) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(56, 189, 248, 0.18) 0px, transparent 50%),
        radial-gradient(at 50% 100%, rgba(139, 92, 246, 0.14) 0px, transparent 60%) !important;
}

.fi-simple-page {
    background: #ffffff !important;
    border: 1px solid rgba(226, 232, 240, 0.95) !important;
    border-radius: 20px !important;
    box-shadow: 0 20px 50px -12px rgba(15, 23, 42, 0.1), 0 8px 16px -6px rgba(15, 23, 42, 0.05) !important;
    padding: 2.5rem 2rem !important;
}

.dark .fi-simple-page {
    background: rgba(15, 23, 42, 0.85) !important;
    backdrop-filter: blur(24px) saturate(190%) !important;
    -webkit-backdrop-filter: blur(24px) saturate(190%) !important;
    border: 1px solid rgba(255, 255, 255, 0.14) !important;
    box-shadow: 0 30px 65px -15px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

.fi-simple-header {
    margin-bottom: 1.5rem !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
}

.fi-simple-header-heading {
    font-size: 1.5rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.02em !important;
    margin-top: 0.5rem !important;
}

/* ==========================================================================
   Modals & Notifications Aero Glass Polish
   ========================================================================== */
.fi-modal-window {
    backdrop-filter: blur(24px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(24px) saturate(180%) !important;
    box-shadow: 0 30px 70px -15px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

.fi-no-notification {
    background: var(--aero-glass-bg) !important;
    backdrop-filter: blur(20px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
    border: 1px solid var(--aero-glass-border) !important;
    border-radius: 14px !important;
    box-shadow: 0 16px 36px -8px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.3) !important;
}


