/* Custom Styles for Quantify */

/* Google Fonts - Source Code Pro */
@import url('https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@300;400;500;600;700&display=swap');

/* Introl Brand Colors & Theme Variables */
:root {
    /* Brand colors */
    --elite-green: #008B00;
    --tactical-black: #080808;
    --nightvision-green: #00F200;
    --seafoam-green: #D8E3D9;
    --white: #FFFFFF;
    --light: #F0F0F0;
    --card-border-radius: 16px; /* Global card border radius */
    
    /* Light theme variables (default) */
    --body-bg: rgba(216, 227, 217, 0.25);
    --card-bg: var(--white);
    --card-border: rgba(0, 0, 0, 0.125);
    --card-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    --text-color: var(--tactical-black);
    --text-muted: rgba(8, 8, 8, 0.7);
    --sidebar-bg: var(--white);
    --sidebar-border: rgba(0, 0, 0, 0.1);
    --nav-item-hover: rgba(0, 0, 0, 0.05);
    --nav-item-active-bg: rgba(0, 139, 0, 0.1);
    --nav-item-active-color: var(--elite-green);
    --btn-primary-bg: var(--elite-green);
    --btn-primary-hover: #00A000;
    --input-bg: var(--white);
    --input-border: #ced4da;
    --input-focus-border: var(--elite-green);
    --table-border: #dee2e6;
    --table-stripe: rgba(0, 0, 0, 0.02);
    --hover-bg: rgba(0, 0, 0, 0.03);
}

/* Typography - ensuring consistent font usage */
html {
    font-family: "Source Code Pro", monospace !important;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color);
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background-color: var(--body-bg);
    font-family: "Source Code Pro", monospace !important;
    color: var(--text-color);
}

.wrapper {
    display: flex;
    min-height: 100vh;
}

/* Main container styles */
.container {
    max-width: 1140px;
}

/* Page container - higher specificity for proper spacing */
body .container.page-container,
html body div.container.page-container {
    /* Space between navbar and content */
    padding-top: 3rem;
    padding-bottom: 3rem;
}

/* Force Source Code Pro on all text elements to override Bootstrap */
h1, h2, h3, h4, h5, h6, p, span, div, a, button, input, select, textarea, 
.navbar, .btn, .card, .badge, .alert, .nav-link, pre, code, label, .dropdown-item,
.form-control, .input-group, .list-group-item, .table, .dropdown-menu {
    font-family: "Source Code Pro", monospace !important;
}

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

.text-muted {
    color: var(--text-muted) !important;
}

.fw-bold {
    font-weight: 700 !important;
}

.fw-normal {
    font-weight: 400 !important;
}

.fw-light {
    font-weight: 300 !important;
}

/* Navbar styling */
.navbar {
    display: none;
}

/* Sidebar */
.sidebar {
    width: 280px;
    flex-shrink: 0;
    background-color: var(--sidebar-bg);
    border-right: 1px solid var(--sidebar-border);
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow-y: auto;
    padding: 0;
    transition: all 0.3s ease;
    z-index: 1000;
}

.sidebar.collapsed {
    width: 80px;
    overflow-x: hidden;
}

.sidebar-content {
    flex: 1;
    padding: 1.5rem;
    overflow-x: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Sidebar header with logo and collapse button */
.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--sidebar-border);
    height: 48px;
    position: relative;
    flex-shrink: 0;
}

.logo-container {
    width: 120px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    overflow: hidden;
}

.logo-container svg {
    max-height: 100%;
    width: auto;
}

/* Button styling */
.sidebar-collapse-btn {
    background-color: transparent;
    border: none;
    color: var(--text-color);
    padding: 0.375rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    font-size: 1.2rem;
    width: 36px;
    height: 36px;
    position: absolute;
    right: 0;
    top: 0;
}

.sidebar-collapse-btn:hover {
    background-color: var(--nav-item-hover);
    cursor: pointer;
}

/* Fix positioning in collapsed state */
.sidebar.collapsed .sidebar-header {
    justify-content: flex-end;
}

/* Navigation - taking full height between header and footer */
.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
    flex-grow: 1;
    min-height: 0;
}

/* Fixed positioning for collapsed state */
.sidebar.collapsed .sidebar-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 1.5rem; /* Match expanded state */
    gap: 0.75rem;
    flex-grow: 1;
}

