/**
 * Campaign Wizard Styles
 * 4-step campaign creation wizard for Casino Promo Portal
 */

/* -----------------------------------------------------------------------
   CSS Custom Properties
   ----------------------------------------------------------------------- */
:root {
    --cw-primary: #4e73df;
    --cw-primary-light: #eef1fb;
    --cw-secondary: #198754;
    --cw-secondary-light: #d1e7dd;
    --cw-danger: #e74a3b;
    --cw-warning: #f6c23e;
    --cw-gray-100: #f8f9fc;
    --cw-gray-200: #eaecf4;
    --cw-gray-500: #b7b9cc;
    --cw-gray-700: #5a5c69;
    --cw-radius: 0.5rem;
    --cw-radius-lg: 0.75rem;
    --cw-shadow: 0 0.15rem 1.75rem rgba(58, 59, 69, 0.1);
    --cw-transition: 0.25s ease;
}

/* -----------------------------------------------------------------------
   Step Indicator Bar
   ----------------------------------------------------------------------- */
.wizard-steps-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem 1rem;
    margin-bottom: 1.5rem;
    gap: 0;
}

.step-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background: var(--cw-gray-200);
    color: var(--cw-gray-500);
    font-weight: 600;
    font-size: 0.95rem;
    border: 2px solid var(--cw-gray-200);
    transition: all var(--cw-transition);
    position: relative;
    cursor: default;
    flex-shrink: 0;
}

.step-indicator.active {
    background: var(--cw-primary);
    border-color: var(--cw-primary);
    color: #fff;
    box-shadow: 0 0 0 4px var(--cw-primary-light);
}

.step-indicator.completed {
    background: #198754;
    border-color: #198754;
    color: #fff;
}

.step-connector {
    flex: 1;
    height: 3px;
    max-width: 6rem;
    background: var(--cw-gray-200);
    transition: background var(--cw-transition);
}

.step-connector.completed {
    background: #198754;
}

.step-label {
    display: block;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-top: 0.4rem;
    font-size: 0.75rem;
    color: var(--cw-gray-700);
    white-space: nowrap;
    font-weight: 500;
}

.step-indicator.active .step-label {
    color: var(--cw-primary);
    font-weight: 600;
}

.step-indicator.completed .step-label {
    color: #198754;
}

/* Clickable step indicators in edit mode */
.wizard-steps-bar.is-edit-mode .step-indicator:not(.active) {
    cursor: pointer;
}
.wizard-steps-bar.is-edit-mode .step-indicator:not(.active):hover {
    background: var(--cw-primary-light);
    border-color: var(--cw-primary);
    color: var(--cw-primary);
}
.wizard-steps-bar.is-edit-mode .step-indicator:not(.active):focus {
    outline: 2px solid var(--cw-primary);
    outline-offset: 2px;
}

/* Issue count sub-label below the step name */
.step-issue-count {
    display: block;
    font-size: 0.58rem;
    font-weight: 600;
    color: var(--cw-danger);
    margin-top: 0.1rem;
    text-align: center;
    white-space: nowrap;
    line-height: 1.3;
    letter-spacing: 0.01em;
}

.step-issue-count:empty {
    display: none;
}

/* Cross-step attention bar */
.cw-attention-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.4rem 0.6rem;
    padding: 0.45rem 0.85rem;
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-radius: var(--cw-radius);
    font-size: 0.8rem;
    color: #92400e;
    margin-bottom: 0.75rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    position: sticky;
    top: 64px;
    z-index: 9;
}

.cw-attention-bar > i {
    color: #d97706;
    font-size: 1rem;
    flex-shrink: 0;
}

.cw-attention-bar #cwAttentionText {
    font-weight: 500;
}

.cw-attention-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
}

.cw-attention-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.15rem 0.55rem;
    border-radius: 2rem;
    font-size: 0.72rem;
    font-weight: 600;
    background: rgba(0,0,0,0.07);
    color: #92400e;
    border: 1px solid rgba(0,0,0,0.1);
    cursor: pointer;
    transition: background var(--cw-transition);
    line-height: 1.5;
}

.cw-attention-pill:hover,
.cw-attention-pill:focus-visible {
    background: rgba(0,0,0,0.14);
    outline: 2px solid #d97706;
    outline-offset: 1px;
    color: #78350f;
}

/* Step status badge — green check (pass) or red count (issues) */
.step-status-badge {
    position: absolute;
    top: -0.3rem;
    right: -0.3rem;
    min-width: 1.1rem;
    height: 1.1rem;
    border-radius: 0.65rem;
    font-size: 0.6rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 0.18rem;
    border: 2px solid #fff;
    opacity: 0;
    transform: scale(0);
    transition: opacity 0.2s ease, transform 0.2s ease;
    pointer-events: none;
    line-height: 1;
    z-index: 2;
}

.step-status-badge.badge-pass {
    background: #198754;
    color: #fff;
    opacity: 1;
    transform: scale(1);
}

.step-status-badge.badge-fail {
    background: var(--cw-danger);
    color: #fff;
    opacity: 1;
    transform: scale(1);
    min-width: 1.25rem;
}

/* -----------------------------------------------------------------------
   Wizard Steps Content
   ----------------------------------------------------------------------- */
.wizard-step {
    display: none;
}

.wizard-step.active {
    display: block;
    animation: cwFadeIn 0.3s ease;
}

@keyframes cwFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.wizard-step-body {
    padding: 1rem 0;
}

/* -----------------------------------------------------------------------
   Type Selection Cards
   ----------------------------------------------------------------------- */
