/* ==================== BABY NAME GENERATOR STYLES ==================== */

/* Hero Section */
.bn-hero-section {
    padding: 60px 0;
    background-color: #ffffff;
}

.bn-hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.bn-hero-image-wrapper {
    position: relative;
}

.bn-hero-image {
    width: 100%;
    height: auto;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(255, 182, 193, 0.2);
}

.bn-hero-content {
    padding: 20px;
}

.bn-hero-content h1 {
    font-size: 36px;
    color: #2e3482;
    margin-bottom: 20px;
    font-weight: 700;
}

.bn-hero-content p {
    font-size: 18px;
    color: #53589a;
    line-height: 1.8;
}

/* Main Section */
.bn-main-section {
    padding: 60px 0;
}

.bn-grid {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 40px;
}

/* Sidebar Filters */
.bn-sidebar {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(46, 52, 130, 0.08);
    height: fit-content;
    position: sticky;
    top: 100px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.bn-sidebar::-webkit-scrollbar {
    width: 2px;
    display: none;
}

.bn-sidebar::-webkit-scrollbar-track {
    background: #fae7f0;
    border-radius: 10px;
}

.bn-sidebar::-webkit-scrollbar-thumb {
    background: #FFB6C1;
    border-radius: 10px;
}

.bn-sidebar::-webkit-scrollbar-thumb:hover {
    background: #ff9eb0;
}

.bn-filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 2px solid #fae7f0;
}

.bn-filter-header h3 {
    font-size: 20px;
    color: #ff9eb0;
    font-weight: 700;
}

.bn-clear-all-btn {
    background: none;
    border: none;
    color: #2e3482;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: color 0.3s ease;
}

.bn-clear-all-btn:hover {
    color: rgb(17, 21, 80);
    text-decoration: underline;
}

.bn-filter-section {
    margin-bottom: 20px;
    border-bottom: 1px solid #f0f0f0;
}

.bn-filter-section:last-child {
    border-bottom: none;
}

.bn-filter-toggle {
    width: 100%;
    padding: 15px 0;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-size: 16px;
    color: #2e3482;
    font-weight: 600;
    transition: all 0.3s ease;
}

.bn-filter-toggle i {
    font-size: 20px;
    color: #FFB6C1;
    transition: transform 0.3s ease;
}

.bn-filter-toggle.active i {
    transform: rotate(180deg);
}

.bn-filter-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
    padding: 0;
}

.bn-filter-toggle.active + .bn-filter-content {
    max-height: 500px;
    padding: 15px 0 20px 0;
}

/* Display Options */
.bn-display-options {
    display: flex;
    gap: 10px;
}

