/* Members dashboard */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
    background: #080a0d;
    color: #fff;
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
}

/* Status bar under nav */
.mb-status {
    max-width: 1440px;
    margin: 0 auto;
    padding: 10px 5%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    font-size: 0.78rem;
    gap: 12px;
    flex-wrap: wrap;
}

.mb-status .who { color: rgba(255, 255, 255, 0.5); }
.mb-status .who strong { color: #fff; font-weight: 600; }

.mb-tier {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 100px;
    font-family: 'Orbitron', monospace;
    font-size: 0.58rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-left: 10px;
}

.mb-tier.free { background: rgba(255, 255, 255, 0.06); color: rgba(255, 255, 255, 0.55); }
.mb-tier.paid { background: rgba(212, 175, 55, 0.12); color: var(--gold); }
.mb-tier.premium { background: rgba(186, 104, 200, 0.15); color: #ba68c8; }

.mb-invites-wrap {
    margin-left: 14px;
    color: rgba(255,255,255,0.4);
}
.mb-invites-link {
    color: var(--gold);
    text-decoration: none;
    font-weight: 600;
}
.mb-invites-link:hover { text-decoration: underline; }

.mb-status-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logout-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    font-family: inherit;
    font-size: 0.78rem;
    padding: 4px 10px;
    transition: color 0.15s;
}

.logout-btn:hover { color: #f08888; }

/* Beta feedback bar */
.mb-feedback-bar {
    background: rgba(212, 175, 55, 0.08);
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    padding: 10px 5%;
    text-align: center;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.7);
}
.mb-feedback-bar strong { color: #fff; }
.mb-feedback-link {
    color: var(--gold);
    font-weight: 700;
    text-decoration: none;
    margin-left: 6px;
}
.mb-feedback-link:hover { text-decoration: underline; }

/* Upgrade prompt */
.mb-upgrade {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.15), rgba(212, 175, 55, 0.05));
    border: 1px solid rgba(212, 175, 55, 0.3);
    color: var(--gold);
    padding: 6px 14px;
    border-radius: 100px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
    transition: filter 0.15s, transform 0.15s;
    font-family: inherit;
}

.mb-upgrade:hover:not(:disabled) {
    filter: brightness(1.2);
    transform: translateY(-1px);
}

.mb-upgrade:disabled { opacity: 0.5; cursor: wait; }

/* Hero */
.mb-hero {
    max-width: 1440px;
    margin: 0 auto;
    padding: 48px 5% 20px;
}

.mb-eyebrow {
    font-family: 'Orbitron', monospace;
    font-size: 0.6rem;
    letter-spacing: 3px;
    color: rgba(212, 175, 55, 0.75);
    text-transform: uppercase;
    margin-bottom: 14px;
}

.mb-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(2.6rem, 5vw, 4.2rem);
    line-height: 1;
    letter-spacing: 2px;
    margin-bottom: 10px;
}

.mb-sub {
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.95rem;
    max-width: 560px;
    line-height: 1.6;
}

/* Post-upgrade success banner */
.mb-banner {
    max-width: 1440px;
    margin: 16px auto 0;
    padding: 14px 5%;
    background: rgba(120, 200, 120, 0.08);
    border: 1px solid rgba(120, 200, 120, 0.3);
    color: #88d888;
    border-radius: 0;
    font-size: 0.9rem;
    text-align: center;
    display: none;
}

/* Email verification warning banner */
.mb-verify-banner {
    max-width: 1440px;
    margin: 12px auto 0;
    padding: 0 5%;
}
.verify-inner {
    background: rgba(240, 200, 136, 0.08);
    border: 1px solid rgba(240, 200, 136, 0.3);
    color: #f0c888;
    border-radius: 10px;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}
.verify-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}
.verify-text {
    flex: 1;
    min-width: 240px;
    font-size: 0.88rem;
    line-height: 1.5;
}
.verify-text strong {
    display: block;
    color: #ffd97a;
    margin-bottom: 2px;
}
.verify-text span {
    color: rgba(240, 200, 136, 0.75);
    font-size: 0.82rem;
}
.verify-resend-btn {
    background: rgba(240, 200, 136, 0.15);
    border: 1px solid rgba(240, 200, 136, 0.4);
    color: #f0c888;
    padding: 7px 14px;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    font-family: inherit;
    flex-shrink: 0;
    transition: filter 0.15s;
}
.verify-resend-btn:hover:not(:disabled) { filter: brightness(1.2); }
.verify-resend-btn:disabled { opacity: 0.5; cursor: wait; }