.type-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
}

.type-card {
    border: 2px solid var(--cw-gray-200);
    border-radius: var(--cw-radius-lg);
    padding: 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all var(--cw-transition);
    background: #fff;
    position: relative;
}

.type-card:hover:not(.disabled) {
    border-color: var(--cw-primary);
    box-shadow: var(--cw-shadow);
    transform: translateY(-2px);
}

.type-card.selected {
    border-color: var(--cw-primary);
    background: var(--cw-primary-light);
    box-shadow: 0 0 0 3px rgba(78, 115, 223, 0.2);
}

.type-card .type-icon {
    font-size: 2.25rem;
    color: var(--cw-primary);
    margin-bottom: 0.75rem;
}

.type-card.selected .type-icon {
    color: var(--cw-primary);
}

.type-card .type-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.type-card .type-desc {
    font-size: 0.85rem;
    color: var(--cw-gray-700);
}

/* Sports card disabled overlay */
.type-card.disabled {
    cursor: not-allowed;
    opacity: 0.55;
    position: relative;
}

.type-card.disabled::after {
    content: "Coming Soon";
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: var(--cw-gray-700);
    color: #fff;
    padding: 0.15rem 0.5rem;
    border-radius: 2rem;
}

.type-card.disabled:hover {
    transform: none;
    box-shadow: none;
    border-color: var(--cw-gray-200);
}

/* When editing an existing campaign the type cannot be changed */
#campaignTypeCards.types-locked .type-card {
    pointer-events: none;
    cursor: default;
}
#campaignTypeCards.types-locked .type-card:not(.selected) {
    opacity: 0.35;
}
#campaignTypeCards.types-locked .type-card.disabled::after {
    display: none;
}

/* Campaign Type Cards - Equal Height (Bootstrap Grid Override) */
#campaignTypeCards .col-md-3 {
    display: flex !important;
}

#campaignTypeCards .type-card {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 255px !important;
}

#campaignTypeCards .type-card .card-body {
    flex: 1 1 auto !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
}

/* Sub-options for type */
.type-sub-options {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--cw-gray-100);
    border-radius: var(--cw-radius);
}

/* -----------------------------------------------------------------------
   Theme Thumbnail Cards
   ----------------------------------------------------------------------- */
.theme-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.75rem;
}

.theme-card {
    border: 2px solid var(--cw-gray-200);
    border-radius: var(--cw-radius);
    overflow: hidden;
    cursor: pointer;
    transition: all var(--cw-transition);
    background: #fff;
}

.theme-card:hover {
    border-color: var(--cw-primary);
    box-shadow: 0 2px 8px rgba(78, 115, 223, 0.15);
}

.theme-card.selected {
    border-color: var(--cw-primary);
    box-shadow: 0 0 0 3px rgba(78, 115, 223, 0.2);
}

.theme-card .theme-thumb {
    width: 100%;
    height: 80px;
    object-fit: cover;
    display: block;
}

.theme-card .theme-name {
    padding: 0.4rem 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    text-align: center;
}

.theme-card.selected .theme-name {
    color: var(--cw-primary);
}

.btn-theme-preview {
    min-width: 86px;
}

#btnPreviewComingSoonPage {
    font-weight: 700;
}

#btnPreviewThankYouPage {
    font-weight: 700;
}

/* -----------------------------------------------------------------------
   Theme Preview Modal
   ----------------------------------------------------------------------- */
#themePreviewCanvas {
    border: 1px solid var(--cw-gray-200);
    border-radius: var(--cw-radius-lg);
    overflow: hidden;
    background: #fff;
}

#comingSoonPreviewCanvas {
    border: 1px solid var(--cw-gray-200);
    border-radius: var(--cw-radius-lg);
    overflow: hidden;
    background: #fff;
}

#thankYouPreviewCanvas {
    border: 1px solid var(--cw-gray-200);
    border-radius: var(--cw-radius-lg);
    overflow: hidden;
    background: #fff;
}

.cw-theme-preview {
    min-height: 620px;
    display: flex;
    flex-direction: column;
    background: #f5f7fb;
    color: #1f2a3a;
}

.cw-preview-header {
    padding: 1.4rem 1.25rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.cw-preview-header-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
}

.cw-preview-header-inner--split {
    min-height: 130px;
    width: 100%;
    flex-direction: row;
    align-items: stretch;
    gap: 0;
}

.cw-preview-split-left,
.cw-preview-split-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.cw-preview-split-title {
    color: #fff;
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
}

.cw-preview-logo {
    max-height: 135px;
    width: auto;
}

/* Football program logo — never gets the white/dark filters applied to org logos */
.cw-preview-football-logo {
    max-height: 120px;
    width: auto;
    flex-shrink: 0;
}

/* Side-by-side org + football logos */
.cw-preview-dual-logo {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
}

/* Split-header right panel: football logo fills the panel height */
.cw-preview--split_header .cw-preview-split-right .cw-preview-football-logo {
    max-height: 100px;
}

.cw-preview-logo-placeholder {
    width: 108px;
    height: 46px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    font-size: 0.8rem;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, var(--cw-preview-primary), var(--cw-preview-secondary));
}

.cw-preview-title {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 700;
}

.cw-preview-middle {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.8rem;
}

.cw-preview-page-content {
    width: min(94%, 760px);
    background: #fff;
    border-radius: 16px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 12px 30px rgba(24, 39, 75, 0.12);
    padding: 1.4rem;
}

