/* ==========================================================================
   Visit Hanoi - Browser Favorites Page & Components
   ========================================================================== */

.content-favorite-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; margin: 12px 0; padding: 9px 14px; border: 1px solid #d0ded4; border-radius: 10px; background: #fff; color: #2d5238; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.content-favorite-button[aria-pressed="true"] { border-color: #edb8c6; background: #fff0f3; color: #b52c50; }
.content-favorite-button [data-favorite-count] { padding: 1px 6px; border-radius: 5px; background: #edf4ef; color: #2d5238; font-variant-numeric: tabular-nums; }
.content-favorite-button:focus-visible { outline: 2px solid #2d5238; outline-offset: 3px; }
.content-favorite-button:disabled { opacity: .6; cursor: progress; }
.vr-toolbar .content-favorite-button { margin: 0; }
@media(max-width:768px) { .vr-toolbar .content-favorite-button [data-favorite-label] { display: none; } .vr-toolbar .content-favorite-button { padding: 9px; } }

/* Toast notification */
.browser-favorites-message {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 12000;
    max-width: min(440px, calc(100vw - 48px));
    padding: 14px 20px;
    border-radius: 12px;
    background: #234731;
    color: #ffffff;
    font-size: 14.5px;
    font-weight: 500;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.22);
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideInFavToast 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

@keyframes slideInFavToast {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Page Section & Header */
.fav-page-section {
    padding: 40px 0 70px;
    background-color: #fafbfc;
    min-height: 60vh;
}

.fav-header-block {
    text-align: center;
    margin-bottom: 28px;
}

.fav-header-block .tour-all-heading {
    margin-bottom: 12px;
}

.fav-header-block .media-intro-subtitle {
    font-family: var(--font-primary), 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(20px, 2.2vw, 24px);
    font-weight: 600;
    color: #2b3a4a;
    max-width: 880px;
    margin: 0 auto;
    line-height: 1.5;
    text-align: center;
    letter-spacing: 0.2px;
}

/* Tabs Danh mục */
.fav-tabs-wrap {
    display: flex;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    margin: 10px 0 26px 0;
}

.fav-tabs-wrap .tour-filter-tabs {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px;
    list-style: none;
    padding: 0 !important;
    margin: 0;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.fav-tabs-wrap .tour-tab-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    border-radius: 999px;
    background-color: #ffffff;
    border: 1.5px solid #d5e2d8;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    font-size: 14.5px;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    transition: all 0.22s ease;
    user-select: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    text-decoration: none !important;
}

.fav-tabs-wrap .tour-tab-item:hover {
    color: #234731;
    background-color: #f0f7f2;
    border-color: #234731;
    transform: translateY(-1px);
}

.fav-tabs-wrap .tour-tab-item.active {
    background-color: #234731;
    color: #ffffff !important;
    border-color: #234731;
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(35, 71, 49, 0.28);
    transform: translateY(-1px);
}

.fav-tabs-wrap .tour-tab-badge {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    padding: 2px 8px;
    border-radius: 999px;
    background: #edf2f7;
    color: #4a5568;
    transition: all 0.22s ease;
}

.fav-tabs-wrap .tour-tab-item.active .tour-tab-badge {
    background: rgba(255, 255, 255, 0.28);
    color: #ffffff !important;
}

/* Thanh tìm kiếm & thống kê ngang bằng toàn bộ khung item */
.fav-search-bar-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
    max-width: 100%;
    margin: 0 0 32px 0;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    box-sizing: border-box;
}

.fav-search-bar-wrap .fav-search-wrap {
    position: relative;
    display: flex;
    align-items: center;
    flex: 1;
}

.fav-input-icon {
    position: absolute;
    left: 16px;
    color: #2d5238;
    font-size: 15px;
    pointer-events: none;
    z-index: 2;
}

.fav-search-input {
    width: 100%;
    height: 48px;
    border: 1.5px solid #cfded4;
    border-radius: 12px;
    padding: 10px 16px 10px 44px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 15px;
    font-weight: 500;
    color: #1e293b;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.2s ease;
    outline: none;
    box-sizing: border-box;
}

.fav-search-input::placeholder {
    color: #64748b;
    font-size: 14.5px;
    opacity: 1;
}

.fav-search-input:focus {
    border-color: #2d5238;
    box-shadow: 0 0 0 3px rgba(45, 82, 56, 0.16);
}

.fav-count-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 48px;
    padding: 0 20px;
    background: #ffffff;
    border: 1.5px solid #cfded4;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    color: #234731;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    font-size: 14.5px;
    font-weight: 600;
    white-space: nowrap;
    user-select: none;
    box-sizing: border-box;
}

.fav-count-pill i {
    color: #2d5238;
    font-size: 14px;
}

.fav-count-pill strong,
#favorites-visible-total {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    font-variant-numeric: normal !important;
    font-feature-settings: "lnum" 1 !important;
    color: #1b3d27 !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    letter-spacing: 0 !important;
    display: inline-block;
}

