/* =========================================
   LOVE HUB — PREMIUM OVERLAY
   ========================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

:root {
    --lh-rose: #f43f5e;
    --lh-rose-light: #fb7185;
    --lh-rose-dark: #e11d48;
    --lh-violet: #8b5cf6;
    --lh-amber: #f59e0b;
    --lh-emerald: #10b981;
    --lh-sky: #0ea5e9;
    --lh-slate: #334155;
    --lh-slate-light: #64748b;
    --lh-bg: #fdf2f8;
    --lh-card: rgba(255, 255, 255, 0.85);
    --lh-glass: rgba(255, 255, 255, 0.6);
    --lh-shadow-sm: 0 1px 3px rgba(244, 63, 94, .08);
    --lh-shadow: 0 4px 20px rgba(244, 63, 94, .12);
    --lh-shadow-lg: 0 10px 40px rgba(244, 63, 94, .18);
    --lh-radius: 22px;
    --lh-radius-sm: 14px;
    --lh-transition: cubic-bezier(.4, 0, .2, 1);
}

/* ===================== FAB ===================== */
.love-hub-fab {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--lh-rose), var(--lh-violet));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    border: none;
    cursor: pointer;
    z-index: 9990;
    box-shadow: 0 6px 24px rgba(244, 63, 94, .45), 0 0 0 0 rgba(244, 63, 94, .3);
    transition: all .35s var(--lh-transition);
    animation: fabPulse 2.5s infinite;
    -webkit-tap-highlight-color: transparent;
}

.love-hub-fab:hover {
    transform: scale(1.12) rotate(-8deg);
    box-shadow: 0 8px 30px rgba(139, 92, 246, .5);
}

.love-hub-fab:active {
    transform: scale(.92);
}

@keyframes fabPulse {

    0%,
    100% {
        box-shadow: 0 6px 24px rgba(244, 63, 94, .45), 0 0 0 0 rgba(244, 63, 94, .25);
    }

    50% {
        box-shadow: 0 6px 24px rgba(244, 63, 94, .45), 0 0 0 14px rgba(244, 63, 94, 0);
    }
}

.love-hub-fab .fab-icon {
    animation: heartBounce 1.2s infinite;
    display: flex;
}

@keyframes heartBounce {

    0%,
    100% {
        transform: scale(1);
    }

    15%,
    45% {
        transform: scale(1.2);
    }

    30% {
        transform: scale(1);
    }
}

.love-hub-fab .fab-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    width: 20px;
    height: 20px;
    background: var(--lh-amber);
    border-radius: 50%;
    font-size: 11px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2.5px solid #fff;
    color: #fff;
    box-shadow: 0 2px 6px rgba(245, 158, 11, .4);
}

/* ===================== OVERLAY ===================== */
.love-hub-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 9999;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s var(--lh-transition);
}

.love-hub-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

@media(min-width:640px) {
    .love-hub-overlay {
        align-items: center;
    }
}

/* ===================== MODAL ===================== */
.lh-modal {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    width: 100%;
    max-width: 440px;
    max-height: 88vh;
    background: var(--lh-bg);
    border-radius: var(--lh-radius) var(--lh-radius) 0 0;
    display: flex;
    flex-direction: column;
    transform: translateY(100%);
    transition: transform .45s var(--lh-transition);
    overflow: hidden;
    box-shadow: var(--lh-shadow-lg);
}

@media(min-width:640px) {
    .lh-modal {
        border-radius: var(--lh-radius);
        transform: translateY(30px) scale(.97);
        opacity: 0;
        transition: all .35s var(--lh-transition);
    }

    .love-hub-overlay.open .lh-modal {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.love-hub-overlay.open .lh-modal {
    transform: translateY(0);
}

/* Header */
.lh-header {
    padding: 18px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--lh-rose), var(--lh-violet));
    color: #fff;
    flex-shrink: 0;
}

.lh-header h2 {
    font-size: 1.15rem;
    font-weight: 800;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    letter-spacing: -.02em;
}

.lh-header h2 span {
    font-size: .7rem;
    background: rgba(255, 255, 255, .25);
    padding: 2px 8px;
    border-radius: 20px;
    font-weight: 600;
}

