/* All Documents Page Styles */

.subpage-hero {
    min-height: 160px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 30px;
    padding-bottom: 20px;
}

.subpage-hero .img.overlay.dark-overlay::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 4, 40, 0.85) 0%, rgba(0, 78, 146, 0.8) 100%);
    z-index: 1;
}

.subpage-hero .heading {
    font-size: 2rem;
    font-weight: 800;
    color: #ffffff;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    margin-bottom: 20px !important;
}

/* Modern Search Box */
.search-container {
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.search-box {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    padding: 2px 2px 2px 20px;
    /* Ultra-compact */
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.search-box:focus-within {
    background: rgba(255, 255, 255, 1);
    border-color: #f1c40f;
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.search-icon {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.1rem;
    margin-right: 15px;
}

.search-box:focus-within .search-icon {
    color: #0056b3;
}

#doc-search-input {
    background: transparent;
    border: none !important;
    color: #ffffff;
    font-size: 0.9rem;
    width: 100%;
    outline: none !important;
    padding: 6px 0;
    /* Ultra-compact */
    box-shadow: none !important;
    line-height: 1;
}

.search-box:focus-within #doc-search-input {
    color: #000428;
}

#doc-search-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.search-box:focus-within #doc-search-input::placeholder {
    color: #999;
}

.btn-search {
    background: #f1c40f;
    color: #000428;
    border: none;
    padding: 6px 20px;
    /* Ultra-compact */
    border-radius: 50px;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    cursor: pointer;
    white-space: nowrap;
}

.btn-search:hover {
    background: #ffffff;
    color: #0056b3;
    transform: scale(1.05);
}

.subpage-hero nav[aria-label="breadcrumb"] {
    margin-top: 15px;
    position: relative;
    z-index: 2;
}

/* Autocomplete Dropdown */
.search-results-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    max-height: 400px;
    overflow-y: auto;
    padding: 15px;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.search-results-dropdown .dropdown-item {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #00204a;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.2s ease;
    font-weight: 500;
    text-align: left;
}

.search-results-dropdown .dropdown-item:hover {
    background: #f0f7ff;
    color: #0056b3;
    transform: translateX(5px);
}

.search-results-dropdown .dropdown-item i {
    color: #0056b3;
    font-size: 1.1rem;
    width: 25px;
}

/* Custom Scrollbar for Dropdown */
.search-results-dropdown::-webkit-scrollbar {
    width: 8px;
}

.search-results-dropdown::-webkit-scrollbar-track {
    background: transparent;
}

.search-results-dropdown::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

.search-results-dropdown::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.2);
}

.custom-breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
}

.custom-breadcrumb .breadcrumb-item {
    font-size: 1.1rem;
    font-weight: 500;
}

.custom-breadcrumb .breadcrumb-item a {
    color: rgba(255, 255, 255, 0.8) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.custom-breadcrumb .breadcrumb-item a:hover {
    color: #f1c40f !important;
    /* Accent gold from theme */
}

.custom-breadcrumb .breadcrumb-item.active {
    color: #ffffff !important;
}

.custom-breadcrumb .breadcrumb-item+.breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.5);
    content: "/";
}


.browse-docs-section {
    padding: 40px 0;
    background-color: #f8f9fa;
}

.category-group {
    background: #ffffff;
    padding: 50px;
    border-radius: 20px;
    box-shadow: 0 15px 45px rgba(0, 32, 74, 0.05);
    /* Soft navy shadow */
    border: 1px solid rgba(0, 32, 74, 0.05);
    margin-bottom: 60px;
    transition: transform 0.3s ease;
}

.category-header {
    border-bottom: 1px solid #f0f4f8;
    padding-bottom: 20px;
    margin-bottom: 35px !important;
}

.category-title {
    font-size: 2.2rem;
    font-weight: 800;
    color: #00204a;
    letter-spacing: -0.5px;
}

.category-count {
    background-color: #f0f7ff;
    color: #0056b3;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 8px 16px;
    border: 1px solid rgba(0, 86, 179, 0.1);
}

.doc-card-link {
    text-decoration: none !important;
    display: block;
    height: 100%;
}