/* Navigation items styling */
.sidebar-nav-item {
    display: flex;
    align-items: center;
    padding: 0.625rem 1rem;
    color: var(--text-color);
    opacity: 0.7;
    text-decoration: none;
    transition: all 0.2s ease;
    border-radius: 16px;
    font-weight: 500;
    white-space: nowrap;
    position: relative;
    width: 100%;
    height: 48px;
    box-sizing: border-box;
}

.sidebar-nav-item:hover {
    background-color: var(--nav-item-hover);
    opacity: 1;
    color: var(--nav-item-active-color);
}

.sidebar-nav-item.active {
    background-color: var(--nav-item-active-bg);
    color: var(--nav-item-active-color);
    opacity: 1;
    font-weight: 600;
}

.sidebar-nav-item i {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
    width: 24px;
    text-align: center;
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
}

.sidebar-nav-item span {
    margin-left: 36px; /* Width of icon (24px) + left space (12px) */
}

/* Tooltip styling */
.tooltip {
    position: fixed;
    z-index: 1070;
}

.tooltip .tooltip-inner {
    background-color: var(--tactical-black);
    color: var(--white);
    font-family: "Source Code Pro", monospace;
    padding: 0.375rem 0.75rem;
    border-radius: 16px;
    font-size: 0.875rem;
}

.tooltip .tooltip-arrow::before {
    border-right-color: var(--tactical-black);
}

/* Collapsed state - only change opacity and visibility of text */
.sidebar.collapsed .sidebar-nav-item span {
    opacity: 0;
    visibility: hidden;
}

/* Ensure icons stay in the exact same position */
.sidebar.collapsed .sidebar-nav-item {
    width: 48px;
    padding: 0;
    justify-content: center;
}

.sidebar.collapsed .sidebar-nav-item i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
}

/* Hide logo in collapsed state but keep space */
.sidebar.collapsed .logo-container {
    opacity: 0;
    width: 0;
    visibility: hidden;
}

/* Add specific postiioning for collapsed state button */
.sidebar.collapsed .sidebar-collapse-btn {
    position: absolute;
    right: calc(50% - 18px); /* Center the button */
    top: 0;
}

.sidebar-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    margin-top: auto;
}

.user-profile {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 0.5rem 0;
    color: var(--tactical-black);
    position: relative;
    text-decoration: none;
}

.user-profile:hover {
    color: var(--tactical-black);
    opacity: 0.8;
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: transparent;
    color: var(--tactical-black);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.8rem;
    margin-right: 0.75rem;
    flex-shrink: 0;
    position: relative;
    z-index: 2;
    border: none;
    overflow: hidden;
}