.lh-close-btn {
    background: rgba(255, 255, 255, .2);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1rem;
    cursor: pointer;
    transition: background .2s;
}

.lh-close-btn:hover {
    background: rgba(255, 255, 255, .35);
}

/* Tabs */
.lh-tabs {
    display: flex;
    background: #fff;
    border-bottom: 1px solid rgba(244, 63, 94, .08);
    flex-shrink: 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.lh-tabs::-webkit-scrollbar {
    display: none;
}

.lh-tab {
    flex: 1;
    min-width: 0;
    padding: 12px 6px 10px;
    background: none;
    border: none;
    color: var(--lh-slate-light);
    font-family: inherit;
    font-weight: 600;
    font-size: .78rem;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    position: relative;
    transition: color .25s;
    white-space: nowrap;
}

.lh-tab .tab-emoji {
    font-size: 1.15rem;
}

.lh-tab.active {
    color: var(--lh-rose);
}

.lh-tab::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 20%;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--lh-rose), var(--lh-violet));
    border-radius: 3px 3px 0 0;
    transition: width .3s var(--lh-transition);
}

.lh-tab.active::after {
    width: 60%;
}

/* Content */
.lh-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    scroll-behavior: smooth;
}

/* Panels */
.lh-panel {
    display: none;
    margin-bottom: 20px;
    animation: panelIn .4s var(--lh-transition);
}

.lh-panel.active {
    display: block;
}

@keyframes panelIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===================== SHARED CARD ===================== */
.lh-card {
    background: var(--lh-card);
    backdrop-filter: blur(6px);
    border-radius: var(--lh-radius-sm);
    padding: 16px;
    margin-bottom: 14px;
    box-shadow: var(--lh-shadow-sm);
    border: 1px solid rgba(244, 63, 94, .06);
}

.lh-card-head {
    font-size: .95rem;
    font-weight: 700;
    color: var(--lh-slate);
    margin: 0 0 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.lh-card-head .icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .85rem;
    flex-shrink: 0;
}

.icon-blue {
    background: #dbeafe;
    color: var(--lh-sky);
}

.icon-purple {
    background: #ede9fe;
    color: var(--lh-violet);
}

.icon-pink {
    background: #fce7f3;
    color: var(--lh-rose);
}

.icon-green {
    background: #d1fae5;
    color: var(--lh-emerald);
}

.icon-amber {
    background: #fef3c7;
    color: var(--lh-amber);
}

/* Progress Bar */
.lh-progress {
    height: 6px;
    border-radius: 3px;
    background: #f1f5f9;
    margin-bottom: 14px;
    overflow: hidden;
}

.lh-progress-fill {
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--lh-rose), var(--lh-violet));
    transition: width .5s var(--lh-transition);
}

/* ===================== QUESTS ===================== */
.quest-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
    border-radius: 12px;
    background: var(--lh-glass);
    margin-bottom: 8px;
    cursor: pointer;
    transition: all .2s var(--lh-transition);
    border: 1.5px solid transparent;
    user-select: none;
}

.quest-row:last-child {
    margin-bottom: 0;
}

.quest-row:hover {
    background: #fff;
    border-color: rgba(244, 63, 94, .12);
}

.quest-row.done {
    opacity: .55;
}

.quest-row.done .q-text {
    text-decoration: line-through;
}

.q-check {
    appearance: none;
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    border: 2px solid var(--lh-rose-light);
    border-radius: 7px;
    flex-shrink: 0;
    margin-top: 1px;
    cursor: pointer;
    position: relative;
    transition: all .2s;
}

.q-check:checked {
    background: linear-gradient(135deg, var(--lh-rose), var(--lh-violet));
    border-color: transparent;
}