.bn-display-btn,
.bn-display-btn-mobile {
    flex: 1;
    padding: 10px 15px;
    background: #fae7f0;
    border: 2px solid #fae7f0;
    border-radius: 8px;
    font-size: 14px;
    color: #2e3482;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.bn-display-btn:hover,
.bn-display-btn-mobile:hover {
    background: #fff5f8;
    border-color: #FFB6C1;
}

.bn-display-btn.active,
.bn-display-btn-mobile.active {
    background: #2e3482;
    border-color: #2e3482;
    color: #fff;
}

/* Gender Options */
.bn-gender-options {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.bn-gender-btn,
.bn-gender-btn-mobile {
    flex: 1;
    padding: 10px 15px;
    background: #fae7f0;
    border: 2px solid #fae7f0;
    border-radius: 8px;
    font-size: 14px;
    color: #2e3482;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 80px;
}

.bn-gender-btn:hover,
.bn-gender-btn-mobile:hover {
    background: #fff5f8;
    border-color: #FFB6C1;
}

.bn-gender-btn.active,
.bn-gender-btn-mobile.active {
    background: #FFB6C1;
    border-color: #FFB6C1;
    color: #fff;
}

/* Origin Options */
.bn-origin-options {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 15px;
}

.bn-origin-btn,
.bn-origin-btn-mobile {
    padding: 8px 16px;
    background: #fae7f0;
    border: 2px solid #fae7f0;
    border-radius: 20px;
    font-size: 13px;
    color: #2e3482;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.bn-origin-btn:hover,
.bn-origin-btn-mobile:hover {
    background: #fff5f8;
    border-color: #FFB6C1;
}

.bn-origin-btn.active,
.bn-origin-btn-mobile.active {
    background: #FFB6C1;
    border-color: #FFB6C1;
    color: #fff;
}

/* Length Options */
.bn-length-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 15px;
}

.bn-length-btn,
.bn-length-btn-mobile {
    padding: 10px 15px;
    background: #fae7f0;
    border: 2px solid #fae7f0;
    border-radius: 8px;
    font-size: 13px;
    color: #2e3482;
    font-weight: 500;
    cursor: pointer;
    text-align: center;
    transition: all 0.3s ease;
}

.bn-length-btn:hover,
.bn-length-btn-mobile:hover {
    background: #fff5f8;
    border-color: #FFB6C1;
}

.bn-length-btn.active,
.bn-length-btn-mobile.active {
    background: #FFB6C1;
    border-color: #FFB6C1;
    color: #fff;
}

/* Letter Grid */
.bn-letter-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    margin-bottom: 15px;
}

.bn-letter-btn,
.bn-letter-btn-mobile {
    width: 36px;
    height: 36px;
    background: #fae7f0;
    border: 2px solid #fae7f0;
    border-radius: 8px;
    font-size: 14px;
    color: #2e3482;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bn-letter-btn:hover,
.bn-letter-btn-mobile:hover {
    background: #fff5f8;
    border-color: #FFB6C1;
    transform: scale(1.1);
}

.bn-letter-btn.active,
.bn-letter-btn-mobile.active {
    background: #FFB6C1;
    border-color: #FFB6C1;
    color: #fff;
}

/* Clear Filter Button */
.bn-clear-filter-btn {
    width: 100%;
    padding: 8px;
    background: none;
    border: none;
    color: #2e3482;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    transition: all 0.3s ease;
}

.bn-clear-filter-btn:hover {
    color: rgb(17, 21, 80);
    text-decoration: underline;
}

/* Results Area */
.bn-results {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(46, 52, 130, 0.08);
}

.bn-results-header {
    margin-bottom: 30px;
}

/* NEW: Top row for results count and filter button */
.bn-results-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.bn-results-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bn-results-count {
    font-size: 20px;
    font-weight: 700;
    color: #2e3482;
}

.bn-results-text {
    font-size: 16px;
    color: #53589a;
}

/* Mobile Filter Button */
.bn-mobile-filter-btn {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background-color: #2e3482;
    color: #fff;
    border: none;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
}

.bn-mobile-filter-btn:hover {
    background-color: #FFB6C1;
    transform: translateY(-2px);
}

.bn-mobile-filter-btn i {
    font-size: 18px;
}

.bn-search-sort-controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.bn-search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.bn-search-box > i {
    position: absolute;
    left: 15px;
    font-size: 20px;
    color: #53589a;
    pointer-events: none;
}

#bnNameSearch {
    flex: 1;
    padding: 12px 20px 12px 45px;
    border: 2px solid #fae7f0;
    border-radius: 10px;
    font-size: 15px;
    color: #2e3482;
    background: #fae7f0;
    transition: all 0.3s ease;
}

#bnNameSearch:focus {
    outline: none;
    border-color: #FFB6C1;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(255, 182, 193, 0.1);
}

.bn-sort-options {
    display: flex;
    align-items: center;
    gap: 15px;
}

.bn-sort-label {
    font-size: 15px;
    color: #53589a;
    font-weight: 500;
}

.bn-sort-btn {
    padding: 10px 24px;
    background: #fae7f0;
    border: 2px solid #fae7f0;
    border-radius: 25px;
    font-size: 14px;
    color: #2e3482;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.bn-sort-btn:hover {
    background: #fff5f8;
    border-color: #FFB6C1;
}

.bn-sort-btn.active {
    background: #2e3482;
    border-color: #2e3482;
    color: #fff;
}

/* Names Table */
.bn-names-table-wrapper {
    overflow-x: auto;
    margin-bottom: 30px;
}

.bn-names-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.bn-names-table thead {
    background:#53589a;
}

.bn-names-table thead tr th {
    padding: 15px 20px;
    color: #fff;
    font-weight: 600;
    font-size: 14px;
    text-align: center;
}

.bn-names-table thead tr th:first-child {
    border-top-left-radius: 12px;
}

.bn-names-table thead tr th:last-child {
    border-top-right-radius: 12px;
}

.bn-fav-col {
    width: 80px;
}

.bn-gender-col {
    width: 100px;
}

.bn-name-col {
    width: auto;
}

.bn-names-table tbody tr {
    transition: all 0.3s ease;
    text-align: center;
}

.bn-names-table tbody tr:nth-child(even) {
    background: #f3f4ff;
}

.bn-names-table tbody tr:nth-child(odd) {
    background: #fff;
}

.bn-names-table tbody tr td {
    padding: 15px 20px;
    color: #2e3482;
    font-size: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.bn-fav-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 22px;
    color: #2e3482;
    transition: all 0.3s ease;
}

.bn-fav-btn:hover,
.bn-fav-btn.active {
    color: #2e3482;
    transform: scale(1.2);
}

.bn-names-table tbody tr:hover .bn-fav-btn.active {
    color: #2e3482;
}

