/**
 * File: wp-content/plugins/ub-sports-trivia/assets/trivia.css
 * Version: 3.0.0
 * Changelog:
 *   3.0.0 - 2026-04-03 - Sequential step-through quiz UI. No sport tabs.
 *            One question shown at a time, progress bar, auto-advance.
 *            Removed sources footer. Matches gp- dark theme tokens.
 *   2.0.0 - 2026-04-03 - Triple-source engine UI.
 *   1.0.0 - 2026-04-03 - Initial.
 */

/* ── Inline card (used in blog post injection) ─────────────────────────── */
.ub-trivia-wrap {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 20px;
    margin: 32px 0;
}
.ub-trivia-wrap--compact { grid-template-columns: 1fr; margin: 0; }
@media(max-width:991px){ .ub-trivia-wrap{grid-template-columns:repeat(2,1fr);} }
@media(max-width:600px) { .ub-trivia-wrap{grid-template-columns:1fr;} }

.ub-trivia-card {
    background: var(--gp-secondary,#1a1a2e);
    border: 1px solid rgba(255,255,255,.06);
    border-radius: var(--gp-radius-lg,16px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform .2s ease, box-shadow .2s ease;
}
.ub-trivia-card:hover { transform: translateY(-3px); box-shadow: 0 10px 36px rgba(0,119,255,.12); }
.ub-trivia-card--compact { margin: 0; }
.ub-trivia-card__header {
    display: flex; align-items: center; gap: 8px;
    padding: 14px 18px;
    background: rgba(0,119,255,.07);
    border-bottom: 1px solid rgba(255,255,255,.05);
}
.ub-trivia-card__icon  { font-size: 20px; line-height: 1; }
.ub-trivia-card__badge {
    font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em;
    color: var(--gp-accent,#0077ff); background: rgba(0,119,255,.12);
    padding: 3px 9px; border-radius: 20px;
}
.ub-trivia-card__source { margin-left: auto; font-size: 10px; color: var(--gp-text-muted,#6b7280); }
.ub-trivia-card__body  { padding: 18px; flex: 1; display: flex; flex-direction: column; gap: 14px; }
.ub-trivia-card__question { font-size: 14px; font-weight: 600; color: var(--gp-white,#fff); line-height: 1.55; margin: 0; }
.ub-trivia-card__options  { display: flex; flex-direction: column; gap: 7px; }
.ub-trivia-card__option {
    width: 100%; padding: 9px 14px;
    background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.09);
    border-radius: var(--gp-radius-md,10px);
    color: var(--gp-white,#fff); font-size: 13px; font-weight: 500;
    text-align: left; cursor: pointer;
    transition: background .15s, border-color .15s, transform .1s;
    line-height: 1.4;
}
.ub-trivia-card__option:hover:not(:disabled) { background: rgba(0,119,255,.14); border-color: var(--gp-accent,#0077ff); transform: translateX(3px); }
.ub-trivia-card__option:disabled { cursor: not-allowed; opacity: .75; }
.ub-trivia-card__option.is-correct { background: rgba(16,185,129,.18); border-color: #10b981; color: #10b981; }
.ub-trivia-card__option.is-wrong   { background: rgba(230,57,70,.14);  border-color: #e63946; color: #e63946; }
.ub-trivia-card__option.is-reveal  { background: rgba(16,185,129,.10); border-color: #10b981; color: #10b981; }
.ub-trivia-card__result {
    padding: 10px 14px; border-radius: var(--gp-radius-md,10px);
    font-size: 13px; font-weight: 600; line-height: 1.4;
}
.ub-trivia-card__result.msg-correct { background: rgba(16,185,129,.14); color: #10b981; border: 1px solid rgba(16,185,129,.25); }
.ub-trivia-card__result.msg-wrong   { background: rgba(230,57,70,.10);  color: #e63946; border: 1px solid rgba(230,57,70,.22); }
.ub-trivia__empty { color: var(--gp-text-muted,#6b7280); text-align: center; padding: 24px; font-style: italic; }

/* ══════════════════════════════════════════════════════════════════════════
   SEQUENTIAL QUIZ  (homepage [ub_trivia_homepage])
   ══════════════════════════════════════════════════════════════════════════ */

.ubt-seq {
    font-family: system-ui, -apple-system, sans-serif;
    max-width: 680px;
    margin: 0 auto;
}

/* Header row: progress bar + counter */
.ubt-seq__head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 22px;
}
.ubt-seq__progress {
    flex: 1;
    height: 5px;
    background: rgba(255,255,255,.08);
    border-radius: 20px;
    overflow: hidden;
}
.ubt-seq__bar {
    height: 100%;
    background: linear-gradient(90deg, var(--gp-accent,#0077ff), #00c6ff);
    border-radius: 20px;
    transition: width .5s cubic-bezier(.4,0,.2,1);
}
.ubt-seq__counter {
    font-size: 11px;
    font-weight: 700;
    color: var(--gp-text-muted,#6b7280);
    white-space: nowrap;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.ubt-seq__counter span { color: var(--gp-accent,#0077ff); }

/* Slides wrapper */
.ubt-seq__slides {
    position: relative;
    min-height: 280px;
}

/* Individual slide */
.ubt-seq__slide {
    display: none;
    animation: ubt-slide-in .35s cubic-bezier(.4,0,.2,1);
}
.ubt-seq__slide.is-active { display: block; }
@keyframes ubt-slide-in {
    from { opacity: 0; transform: translateX(28px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* Card */
.ubt-seq__card {
    background: var(--c-card, #0d1826);
    border: 1px solid rgba(255,255,255,.07);
    border-radius: 16px;
    overflow: hidden;
}

/* Card header */
.ubt-seq__card-head {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 14px 20px;
    background: rgba(0,119,255,.07);
    border-bottom: 1px solid rgba(255,255,255,.05);
}
.ubt-seq__icon { font-size: 20px; line-height: 1; }
.ubt-seq__cat  {
    font-size: 10px; font-weight: 800; text-transform: uppercase;
    letter-spacing: .08em; color: var(--gp-accent,#0077ff);
    background: rgba(0,119,255,.12); padding: 3px 10px; border-radius: 20px;
}

/* Question */
.ubt-seq__question {
    padding: 22px 20px 18px;
    font-size: 15px;
    font-weight: 700;
    color: var(--c-whi,#fff);
    line-height: 1.55;
    margin: 0;
    border-bottom: 1px solid rgba(255,255,255,.05);
}

/* Options */
.ubt-seq__options {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 16px 20px;
}
.ubt-seq__opt {
    width: 100%;
    padding: 11px 16px;
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.09);
    border-radius: 10px;
    color: var(--c-text,rgba(255,255,255,.88));
    font-size: 14px;
    font-weight: 500;
    text-align: left;
    cursor: pointer;
    transition: background .15s, border-color .15s, transform .12s;
    line-height: 1.4;
}
.ubt-seq__opt:hover:not(:disabled) {
    background: rgba(0,119,255,.14);
    border-color: var(--gp-accent,#0077ff);
    transform: translateX(4px);
}
.ubt-seq__opt:disabled { cursor: not-allowed; opacity: .72; }
.ubt-seq__opt.is-correct { background: rgba(16,185,129,.18); border-color: #10b981; color: #10b981; }
.ubt-seq__opt.is-wrong   { background: rgba(230,57,70,.14);  border-color: #e63946; color: #e63946; }
.ubt-seq__opt.is-reveal  { background: rgba(16,185,129,.10); border-color: #10b981; color: #10b981; }

/* Result message */
.ubt-seq__result {
    margin: 0 20px 4px;
    padding: 11px 15px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.4;
}
.ubt-seq__result.msg-correct { background: rgba(16,185,129,.14); color: #10b981; border: 1px solid rgba(16,185,129,.25); }
.ubt-seq__result.msg-wrong   { background: rgba(230,57,70,.10);  color: #e63946; border: 1px solid rgba(230,57,70,.22); }

/* Next button */
.ubt-seq__next {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin: 12px 20px 20px;
    padding: 11px 22px;
    background: var(--gp-accent,#0077ff);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background .15s, transform .15s, box-shadow .15s;
    box-shadow: 0 4px 16px rgba(0,119,255,.28);
}
.ubt-seq__next:hover {
    background: #005ecb;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,119,255,.38);
}
.ubt-seq__next svg { transition: transform .15s; }
.ubt-seq__next:hover svg { transform: translateX(3px); }

/* Done state */
.ubt-seq__done {
    margin: 12px 20px 20px;
    padding: 14px 18px;
    background: rgba(16,185,129,.12);
    border: 1px solid rgba(16,185,129,.25);
    border-radius: 10px;
    color: #10b981;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
}

/* Post widget */
.ubt-post-widget {
    margin: 32px 0;
    padding: 20px;
    background: var(--gp-secondary,#1a1a2e);
    border: 1px solid rgba(0,119,255,.2);
    border-left: 4px solid var(--gp-accent,#0077ff);
    border-radius: 16px;
}
.ubt-post-widget__label {
    display: flex; align-items: center; gap: 8px;
    font-size: 13px; font-weight: 700; color: var(--gp-white,#fff);
    text-transform: uppercase; letter-spacing: .07em; margin-bottom: 14px;
}
.ubt-post-widget__source {
    margin-left: auto; font-size: 11px; color: var(--gp-text-muted,#6b7280);
    font-weight: 400; text-transform: none;
}
.ubt-post-widget .ub-trivia-card { box-shadow: none; border: 1px solid rgba(255,255,255,.05); }
.ubt-post-widget__note {
    font-size: 11px; color: var(--gp-text-muted,#6b7280);
    margin: 12px 0 0; text-align: center;
}
.ubt-post-widget__note a { color: var(--gp-accent,#0077ff); text-decoration: none; }
.ubt-post-widget__note a:hover { text-decoration: underline; }

/* Admin */
.ubt-admin { max-width: 1000px; }
.ubt-admin__version { font-size: 13px; color: #6b7280; font-weight: 400; margin-left: 8px; }
.ubt-admin__section-title { margin-top: 32px; border-bottom: 2px solid #0077ff; padding-bottom: 6px; }
.ubt-admin__stats { display: flex; gap: 12px; flex-wrap: wrap; margin: 16px 0 24px; }
.ubt-stat { background: #1a1a2e; border: 1px solid rgba(0,119,255,.25); border-radius: 10px; padding: 14px 20px; text-align: center; min-width: 110px; }
.ubt-stat__n { display: block; font-size: 22px; font-weight: 800; color: #0077ff; }
.ubt-stat__l { display: block; font-size: 11px; color: #6b7280; margin-top: 3px; }
.ubt-admin__actions { margin-bottom: 16px; }