.cw-preview-page-content a,
.cw-preview-page-content a:visited,
.cw-preview-page-content a:hover,
.cw-preview-page-content a:active {
    color: var(--cw-preview-secondary);
}

.cw-preview-content-card {
    width: min(92%, 560px);
    background: #fff;
    border-radius: 16px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 12px 30px rgba(24, 39, 75, 0.12);
    padding: 1.25rem 1.3rem;
}

.cw-preview-kicker {
    margin: 0 0 0.2rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.72rem;
    color: #6f7f97;
    font-weight: 700;
}

.cw-preview-content-card h4 {
    margin: 0 0 0.45rem;
    font-size: 1.12rem;
}

.cw-preview-content-card p {
    margin: 0;
    color: #566277;
}

.cw-preview-sample-lines {
    margin-top: 1rem;
    display: grid;
    gap: 0.5rem;
}

.cw-preview-sample-lines span {
    height: 8px;
    border-radius: 999px;
    background: rgba(69, 89, 120, 0.18);
}

.cw-preview-sample-lines span:nth-child(2) {
    width: 78%;
}

.cw-preview-sample-lines span:nth-child(3) {
    width: 64%;
}

.cw-preview-footer {
    margin-top: auto;
    padding: 0.9rem 1.2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    background: #fff;
}

.cw-preview-footer-inner {
    text-align: center;
}

.cw-preview-footer-inner img {
    max-height: 56px;
    width: auto;
}

.cw-preview-footer-inner p {
    margin: 0;
}

.cw-preview--light_classic {
    background: linear-gradient(180deg, #f8fbff 0%, #f5f7fb 44%);
}

.cw-preview--light_classic .cw-preview-header {
    background: linear-gradient(135deg, var(--cw-preview-primary) 0%, var(--cw-preview-secondary) 100%);
    border-bottom: none;
    box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.18);
}

.cw-preview--light_classic .cw-preview-logo,
.cw-preview--light_classic .cw-preview-logo-placeholder {
    background: rgba(255, 255, 255, 0.94);
    border-radius: 18px;
    padding: 10px 18px;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.14);
}

.cw-preview--light_classic .cw-preview-content-card {
    border-top: 4px solid var(--cw-preview-primary);
}

.cw-preview--dark_overlay {
    background:
        radial-gradient(circle at top left, var(--cw-preview-primary) 0%, transparent 42%),
        linear-gradient(140deg, #1b2537 0%, #101827 72%);
    color: #eef4ff;
}

.cw-preview--dark_overlay .cw-preview-title,
.cw-preview--dark_overlay .cw-preview-content-card h4 {
    color: #ffffff;
}

.cw-preview--dark_overlay .cw-preview-header {
    background:
        linear-gradient(135deg, rgba(8, 13, 20, 0.68) 0%, rgba(13, 22, 36, 0.88) 100%),
        var(--cw-preview-primary);
    border-bottom-color: rgba(255, 255, 255, 0.12);
}

.cw-preview--dark_overlay .cw-preview-content-card {
    background:
        linear-gradient(160deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.02) 100%),
        rgba(20, 30, 46, 0.82);
    border-color: rgba(255, 255, 255, 0.16);
    box-shadow: 0 18px 34px rgba(4, 8, 14, 0.3);
    color: #e9f0ff;
}

.cw-preview--dark_overlay .cw-preview-content-card p,
.cw-preview--dark_overlay .cw-preview-kicker {
    color: #dce8fb;
}

.cw-preview--dark_overlay .cw-preview-sample-lines span {
    background: rgba(220, 232, 251, 0.28);
}

.cw-preview--dark_overlay .cw-preview-footer {
    background:
        linear-gradient(90deg, rgba(9, 14, 22, 0.9) 0%, rgba(9, 14, 22, 0.9) 72%, var(--cw-preview-secondary) 140%);
    border-top-color: rgba(255, 255, 255, 0.12);
}

.cw-preview--dark_overlay .cw-preview-footer-inner,
.cw-preview--dark_overlay .cw-preview-footer-inner p,
.cw-preview--dark_overlay .cw-preview-footer-inner span,
.cw-preview--dark_overlay .cw-preview-footer-inner div,
.cw-preview--dark_overlay .cw-preview-footer-inner a {
    color: #eef4ff;
}

.cw-preview--dark_overlay .cw-preview-footer-inner img {
    filter: brightness(1.04);
}

.cw-preview--dark_overlay a,
.cw-preview--dark_overlay a:visited {
    color: var(--cw-preview-secondary);
}

.cw-preview--dark_overlay a:hover,
.cw-preview--dark_overlay a:active {
    color: var(--cw-preview-secondary);
    opacity: 0.82;
}

.cw-preview--split_header .cw-preview-header {
    padding: 0;
    background: linear-gradient(90deg, var(--cw-preview-primary) 0%, var(--cw-preview-primary) 52%, var(--cw-preview-secondary) 52%, var(--cw-preview-secondary) 100%);
}

.cw-preview--split_header .cw-preview-header-inner {
    min-height: 130px;
}

.cw-preview--split_header .cw-preview-logo {
    filter: brightness(0) invert(1);
}

