
/* Page header */
header.recurring-header {
    background: var(--primary);
    padding: 3.5rem var(--container-padding) 2.75rem;
    text-align: center;
    color: var(--white);
}
header.recurring-header h1 {
    font-family: var(--font-display);
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: var(--white);
}
header.recurring-header .subtitle {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.78);
    max-width: 580px;
    margin: 0 auto;
    line-height: 1.55;
}

/* Container */
.recurring-container {
    max-width: 880px;
    margin: 0 auto;
    padding: 1.75rem var(--container-padding) 4rem;
}

.reload-check-note {
    background: var(--wash);
    border: var(--keyline-w-sm) solid var(--keyline);
    border-radius: var(--r-sm);
    padding: 0.85rem 1rem;
    color: var(--ink-70);
    line-height: 1.5;
}
.reload-check-note a { color: var(--ink-deep); font-weight: 700; }

/* Section heading */
.section-heading {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-light);
    margin: 2.25rem 0 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.section-heading::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
}
.section-heading:first-child {
    margin-top: 0;
}
/* Clears the site nav (64px) plus the sticky quick-nav when jumped to */
.section-anchor {
    scroll-margin-top: 130px;
}

/* ── Sticky section quick-nav ── */
.section-nav {
    position: sticky;
    top: 64px; /* site nav height */
    z-index: 900;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin: 0 0 1.5rem;
    padding: 0.6rem 0;
    background: rgba(250, 247, 242, 0.97);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}
.section-nav::-webkit-scrollbar { display: none; }
.section-nav-label {
    font-family: var(--font-display);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-light);
    flex-shrink: 0;
    padding-right: 0.15rem;
}
.section-nav-pill {
    flex-shrink: 0;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    padding: 0.4rem 0.85rem;
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.section-nav-pill:hover {
    border-color: #ff6b4a;
    color: #1a2332;
}
.section-nav-pill.active {
    background: #1a2332;
    border-color: #1a2332;
    color: white;
}
@media (max-width: 540px) {
    .section-nav { gap: 0.35rem; }
    .section-nav-label { display: none; }
    .section-nav-pill { padding: 0.38rem 0.7rem; font-size: 0.78rem; }
}
.section-ev-total {
    background: rgba(31, 122, 92, 0.14);
    color: #17604a;
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    text-transform: none;
    letter-spacing: normal;
    padding: 0.4rem 1.1rem;
    border-radius: var(--r-pill);
    white-space: nowrap;
}

/* Filter bar */
.filter-bar {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 1.25rem;
}
.filter-bar .filter-label {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-right: 0.4rem;
}
.filter-pill {
    background: var(--white);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 0.4rem 0.95rem;
    border-radius: var(--r-pill);
    font-family: 'Work Sans', sans-serif;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}
.filter-pill:hover {
    border-color: var(--accent);
    color: var(--accent);
}
.filter-pill.active {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--white);
}
.filter-pill .count {
    opacity: 0.7;
    font-weight: 400;
    margin-left: 0.3rem;
    font-size: 0.78rem;
}

/* Offer feed */
.offer-feed {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    overflow: hidden;
    box-shadow: var(--shadow-1);
}