.q-check:checked::after {
    content: '✓';
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

.q-body {
    flex: 1;
}

.q-text {
    font-size: .9rem;
    font-weight: 600;
    color: var(--lh-slate);
    margin: 0 0 3px;
    line-height: 1.35;
}

.q-reward {
    font-size: .75rem;
    color: var(--lh-amber);
    font-weight: 700;
}

/* ===================== GIFT ADVISOR ===================== */
.lh-select,
.lh-input {
    width: 100%;
    padding: 11px 14px;
    border-radius: 10px;
    border: 1.5px solid #e2e8f0;
    background: #f8fafc;
    font-family: inherit;
    font-size: .9rem;
    color: var(--lh-slate);
    outline: none;
    transition: border-color .2s, box-shadow .2s;
    box-sizing: border-box;
}

.lh-select:focus,
.lh-input:focus {
    border-color: var(--lh-rose-light);
    box-shadow: 0 0 0 3px rgba(244, 63, 94, .08);
    background: #fff;
}

.lh-label {
    display: block;
    font-size: .8rem;
    font-weight: 600;
    color: var(--lh-slate-light);
    margin-bottom: 6px;
}

.lh-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 13px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, var(--lh-rose), var(--lh-violet));
    color: #fff;
    font-family: inherit;
    font-weight: 700;
    font-size: .95rem;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(244, 63, 94, .3);
    transition: all .25s var(--lh-transition);
}

.lh-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, .35);
}

.lh-btn:active {
    transform: translateY(0);
}

.lh-btn:disabled {
    opacity: .6;
    cursor: not-allowed;
    transform: none;
}

.lh-btn-outline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 11px;
    border-radius: 12px;
    border: 2px solid var(--lh-rose-light);
    background: transparent;
    color: var(--lh-rose);
    font-family: inherit;
    font-weight: 700;
    font-size: .9rem;
    cursor: pointer;
    transition: all .2s;
}

.lh-btn-outline:hover {
    background: rgba(244, 63, 94, .06);
}