.bn-gender-icon {
    font-size: 20px;
}

.bn-gender-icon.male {
    color: #FFB6C1;
}

.bn-gender-icon.female {
    color: #FFB6C1;
}

.bn-gender-icon.unisex {
    color: #2e3482;
}

/* Pagination */
.bn-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    padding: 20px 0;
}

.bn-pagination-btn {
    padding: 10px 16px;
    background: #fae7f0;
    border: 2px solid #fae7f0;
    border-radius: 8px;
    font-size: 14px;
    color: #2e3482;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bn-pagination-btn:hover:not(:disabled) {
    border-color: #2e3482;
    transform: translateY(-2px);
}

.bn-pagination-btn.active {
    background: #2e3482;
    border-color: #2e3482;
    color: #fff;
}

.bn-pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.bn-pagination-btn i {
    font-size: 18px;
}

.bn-pagination-ellipsis {
    padding: 10px;
    color: #53589a;
    font-weight: 600;
}

/* Mobile Filter Bottom Sheet */
.bn-filter-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.bn-filter-overlay.active {
    display: block;
    opacity: 1;
}

.bn-filter-bottom-sheet {
    display: none;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #fff;
    border-radius: 20px 20px 0 0;
    z-index: 9999;
    max-height: 85vh;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
}

.bn-filter-bottom-sheet.active {
    display: block;
    transform: translateY(0);
}

.bn-bottom-sheet-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 2px solid #f0f0f0;
    position: sticky;
    top: 0;
    background-color: #fff;
    border-radius: 20px 20px 0 0;
    z-index: 1;
}

.bn-bottom-sheet-header h3 {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: #2e3482;
}

.bn-close-bottom-sheet {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    background-color: #fae7f0;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 24px;
    color: #2e3482;
    font-weight: 300;
}

.bn-close-bottom-sheet:hover {
    background-color: #FFB6C1;
    color: #fff;
}

.bn-bottom-sheet-content {
    padding: 20px 25px;
    max-height: calc(85vh - 140px);
    overflow-y: auto;
}

.bn-bottom-sheet-actions {
    padding: 20px 25px;
    border-top: 2px solid #f0f0f0;
    display: flex;
    gap: 15px;
    position: sticky;
    bottom: 0;
    background-color: #fff;
}

.bn-btn-clear-all,
.bn-btn-apply {
    flex: 1;
    padding: 14px 24px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-family: 'Poppins', sans-serif;
}

.bn-btn-clear-all {
    background-color: #f0f0f0;
    color: #2e3482;
}

.bn-btn-clear-all:hover {
    background-color: #e0e0e0;
}

.bn-btn-apply {
    background-color: #2e3482;
    color: #fff;
}

.bn-btn-apply:hover {
    background-color: #FFB6C1;
    transform: translateY(-2px);
}