.cw-preview--hero_banner .cw-preview-header {
    border-bottom: 0;
    background:
        linear-gradient(rgba(13, 28, 52, 0.52), rgba(13, 28, 52, 0.58)),
        linear-gradient(120deg, var(--cw-preview-primary) 0%, var(--cw-preview-secondary) 100%);
    min-height: 178px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cw-preview--hero_banner .cw-preview-title {
    color: #fff;
    font-size: 1.35rem;
}

.cw-preview--hero_banner .cw-preview-logo {
    filter: brightness(0) invert(1);
}

/* -----------------------------------------------------------------------
   Football Theme Previews (modal) — green / grass tailored
   ----------------------------------------------------------------------- */
.cw-preview--gridiron .cw-preview-header {
    background:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.18) 0 2px, transparent 2px 60px),
        linear-gradient(135deg, var(--cw-preview-primary) 0%, var(--cw-preview-secondary) 100%);
    border-top: 4px solid rgba(255, 255, 255, 0.85);
    border-bottom: 4px solid rgba(255, 255, 255, 0.85);
}
.cw-preview--gridiron {
    background: #eaf3ea;
}
.cw-preview--gridiron .cw-preview-content-card {
    border-top: 5px solid var(--cw-preview-primary);
    border-radius: 14px;
}

.cw-preview--end_zone .cw-preview-header {
    background:
        linear-gradient(115deg, transparent 0%, transparent 64%, rgba(255, 255, 255, 0.20) 64%, rgba(255, 255, 255, 0.20) 71%, transparent 71%),
        linear-gradient(135deg, var(--cw-preview-secondary) 0%, var(--cw-preview-primary) 70%);
    border-bottom: 6px solid var(--cw-preview-secondary);
}
.cw-preview--end_zone {
    background: #f2f6ee;
}
.cw-preview--end_zone .cw-preview-content-card {
    border-left: 6px solid var(--cw-preview-primary);
    border-radius: 12px;
}

.cw-preview--kickoff .cw-preview-header {
    background: linear-gradient(160deg, var(--cw-preview-primary) 0%, var(--cw-preview-secondary) 100%);
    border-radius: 0 0 26px 26px;
}
.cw-preview--kickoff {
    background: #f6faf6;
}
.cw-preview--kickoff .cw-preview-content-card {
    border-radius: 18px;
}

.cw-preview--stadium_lights {
    background: #081210;
    color: #e8f3ea;
}
.cw-preview--stadium_lights .cw-preview-header {
    background:
        radial-gradient(circle at 50% -10%, rgba(140, 240, 170, 0.34) 0%, transparent 55%),
        radial-gradient(circle at top left, var(--cw-preview-primary) 0%, transparent 46%),
        linear-gradient(135deg, rgba(6, 16, 12, 0.94) 0%, rgba(10, 26, 18, 0.96) 60%, rgba(5, 13, 10, 0.97) 100%);
    border-bottom: 1px solid rgba(120, 220, 150, 0.18);
}
.cw-preview--stadium_lights .cw-preview-title,
.cw-preview--stadium_lights .cw-preview-content-card h4 {
    color: #ffffff;
}
.cw-preview--stadium_lights .cw-preview-content-card {
    background:
        linear-gradient(160deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.02) 100%),
        rgba(12, 28, 20, 0.86);
    border-color: rgba(120, 220, 150, 0.18);
    border-radius: 16px;
    color: #e8f3ea;
}
.cw-preview--stadium_lights .cw-preview-content-card p,
.cw-preview--stadium_lights .cw-preview-kicker {
    color: #b6d4bf;
}
.cw-preview--stadium_lights .cw-preview-logo {
    filter: drop-shadow(0 0 16px rgba(130, 240, 165, 0.45));
}

/* -----------------------------------------------------------------------
   Red / White & Blue (USA) Theme Previews (modal)
   ----------------------------------------------------------------------- */