.doc-card {
    background: #ffffff;
    border: 1px solid #edf2f7;
    border-radius: 16px;
    padding: 30px 20px;
    height: 100%;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.doc-card::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #0056b3, #00204a);
    transform: scaleX(0);
    transition: transform 0.4s ease;
    transform-origin: left;
}

.doc-card:hover {
    transform: translateY(-8px);
    border-color: transparent;
    box-shadow: 0 20px 40px rgba(0, 32, 74, 0.1);
}

.doc-card:hover::after {
    transform: scaleX(1);
}

.doc-card-icon {
    width: 70px;
    height: 70px;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    border-radius: 20px;
    color: #0056b3;
    font-size: 1.8rem;
    transition: all 0.3s ease;
    box-shadow: inset 0 0 0 1px rgba(0, 86, 179, 0.05);
}

.doc-card:hover .doc-card-icon {
    background: #0056b3;
    color: #ffffff;
    transform: rotate(-5deg) scale(1.1);
}

.doc-card-icon img {
    max-width: 40px;
    height: auto;
}

.doc-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 15px;
    line-height: 1.4;
}

.doc-excerpt {
    font-size: 0.95rem;
    color: #4a5568;
    margin-bottom: 25px;
    line-height: 1.6;
}

.doc-action {
    margin-top: auto;
    font-size: 0.9rem;
    font-weight: 700;
    color: #0056b3;
    display: inline-flex;
    align-items: center;
    transition: all 0.3s ease;
    padding: 8px 16px;
    background: #f0f7ff;
    border-radius: 50px;
}

.doc-card:hover .doc-action {
    background: #0056b3;
    color: #ffffff;
}

/* Sticky Category Sidebar */
.docs-sidebar-wrapper {
    position: sticky;
    top: 100px;
    z-index: 10;
}

.docs-sidebar {
    background: #ffffff;
    border: 1px solid #edf2f7;
    border-radius: 20px;
    padding: 30px 20px;
    box-shadow: 0 10px 30px rgba(0, 32, 74, 0.05);
}

.sidebar-title {
    font-size: 1.1rem;
    font-weight: 800;
    color: #00204a;
    margin-bottom: 25px;
    padding-left: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.category-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-nav li {
    margin-bottom: 8px;
}

.nav-link-cat {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: #4a5568;
    text-decoration: none !important;
    border-radius: 12px;
    transition: all 0.3s ease;
    font-weight: 500;
    font-size: 0.95rem;
}

.nav-link-cat:hover {
    background: #f8fafc;
    color: #0056b3;
    transform: translateX(5px);
}

.nav-link-cat.active {
    background: #eef7ff;
    color: #0056b3;
    font-weight: 700;
}

.nav-link-cat .dot {
    width: 6px;
    height: 6px;
    background: #cbd5e0;
    border-radius: 50%;
    margin-right: 12px;
    transition: all 0.3s ease;
}

.nav-link-cat.active .dot,
.nav-link-cat:hover .dot {
    background: #0056b3;
    box-shadow: 0 0 10px rgba(0, 86, 179, 0.5);
    transform: scale(1.5);
}

.nav-link-cat .name {
    flex: 1;
}

.nav-link-cat .count {
    font-size: 0.75rem;
    background: #f1f5f9;
    padding: 2px 8px;
    border-radius: 10px;
    color: #718096;
    margin-left: 10px;
}

.nav-link-cat.active .count {
    background: #0056b3;
    color: #ffffff;
}

/* Page Layout Tweaks */
.docs-content-area {
    padding-left: 20px;
}

/* Responsive Adjustments */
@media (max-width: 991.98px) {
    .docs-sidebar-wrapper {
        position: static;
        margin-bottom: 30px;
    }

    .docs-content-area {
        padding-left: 0;
    }

    .category-nav {
        display: flex;
        overflow-x: auto;
        padding-bottom: 15px;
        -webkit-overflow-scrolling: touch;
    }

    .category-nav li {
        margin-bottom: 0;
        margin-right: 10px;
        flex: 0 0 auto;
    }

    .nav-link-cat {
        white-space: nowrap;
        background: #ffffff;
        border: 1px solid #edf2f7;
    }

    .browse-docs-section {
        padding: 50px 0;
    }

    .category-group {
        padding: 25px;
    }

    .category-title {
        font-size: 1.5rem;
    }
}