/* ── HERO ── */

.hero-float {
    position: absolute;
    pointer-events: none;
    opacity: .07;
    animation: floatUp linear infinite;
    user-select: none;
    font-size: clamp(1.6rem, 3vw, 3rem)
}

@keyframes floatUp {
    0% {
        transform: translateY(110vh) rotate(0deg);
        opacity: .04
    }

    60% {
        opacity: .1
    }

    100% {
        transform: translateY(-10vh) rotate(15deg);
        opacity: .04
    }
}

.hero-cloud {
    position: absolute;
    pointer-events: none;
    font-size: clamp(2rem, 4vw, 4rem);
    opacity: .06;
    animation: cloudDrift 20s linear infinite;
    user-select: none
}

@keyframes cloudDrift {
    0% {
        transform: translateX(-120px) translateY(0) rotate(0deg);
        opacity: .04
    }

    50% {
        opacity: .1
    }

    100% {
        transform: translateX(120vw) translateY(-60px) rotate(8deg);
        opacity: .04
    }
}

.rh-hero {
    min-height: 88vh;
    display: flex;
    align-items: center;
    background: var(--bg);
    position: relative;
    overflow: hidden;
    padding-top: 100px;
    padding-bottom: 60px;
}

.rh-hero-mesh {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background: radial-gradient(ellipse 80% 60% at 70% 20%, rgba(249, 115, 22, .10) 0%, transparent 60%), radial-gradient(ellipse 60% 50% at 10% 80%, rgba(168, 85, 247, .09) 0%, transparent 60%), radial-gradient(ellipse 50% 40% at 90% 85%, rgba(6, 182, 212, .07) 0%, transparent 60%);
    animation: meshFloat 12s ease-in-out infinite alternate;
}

@keyframes meshFloat {
    0% {
        transform: scale(1) rotate(0deg);
        opacity: .9
    }

    100% {
        transform: scale(1.04) rotate(1.5deg);
        opacity: 1
    }
}

.rh-hero-grid {
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: .035;
    background-image: linear-gradient(var(--text) 1px, transparent 1px), linear-gradient(90deg, var(--text) 1px, transparent 1px);
    background-size: 52px 52px;
}

.rh-orb {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(60px);
    opacity: .18;
}

.rh-orb-1 {
    width: 500px;
    height: 500px;
    top: -15%;
    right: -10%;
    background: linear-gradient(135deg, #f97316, #ec4899);
    animation: orbFloat1 10s ease-in-out infinite alternate;
}

.rh-orb-2 {
    width: 380px;
    height: 380px;
    bottom: -8%;
    left: -8%;
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    animation: orbFloat2 13s ease-in-out infinite alternate;
}

.rh-orb-3 {
    width: 260px;
    height: 260px;
    top: 50%;
    left: 45%;
    background: linear-gradient(135deg, #22c55e, #06b6d4);
    animation: orbFloat3 8s ease-in-out infinite alternate;
}

@keyframes orbFloat1 {
    0% {
        transform: translate(0, 0) scale(1)
    }

    100% {
        transform: translate(-30px, 25px) scale(1.08)
    }
}

@keyframes orbFloat2 {
    0% {
        transform: translate(0, 0) scale(1)
    }

    100% {
        transform: translate(20px, -20px) scale(1.05)
    }
}

@keyframes orbFloat3 {
    0% {
        transform: translate(0, 0) scale(1)
    }

    100% {
        transform: translate(-15px, 15px) scale(1.1)
    }
}

.rh-hero-inner {
    position: relative;
    z-index: 1;
    max-width: 860px;
    margin: 0 auto;
    text-align: center;
}

.rh-hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 20px;
    border-radius: 999px;
    border: 1px solid rgba(249, 115, 22, .28);
    background: rgba(249, 115, 22, .08);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 28px;
}

.rh-hero-eyebrow-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    animation: pulse 1.4s infinite;
}

.rh-hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.8rem, 7vw, 5.2rem);
    font-weight: 700;
    line-height: 1.06;
    color: var(--text);
    margin-bottom: 24px;
    letter-spacing: -.03em;
}

.rh-hero-sub {
    font-size: 1.12rem;
    color: var(--text2);
    line-height: 1.75;
    max-width: 620px;
    margin: 0 auto 40px;
}