/* Section */
.mb-section {
    max-width: 1440px;
    margin: 40px auto 0;
    padding: 0 5%;
}

.mb-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 18px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.mb-section-label {
    font-family: 'Orbitron', monospace;
    font-size: 0.58rem;
    letter-spacing: 3px;
    color: rgba(255, 255, 255, 0.3);
    text-transform: uppercase;
}

.mb-section-h {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.6rem;
    letter-spacing: 1.5px;
}

.mb-count {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.3);
}

/* Video grid */
.mb-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 18px;
    padding-bottom: 30px;
}

.v-card {
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    cursor: pointer;
    background: rgba(28, 31, 36, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                border-color 0.2s,
                box-shadow 0.3s;
}

.v-card:hover {
    transform: translateY(-4px);
    border-color: rgba(212, 175, 55, 0.3);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.v-card.locked { cursor: default; opacity: 0.6; }
.v-card.locked:hover {
    transform: none;
    border-color: rgba(255, 255, 255, 0.05);
    box-shadow: none;
}

.v-thumb {
    aspect-ratio: 16/9;
    background: #12141a;
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.v-thumb::after {
    content: "▶";
    position: absolute;
    color: rgba(255, 255, 255, 0.85);
    font-size: 2rem;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-left: 6px;
    transition: transform 0.2s, background 0.2s;
}

.v-card:not(.locked):hover .v-thumb::after {
    transform: scale(1.1);
    background: var(--gold);
    color: #000;
}

.v-card.locked .v-thumb::after {
    content: "🔒";
    padding-left: 0;
    background: rgba(0, 0, 0, 0.65);
    font-size: 1.4rem;
}

.v-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-family: 'Orbitron', monospace;
    letter-spacing: 1px;
}

.v-body { padding: 14px 16px 18px; }

.v-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 4px;
    line-height: 1.3;
}

.v-desc {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.45);
    line-height: 1.5;
}

.v-tier {
    display: inline-block;
    margin-top: 8px;
    padding: 2px 8px;
    border-radius: 100px;
    font-family: 'Orbitron', monospace;
    font-size: 0.54rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.v-tier.free { background: rgba(255, 255, 255, 0.06); color: rgba(255, 255, 255, 0.5); }
.v-tier.paid { background: rgba(212, 175, 55, 0.12); color: var(--gold); }
.v-tier.premium { background: rgba(186, 104, 200, 0.15); color: #ba68c8; }

/* Download row */
.d-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-bottom: 30px;
}

.d-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 20px;
    align-items: center;
    padding: 14px 18px;
    background: rgba(28, 31, 36, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    transition: border-color 0.15s;
}

.d-row:hover { border-color: rgba(212, 175, 55, 0.2); }
.d-row.locked { opacity: 0.5; }

.d-info { display: flex; flex-direction: column; gap: 3px; }
.d-title { font-size: 0.92rem; font-weight: 600; }
.d-meta { font-size: 0.74rem; color: rgba(255, 255, 255, 0.4); }

.d-btn {
    background: var(--gold);
    color: #000;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.72rem;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: filter 0.15s;
}

.d-btn:hover:not(.disabled) { filter: brightness(1.1); }

.d-btn.disabled {
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.4);
    cursor: not-allowed;
}

/* Empty state */
.mb-empty {
    padding: 40px 20px;
    text-align: center;
    color: rgba(255, 255, 255, 0.35);
    font-size: 0.88rem;
    border: 1px dashed rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    margin-bottom: 30px;
}

/* Loading */
.mb-loading {
    text-align: center;
    padding: 80px 20px;
    color: rgba(255, 255, 255, 0.3);
    font-family: 'Orbitron', monospace;
    font-size: 0.7rem;
    letter-spacing: 3px;
}

/* Video modal */
.v-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 20px;
}

.v-modal.open { display: flex; }

.v-modal-inner {
    width: 100%;
    max-width: 1100px;
    position: relative;
}

.v-modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1.4rem;
    cursor: pointer;
    padding: 8px 16px;
}

.v-modal-frame {
    aspect-ratio: 16/9;
    width: 100%;
    border-radius: 10px;
    overflow: hidden;
    background: #000;
}