/* Avatar styling for both default and profile image */
.default-avatar {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* When profile image is visible, hide default icon with CSS */
[data-auth="user-avatar"][style*="display: block"] ~ .default-avatar,
[data-auth="user-avatar"][style*="display: block"] + .default-avatar {
    opacity: 0 !important;
    visibility: hidden !important;
}

.user-info {
    display: flex;
    flex-direction: column;
    transition: opacity 0.3s ease, width 0.3s ease, visibility 0.3s ease;
    overflow: hidden;
}

.user-name {
    font-weight: 600;
    font-size: 0.9rem;
    line-height: 1.2;
    white-space: nowrap;
}

.user-email {
    font-size: 0.75rem;
    color: var(--tactical-black);
    opacity: 0.7;
}

/* Main Content */
.main-content {
    flex: 1;
    padding: 2rem;
    overflow-x: hidden;
    transition: margin-left 0.3s ease, width 0.3s ease;
}

/* Main content with sidebar */
.main-content.with-sidebar {
    margin-left: 280px; /* Same as sidebar width */
    width: calc(100% - 280px); /* Ensure proper width */
}

/* Main content without sidebar (full-width) */
.main-content.no-sidebar {
    margin-left: 0;
    width: 100%;
    max-width: 100%;
}

/* Adjust main content when sidebar is collapsed */
.sidebar.collapsed + .main-content.with-sidebar {
    margin-left: 80px;
    width: calc(100% - 80px); /* Ensure proper width when collapsed */
}

/* Button styles - Elite Green */
.btn-primary {
    color: var(--white);
    background-color: var(--btn-primary-bg);
    border-color: var(--btn-primary-bg);
}

.btn-outline-primary {
    color: var(--btn-primary-bg);
    border-color: var(--btn-primary-bg);
}

.btn-outline-primary:hover {
    background-color: var(--btn-primary-bg);
    color: var(--white);
}

.btn-outline-light {
    border-color: var(--tactical-black) !important;
    color: var(--tactical-black) !important;
}

.btn-outline-light:hover {
    background-color: var(--tactical-black) !important;
    color: var(--white) !important;
}

/* Card styling */
.card {
    border-radius: var(--card-border-radius);
    border: 0 !important; /* Remove border in light mode */
    background-color: var(--card-bg);
    box-shadow: var(--card-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.card-text {
    color: var(--text-color);
}

/* Card header with solid white background */
.card-header,
.card .card-header,
.card > .card-header,
div.card-header,
.quote-card .card .card-header {
    background-color: #ffffff !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.125);
    padding: 1.5rem 1.5rem 1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}

.card-header .card-title {
    font-size: 1.1rem;
    line-height: 1.3;
    font-weight: 600;
    word-break: break-word;
}

/* Client name styling */
.card-header .card-title.client-name {
    font-size: 2rem;
    line-height: 1.2;
    font-weight: 700;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Responsive client name using breakpoints */
@media (max-width: 1400px) {
    .card-header .card-title.client-name {
        font-size: 1.75rem;
    }
}

@media (max-width: 1200px) {
    .card-header .card-title.client-name {
        font-size: 1.5rem;
    }
}

@media (max-width: 992px) {
    .card-header .card-title.client-name {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .card-header .card-title.client-name {
        font-size: 1.25rem;
    }
}

@media (max-width: 576px) {
    .card-header .card-title.client-name {
        font-size: 1.15rem;
    }
}

.card-header .dropdown .btn {
    width: 32px;
    height: 32px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-body {
    padding: 1.5rem;
}

/* Card footer with solid white background */
.card-footer,
.card .card-footer,
.card > .card-footer,
div.card-footer,
.quote-card .card .card-footer {
    background-color: #ffffff !important;
    border-top: 1px solid rgba(0, 0, 0, 0.125);
    padding: 1rem 1.5rem;
    border-bottom-left-radius: var(--card-border-radius) !important;
    border-bottom-right-radius: var(--card-border-radius) !important;
}

.quote-details {
    margin-top: 0.75rem;
    font-size: 0.9rem;
    color: var(--tactical-black);
    opacity: 0.8;
}

.quote-amount {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--elite-green);
}

.quote-meta {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    font-size: 0.85rem;
}

.quote-date {
    font-weight: 500;
}

/* Button hover effects */
.btn {
    transition: all 0.2s;
    font-weight: 500;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Form elements */
.form-control {
    color: var(--text-color);
    background-color: var(--input-bg);
    border-color: var(--input-border);
}

.form-control:focus {
    border-color: var(--input-focus-border);
    box-shadow: 0 0 0 0.25rem rgba(0, 139, 0, 0.25);
}

/* Form animation */
form {
    animation: fadeIn 0.5s ease;
}

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

/* Loading spinner customization */
.spinner-border {
    color: var(--elite-green);
}

/* PDF button customization */
.btn-outline-secondary {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border-color: var(--tactical-black);
    color: var(--tactical-black);
}

.btn-outline-secondary:hover {
    background-color: var(--tactical-black);
    color: var(--white);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        width: 280px;
        height: 100%;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 1030;
        border-right: 1px solid rgba(0, 0, 0, 0.1);
    }
    
    .sidebar.collapsed {
        transform: translateX(-100%);
    }
    
    .sidebar.mobile-visible {
        transform: translateX(0);
        box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    }
    
    .sidebar-content {
        padding: 1rem;
    }
    
    .main-content {
        margin-left: 0 !important;
        width: 100% !important;
        padding: 1rem;
    }
    
    /* Larger logo container on mobile */
    .logo-container {
        width: 160px;
        height: 42px;
    }
    
    /* Mobile toggle button for sidebar */
    .mobile-sidebar-toggle {
        position: fixed;
        bottom: 1.5rem;
        right: 1.5rem;
        z-index: 1040;
        width: 48px;
        height: 48px;
        border-radius: 50%;
        background-color: var(--elite-green);
        color: white;
        display: flex;
        align-items: center;
        justify-content: center;
        border: none;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
        transition: all 0.2s ease;
    }
    
    .mobile-sidebar-toggle:hover {
        background-color: var(--tactical-black);
        transform: scale(1.05);
    }
    
    .mobile-sidebar-toggle i {
        font-size: 1.25rem;
    }
    
    /* Overlay when sidebar is open on mobile */
    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 1025;
        display: none;
        opacity: 0;
        transition: opacity 0.3s ease;
    }
    
    .sidebar-overlay.active {
        display: block;
        opacity: 1;
    }
    
    /* User avatar in footer stays visible */
    .sidebar-footer {
        padding: 0.75rem 1rem;
    }
    
    .sidebar-nav-item i {
        font-size: 1.3rem;
    }
}

/* Quote Generator Styles */
#quoteGenerator {
    animation: fadeIn 0.5s ease;
}

.htmx-indicator {
    display: none;
}

.htmx-request .htmx-indicator {
    display: block;
}

.htmx-request.htmx-indicator {
    display: block;
}

#quoteResult {
    animation: fadeIn 0.5s ease;
}

#quoteResult pre {
    white-space: pre-wrap;
    font-size: 0.9rem;
    line-height: 1.6;
}

.list-group-item {
    transition: background-color 0.2s;
    border-color: rgba(8, 8, 8, 0.1);
}

.list-group-item:hover {
    background-color: rgba(216, 227, 217, 0.5);
}

/* Badge styling */
.badge {
    font-weight: 500;
    padding: 0.5em 0.75em;
}

.bg-primary {
    background-color: var(--elite-green) !important;
}

/* Custom background classes */
.bg-light {
    background-color: rgba(216, 227, 217, 0.5) !important; /* Seafoam with 50% opacity */
}

/* Print styles */
@media print {
    body * {
        visibility: hidden;
    }
    
    #quoteResult, #quoteResult * {
        visibility: visible;
    }
    
    #quoteResult {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        box-shadow: none;
    }
    
    .btn {
        display: none;
    }
}