/* Card & Grid Overrides */
.fav-card {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.07);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
    transition: transform 0.35s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.35s ease, border-color 0.35s ease;
    display: flex;
    flex-direction: column;
}

.fav-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.12);
    border-color: rgba(35, 71, 49, 0.25);
}

.fav-card .tour-card-img-wrap {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #eef2ef;
}

.fav-card .tour-card-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.fav-card:hover .tour-card-thumb {
    transform: scale(1.06);
}

/* Category Badges on Card Thumbnail */
.fav-card .tour-card-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 4;
    border-radius: 20px;
    font-size: 12.5px;
    font-weight: 700;
    padding: 5px 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    letter-spacing: 0.2px;
}

.badge-fav-video { background: #dc2626 !important; color: #ffffff !important; }
.badge-fav-picture { background: #0284c7 !important; color: #ffffff !important; }
.badge-fav-book { background: #d97706 !important; color: #ffffff !important; }
.badge-fav-dest { background: #15803d !important; color: #ffffff !important; }
.badge-fav-fest { background: #7c3aed !important; color: #ffffff !important; }
.badge-fav-food { background: #ea580c !important; color: #ffffff !important; }
.badge-fav-spec { background: #b45309 !important; color: #ffffff !important; }
.badge-fav-hotel { background: #0d9488 !important; color: #ffffff !important; }

/* Video Play Overlay */
.fav-play-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.18);
    pointer-events: none;
}

.fav-play-icon i {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(45, 82, 56, 0.9);
    border: 2px solid #ffffff;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, background-color 0.2s ease;
}

.fav-card:hover .fav-play-icon i {
    transform: scale(1.12);
    background: #2d5238;
}

/* Floating Unfavorite / Remove Button (Top-Right) */
.fav-card-remove-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 5;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 13px;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(225, 29, 72, 0.22);
    border-radius: 20px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.12);
    color: #e11d48;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: all 0.22s cubic-bezier(0.25, 0.8, 0.25, 1);
    outline: none;
    user-select: none;
}

.fav-card-remove-btn i {
    font-family: "Font Awesome 6 Free" !important;
    font-weight: 900 !important;
    font-size: 13.5px;
    color: #e11d48;
    transition: transform 0.2s ease, color 0.2s ease;
}

.fav-card-remove-btn:hover {
    background: #ffe4e6;
    border-color: #fca5a5;
    color: #be123c;
    transform: translateY(-1px) scale(1.04);
    box-shadow: 0 4px 14px rgba(225, 29, 72, 0.25);
}

.fav-card-remove-btn:hover i {
    transform: scale(1.15);
}

.fav-card-remove-btn .fav-remove-label-hover { display: none; }
.fav-card-remove-btn:hover .fav-remove-label-default { display: none; }
.fav-card-remove-btn:hover .fav-remove-label-hover { display: inline; }

/* Card Content Area */
.fav-card .tour-card-content {
    padding: 18px 20px 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.fav-card .tour-card-title {
    font-size: 17.5px;
    font-weight: 700;
    line-height: 1.45;
    color: #1e293b;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.9em;
}

.fav-card:hover .tour-card-title {
    color: #234731;
}

.fav-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin: 8px 0 14px;
    padding-top: 10px;
    border-top: 1px dashed #e2e8f0;
    font-size: 13px;
    color: #64748b;
}

.fav-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.fav-likes {
    color: #e11d48;
    font-weight: 600;
}

.fav-likes i {
    font-size: 13px;
}

.fav-unavailable {
    color: #d97706;
    font-weight: 500;
}

.fav-card-footer {
    margin-top: auto;
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.fav-card-action {
    font-size: 13.5px;
    font-weight: 700;
    color: #2d5238;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.fav-card:hover .fav-card-action {
    color: #143020;
    gap: 9px;
}

/* Empty State Card */
.fav-empty-card {
    padding: 60px 24px;
    text-align: center;
    background: #ffffff;
    border-radius: 20px;
    border: 2px dashed #cbd5e1;
    max-width: 680px;
    margin: 30px auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.fav-empty-icon {
    width: 76px;
    height: 76px;
    margin: 0 auto 20px;
    border-radius: 50%;
    background: #fff1f2;
    color: #e11d48;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: 0 4px 16px rgba(225, 29, 72, 0.15);
    animation: pulseHeart 2s infinite ease-in-out;
}

@keyframes pulseHeart {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.08); }
}

.fav-empty-title {
    font-size: 22px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 10px;
}

.fav-empty-desc {
    font-size: 15px;
    color: #64748b;
    max-width: 520px;
    margin: 0 auto 26px;
    line-height: 1.6;
}

.fav-empty-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
}

.fav-btn-action {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: 12px;
    font-size: 14.5px;
    font-weight: 700;
    text-decoration: none !important;
    transition: all 0.2s ease;
}

.fav-btn-primary {
    background: #2d5238;
    color: #ffffff !important;
    box-shadow: 0 2px 8px rgba(45, 82, 56, 0.25);
}

.fav-btn-primary:hover {
    background: #1f3c27;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(45, 82, 56, 0.35);
}

.fav-btn-secondary {
    background: #f1f5f9;
    color: #334155 !important;
    border: 1px solid #cbd5e1;
}

.fav-btn-secondary:hover {
    background: #e2e8f0;
    color: #1e293b !important;
    transform: translateY(-1px);
}

.fav-reset-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    background: #2d5238;
    color: #ffffff;
    border: 0;
    cursor: pointer;
    transition: all 0.2s ease;
}

.fav-reset-btn:hover {
    background: #1f3c27;
    transform: translateY(-1px);
}

/* Fallback & Helper links */
.browser-favorites-library-link {
    display: block;
    max-width: 1200px;
    margin: 12px auto;
    padding: 0 16px;
    color: #2d5238;
    font-weight: 600;
}

[data-browser-favorite][aria-pressed="true"] {
    color: #b52c50;
}

/* Font Awesome Protection Rules */
.fa-heart,
#heart-icon,
#favHeartIcon,
[data-book-favorite] i,
[data-browser-favorite] i,
.foodplace-like-btn i,
.specialty-like-btn i,
.festival-like-btn i,
.accommodation-like-btn i,
.interactive-like i {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
    font-style: normal !important;
    font-variant: normal !important;
    text-rendering: auto !important;
    display: inline-block !important;
    line-height: 1 !important;
}

.fa-heart.fa-solid,
.liked-active .fa-heart,
[aria-pressed="true"] .fa-heart {
    font-family: "Font Awesome 6 Free" !important;
    font-weight: 900 !important;
}

.fa-heart.fa-regular,
[aria-pressed="false"] .fa-heart {
    font-family: "Font Awesome 6 Free" !important;
    font-weight: 400 !important;
}

/* Responsive Breakpoints */
@media (max-width: 768px) {
    .browser-favorites-toolbar {
        flex-direction: column;
        align-items: stretch;
        padding: 14px 16px;
    }

    .fav-toolbar-controls {
        flex-direction: column;
    }

    .fav-select-wrap,
    .fav-search-wrap {
        width: 100%;
        min-width: 0;
    }

    .fav-count-pill {
        justify-content: center;
        width: 100%;
    }
}
.itinerary-favorite-links{display:flex;justify-content:center;flex-wrap:wrap;gap:16px;margin:20px 0}.itinerary-favorite-links a{display:inline-block;padding:10px 16px;border:1px solid #28543c;border-radius:8px;color:#28543c;font-weight:600}.itinerary-favorite-links a:first-child{background:#28543c;color:white}
.tour-planner-launch{display:inline-flex!important;align-items:center;gap:8px;margin:10px 8px 10px 0;padding:11px 18px;background:#28543c!important;color:#fff!important;border:1px solid #bfd2b8;border-radius:8px;font:600 14px/1.4 Arial,sans-serif;text-decoration:none!important;white-space:normal;vertical-align:middle}.tour-planner-launch:hover{background:#1c402b!important}.tour-planner-launch:focus-visible{outline:3px solid #d4bd83;outline-offset:3px}