.offer-row {
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background-color 0.15s ease;
}
.offer-row:last-child { border-bottom: none; }
.offer-row:hover { background-color: #faf7f2; }
.offer-row.open { background-color: #faf7f2; }

/* Summary line */
.row-summary {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 1rem;
    align-items: center;
    padding: 0.95rem 1.1rem;
}
.row-left { min-width: 0; }
.row-casino-line {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.2rem;
    flex-wrap: wrap;
}
.row-casino {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.2;
}
.type-pill {
    display: inline-block;
    padding: 0.15rem 0.55rem;
    border-radius: var(--r-pill);
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    line-height: 1.4;
}
.type-pill.free-spins       { background: rgba(31, 122, 92, 0.12); color: #17604a; }
.type-pill.reload            { background: rgba(90, 90, 168, 0.12); color: #4338ca; }
.type-pill.recurring-reload  { background: rgba(163, 97, 26, 0.12); color: #7d4a12; }
.type-pill.wager-reward      { background: rgba(122, 94, 168, 0.12); color: #7e22ce; }
.type-pill.ended             { background: rgba(104, 113, 127, 0.15); color: #48536a; }

/* Wager for Rewards: variable reward, so the section carries a standing
   "not risk-free" note and the EV badge is labelled as a minimum. */
.section-note {
    font-size: 0.82rem;
    color: var(--text-light);
    line-height: 1.55;
    margin: -0.35rem 0 1rem;
    padding: 0.65rem 0.85rem;
    background: rgba(122, 94, 168, 0.07);
    border-left: 3px solid rgba(122, 94, 168, 0.45);
    border-radius: 0 var(--r-md) var(--r-md) 0;
}
.reward-range-value { font-variant-numeric: tabular-nums; }

.row-headline {
    font-size: 0.88rem;
    color: var(--text-light);
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

/* Day tags */
.row-days {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    margin-top: 0.35rem;
}
.day-tag {
    display: inline-block;
    padding: 0.1rem 0.45rem;
    border-radius: var(--r-sm);
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(163, 97, 26, 0.1);
    color: #7d4a12;
    border: 1px solid rgba(163, 97, 26, 0.25);
}
.day-tag.day-today {
    background: rgba(31, 122, 92, 0.15);
    color: #17604a;
    border-color: rgba(31, 122, 92, 0.35);
}

.row-right {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-shrink: 0;
}
.row-ev-wrap {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}
.row-ev {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    color: #1f7a5c;
    line-height: 1;
    min-width: 60px;
    text-align: right;
}
.not-today-note {
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #7d4a12;
    margin-top: 0.2rem;
    text-align: right;
    white-space: nowrap;
}
.offer-row.not-today { opacity: 0.6; }
.offer-row.not-today:hover { background-color: #faf7f2; }
.offer-row.not-today .row-ev { color: #99a2b0; }
.row-track-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.4rem 0.7rem;
    background: var(--white);
    border: 1.5px solid var(--border);
    border-radius: var(--r-md);
    color: var(--text);
    font-family: 'Work Sans', sans-serif;
    font-weight: 600;
    font-size: 0.78rem;
    cursor: pointer;
    transition: all 0.15s ease;
    white-space: nowrap;
}
.row-track-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}
.row-chevron {
    color: var(--text-light);
    font-size: 0.85rem;
    transition: transform 0.25s ease;
    user-select: none;
    width: 16px;
    text-align: center;
}
.offer-row.open .row-chevron { transform: rotate(180deg); }

/* Expanded detail panel */
.row-detail {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.offer-row.open .row-detail { max-height: 900px; }
.row-detail-inner {
    padding: 0.25rem 1.1rem 1.2rem 1.1rem;
    border-top: 1px dashed var(--border);
    margin: 0 0.25rem;
    background: var(--white);
}
.row-deal {
    color: var(--text);
    font-size: 0.92rem;
    line-height: 1.6;
    margin: 1rem 0 0.85rem;
    white-space: pre-line;
}
.row-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem 1.5rem;
    padding: 0.7rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    margin-bottom: 0.85rem;
}
.row-meta-item {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}
.row-meta-label {
    font-size: 0.66rem;
    font-weight: 700;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.row-meta-value {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--primary);
}
.row-tip {
    background: rgba(255, 107, 74, 0.07);
    border-left: 3px solid var(--accent);
    padding: 0.6rem 0.85rem;
    border-radius: var(--r-sm);
    font-size: 0.85rem;
    color: var(--text);
    line-height: 1.5;
    margin: 0 0 0.95rem;
}
.row-tip strong {
    color: var(--accent);
    font-weight: 700;
    margin-right: 0.3rem;
}
.row-actions {
    display: flex;
    gap: 0.55rem;
}
.row-claim-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 1rem;
    background: var(--accent);
    color: var(--white);
    text-decoration: none;
    border-radius: var(--r-md);
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}
.row-claim-btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-2);
    color: var(--white);
}

/* Ended row variant */
.offer-row.ended { opacity: 0.62; }
.offer-row.ended:hover { background: var(--white); cursor: pointer; }
.offer-row.ended .row-claim-btn {
    background: #99a2b0;
    cursor: not-allowed;
    pointer-events: none;
}

/* Gubbed filter */
.gubbed-hidden { display: none !important; }
.gub-filter-bar { display: flex; align-items: center; gap: 0.75rem; margin: 0.75rem 0 1rem; }
.hide-gubbed-btn { display: inline-flex; align-items: center; padding: 0.35rem 0.85rem; border-radius: var(--r-md); border: 2px solid #e3ddd3; background: white; color: #48536a; font-family: 'Work Sans', sans-serif; font-size: 0.85rem; font-weight: 500; cursor: pointer; transition: all 0.2s ease; white-space: nowrap; }
.hide-gubbed-btn:hover { border-color: #c4cad4; background: #f8f5f0; }
.hide-gubbed-btn.active { background: #1a2332; border-color: #1a2332; color: white; }
.gub-tooltip-wrap { position: relative; display: inline-flex; align-items: center; }
.gub-tooltip-icon { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; border-radius: 50%; background: #e3ddd3; color: #68717f; font-size: 0.65rem; font-weight: 700; cursor: default; margin-left: 6px; flex-shrink: 0; }
.gub-tooltip-icon:hover + .gub-tooltip-text, .gub-tooltip-icon:focus + .gub-tooltip-text, .gub-tooltip-text:hover { opacity: 1; pointer-events: auto; }
.gub-tooltip-text { position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); background: #1a2332; color: white; font-size: 0.75rem; line-height: 1.4; padding: 0.5rem 0.75rem; border-radius: var(--r-md); white-space: normal; width: 220px; opacity: 0; pointer-events: none; transition: opacity 0.15s ease; z-index: 100; }
.gub-tooltip-text::after { content: ''; position: absolute; top: 100%; left: 50%; transform: translateX(-50%); border: 5px solid transparent; border-top-color: #1a2332; }
.gub-tooltip-link { display: block; margin-top: 0.4rem; color: #93c5fd; text-decoration: underline; }
.gub-tooltip-link:hover { color: white; }

/* Higher risk section (collapsed by default via <details>) */
.higher-risk-details {
    margin-top: 2.25rem;
}
.higher-risk-summary {
    cursor: pointer;
    list-style: none;
    user-select: none;
}
.higher-risk-summary::-webkit-details-marker { display: none; }
.higher-risk-summary::before {
    content: '▸';
    display: inline-block;
    margin-right: 0.4rem;
    transition: transform 0.2s ease;
    color: var(--text-light);
}
.higher-risk-details[open] .higher-risk-summary::before { transform: rotate(90deg); }
.risk-count {
    background: rgba(168, 58, 44, 0.12);
    color: #7d271d;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.1rem 0.5rem;
    border-radius: var(--r-pill);
    margin-left: 0.3rem;
}
.higher-risk-note {
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.6;
    margin: 0 0 1rem;
}
.risk-badge {
    display: inline-block;
    padding: 0.15rem 0.55rem;
    border-radius: var(--r-pill);
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    line-height: 1.4;
}
.risk-badge.medium-risk { background: rgba(163, 97, 26, 0.15); color: #7d4a12; }
.risk-badge.high-risk   { background: rgba(168, 58, 44, 0.15); color: #7d271d; }

/* Empty state */
.empty-state {
    display: none;
    text-align: center;
    padding: 2.5rem 1rem;
    color: var(--text-light);
    background: var(--white);
    border: 1px dashed var(--border);
    border-radius: var(--r-md);
    font-size: 0.95rem;
}

/* Locked rows - applied by JS for non-subscribers */
.offer-row.gated-locked { cursor: pointer; }
.offer-row.gated-locked:hover { background: #f8f5f0; }
.offer-row.gated-locked .row-casino { display: none; }
.offer-row.gated-locked .row-locked-label { display: inline; }
.offer-row.gated-locked .row-headline { color: #99a2b0; font-style: italic; }
.offer-row.gated-locked .row-track-btn { display: none; }
.offer-row.gated-locked .row-tick-btn { display: none; }
.offer-row.gated-locked .row-chevron { display: none; }
.offer-row.gated-locked .row-detail { display: none !important; }
.row-locked-label { display: none; font-weight: 600; color: var(--text-primary, #354052); font-size: 0.95rem; }
.row-lock-btn { display: none; background: #48536a; color: white; border: none; border-radius: var(--r-md); padding: 0.35rem 0.75rem; font-family: inherit; font-size: 0.82rem; font-weight: 600; cursor: pointer; white-space: nowrap; text-decoration: none; }
.offer-row.gated-locked .row-lock-btn { display: inline-flex; align-items: center; gap: 0.3rem; }

/* Tick button */
.row-tick-btn {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid var(--border);
    background: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: transparent;
    font-size: 0.7rem;
    transition: border-color 0.15s, background 0.15s;
    padding: 0;
}
.row-tick-btn:hover { border-color: #1f7a5c; }
.offer-row.is-done-today .row-tick-btn {
    border-color: #1f7a5c;
    background: #dbeae4;
    color: #114a39;
}
.offer-row.is-done-today .row-casino { text-decoration: line-through; opacity: 0.55; }
.offer-row.is-done-today .row-ev { color: #99a2b0; }

/* Mobile */
@media (max-width: 540px) {
    .row-summary {
        grid-template-columns: 1fr auto;
        padding: 0.85rem 0.95rem;
    }
    .row-track-btn {
        padding: 0.35rem 0.55rem;
        font-size: 0;
        gap: 0;
    }
    .row-track-btn::before {
        content: "📊";
        font-size: 0.95rem;
    }
    .row-track-btn span { display: none; }
    .row-ev {
        font-size: 1rem;
        min-width: 50px;
    }
    .row-meta-grid {
        grid-template-columns: 1fr;
        gap: 0.55rem;
    }
    .row-right { gap: 0.4rem; }
}