/* Footer styling */
.footer {
    background-color: var(--white);
    border-top: 1px solid rgba(8, 8, 8, 0.1);
    box-shadow: none;
    height: 60px;
    display: flex;
    align-items: center;
}

/* Safari-specific radio button styling */
@supports (-webkit-appearance: none) {
    input[type="radio"] {
        -webkit-appearance: none;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        border: 1px solid rgba(8, 8, 8, 0.3);
        margin-right: 5px;
        position: relative;
        vertical-align: middle;
        outline: none;
    }
    
    input[type="radio"]:checked {
        border-color: var(--elite-green);
        background-color: white;
    }
    
    input[type="radio"]:checked:after {
        content: "";
        position: absolute;
        top: 4px;
        left: 4px;
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: var(--elite-green);
    }
    
    input[type="radio"]:focus {
        box-shadow: 0 0 0 3px rgba(0, 139, 0, 0.25);
    }
}

/* Quote card modern styling */
.card.h-100.shadow-sm {
    border-radius: 16px;
    transition: all 0.2s ease;
    border: 1px solid rgba(0,0,0,0.05);
}

.card.h-100.shadow-sm:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1) !important;
}

.quote-amount.text-primary {
    color: var(--elite-green) !important;
    font-size: 1.6rem;
    margin-bottom: 0.7rem;
}

.quote-specs {
    background-color: rgba(216, 227, 217, 0.2);
    border-radius: 16px;
    padding: 10px;
}

.quote-specs .col {
    margin-bottom: 8px;
}

.quote-specs .badge {
    font-size: 0.75rem;
    padding: 0.35em 0.65em;
}

.quote-specs small {
    font-size: 0.75rem;
    line-height: 1.2;
    color: var(--tactical-black);
    opacity: 0.8;
}

/* Font size utility class */
.fs-7 {
    font-size: 0.85rem !important;
}

/* Add clean hover states to card action buttons */
.card-footer .btn-sm {
    transition: all 0.15s ease;
}

.card-footer .btn-sm:hover {
    transform: translateY(-2px);
}

/* Make the date in footer more subtle */
.quote-meta.small.text-muted {
    opacity: 0.7;
}

/* Component list styling */
.component-list {
    margin-top: 15px;
    margin-bottom: 15px;
    padding-right: 5px;
}

.component-item {
    padding: 2px 0;
    line-height: 1.3;
}