.cw-preview--star_spangled {
    background: #f5f7fc;
}
.cw-preview--star_spangled .cw-preview-header {
    background:
        radial-gradient(circle at 12% 28%, rgba(255, 255, 255, 0.88) 0 2px, transparent 3px),
        radial-gradient(circle at 22% 56%, rgba(255, 255, 255, 0.82) 0 2px, transparent 3px),
        radial-gradient(circle at 14% 80%, rgba(255, 255, 255, 0.8) 0 2px, transparent 3px),
        radial-gradient(circle at 30% 38%, rgba(255, 255, 255, 0.75) 0 2px, transparent 3px),
        repeating-linear-gradient(to right, var(--cw-preview-primary, #b22234) 0 14px, #ffffff 14px 28px) right center / 32% 100% no-repeat,
        linear-gradient(135deg, var(--cw-preview-secondary, #0a3161) 0%, #0a1f3d 100%);
    border-top: 5px solid var(--cw-preview-primary, #b22234);
    border-bottom: 5px solid #ffffff;
}
.cw-preview--star_spangled .cw-preview-title {
    color: #ffffff;
}
.cw-preview--star_spangled .cw-preview-content-card {
    border-top: 5px solid var(--cw-preview-primary, #b22234);
    border-radius: 12px;
}
/* Logo readability plate — float logo(s) on a light card over the busy header */
.cw-preview--star_spangled .cw-preview-dual-logo,
.cw-preview--old_glory .cw-preview-dual-logo,
.cw-preview--star_spangled .cw-preview-header-inner > .cw-preview-logo,
.cw-preview--old_glory .cw-preview-header-inner > .cw-preview-logo {
    background: rgba(255, 255, 255, 0.96);
    border-radius: 16px;
    padding: 12px 18px;
    box-shadow: 0 12px 26px rgba(8, 18, 38, 0.4);
}

.cw-preview--red_zone {
    background: #fdf3f4;
}
.cw-preview--red_zone .cw-preview-header {
    background:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.18) 0 2px, transparent 2px 56px),
        linear-gradient(135deg, var(--cw-preview-primary, #c8102e) 0%, #8d0d22 100%);
    border-top: 4px solid #ffffff;
    border-bottom: 4px solid var(--cw-preview-secondary, #0a3161);
}
.cw-preview--red_zone .cw-preview-title {
    color: #ffffff;
}
.cw-preview--red_zone .cw-preview-content-card {
    border-top: 5px solid var(--cw-preview-secondary, #0a3161);
    border-radius: 12px;
}

.cw-preview--all_american {
    background: #ffffff;
}
.cw-preview--all_american .cw-preview-header {
    background: #ffffff;
    border-top: 6px solid var(--cw-preview-primary, #b22234);
    border-bottom: 6px solid var(--cw-preview-secondary, #0a3161);
}
.cw-preview--all_american .cw-preview-title {
    color: var(--cw-preview-secondary, #0a3161);
}
.cw-preview--all_american .cw-preview-content-card {
    border-left: 6px solid var(--cw-preview-primary, #b22234);
    border-radius: 10px;
}

.cw-preview--old_glory {
    background: #f7f4ec;
}
.cw-preview--old_glory .cw-preview-header {
    background:
        repeating-linear-gradient(125deg, rgba(178, 34, 52, 0.55) 0 10px, transparent 10px 26px),
        linear-gradient(135deg, #0a1f3d 0%, var(--cw-preview-secondary, #0a3161) 100%);
    border-bottom: 5px solid var(--cw-preview-primary, #b22234);
}
.cw-preview--old_glory .cw-preview-title {
    color: #ffffff;
}
.cw-preview--old_glory .cw-preview-content-card {
    border-left: 6px solid var(--cw-preview-primary, #b22234);
    border-radius: 10px;
}

/* -----------------------------------------------------------------------
   Standard Theme Card Thumbnails
   ----------------------------------------------------------------------- */
.theme-thumbnail.light-classic-thumb,
.theme-thumbnail.dark-overlay-thumb,
.theme-thumbnail.split-header-thumb,
.theme-thumbnail.hero-banner-thumb {
    height: 58px;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.08);
}
.theme-thumbnail.light-classic-thumb {
    background: linear-gradient(135deg, #eef1fb 0%, #ffffff 100%);
}
.theme-thumbnail.dark-overlay-thumb {
    background: linear-gradient(135deg, #1b2537 0%, #101827 100%);
}
.theme-thumbnail.split-header-thumb {
    background: linear-gradient(90deg, #4e73df 0 50%, #fbbc04 50% 100%);
}
.theme-thumbnail.hero-banner-thumb {
    background: linear-gradient(120deg, #4e73df 0%, #fbbc04 100%);
    border-radius: 8px 8px 20px 20px;
}

/* -----------------------------------------------------------------------
   Football Theme Card Thumbnails
   ----------------------------------------------------------------------- */
.theme-thumbnail.gridiron-thumb,
.theme-thumbnail.end-zone-thumb,
.theme-thumbnail.kickoff-thumb,
.theme-thumbnail.stadium-lights-thumb,
.theme-thumbnail.star-spangled-thumb,
.theme-thumbnail.red-zone-thumb,
.theme-thumbnail.all-american-thumb,
.theme-thumbnail.old-glory-thumb {
    height: 58px;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.08);
}
.theme-thumbnail.gridiron-thumb {
    background:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.55) 0 2px, transparent 2px 16px),
        linear-gradient(135deg, #2e7d32 0%, #14532d 100%);
}
.theme-thumbnail.end-zone-thumb {
    background:
        linear-gradient(115deg, transparent 60%, rgba(255, 255, 255, 0.5) 60%, rgba(255, 255, 255, 0.5) 68%, transparent 68%),
        linear-gradient(135deg, #14532d 0%, #2e7d32 70%);
}
.theme-thumbnail.kickoff-thumb {
    background: linear-gradient(160deg, #43a047 0%, #1b5e20 100%);
    border-radius: 8px 8px 16px 16px;
}
.theme-thumbnail.stadium-lights-thumb {
    background:
        radial-gradient(circle at 50% -20%, rgba(140, 240, 170, 0.5) 0%, transparent 60%),
        linear-gradient(135deg, #0a1a12 0%, #061008 100%);
}

/* Red / White & Blue (USA) theme thumbnails */
.theme-thumbnail.star-spangled-thumb {
    background:
        radial-gradient(circle at 18% 30%, rgba(255, 255, 255, 0.9) 0 1.5px, transparent 2px),
        radial-gradient(circle at 34% 60%, rgba(255, 255, 255, 0.9) 0 1.5px, transparent 2px),
        radial-gradient(circle at 26% 80%, rgba(255, 255, 255, 0.85) 0 1.5px, transparent 2px),
        linear-gradient(90deg, #0a3161 0 55%, #b22234 55% 67%, #ffffff 67% 79%, #b22234 79% 91%, #ffffff 91% 100%);
}
.theme-thumbnail.red-zone-thumb {
    background:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.55) 0 2px, transparent 2px 16px),
        linear-gradient(135deg, #c8102e 0%, #8d0d22 100%);
}
.theme-thumbnail.all-american-thumb {
    background:
        linear-gradient(#b22234 0 18%, #ffffff 18% 82%, #0a3161 82% 100%);
}
.theme-thumbnail.old-glory-thumb {
    background:
        repeating-linear-gradient(125deg, rgba(178, 34, 52, 0.85) 0 8px, transparent 8px 18px),
        linear-gradient(135deg, #0a1f3d 0%, #0a3161 100%);
}

/* -----------------------------------------------------------------------
   Background Image Selector
   ----------------------------------------------------------------------- */
.bg-choice-card {
    border: 2px solid var(--cw-gray-200);
    border-radius: var(--cw-radius);
    overflow: hidden;
    cursor: pointer;
    transition: all var(--cw-transition);
    background: #fff;
}
.bg-choice-card:hover {
    border-color: var(--cw-primary);
}
.bg-choice-card.selected {
    border-color: var(--cw-primary);
    box-shadow: 0 0 0 3px rgba(78, 115, 223, 0.2);
}
.bg-choice-thumb {
    height: 72px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
.bg-choice-none {
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        repeating-linear-gradient(45deg, #f1f3f5 0 8px, #e9ecef 8px 16px);
    color: #6c757d;
    font-size: 0.7rem;
    font-weight: 600;
    text-align: center;
}

/* -----------------------------------------------------------------------
   Color Pickers
   ----------------------------------------------------------------------- */
.color-picker-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.color-picker-group input[type="color"] {
    width: 3rem;
    height: 2.25rem;
    padding: 0.15rem;
    border: 1px solid var(--cw-gray-200);
    border-radius: var(--cw-radius);
    cursor: pointer;
    background: none;
}

.color-picker-group input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 2px;
}

.color-picker-group input[type="color"]::-webkit-color-swatch {
    border: none;
    border-radius: 3px;
}

.color-swatch {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border-radius: 3px;
    border: 1px solid rgba(0, 0, 0, 0.15);
    vertical-align: middle;
}

/* -----------------------------------------------------------------------
   Field Builder Toggle Rows
   ----------------------------------------------------------------------- */
.field-builder-row {
    background: var(--cw-gray-100);
    border: 1px solid var(--cw-gray-200);
    transition: background var(--cw-transition);
}

.field-builder-row:hover {
    background: #fff;
    border-color: var(--cw-gray-500);
}

.field-builder-row.identity-row {
    border-left: 3px solid var(--cw-primary);
}

.field-builder-row .field-label {
    font-weight: 500;
    font-size: 0.9rem;
}

#identityWarning {
    font-size: 0.85rem;
}

/* Field Builder Toggle Switch Colors */
.field-builder-row .form-check-input {
    /* Unchecked (disabled) - red background */
    background-color: #dc3545;
    border-color: #dc3545;
}

.field-builder-row .form-check-input:checked {
    /* Checked (enabled) - green background */
    background-color: #28a745;
    border-color: #28a745;
}

.field-builder-row .form-check-input:focus {
    /* Focus states */
    box-shadow: 0 0 0 0.25rem rgba(40, 167, 69, 0.25);
}

.field-builder-row .form-check-input:not(:checked):focus {
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25);
}

/* Require Activation Toggle Switch Colors */
#requireActivationTable .require-activation-toggle {
    background-color: #dc3545;
    border-color: #dc3545;
}

#requireActivationTable .require-activation-toggle:checked {
    background-color: #28a745;
    border-color: #28a745;
}

#requireActivationTable .require-activation-toggle:focus {
    box-shadow: 0 0 0 0.25rem rgba(40, 167, 69, 0.25);
}

#requireActivationTable .require-activation-toggle:not(:checked):focus {
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25);
}

/* -----------------------------------------------------------------------
   Game Mapping List
   ----------------------------------------------------------------------- */
#gamesListContainer .game-row {
    border: 1px solid var(--cw-gray-200);
    transition: box-shadow var(--cw-transition);
}

#gamesListContainer .game-row:hover {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

#gamesListContainer .game-row input[type="date"] {
    max-width: 160px;
}

/* -----------------------------------------------------------------------
   Game Entry Cards (Step 3)
   ----------------------------------------------------------------------- */
.game-entry.card {
    border-width: 3px !important;
    border-style: solid !important;
    border-color: var(--cw-gray-300);
    transition: box-shadow 0.2s ease;
}

.game-entry:hover {
    box-shadow: 0 3px 14px rgba(0, 0, 0, 0.09);
}

/* Colored header bar — background tint applied inline by JS */
.game-entry-card-header {
    border-bottom: 1px solid rgba(0, 0, 0, 0.09);
}

/* Numbered circle badge — color applied inline by JS */
.game-entry-number-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    font-size: 0.7rem;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
    line-height: 1;
}

/* -----------------------------------------------------------------------
   Calendar Container
   ----------------------------------------------------------------------- */
.campaign-calendar-wrap {
    margin-top: 1.5rem;
}

#campaignCalendar {
    min-height: 400px;
    background: #fff;
    border-radius: var(--cw-radius);
    padding: 0.75rem;
    border: 1px solid var(--cw-gray-200);
}

#campaignCalendar .fc-daygrid-day.calendar-gap-day {
    background: rgba(231, 74, 59, 0.08);
}

#campaignCalendar .fc-daygrid-day.calendar-gap-day .fc-daygrid-day-number {
    color: var(--cw-danger);
    font-weight: 600;
}

/* Overlap day highlighting (multiple games on same date) */
#campaignCalendar .fc-daygrid-day.calendar-overlap-day {
    background: repeating-linear-gradient(
        45deg,
        #fff3cd,
        #fff3cd 5px,
        #ffe5b3 5px,
        #ffe5b3 10px
    ) !important;
    border: 2px solid #ff9800 !important;
}

#campaignCalendar .fc-daygrid-day.calendar-overlap-day .fc-daygrid-day-number {
    color: #ff6b00;
    font-weight: 700;
    text-shadow: 0 0 2px rgba(255, 255, 255, 0.8);
}

/* Campaign milestone events styling */
#campaignCalendar .fc-event.campaign-milestone {
    font-weight: 700;
    font-size: 0.85rem;
}

/* -----------------------------------------------------------------------
   Reward Matrix Upload Area
   ----------------------------------------------------------------------- */
#rewardMatrixZone {
    border: 2px dashed var(--cw-gray-500);
    border-radius: var(--cw-radius-lg);
    padding: 2rem 1.5rem;
    text-align: center;
    background: var(--cw-gray-100);
    transition: all var(--cw-transition);
    cursor: pointer;
}

#rewardMatrixZone:hover,
#rewardMatrixZone.drag-over {
    border-color: var(--cw-primary);
    background: var(--cw-primary-light);
}

#rewardMatrixZone .upload-icon {
    font-size: 2rem;
    color: var(--cw-gray-500);
    margin-bottom: 0.5rem;
}

#rewardMatrixZone.drag-over .upload-icon {
    color: var(--cw-primary);
}

#rewardMatrixZone .upload-text {
    font-size: 0.9rem;
    color: var(--cw-gray-700);
}

#rewardMatrixZone .upload-hint {
    font-size: 0.78rem;
    color: var(--cw-gray-500);
    margin-top: 0.25rem;
}