.v-modal-frame iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* ─── Purchases & library list ─────────────────────────────────────────── */
.mb-purchases {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.purch-row {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    transition: border-color 0.2s, background 0.2s;
    flex-wrap: wrap;
}
.purch-row:hover {
    border-color: rgba(212, 175, 55, 0.25);
    background: rgba(255, 255, 255, 0.035);
}

.purch-main { flex: 1; min-width: 220px; }

.purch-title {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}
.purch-product {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.15rem;
    letter-spacing: 0.05em;
    color: #f0f0f0;
    text-transform: uppercase;
}

.purch-badge {
    display: inline-block;
    padding: 3px 9px;
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}
.purch-badge--paid {
    background: rgba(212, 175, 55, 0.15);
    color: #d4af37;
    border: 1px solid rgba(212, 175, 55, 0.4);
}
.purch-badge--free {
    background: rgba(120, 200, 120, 0.12);
    color: #88d888;
    border: 1px solid rgba(120, 200, 120, 0.35);
}
.purch-badge--revoked {
    background: rgba(239, 83, 80, 0.12);
    color: #ef5350;
    border: 1px solid rgba(239, 83, 80, 0.35);
}

.purch-meta {
    font-size: 0.78rem;
    color: rgba(220, 220, 220, 0.6);
    letter-spacing: 0.02em;
}
.purch-order {
    color: rgba(212, 175, 55, 0.7);
    font-family: monospace;
    margin-left: 6px;
}

.purch-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.purch-download-btn {
    display: inline-flex;
    align-items: center;
    background: #d4af37;
    color: #0a0a0a;
    padding: 7px 16px;
    border-radius: 4px;
    font-family: 'Inter', sans-serif;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
    border: 1px solid #d4af37;
    min-height: 32px;
}
.purch-download-btn:hover { background: #e5c65a; border-color: #e5c65a; }
.purch-download-btn:active { transform: translateY(1px); }
.purch-download-btn--mac { background: transparent; color: #d4af37; }
.purch-download-btn--mac:hover { background: #d4af37; color: #0a0a0a; }

.purch-serial-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.purch-serial-toggle {
    background: transparent;
    border: 1px solid rgba(212, 175, 55, 0.4);
    color: #d4af37;
    padding: 7px 14px;
    border-radius: 4px;
    font-family: 'Inter', sans-serif;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}
.purch-serial-toggle:hover {
    background: rgba(212, 175, 55, 0.1);
    border-color: #d4af37;
}

.purch-serial {
    font-family: monospace;
    font-size: 0.78rem;
    color: #d4af37;
    background: rgba(212, 175, 55, 0.08);
    padding: 7px 12px;
    border-radius: 4px;
    border: 1px solid rgba(212, 175, 55, 0.25);
    word-break: break-all;
    user-select: all;
    max-width: 260px;
}

.purch-serial-copy {
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.4);
    color: #d4af37;
    padding: 7px 12px;
    border-radius: 4px;
    font-family: 'Inter', sans-serif;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s;
}
.purch-serial-copy:hover { background: rgba(212, 175, 55, 0.25); }
.purch-serial-copy.copied {
    background: rgba(120, 200, 120, 0.18);
    border-color: rgba(120, 200, 120, 0.5);
    color: #88d888;
}

.purch-guide-links {
    flex-basis: 100%;
    display: flex;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    flex-wrap: wrap;
}

.purch-guide-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.38);
    padding: 5px 12px;
    border-radius: 4px;
    font-family: 'Inter', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.purch-guide-btn:hover {
    color: rgba(212, 175, 55, 0.85);
    border-color: rgba(212, 175, 55, 0.3);
    background: rgba(212, 175, 55, 0.05);
}

@media (max-width: 700px) {
    .purch-row { flex-direction: column; align-items: stretch; }
    .purch-actions { justify-content: flex-start; }
    .purch-serial { max-width: 100%; }
}

/* ─── Mobile responsive for the dashboard ─────────────────────────────
 * The auto-fill grid (minmax 280px) collapses to one column natively
 * once viewport drops below ~310px. The tweaks below tighten padding
 * and let section heads stack on narrow screens.
 */

@media (max-width: 720px) {
    .mb-hero { padding: 32px 5% 16px; }
    .mb-sub { font-size: 0.88rem; }
    .mb-section { margin-top: 28px; padding: 0 5%; }
    .mb-section-head {
        flex-wrap: wrap;
        gap: 4px 12px;
        align-items: flex-end;
    }
    .mb-section-h { font-size: 1.35rem; }
    .mb-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .verify-inner { padding: 12px 14px; gap: 10px; }
    .verify-text { min-width: 0; font-size: 0.84rem; }
    .verify-resend-btn { width: 100%; }
}