.rh-hero-chips {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-bottom: 44px;
}

.rh-chip {
    padding: 8px 18px;
    border-radius: 999px;
    border: 1.5px solid var(--border);
    background: var(--bg-card);
    font-size: 13px;
    font-weight: 600;
    color: var(--text2);
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.rh-chip:hover,
.rh-chip.active {
    border-color: var(--accent);
    background: rgba(249, 115, 22, .08);
    color: var(--accent);
    transform: translateY(-2px);
}

.rh-hero-cta {
    display: flex;
    gap: 14px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 56px;
}

/* Stats bar */
.rh-stats-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.rh-stat {
    padding: 26px 20px;
    text-align: center;
    border-right: 1px solid var(--border);
    transition: background .2s;
}

.rh-stat:last-child {
    border-right: none;
}

.rh-stat:hover {
    background: var(--bg3);
}

.rh-stat-num {
    font-family: var(--font-display);
    font-size: 2.1rem;
    font-weight: 700;
    color: var(--accent);
    display: block;
    line-height: 1;
    margin-bottom: 6px;
}

.rh-stat-lbl {
    font-size: 13px;
    color: var(--text3);
    font-weight: 500;
}

/* ── Anchor strip ── */
.rh-anchor-strip {
    background: var(--bg2);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 72px;
    z-index: 50;
}

.rh-anchor-inner {
    display: flex;
    gap: 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.rh-anchor-inner::-webkit-scrollbar {
    display: none;
}

.rh-anchor-btn {
    flex-shrink: 0;
    padding: 16px 22px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text3);
    border: none;
    background: transparent;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all .2s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 7px;
    text-decoration: none;
}

.rh-anchor-btn:hover,
.rh-anchor-btn.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
    background: rgba(249, 115, 22, .04);
}

/* ── rh-card ── */
.rh-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
}

.rh-card:hover {
    transform: translateY(-8px);
    border-color: var(--border-h);
    box-shadow: var(--shadow-lg);
}

.rh-card-top-bar {
    height: 4px;
    background: var(--card-gradient, linear-gradient(90deg, #f97316, #ec4899));
}

.rh-card-body {
    padding: 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.rh-card-title {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px;
    line-height: 1.4;
}

.rh-card-desc {
    font-size: 13px;
    color: var(--text2);
    line-height: 1.7;
    margin-bottom: 16px;
    flex: 1;
}

/* Download link */
.rh-dl {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--accent);
    font-size: 13px;
    font-weight: 600;
    transition: var(--transition);
}

.rh-dl:hover {
    gap: 10px;
}

/* ── Question card (q-card) ── */
.q-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
}

.q-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-h);
    box-shadow: var(--shadow-lg);
}

.q-card-header {
    padding: 24px 24px 18px;
    border-bottom: 1px solid var(--border);
}

.q-num {
    font-family: var(--font-display);
    font-size: 2.6rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 4px;
}

.q-title {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 6px;
}

.q-desc {
    font-size: 13px;
    color: var(--text2);
    line-height: 1.65;
}

.q-card-body {
    padding: 18px 24px 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.q-meta {
    display: flex;
    gap: 14px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.q-meta span {
    font-size: 12px;
    color: var(--text3);
    display: flex;
    align-items: center;
    gap: 5px;
}

.q-preview {
    background: var(--bg2);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 16px;
}

.q-preview-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--text3);
    margin-bottom: 8px;
}

.q-preview-item {
    font-size: 13px;
    color: var(--text2);
    padding: 5px 0;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: flex-start;
    gap: 8px;
    line-height: 1.5;
}

.q-preview-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.q-num-badge {
    font-weight: 700;
    color: var(--accent);
    flex-shrink: 0;
    font-size: 13px;
}

.q-btns {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

/* ── Topic badge ── */
.topic-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 12px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
}

/* ── Section header ── */
/* Section divider */
.q-section-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px
}

.q-section-icon {
    font-size: 1.8rem
}

.q-section-label h3 {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text)
}

.q-section-label p {
    font-size: 13px;
    color: var(--text3)
}


.sec-head {
    text-align: center;
    max-width: 680px;
    margin: 0 auto 56px;
}

.sec-head h2 {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    color: var(--text);
    margin-bottom: 14px;
}