#rewardMatrixPreview {
    margin-top: 1rem;
}

/* -----------------------------------------------------------------------
   Validation Checklist
   ----------------------------------------------------------------------- */
#validationChecklist {
    list-style: none;
    padding: 0;
    margin: 0;
}

#validationChecklist li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid var(--cw-gray-200);
    font-size: 0.9rem;
}

#validationChecklist li:last-child {
    border-bottom: none;
}

#validationChecklist li i {
    font-size: 1.15rem;
    flex-shrink: 0;
}

#validationChecklist .validation-pass span {
    color: #333;
}

#validationChecklist .validation-fail span {
    color: var(--cw-danger);
    font-weight: 500;
}

#validationChecklist .validation-warn span {
    color: #856404;
}

#validationChecklist .validation-info span {
    color: #0c63e4;
}

/* -----------------------------------------------------------------------
   Review Summary Cards
   ----------------------------------------------------------------------- */
.review-card {
    background: var(--cw-gray-100);
    border: 1px solid var(--cw-gray-200);
    border-radius: var(--cw-radius);
    height: 100%;
}

.review-card h6 {
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--cw-primary);
}

.review-card p {
    margin-bottom: 0.35rem;
    font-size: 0.9rem;
}

.review-card ul {
    padding-left: 1.25rem;
    font-size: 0.9rem;
}

