/* ============================================================
   guest-demo.css — 遊客體驗版投放頁專屬樣式
   只補這頁特有的元件（遊客 topbar / badge / 註冊彈窗）；
   按鈕沿用 base.css 的 .btn 家族。
   ============================================================ */

/* ─── 遊客 topbar ─── */
.guest-topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-4);
    min-height: 72px;
    padding: var(--sp-3) var(--sp-6);
    background: var(--bg-surface);
    border-bottom: 1.5px solid var(--c-ink);
    box-shadow: 0 2px 0 rgba(0, 0, 0, 0.04);
}
[data-theme="dark"] .guest-topbar {
    border-bottom-color: var(--border-strong);
}

.guest-topbar__brand {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-3);
    font-size: var(--fs-md);
    font-weight: var(--fw-extra);
    color: var(--c-ink);
    letter-spacing: -0.02em;
    text-decoration: none;
}

.guest-topbar__actions {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
}

/* ─── 遊客瀏覽導覽列（三個 demo 頁；讓遊客像用戶一樣隨意切換）─── */
.guest-nav {
    display: flex;
    align-items: center;
    gap: var(--sp-1);
}
.guest-nav__link {
    padding: 8px 14px;
    border-radius: var(--radius-md);
    font-size: var(--fs-sm);
    font-weight: var(--fw-semibold);
    color: var(--text-secondary);
    text-decoration: none;
    white-space: nowrap;
    transition: background-color var(--t-fast), color var(--t-fast);
}
.guest-nav__link:hover { background: var(--bg-elevated); color: var(--c-ink); }
.guest-nav__link.is-active { background: var(--bg-elevated); color: var(--c-ink); font-weight: var(--fw-extra); }

/* ─── 體驗模式 badge ─── */
.guest-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    background: var(--c-yellow);
    color: var(--text-on-yellow);
    border: 1.5px solid var(--c-ink);
    border-radius: var(--radius-pill);
    font-size: var(--fs-xs);
    font-weight: var(--fw-bold);
    letter-spacing: 0.02em;
    white-space: nowrap;
    box-shadow: 2px 2px 0 var(--c-ink);
}
[data-theme="dark"] .guest-badge {
    border-color: var(--c-yellow);
    box-shadow: 2px 2px 0 rgba(var(--c-yellow-rgb), 0.35);
}

/* ─── 註冊彈窗 ─── */
.guest-modal[hidden] { display: none; }
.guest-modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--sp-5);
}

.guest-modal__scrim {
    position: absolute;
    inset: 0;
    background: rgba(10, 15, 31, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

.guest-modal__panel {
    position: relative;
    width: 100%;
    max-width: 440px;
    background: var(--bg-surface);
    border: 1.5px solid var(--c-ink);
    border-radius: var(--radius-2xl);
    padding: var(--sp-6);
    box-shadow: 8px 8px 0 var(--c-ink);
    text-align: center;
    animation: guestModalIn 260ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
[data-theme="dark"] .guest-modal__panel {
    border-color: var(--border-strong);
    box-shadow: 8px 8px 0 rgba(var(--c-yellow-rgb), 0.25);
}
@keyframes guestModalIn {
    from { opacity: 0; transform: translateY(10px) scale(0.98); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.guest-modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: var(--radius-pill);
    font-size: 26px;
    line-height: 1;
    color: var(--text-tertiary);
    cursor: pointer;
    transition: all var(--t-fast);
}
.guest-modal__close:hover {
    background: var(--c-cream-deep);
    color: var(--c-pink);
}

.guest-modal__title {
    font-size: var(--fs-lg);
    font-weight: var(--fw-extra);
    color: var(--c-ink);
    letter-spacing: -0.02em;
    margin: var(--sp-2) 0 var(--sp-3);
}

.guest-modal__body {
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    line-height: 1.7;
    margin: 0 auto var(--sp-5);
    max-width: 34ch;
}

.guest-modal__actions {
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
}
.guest-modal__actions .btn { width: 100%; }

/* 窄螢幕：topbar 換行，導覽列移到第二列、置中可橫向捲動（不擠壓品牌/按鈕）*/
@media (max-width: 900px) {
    .guest-topbar { flex-wrap: wrap; }
    .guest-nav { order: 3; width: 100%; justify-content: center; overflow-x: auto; }
}

@media (max-width: 480px) {
    .guest-topbar { padding: var(--sp-3) var(--sp-4); }
    .guest-topbar__brand .guest-badge { display: none; }
    .guest-modal__panel { padding: var(--sp-5); box-shadow: 6px 6px 0 var(--c-ink); }
}