.sec-head p {
    font-size: 1rem;
    color: var(--text2);
    line-height: 1.7;
}

/* ── Topic grid ── */
.topic-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.topic-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 22px 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
    transition: var(--transition);
    cursor: pointer;
}

.topic-item:hover {
    border-color: var(--border-h);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.topic-icon {
    font-size: 2rem;
}

.topic-name {
    font-family: var(--font-display);
    font-size: .9rem;
    font-weight: 700;
    color: var(--text);
}

.topic-count {
    font-size: 12px;
    color: var(--text3);
}

/* ── Question list section ── */
.q-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.q-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 18px 22px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    transition: var(--transition);
}

.q-item:hover {
    border-color: var(--border-h);
    background: var(--bg3);
}

.q-item-num {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent);
    min-width: 36px;
    flex-shrink: 0;
}

.q-item-text {
    font-size: .94rem;
    color: var(--text2);
    line-height: 1.65;
    flex: 1;
}

.q-item-tag {
    flex-shrink: 0;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
}

.tag-basic {
    background: rgba(34, 197, 94, .12);
    color: #16a34a
}

.tag-medium {
    background: rgba(249, 115, 22, .12);
    color: #ea580c
}

.tag-advanced {
    background: rgba(168, 85, 247, .12);
    color: #9333ea
}

/* ── CTA Banner ── */
.cta-banner {
    border-radius: 24px;
    overflow: hidden;
    padding: 70px 60px;
    text-align: center;
    position: relative;
    background: linear-gradient(135deg, #f97316 0%, #ec4899 50%, #a855f7 100%);
}

.cta-banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 30% 50%, rgba(255, 255, 255, .15), transparent 60%);
    pointer-events: none;
}

.cta-content {
    position: relative;
    z-index: 1;
}

.cta-title {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    color: #fff;
    margin-bottom: 14px;
}

.cta-sub {
    font-size: 1rem;
    color: rgba(255, 255, 255, .85);
    margin-bottom: 32px;
    line-height: 1.7;
}

.cta-form {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-input {
    padding: 14px 20px;
    border-radius: var(--radius-lg);
    border: none;
    font-size: 14px;
    width: 280px;
    background: rgba(255, 255, 255, .2);
    color: #fff;
    backdrop-filter: blur(8px);
    outline: none;
}

.cta-input::placeholder {
    color: rgba(255, 255, 255, .65);
}

.cta-btn {
    padding: 14px 28px;
    border-radius: var(--radius-lg);
    border: none;
    background: #fff;
    color: #f97316;
    font-family: var(--font-display);
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .2);
}

/* ─── MCQ Quiz Engine ─── */
.quiz-controls {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 32px;
    padding: 20px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg)
}

.quiz-filter {
    display: flex;
    gap: 8px;
    flex-wrap: wrap
}

.filter-btn {
    padding: 7px 16px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .05em;
    border: 1.5px solid var(--border);
    background: transparent;
    color: var(--text3);
    cursor: pointer;
    transition: var(--transition)
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff
}

.reset-btn {
    padding: 7px 16px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .05em;
    border: 1.5px solid var(--border);
    background: transparent;
    color: var(--text3);
    cursor: pointer;
    transition: var(--transition)
}

.reset-btn:hover {
    background: #fff;
}

.quiz-meta {
    font-size: 13px;
    color: var(--text3);
    font-weight: 500
}

.quiz-score-bar {
    height: 5px;
    background: var(--bg3);
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 10px
}

.quiz-score-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #22c55e, #10b981);
    transition: width .6s var(--ease-out)
}

/* MCQ Card */
.mcq-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 28px 30px;
    margin-bottom: 16px;
    transition: var(--transition);
    position: relative;
    overflow: hidden
}

.mcq-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--accent);
    opacity: 0;
    transition: opacity .3s
}

.mcq-card.answered::before {
    opacity: 1
}

.mcq-card:hover {
    border-color: var(--border-h);
    box-shadow: var(--shadow-md)
}

.mcq-card.hidden {
    display: none
}

.mcq-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 20px
}

.mcq-num {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--accent);
    min-width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(245, 158, 11, .1);
    border: 1px solid rgba(245, 158, 11, .2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0
}