/* -----------------------------------------------------------------------
   Success / Launch Result Area
   ----------------------------------------------------------------------- */
.launch-result {
    animation: cwFadeIn 0.5s ease;
}

.launch-result h4 {
    font-weight: 700;
}

.launch-result .qr-code-img {
    max-width: 200px;
    border: 1px solid var(--cw-gray-200);
    border-radius: var(--cw-radius);
    padding: 0.5rem;
    background: #fff;
}

#launchResultArea {
    margin-top: 1rem;
}

/* -----------------------------------------------------------------------
   Wizard Navigation Buttons
   ----------------------------------------------------------------------- */
.wizard-nav-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    margin-top: 1.5rem;
    border-top: 1px solid var(--cw-gray-200);
    position: sticky;
    bottom: 0;
    background: #fff;
    z-index: 10;
}

.wizard-nav-buttons .btn {
    min-width: 120px;
}

.wizard-nav-right {
    display: flex;
    gap: 0.5rem;
    margin-left: auto;
}

.wizard-btn-go-live {
    background: var(--cw-secondary);
    border-color: var(--cw-secondary);
    color: #fff;
    font-weight: 600;
}

.wizard-btn-go-live:hover:not(:disabled) {
    background: #17a673;
    border-color: #17a673;
    color: #fff;
}

.wizard-btn-go-live:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* -----------------------------------------------------------------------
   Alerts
   ----------------------------------------------------------------------- */
#wizardStepAlert {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1080;
    max-width: 400px;
    box-shadow: var(--cw-shadow);
}

#wizardAlerts {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1080;
    max-width: 400px;
}

/* -----------------------------------------------------------------------
   Invite Key Group
   ----------------------------------------------------------------------- */
#inviteKeyGroup .input-group {
    max-width: 320px;
}

/* -----------------------------------------------------------------------
   Responsive
   ----------------------------------------------------------------------- */
@media (max-width: 991.98px) {
    .type-cards-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }

    .theme-cards-grid {
        grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    }

    #campaignCalendar {
        min-height: 300px;
    }

    .wizard-steps-bar {
        padding: 1rem 0.5rem;
    }

    .step-connector {
        max-width: 3rem;
    }

    .step-label {
        font-size: 0.65rem;
    }
}

@media (max-width: 767.98px) {
    .wizard-nav-buttons {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .wizard-nav-buttons .btn {
        min-width: 0;
        flex: 1 1 auto;
    }

    .wizard-nav-right {
        width: 100%;
        justify-content: flex-end;
    }

    .step-indicator {
        width: 2rem;
        height: 2rem;
        font-size: 0.8rem;
    }

    .step-label {
        display: none;
    }

    .step-connector {
        max-width: 2rem;
    }

    #gamesListContainer .game-row {
        flex-wrap: wrap;
    }

    #gamesListContainer .game-row input[type="date"] {
        max-width: 100%;
    }

    #rewardMatrixZone {
        padding: 1.25rem 1rem;
    }
}