/* Inspiration Section */
.bn-inspiration-section {
    padding: 60px 0;
    background: linear-gradient(135deg, #fae7f0 0%, #fff5f8 100%);
}

.bn-inspiration-content {
    max-width: 900px;
    margin: 0 auto;
}

.bn-inspiration-content h2 {
    font-size: 32px;
    color: #2e3482;
    margin-bottom: 30px;
    font-weight: 700;
    text-align: center;
}

/* Accordion Styles */
.bn-info-accordion {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.bn-accordion-item {
    border: 1px solid #f0f0f0;
    border-radius: 20px;
    background-color: #fff;
    overflow: hidden;
    transition: all 0.3s ease;
}

.bn-accordion-item:hover {
    border-color: #FFB6C1;
    box-shadow: 0 4px 12px rgba(255, 182, 193, 0.15);
}

.bn-accordion-header {
    width: 100%;
    padding: 20px 24px;
    background: none;
    color: #2e3482;
    border: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    font-weight: 600;
    font-size: 1rem;
}

.bn-accordion-header span {
    flex: 1;
}

.bn-accordion-toggle {
    font-size: 1.5rem;
    color: #2e3482;
    transition: transform 0.4s ease, color 0.3s ease;
    flex-shrink: 0;
    margin-left: 16px;
}

.bn-accordion-item.active .bn-accordion-header {
    color: #2e3482;
}

.bn-accordion-item.active .bn-accordion-toggle {
    transform: rotate(45deg);
    color: #FFB6C1;
}

.bn-accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
    padding: 0 24px;
}

.bn-accordion-item.active .bn-accordion-content {
    padding-top: 20px;
    margin-bottom: 30px;
}

.bn-accordion-content-inner {
    padding: 0;
}

.bn-accordion-content-inner p {
    font-size: 16px;
    color: #53589a;
    line-height: 1.8;
    margin-bottom: 15px;
}

/* Animation Classes */
.bn-fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.bn-fade-in.active {
    opacity: 1;
    transform: translateY(0);
}

.bn-slide-in-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.bn-slide-in-left.active {
    opacity: 1;
    transform: translateX(0);
}

.bn-slide-in-right {
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.bn-slide-in-right.active {
    opacity: 1;
    transform: translateX(0);
}

/* Responsive Design */
@media screen and (max-width: 1024px) {
    .bn-grid {
        grid-template-columns: 300px 1fr;
        gap: 30px;
    }

    .bn-letter-grid {
        grid-template-columns: repeat(9, 1fr);
        gap: 8px;
    }

    .bn-length-options {
        grid-template-columns: repeat(3, 1fr);
    }

    .bn-sidebar {
        padding: 25px;
    }
    
    .bn-hero-content h1 {
        font-size: 32px;
    }
    
    /* Show mobile filter button on tablet */
    .bn-mobile-filter-btn {
        display: flex;
    }
    
    /* Results count and filter button remain in same row */
    .bn-results-top-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
}

@media screen and (max-width: 768px) {
    .bn-hero-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .bn-hero-content h1 {
        font-size: 28px;
    }
    
    .bn-hero-content p {
        font-size: 16px;
    }
    
    .bn-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    /* Hide desktop sidebar on mobile */
    .bn-desktop-sidebar {
        display: none;
    }
    
    /* Show mobile filter button */
    .bn-mobile-filter-btn {
        display: flex;
    }
    
    /* Results count and filter button in same row for mobile */
    .bn-results-top-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 15px;
        margin-bottom: 30px;
    }
    
    .bn-results {
        padding: 20px;
    }
    
    .bn-search-sort-controls {
        gap: 20px;
    }
    
    .bn-sort-options {
        flex-wrap: wrap;
    }
    
    .bn-inspiration-content h2 {
        font-size: 26px;
    }
    
    .bn-accordion-header {
        padding: 16px 20px;
        font-size: 0.95rem;
    }
    
    .bn-accordion-toggle {
        font-size: 1.25rem;
        margin-left: 12px;
    }
    
    .bn-accordion-content {
        padding: 0 20px;
    }
    
    .bn-pagination {
        flex-wrap: wrap;
    }
    
    .bn-pagination-btn {
        min-width: 40px;
        padding: 8px 12px;
    }
}

@media screen and (max-width: 480px) {
    .bn-hero-section,
    .bn-main-section,
    .bn-inspiration-section {
        padding: 40px 0;
    }
    
    .bn-hero-content h1 {
        font-size: 24px;
    }
    
    .bn-hero-content p {
        font-size: 15px;
    }
    
    .bn-results {
        padding: 15px;
    }
    
    .bn-results-count {
        font-size: 18px;
    }
    
    .bn-results-text {
        font-size: 14px;
    }
    
    /* Keep results count and filter button in same row even on small mobile */
    .bn-results-top-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 10px;
        margin-bottom: 25px;
    }
    
    /* Make filter button more compact on small mobile */
    .bn-mobile-filter-btn {
        padding: 10px 20px;
        font-size: 14px;
        white-space: nowrap;
    }
    
    .bn-mobile-filter-btn i {
        font-size: 16px;
    }
    
    #bnNameSearch {
        font-size: 14px;
        padding: 10px 20px 10px 40px;
    }
    
    .bn-sort-label {
        width: 100%;
        font-size: 14px;
    }
    
    .bn-sort-btn {
        padding: 8px 20px;
        font-size: 13px;
    }
    
    .bn-names-table thead tr th {
        padding: 12px 10px;
        font-size: 13px;
    }
    
    .bn-names-table tbody tr td {
        padding: 12px 10px;
        font-size: 14px;
    }
    
    .bn-fav-btn {
        font-size: 18px;
    }
    
    .bn-gender-icon {
        font-size: 18px;
    }
    
    .bn-inspiration-content h2 {
        font-size: 22px;
    }
    
    .bn-accordion-header {
        padding: 14px 16px;
        font-size: 0.9rem;
        gap: 10px;
    }
    
    .bn-accordion-toggle {
        font-size: 1.2rem;
        margin-left: 8px
    }
    
    .bn-accordion-content {
        padding: 0 16px;
    }
    
    .bn-accordion-content-inner p {
        font-size: 15px;
    }
    
    .bn-pagination-btn {
        min-width: 36px;
        padding: 6px 10px;
        font-size: 13px;
    }
    
    /* Mobile bottom sheet adjustments */
    .bn-letter-grid {
        grid-template-columns: repeat(6, 1fr);
    }
    
    .bn-letter-btn,
    .bn-letter-btn-mobile {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }
}