/* Haver - Custom Styles */

:root {
    --haver-primary: #0d6efd;
    --haver-secondary: #6c757d;
}

/* Sidebar */
.sidebar {
    position: fixed;
    top: 56px;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 48px 0 0;
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
    background-color: #fff;
    width: 100%;
}

@media (min-width: 768px) {
    .sidebar {
        width: auto;
    }
}

@media (max-width: 767.98px) {
    .sidebar {
        position: fixed;
        top: 56px;
        left: 0;
        right: 0;
        bottom: auto;
        max-height: calc(100vh - 56px);
        overflow-y: auto;
        padding-top: 1rem;
    }
    
    .sidebar.collapse:not(.show) {
        display: none;
    }
    
    .sidebar.collapsing {
        height: auto;
        transition: none;
    }
}

.sidebar .nav-link {
    font-weight: 500;
    color: #333;
    padding: 0.75rem 1rem;
}

.sidebar .nav-link:hover {
    color: var(--haver-primary);
    background-color: rgba(13, 110, 253, 0.1);
}

.sidebar .nav-link.active {
    color: var(--haver-primary);
    background-color: rgba(13, 110, 253, 0.1);
}

.sidebar .nav-link i {
    margin-right: 0.5rem;
    width: 20px;
    text-align: center;
}

/* Cards */
.card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: box-shadow 0.15s ease-in-out;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
}

/* Forms */
.form-control:focus,
.form-select:focus {
    border-color: var(--haver-primary);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Shopping List Items */
.list-group-item {
    transition: background-color 0.15s ease-in-out;
}

.list-group-item:hover {
    background-color: #f8f9fa;
}

/* HTMX loading indicator */
.htmx-indicator {
    display: none;
}

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

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

/* Responsive adjustments */
@media (max-width: 768px) {
    .navbar-brand {
        font-size: 1.1rem;
    }
    
    main {
        padding-top: 1rem !important;
    }
}

/* Dark mode (future) */
@media (prefers-color-scheme: dark) {
    /* TODO: Implement dark mode styles */
}