.component-name {
    font-family: "Source Code Pro", monospace !important;
    font-size: 0.85rem;
    line-height: 1.4;
    word-break: break-word;
}

.quote-number {
    font-size: 0.85rem;
    color: var(--tactical-black);
    opacity: 0.7;
}

/* Status pill styling */
.badge.bg-secondary.bg-opacity-10 {
    background-color: rgba(108, 117, 125, 0.1) !important;
    color: #6c757d !important;
    font-size: 0.75rem;
    font-weight: 500;
}

/* Card header styling */
.card-header .card-title {
    font-size: 1.5em; /* Approximately 24px */
    line-height: 1.2;
}

/* Badge styling */
.badge.rounded-pill {
    border-radius: 16px;
    padding: 0.35em 0.9em;
    font-weight: 500;
}

.badge.bg-dark.bg-opacity-10 {
    background-color: rgba(8, 8, 8, 0.1) !important;
    color: var(--tactical-black) !important;
    font-weight: 400;
}

/* Fix for user avatar in collapsed state */
.sidebar.collapsed .sidebar-footer {
    display: flex;
    justify-content: center;
    padding: 1rem 0;
}

.sidebar.collapsed .user-avatar {
    margin-right: 0;
}

.sidebar.collapsed .user-info,
.sidebar.collapsed .user-profile i.bi-chevron-down {
    opacity: 0;
    width: 0;
    visibility: hidden;
}

/* Brand in collapsed state */
.sidebar.collapsed .sidebar-brand svg {
    opacity: 0;
    width: 0;
    margin: 0;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

/* Navigation item styles */
.sidebar-nav-item {
    display: flex;
    align-items: center;
    padding: 0.625rem 1rem;
    color: var(--text-color);
    opacity: 0.7;
    text-decoration: none;
    transition: all 0.2s ease;
    border-radius: 16px;
    font-weight: 500;
    white-space: nowrap;
    position: relative;
    width: 100%;
}

.sidebar-nav-item i {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.75rem;
    font-size: 1.2rem;
    flex-shrink: 0;
    width: 24px;
    text-align: center;
}

/* Adjust the collapsed state navigation */
.sidebar.collapsed .sidebar-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top:1.5rem; /* Distance from top in collapsed state */
}

/* Fix brand hiding in collapsed state */
.sidebar.collapsed .sidebar-brand-container,
.sidebar.collapsed .sidebar-brand {
    display: none;
}

/* Responsive quote cards */
@media (max-width: 767px) {
    .card-header {
        padding: 0.75rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .card-footer {
        padding: 0.75rem;
    }
    
    .component-list {
        margin-top: 10px;
        margin-bottom: 10px;
    }
    
    .price-container {
        font-size: 1.1rem;
    }
    
    .card-title {
        font-size: 1.1rem;
    }
}

/* Bootstrap SM breakpoint utility classes */
@media (max-width: 575px) {
    .w-sm-auto {
        width: auto !important;
    }
    
    .w-100 {
        width: 100% !important;
    }
}

@media (min-width: 576px) {
    .w-sm-auto {
        width: auto !important;
    }
}

/* Add text truncation class for long texts */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Simple authentication styling for server-side auth */
body:not(.authenticated) {
    /* If not authenticated, the middleware will redirect to signin anyway */
}

/* Hide Supabase debug elements */
#storage-debug-modal, 
button.supabase-debug-button,
div[style*="position: fixed"][style*="bottom: 0"][style*="left: 0"],
div[style*="position: fixed"][style*="background-color: rgb(100, 90, 255)"],
div[style*="position: fixed"][style*="border-radius: 4px"],
#supabase-debug-indicator,
[id*="supabase"],
[class*="supabase"],
div[style*="position: fixed"][style*="bottom: 0"][style*="left: 0"][style*="z-index: 999999"],
div[style*="position: fixed"][style*="z-index: 999999"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
}

/* Price container styling */
.price-container {
    font-weight: 600;
    color: var(--tactical-black);
    font-size: clamp(20px, 4vw, 28px);
    margin-right: 0.5rem;
}

/* Responsive styles for mobile */
@media (max-width: 576px) {
    .d-flex.flex-wrap.justify-content-between {
        flex-direction: column;
        align-items: flex-start !important;
    }
    
    .price-container {
        margin-bottom: 0.5rem;
    }
}

/* Delivery badge styling removed as it's no longer needed */

/* Quotes header layout */
.quotes-header {
    position: relative;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

/* Search Input Styling */
.search-container {
    position: relative;
    min-width: 180px;
    width: 240px;
}

#quoteSearch {
    border: 1px solid rgba(8, 8, 8, 0.1);
    border-radius: 16px;
    padding: 0.6rem 1rem 0.6rem 2.5rem;
    transition: all 0.2s ease;
    background-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    width: 100%;
}

#quoteSearch:focus {
    border-color: var(--elite-green);
    box-shadow: 0 0 0 0.25rem rgba(0, 139, 0, 0.15);
    background-color: rgba(255, 255, 255, 0.8);
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--tactical-black);
    opacity: 0.5;
    z-index: 10;
}