.mcq-question {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.55;
    flex: 1
}

.mcq-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 20px
}

.mcq-service-tag {
    padding: 3px 12px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
    background: rgba(245, 158, 11, .1);
    color: var(--accent);
    border: 1px solid rgba(245, 158, 11, .2)
}

.mcq-diff-tag {
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700
}

/* Options */
.mcq-options {
    display: flex;
    flex-direction: column;
    gap: 10px
}

.mcq-option {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 13px 18px;
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border);
    background: var(--bg3);
    cursor: pointer;
    transition: var(--transition);
    user-select: none
}

.mcq-option:hover:not(.disabled) {
    border-color: var(--accent);
    background: rgba(245, 158, 11, .07);
    transform: translateX(4px)
}

.mcq-option.selected {
    border-color: var(--accent);
    background: rgba(245, 158, 11, .1)
}

.mcq-option.correct {
    border-color: #22c55e;
    background: rgba(34, 197, 94, .1);
    animation: correctPop .4s var(--ease-spring)
}

.mcq-option.wrong {
    border-color: #ef4444;
    background: rgba(239, 68, 68, .09)
}

.mcq-option.reveal-correct {
    border-color: #22c55e;
    background: rgba(34, 197, 94, .07)
}

@keyframes correctPop {
    0% {
        transform: scale(.97)
    }

    60% {
        transform: scale(1.015)
    }

    100% {
        transform: scale(1)
    }
}

.mcq-option.disabled {
    cursor: not-allowed;
    pointer-events: none
}

.opt-letter {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    border: 1.5px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 12px;
    font-weight: 800;
    color: var(--text3);
    flex-shrink: 0;
    transition: var(--transition)
}

.mcq-option.correct .opt-letter {
    background: #22c55e;
    border-color: #22c55e;
    color: #fff
}

.mcq-option.wrong .opt-letter {
    background: #ef4444;
    border-color: #ef4444;
    color: #fff
}

.mcq-option.reveal-correct .opt-letter {
    background: rgba(34, 197, 94, .2);
    border-color: #22c55e;
    color: #22c55e
}

.mcq-option.selected .opt-letter {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff
}

.opt-text {
    font-size: .93rem;
    color: var(--text2);
    line-height: 1.5;
    flex: 1
}

.mcq-option.correct .opt-text,
.mcq-option.reveal-correct .opt-text {
    color: var(--text);
    font-weight: 600
}

.mcq-option.wrong .opt-text {
    color: var(--text)
}

/* Explanation box */
.mcq-explanation {
    margin-top: 16px;
    padding: 14px 18px;
    border-radius: var(--radius-md);
    background: rgba(59, 130, 246, .07);
    border: 1px solid rgba(59, 130, 246, .18);
    font-size: .88rem;
    color: var(--text2);
    line-height: 1.65;
    display: none
}

.mcq-explanation.show {
    display: block;
    animation: fadeSlide .3s var(--ease-out)
}