/* Gift Result Cards */
.gift-result-card {
    background: linear-gradient(135deg, #fff5f7, #fdf4ff);
    border-radius: 14px;
    padding: 16px;
    margin-top: 14px;
    border-left: 4px solid var(--lh-rose);
    box-shadow: var(--lh-shadow-sm);
    animation: panelIn .4s;
}

.gift-result-card h4 {
    color: var(--lh-rose-dark);
    font-size: .95rem;
    font-weight: 700;
    margin: 0 0 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.gift-result-card p {
    font-size: .85rem;
    color: var(--lh-slate);
    line-height: 1.5;
    margin: 0;
}

.gift-result-tip {
    border-left-color: var(--lh-violet);
    background: linear-gradient(135deg, #f5f3ff, #fdf4ff);
    margin-top: 10px;
}

.gift-result-tip h4 {
    color: var(--lh-violet);
}

/* ===================== MINI GAME ===================== */
.mg-setup {
    text-align: center;
}

.mg-setup p {
    font-size: .85rem;
    color: var(--lh-slate-light);
    margin: 0 0 16px;
    line-height: 1.5;
}

.mg-player-select {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}

.mg-player-card {
    padding: 16px 12px;
    border-radius: 14px;
    border: 2px solid #e2e8f0;
    background: #fff;
    cursor: pointer;
    text-align: center;
    transition: all .25s var(--lh-transition);
}

.mg-player-card:hover {
    border-color: var(--lh-rose-light);
}

.mg-player-card.selected {
    border-color: var(--lh-rose);
    background: #fff1f2;
    box-shadow: 0 0 0 3px rgba(244, 63, 94, .1);
}

.mg-player-card .emoji {
    font-size: 2rem;
    margin-bottom: 6px;
}

.mg-player-card .label {
    font-size: .85rem;
    font-weight: 700;
    color: var(--lh-slate);
}

.mg-question-text {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--lh-slate);
    text-align: center;
    margin: 0 0 20px;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1.4;
}

.mg-answers {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mg-answer-btn {
    padding: 14px;
    border-radius: 12px;
    border: 2px solid #e2e8f0;
    background: #fff;
    font-family: inherit;
    font-weight: 600;
    font-size: .9rem;
    color: var(--lh-slate);
    cursor: pointer;
    transition: all .2s;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 10px;
}

.mg-answer-btn .letter {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .75rem;
    font-weight: 800;
    color: var(--lh-slate-light);
    flex-shrink: 0;
}

.mg-answer-btn:hover {
    border-color: var(--lh-rose-light);
    background: #fff1f2;
}

.mg-answer-btn:hover .letter {
    background: #fce7f3;
    color: var(--lh-rose);
}

.mg-answer-btn.picked {
    border-color: var(--lh-rose);
    background: #fff1f2;
}

.mg-answer-btn.picked .letter {
    background: var(--lh-rose);
    color: #fff;
}

.mg-status {
    text-align: center;
    margin-top: 16px;
    font-size: .85rem;
    font-weight: 600;
    color: var(--lh-slate-light);
}

.mg-final {
    text-align: center;
    padding: 10px 0;
    animation: panelIn .5s;
}

.mg-final .trophy {
    font-size: 3.5rem;
    margin-bottom: 8px;
}

.mg-final h3 {
    color: var(--lh-rose-dark);
    margin: 0 0 8px;
    font-size: 1.15rem;
}

.mg-final p {
    color: var(--lh-slate);
    font-size: .9rem;
    line-height: 1.5;
    margin: 0 0 16px;
}

.mg-score-compare {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 20px;
}

.mg-score-box {
    background: #fff;
    border-radius: 14px;
    padding: 14px 20px;
    box-shadow: var(--lh-shadow-sm);
    text-align: center;
    min-width: 100px;
}

.mg-score-box .who {
    font-size: .75rem;
    color: var(--lh-slate-light);
    font-weight: 600;
    margin-bottom: 4px;
}

.mg-score-box .pts {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--lh-rose);
}

/* ===================== MILESTONES ===================== */
.ms-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    background: #fff;
    border-radius: 14px;
    margin-bottom: 10px;
    box-shadow: var(--lh-shadow-sm);
    transition: transform .2s;
    border-left: 4px solid var(--lh-rose-light);
}

.ms-item:hover {
    transform: translateX(4px);
}

.ms-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.ms-detail {
    flex: 1;
    min-width: 0;
}

.ms-name {
    font-size: .9rem;
    font-weight: 700;
    color: var(--lh-slate);
    margin: 0 0 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ms-date-text {
    font-size: .75rem;
    color: var(--lh-slate-light);
}

.ms-counter {
    text-align: right;
    flex-shrink: 0;
}

.ms-num {
    font-size: 1.3rem;
    font-weight: 900;
    color: var(--lh-rose);
    line-height: 1;
}

.ms-unit {
    font-size: .65rem;
    font-weight: 700;
    color: var(--lh-rose-light);
    text-transform: uppercase;
    letter-spacing: .05em;
    margin-top: 2px;
}

.ms-del {
    background: none;
    border: none;
    color: #cbd5e1;
    cursor: pointer;
    padding: 4px;
    margin-left: 4px;
    transition: color .2s;
    font-size: .9rem;
}

.ms-del:hover {
    color: #ef4444;
}

.lh-empty {
    text-align: center;
    padding: 24px 10px;
    color: var(--lh-slate-light);
}

.lh-empty .icon {
    font-size: 2.5rem;
    margin-bottom: 10px;
    opacity: .5;
}

.lh-empty p {
    margin: 0;
    font-size: .85rem;
}

.lh-divider {
    border: 0;
    border-top: 1.5px dashed #f1f5f9;
    margin: 16px 0;
}

.lh-form-group {
    margin-bottom: 12px;
}

/* ===================== HUB TOAST ===================== */
.lh-toast {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(16px);
    background: rgba(15, 23, 42, .88);
    backdrop-filter: blur(8px);
    color: #fff;
    padding: 10px 22px;
    border-radius: 30px;
    font-family: 'Inter', sans-serif;
    font-size: .85rem;
    font-weight: 600;
    opacity: 0;
    pointer-events: none;
    transition: all .35s var(--lh-transition);
    z-index: 10001;
    white-space: nowrap;
}

.lh-toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* ===================== STREAK BADGE ===================== */
.lh-streak {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 16px;
    background: linear-gradient(135deg, #fef3c7, #fce7f3);
    border-radius: 30px;
    font-size: .8rem;
    font-weight: 700;
    color: var(--lh-amber);
    margin-bottom: 14px;
}

.lh-streak .fire {
    font-size: 1.1rem;
}