/* Responsive search input */
@media (max-width: 992px) {
    .search-container {
        width: 200px;
    }
}

@media (max-width: 768px) {
    .search-container {
        width: 100%;
        max-width: none;
        margin: 0.5rem 0;
        order: 2;
    }
    
    .quotes-header {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 0.5rem;
    }
    
    .quotes-header .ms-auto {
        margin-left: 0 !important;
        margin-top: 0.5rem;
        width: 100%;
    }
}

/* Sign-in link in sidebar */
.sign-in-link {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: var(--sidebar-text-color);
    border-top: 1px solid var(--sidebar-border-color);
    transition: all 0.3s ease;
}

.sign-in-link:hover {
    background-color: var(--sidebar-hover-bg);
    color: var(--elite-green);
}

.sign-in-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background-color: rgba(0, 138, 24, 0.1);
    font-size: 18px;
    margin-right: 12px;
}

.sign-in-icon i {
    color: var(--elite-green);
}

.sign-in-text {
    font-weight: 500;
}

/* Badge styles in user profile */
.user-profile .user-role {
    font-size: 11px;
    margin-top: 3px;
}

.user-profile .badge {
    padding: 3px 6px;
}

.collapsed .sidebar-footer .user-role,
.collapsed .sidebar-footer .sign-in-text {
    display: none;
}

/* Avatar styles */
.user-avatar {
    position: relative;
}

.user-avatar img {
    width: 36px;
    height: 36px;
    object-fit: cover;
}

.user-avatar span {
    position: absolute;
    top: 0;
    left: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--elite-green);
    color: white;
    border-radius: 50%;
    font-weight: bold;
}

/* Default avatar styling */
.default-avatar {
    background-color: #f0f0f0 !important;
    border: none !important;
    color: var(--tactical-black) !important;
}

/* Icon size relative to container size */
.default-avatar .bi-person {
    font-size: 60%; /* Default size */
}

.default-avatar[style*="width: 24px"] .bi-person {
    font-size: 14px; /* Small size for quote list */
}

.default-avatar[style*="width: 40px"] .bi-person {
    font-size: 24px; /* Medium size for sidebar */
}

.default-avatar[style*="width: 120px"] .bi-person {
    font-size: 60px; /* Large size for account page */
}

/* Profile image styling */
[data-auth="user-avatar"] {
    background-color: transparent !important;
    border: none !important; 
    object-fit: cover;
    width: 100% !important;
    height: 100% !important;
    border-radius: 50% !important;
}

/* Table styling */
.table {
    color: var(--text-color);
    border-color: var(--table-border);
}

.table-striped > tbody > tr:nth-of-type(odd) {
    background-color: var(--table-stripe);
}

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

/* Modal style adjustments */
.modal-content {
    background-color: var(--card-bg);
    color: var(--text-color);
    border-color: var(--card-border);
}

.modal-header {
    border-bottom-color: var(--card-border);
}

.modal-footer {
    border-top-color: var(--card-border);
}

/* Make sure quote card headers and footers are white in light mode */
.quote-card .card-header,
.container > .card > .card-header,
.quote-detail .card-header {
    background-color: #ffffff !important;
}

.quote-card .card-footer,
.container > .card > .card-footer,
.quote-detail .card-footer {
    background-color: #ffffff !important;
}

/* Theme toggle positioning */
.theme-toggle-container {
    margin-top: auto !important;
    position: relative;
}

/* Simple marker for signin page - no styles here */
html[data-page="signin"] {
    /* Styles for signin page are contained within the signin.html template */
    /* This prevents theme toggles from affecting the signin page */
} 