/* -----------------------------------------------------------------------
   Next Button Inline Validation Error
   ----------------------------------------------------------------------- */
.next-btn-error {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.9rem;
    border-radius: var(--cw-radius);
    border: 1px solid #fcd34d;
    background: #fffbeb;
    font-size: 0.83rem;
    color: #78350f;
}

.next-btn-error .ti-alert-triangle {
    color: #d97706;
    font-size: 1rem;
}

.next-btn-error a {
    color: #92400e;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
    white-space: nowrap;
}

.next-btn-error a:hover {
    color: #78350f;
}

/* -----------------------------------------------------------------------
   Shake animation — applied to Next button on invalid click
   ----------------------------------------------------------------------- */
@keyframes cwShake {
    0%, 100% { transform: translateX(0); }
    15%       { transform: translateX(-6px); }
    30%       { transform: translateX( 6px); }
    45%       { transform: translateX(-4px); }
    60%       { transform: translateX( 4px); }
    75%       { transform: translateX(-2px); }
    90%       { transform: translateX( 2px); }
}

.cw-shake {
    animation: cwShake 0.45s ease;
}

/* -----------------------------------------------------------------------
   Field highlight — briefly pulses the scroll target
   ----------------------------------------------------------------------- */
@keyframes cwHighlight {
    0%, 100% { box-shadow: none; }
    25%, 75%  { box-shadow: 0 0 0 3px rgba(231, 74, 59, 0.35), 0 0 0 6px rgba(231, 74, 59, 0.08); }
}

.cw-field-highlight {
    animation: cwHighlight 1.4s ease;
    border-radius: 4px;
}

/* -----------------------------------------------------------------------
   Step 3 Progress Checklist
   ----------------------------------------------------------------------- */
#step3ChecklistCard .card-header {
    background: var(--cw-gray-100);
}

.step3-cl-item {
    display: flex;
    flex-direction: column;
    padding: 0.65rem 1rem;
    border-bottom: 1px solid var(--cw-gray-200);
    border-left: 3px solid transparent;
    gap: 0.2rem;
    transition: background var(--cw-transition), border-color var(--cw-transition);
}

.step3-cl-item:last-child {
    border-bottom: none;
}

.step3-cl-item.cl-pass {
    border-left-color: #198754;
    background: var(--cw-secondary-light);
}

.step3-cl-item.cl-fail {
    border-left-color: var(--cw-danger);
    background: #fff5f5;
}

.step3-cl-item.cl-pending {
    border-left-color: var(--cw-gray-200);
}

.step3-cl-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.83rem;
    font-weight: 500;
}

.step3-cl-icon {
    font-size: 1rem;
    flex-shrink: 0;
}

.step3-cl-item.cl-pass .step3-cl-icon  { color: #198754; }
.step3-cl-item.cl-fail .step3-cl-icon  { color: var(--cw-danger); }
.step3-cl-item.cl-pending .step3-cl-icon { color: var(--cw-gray-500); }

.step3-cl-detail {
    font-size: 0.77rem;
    color: var(--cw-gray-700);
    padding-left: 1.55rem;
    line-height: 1.45;
}

.step3-cl-game-issue {
    display: block;
    margin-top: 0.1rem;
}

/* -----------------------------------------------------------------------
   Step Required Items Bar
   ----------------------------------------------------------------------- */
.step-req-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 1.1rem;
    padding: 0.55rem 1rem;
    border-radius: var(--cw-radius);
    border: 1px solid var(--cw-gray-200);
    background: var(--cw-gray-100);
    font-size: 0.78rem;
    transition: background var(--cw-transition), border-color var(--cw-transition);
}

.step-req-bar.all-complete {
    background: #d1e7dd;
    border-color: #a3cfbb;
}

.step-req-bar .srb-label {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--cw-gray-700);
    flex-shrink: 0;
    margin-right: 0.15rem;
}

.step-req-bar .srb-item {
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
    transition: color var(--cw-transition);
}

.step-req-bar .srb-item.srb-done {
    color: #198754;
}

.step-req-bar .srb-item.srb-pending {
    color: #888;
}

.step-req-bar .srb-all-done {
    display: none;
    align-items: center;
    gap: 0.28rem;
    color: #198754;
    font-weight: 600;
    font-size: 0.75rem;
}

.step-req-bar.all-complete .srb-all-done {
    display: inline-flex;
}

/* -----------------------------------------------------------------------
   Step 2 — Required / Optional / Launch section badges
   ----------------------------------------------------------------------- */
.cw-section-badge {
    display: inline-flex;
    align-items: center;
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.1rem 0.45rem;
    border-radius: 2rem;
    vertical-align: middle;
    margin-left: 0.45rem;
    line-height: 1.5;
}

/* Red — required to proceed to next step */
.cw-badge-req {
    background: #fff0f0;
    color: #b91c1c;
    border: 1px solid #fca5a5;
}

/* Muted gray — not required */
.cw-badge-opt {
    background: var(--cw-gray-100);
    color: var(--cw-gray-500);
    border: 1px solid var(--cw-gray-200);
}

/* Blue — required to go live but not to advance the step */
.cw-badge-launch {
    background: #eff6ff;
    color: #1d4ed8;
    border: 1px solid #bfdbfe;
}

/* Card-level left accent for required cards */
.cw-required-card {
    border-left: 3px solid rgba(185, 28, 28, 0.25);
}

.cw-launch-card {
    border-left: 3px solid rgba(29, 78, 216, 0.2);
}