@keyframes fadeSlide {
    from {
        opacity: 0;
        transform: translateY(-6px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

.mcq-explanation strong {
    color: var(--accent-3)
}

.mcq-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid var(--border)
}

.mcq-hint {
    font-size: 12px;
    color: var(--text3)
}

.check-btn {
    padding: 8px 20px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    border: 1.5px solid var(--accent);
    background: transparent;
    color: var(--accent);
    transition: var(--transition)
}

.check-btn:hover {
    background: var(--accent);
    color: #fff
}

.check-btn:disabled {
    opacity: .4;
    cursor: not-allowed
}


/* Score dashboard */
.score-dashboard {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 32px;
    margin-bottom: 36px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    overflow: hidden
}

.score-cell {
    padding: 20px;
    text-align: center;
    border-right: 1px solid var(--border)
}

.score-cell:last-child {
    border-right: none
}

.score-cell-num {
    font-family: var(--font-display);
    font-size: 1.9rem;
    font-weight: 800;
    display: block;
    line-height: 1;
    margin-bottom: 4px
}

.score-cell-lbl {
    font-size: 12px;
    color: var(--text3);
    font-weight: 500
}

.score-correct {
    color: #22c55e
}

.score-wrong {
    color: #ef4444
}

.score-skip {
    color: var(--accent)
}

.score-total {
    color: var(--accent-3)
}

/* ── Other question banks ── */
.qb-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.qb-card:hover {
    transform: translateY(-8px);
    border-color: var(--border-h);
    box-shadow: var(--shadow-lg);
}

.qb-card-header {
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    position: relative;
}

.qb-card-body {
    padding: 20px 22px 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.qb-card-title {
    font-family: var(--font-display);
    font-size: .98rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 6px;
}

.qb-card-meta {
    font-size: 12px;
    color: var(--text3);
    margin-bottom: 14px;
}

.qb-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 18px;
    flex: 1;
}

.qb-tag {
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 600;
    background: var(--bg2);
    border: 1px solid var(--border);
    color: var(--text3);
}

/* Inline download nudge box */
.dl-nudge {
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 36px;
    text-align: center;
    margin-top: 40px
}

.dl-nudge h3 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px
}

.dl-nudge p {
    font-size: 14px;
    color: var(--text2);
    margin-bottom: 20px
}

/* ── Download modal ── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .65);
    backdrop-filter: blur(6px);
    z-index: 9000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s;
}

.modal-overlay.open {
    opacity: 1;
    pointer-events: all;
}

.modal-box {
    background: var(--bg2);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 40px 36px;
    max-width: 480px;
    width: 100%;
    position: relative;
    transform: translateY(20px) scale(.97);
    transition: transform .35s var(--ease-out);
    box-shadow: var(--shadow-lg);
}

.modal-overlay.open .modal-box {
    transform: translateY(0) scale(1);
}

.modal-close {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--bg-glass);
    color: var(--text2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.modal-title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 6px;
}

.modal-sub {
    font-size: 14px;
    color: var(--text2);
    margin-bottom: 28px;
    line-height: 1.6;
}

.modal-field {
    margin-bottom: 18px;
}

.modal-label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: var(--text3);
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 8px;
}

.modal-input {
    width: 100%;
    padding: 13px 16px;
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border);
    background: var(--bg3);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 14px;
    transition: border-color .2s;
    outline: none;
}

.modal-input:focus {
    border-color: var(--accent);
}

.modal-select {
    width: 100%;
    padding: 13px 16px;
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border);
    background: var(--bg3);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 14px;
    transition: border-color .2s;
    outline: none;
    cursor: pointer;
}

.modal-select:focus {
    border-color: var(--accent);
}

.modal-btn {
    width: 100%;
    padding: 16px;
    border-radius: var(--radius-lg);
    border: none;
    background: linear-gradient(135deg, #f97316, #ec4899);
    color: #fff;
    font-family: var(--font-display);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    margin-top: 8px;
}

.modal-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 36px rgba(249, 115, 22, .4);
}

.modal-btn:disabled {
    opacity: .6;
    cursor: not-allowed;
    transform: none;
}

.modal-success {
    display: none;
    text-align: center;
}

.modal-success.show {
    display: block;
}

.success-icon {
    font-size: 3.5rem;
    margin-bottom: 16px;
}

.success-title {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 10px;
}

.success-sub {
    font-size: 14px;
    color: var(--text2);
    line-height: 1.7;
    margin-bottom: 24px;
}

.modal-form-wrap {
    transition: opacity .3s;
}

.modal-form-wrap.hide {
    opacity: 0;
    pointer-events: none;
    display: none;
}

/* ── Responsive ── */
@media (max-width:1024px) {
    .rh-stats-bar {
        grid-template-columns: repeat(2, 1fr);
    }

    .rh-stats-bar .rh-stat:nth-child(2) {
        border-right: none;
    }

    .rh-stats-bar .rh-stat:nth-child(3) {
        border-top: 1px solid var(--border);
    }

    .topic-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width:900px) {
    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }

    .topic-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width:768px) {
    .rh-hero {
        min-height: auto;
    }

    .grid-2 {
        grid-template-columns: 1fr;
    }

    .grid-3 {
        grid-template-columns: 1fr;
    }

    .topic-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .rh-stats-bar {
        grid-template-columns: 1fr 1fr;
    }

    .cta-banner {
        padding: 44px 24px;
    }

    .modal-box {
        padding: 28px 20px;
    }
}

@media (max-width:480px) {
    .topic-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}