/* ======================================
   Finance Helper Menu Sidebar Styles
   ====================================== */

/* Sticky Trigger Button */
.fh-menu-sidebar__trigger {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--color_prime, #1B2754);
    color: #ffffff;
    border: none;
    box-shadow: 0 4px 16px rgba(8, 40, 48, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.fh-menu-sidebar__trigger:hover {
    background: var(--color_secondary, #4DA09D);
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(8, 40, 48, 0.4);
}

.fh-menu-sidebar__trigger:active {
    transform: scale(0.95);
}

/* Button Icons */
.fh-menu-sidebar__icon {
    width: 28px;
    height: 28px;
    position: absolute;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    pointer-events: none;
}

.fh-menu-sidebar__icon.active {
    opacity: 1;
}

/* Overlay */
.fh-menu-sidebar__overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 998;
}

.fh-menu-sidebar__overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Sidebar Panel */
.fh-menu-sidebar__panel {
    position: fixed;
    top: 0;
    right: -450px;
    width: 400px;
    height: 100vh;
    background: #fff;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.2);
    display: flex;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
}

.fh-menu-sidebar__panel.open {
    right: 0;
}

/* Tab Navigation (Right Side) */
.fh-menu-sidebar__tabs {
    width: 75px;
    background: var(--color_prime, #1B2754);
    display: flex;
    flex-direction: column;
    padding: 0;
    gap: 0.75rem;
    order: 2;
}

.fh-menu-sidebar__tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 0.5rem;
    background: transparent;
    border: 2px solid transparent;
    border-radius: 0;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    position: relative;
}

.fh-menu-sidebar__tab:hover {
    background: rgba(255, 241, 229, 0.1);
}

.fh-menu-sidebar__tab.active {
    background: var(--color_secondary, #4DA09D);
    border-color: var(--color_secondary, #4DA09D);
}

.fh-menu-sidebar__tab--link:hover,
.fh-menu-sidebar__tab--link.active {
    background: var(--color_secondary, #ed2024);
    border-color: var(--color_secondary, #ed2024);
}

.fh-menu-sidebar__tab-icon {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.fh-menu-sidebar__tab-title {
    font-size: 11px;
    text-align: center;
    line-height: 1.2;
    font-weight: 500;
}

.fh-menu-sidebar__close {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: transparent;
    border: 2px solid #ffffff;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.3s ease;
    align-self: center;
    margin-bottom: 20px;
}

.fh-menu-sidebar__close:hover {
    background: var(--color_secondary, #ed2024);
    border-color: var(--color_secondary, #ed2024);
}

.fh-menu-sidebar__close svg {
    width: 20px;
    height: 20px;
}

/* Content Area (Left Side) */
.fh-menu-sidebar__content {
    flex: 1;
    overflow-y: auto;
    order: 1;
}

.fh-menu-sidebar__content-panel {
    display: none;
    height: 100%;
}

.fh-menu-sidebar__content-panel.active {
    display: flex;
    flex-direction: column;
}

.fh-menu-sidebar__content-panel[data-content="favorite-articles"] .fh-menu-sidebar__article-item {
    padding: .75rem;
    border: 1px solid var(--color_stroke);
}

.fh-menu-sidebar__content-panel[data-content="favorite-articles"] .fh-menu-sidebar__article-item:after {
    content: none;
}


.fh-menu-sidebar__content-title {
    padding: 1.5rem 1.5rem 1rem;
    margin: 0;
    font-size: 1.5rem;
    color: var(--color_prime, #1B2754);
    border-bottom: 2px solid var(--color4, rgba(8, 40, 48, 0.2));
    display: none;
}

.fh-menu-sidebar__content-body {
    flex: 1;
    padding: 1rem;
    overflow-y: auto;
}

/* Loader */
.fh-menu-sidebar__loader {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--color3, #565656);
    font-size: 1rem;
}

/* Empty State */
.fh-menu-sidebar__empty {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--color3, #565656);
    font-size: 0.95rem;
}

/* Articles List */
.fh-menu-sidebar__articles-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.fh-menu-sidebar__article-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-radius: 0;
    transition: background 0.3s ease;
}

.fh-menu-sidebar__article-item:after {
    content: "";
    left: 0;
    right: 0;
    bottom: -9px;
    position: absolute;
    height: 1px;
    background: var(--color_stroke);
}

.fh-menu-sidebar__article-item:hover {
    background: #f1f1f2;
}

.fh-menu-sidebar__article-image {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 6px;
    overflow: hidden;
}

.fh-menu-sidebar__article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.fh-menu-sidebar__article-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.fh-menu-sidebar__article-title {
    margin: 0;
    font-family: var(--font-size-4-font-family);
    font-size: 14px;
    line-height: 18px;
    font-weight: 500;
}

.fh-menu-sidebar__article-title a {
    color: var(--color_prime, #1B2754);
    text-decoration: none;
    transition: color 0.3s ease;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    overflow: hidden !important;
    -webkit-box-orient: vertical;
    word-break: break-word;
}

.fh-menu-sidebar__article-title a:hover {
    color: var(--color_secondary, #4DA09D);
}

.fh-menu-sidebar__article-date {
    padding-left: 25px;
    position: relative;
    font-size: 13px;
    line-height: 17px;
    color: #8c8c8c;
    margin-top: 10px;
}

time.fh-menu-sidebar__article-date:before {
    content: "";
    background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTciIGhlaWdodD0iMTciIHZpZXdCb3g9IjAgMCAxNyAxNyIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTguNSAxN0MzLjgwODc0IDE3IDAgMTMuMTkxMyAwIDguNUMwIDMuODA4NzQgMy44MDg3NCAwIDguNSAwQzEzLjE5MTMgMCAxNyAzLjgwODc0IDE3IDguNUMxNyAxMy4xOTEzIDEzLjE5MTMgMTcgOC41IDE3Wk04LjUgMS4zOTM0NEM0LjU3NTE0IDEuMzkzNDQgMS4zOTM0NCA0LjU3NTE0IDEuMzkzNDQgOC41QzEuMzkzNDQgMTIuNDI0OSA0LjU3NTE0IDE1LjYwNjYgOC41IDE1LjYwNjZDMTIuNDI0OSAxNS42MDY2IDE1LjYwNjYgMTIuNDAxNiAxNS42MDY2IDguNUMxNS42MDY2IDQuNTk4MzYgMTIuNDI0OSAxLjM5MzQ0IDguNSAxLjM5MzQ0WiIgZmlsbD0iI0E4QThBOCIvPgo8cGF0aCBkPSJNMTIuMzU1OCA5LjY2MTI0SDguMTA1NzhDNy43MTA5NyA5LjY2MTI0IDcuNDA5MDYgOS4zNTkzMyA3LjQwOTA2IDguOTY0NTJWNC4wODc0N0M3LjQwOTA2IDMuNjkyNjYgNy43MTA5NyAzLjM5MDc1IDguMTA1NzggMy4zOTA3NUM4LjUwMDU5IDMuMzkwNzUgOC44MDI1IDMuNjkyNjYgOC44MDI1IDQuMDg3NDdWOC4yNjc4SDEyLjM3OUMxMi43NzM4IDguMjY3OCAxMy4wNzU3IDguNTY5NzEgMTMuMDc1NyA4Ljk2NDUyQzEzLjA1MjUgOS4zMzYxIDEyLjc1MDYgOS42NjEyNCAxMi4zNTU4IDkuNjYxMjRaIiBmaWxsPSIjQThBOEE4Ii8+Cjwvc3ZnPgo=");
    width: 17px;
    height: 17px;
    position: absolute;
    left: 0;
    top: 0;
}

/* Quotes List */
.fh-menu-sidebar__quote-lookup {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.fh-menu-sidebar__quote-input {
    flex: 1;
    padding: 0.75rem;
    border: 2px solid var(--color4, rgba(8, 40, 48, 0.2));
    border-radius: 8px;
    background: #fff;
    font-size: 0.95rem;
    transition: border-color 0.3s ease;
}

.fh-menu-sidebar__quote-input:focus {
    outline: none;
    border-color: var(--color_secondary, #4DA09D);
}

.fh-menu-sidebar__quote-search {
    padding: 0.75rem 1.25rem;
    background: var(--color_prime, #1B2754);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}

.fh-menu-sidebar__quote-search:hover {
    background: var(--color_secondary, #4DA09D);
}

.fh-menu-sidebar__quotes-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.fh-menu-sidebar__quote-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color_stroke);
    transition: background 0.3s ease;
}

.fh-menu-sidebar__quote-item:hover {
    background: #f1f1f2;
}

.fh-menu-sidebar__quote-symbol {
    font-size: 14px;
    font-weight: 700;
    color: var(--color_prime, #1B2754);
    text-decoration: none;
    transition: color 0.3s ease;
}

.fh-menu-sidebar__quote-symbol:hover {
    color: var(--color_secondary, #ED2024);
}

.fh-menu-sidebar__quote-data {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.25rem;
}

.fh-menu-sidebar__quote-price {
    font-size: 14px;
    font-weight: 600;
    color: var(--color_prime, #1B2754);
}

.fh-menu-sidebar__quote-change {
    font-size: 14px;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.fh-menu-sidebar__quote-change.positive {
    color: #1c8843;
}

.fh-menu-sidebar__quote-change.negative {
    color: #d51212;
}

/* Currency Converter */
.fh-currency-converter {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.fh-currency-converter__group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.fh-currency-converter__label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color_prime, #1B2754);
}

.fh-currency-converter__row {
    display: flex;
    gap: 0.75rem;
}

.fh-currency-converter__amount {
    padding: 0.575rem;
    border: 1px solid var(--color_stroke);
    border-radius: 0;
    background: #fff;
    font-size: 16px;
    font-weight: 600;
    transition: border-color 0.3s ease;
    flex: 0 0 60%;
    width: 60%;
}

.fh-currency-converter__amount:focus {
    outline: none;
    border-color: var(--color_secondary, #4DA09D);
}

.fh-currency-converter__select {
    padding: 0.5rem 1rem;
    border: 1px solid var(--color_stroke);
    border-radius: 0;
    background: #fff;
    font-size: 1rem;
    font-weight: 600;
    color: var(--color_prime, #1B2754);
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.fh-currency-converter__select:focus {
    outline: none;
    border-color: var(--color_secondary, #4DA09D);
}

.fh-currency-converter__swap {
    align-self: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--color_prime, #1B2754);
    color: #ffffff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.fh-currency-converter__swap:hover {
    background: var(--color_secondary, #4DA09D);
    transform: rotate(180deg);
}

.fh-currency-converter__swap svg {
    width: 24px;
    height: 24px;
}

.fh-currency-converter__rate {
    padding: 0.75rem;
    background: #f1f1f2;
    text-align: center;
}

.fh-currency-converter__rate small {
    font-size: 0.9rem;
    color: var(--color_prime, #1B2754);
}

/* Favorite Buttons */
.fh-favorite-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    background: #ffffff;
    border: 1px solid var(--color_stroke);
    border-radius: 0;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.fh-favorite-button__wrapper {
    text-align: right;
    margin-bottom: 20px;
    margin-top: -20px;
}

.fh-favorite-button:hover {
    background: #f1f1f2;
}

.fh-favorite-button.is-favorite {
    background: var(--color_secondary, #ed2024);
    color: #fff;
    border-color: var(--color_secondary, #ed2024);
}

.fh-favorite-button svg {
    width: 18px;
    height: 18px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .fh-menu-sidebar__panel {
        width: 100%;
        right: -100%;
    }

    .fh-menu-sidebar__panel.open {
        right: 0;
    }


    .fh-menu-sidebar__tab {
        padding: 0.5rem 0.25rem;
        gap: 0.35rem;
    }

    .fh-menu-sidebar__tab-icon {
        width: 20px;
        height: 20px;
    }

    .fh-menu-sidebar__tab-title {
        font-size: 10px;
    }

    .fh-menu-sidebar__content-title {
        font-size: 1.25rem;
        padding: 1rem;
    }

    .fh-menu-sidebar__overlay {
        display: none;
    }
}

/* Scrollbar Styling */
.fh-menu-sidebar__content-body::-webkit-scrollbar {
    width: 6px;
}

.fh-menu-sidebar__content-body::-webkit-scrollbar-track {
    background: transparent;
}

.fh-menu-sidebar__content-body::-webkit-scrollbar-thumb {
    background: #bdbdbd;
    border-radius: 0;
}

.fh-menu-sidebar__content-body::-webkit-scrollbar-thumb:hover {
    background: var(--color_prime, #1B2754);
}

/* Remove Button */
.fh-menu-sidebar__remove-btn {
    position: absolute;
    top: -0.5rem;
    right: -0.5rem;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--color_secondary, #ed2024);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
    z-index: 10;
}

.fh-menu-sidebar__remove-btn:hover {
    background: var(--color15, #B80000);
    transform: scale(1.1);
}

.fh-menu-sidebar__remove-btn svg {
    width: 16px;
    height: 16px;
}

.fh-menu-sidebar__article-item {
    position: relative;
}

.fh-menu-sidebar__article-item:hover .fh-menu-sidebar__remove-btn {
    opacity: 1;
}

.fh-menu-sidebar__quote-item {
    position: relative;
}

.fh-menu-sidebar__quote-item:hover .fh-menu-sidebar__remove-btn {
    opacity: 1;
}

