/* Rich Ways Referrals — dashboard
 * Editorial dark layout matching jackkalala.com
 * Generous whitespace, serif headers, gold accents, no boxy "cards" feel
 */

.rwr-app {
    --rwr-bg: #111518;
    --rwr-surface: #161a1d;
    --rwr-border: #2a2f33;
    --rwr-border-soft: #1d2125;
    --rwr-text: #e8e6e1;
    --rwr-text-muted: #9a978e;
    --rwr-text-dim: #6a6760;
    --rwr-text-faint: #8a8780;
    --rwr-gold: #c9a961;
    --rwr-gold-soft: #8a8266;
    --rwr-font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
    --rwr-font-sans: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', 'Segoe UI', Arial, sans-serif;
    --rwr-font-mono: 'SF Mono', 'Courier New', monospace;

    background: var(--rwr-bg);
    color: var(--rwr-text);
    font-family: var(--rwr-font-sans);
    box-sizing: border-box;
    padding: 64px 0 80px;
    width: 100%;
}

/* Inner wrapper centers the content at a readable width */
.rwr-app-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 64px;
    box-sizing: border-box;
}

/* Make sure body and main containers don't add white space around us */
body.rwr-fullbleed-page {
    background: #111518 !important;
}
body.rwr-fullbleed-page #main,
body.rwr-fullbleed-page main,
body.rwr-fullbleed-page .site-main,
body.rwr-fullbleed-page .entry-content,
body.rwr-fullbleed-page article,
body.rwr-fullbleed-page .elementor-section-wrap,
body.rwr-fullbleed-page .elementor-widget-theme-post-content {
    background: #111518 !important;
    padding: 0 !important;
    margin: 0 !important;
    max-width: none !important;
    width: 100% !important;
}
.rwr-app *, .rwr-app *::before, .rwr-app *::after { box-sizing: border-box; }

/* ─── Typography utilities ──────────────────────────────────────── */

.rwr-eyebrow {
    font-size: 10px;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--rwr-text-faint);
    font-weight: 500;
    margin-bottom: 14px;
}
.rwr-accent { color: var(--rwr-gold); font-style: normal; }
em.rwr-accent { font-style: italic; }
.rwr-mono { font-family: var(--rwr-font-mono); letter-spacing: 0.5px; }
.rwr-text-right { text-align: right; }
.rwr-amount {
    color: var(--rwr-gold);
    font-family: var(--rwr-font-serif);
    font-size: 15px;
}

/* ─── Notices ───────────────────────────────────────────────────── */

.rwr-notice {
    padding: 16px 20px;
    margin-bottom: 32px;
    font-size: 14px;
    border-left: 2px solid;
}
.rwr-notice-success {
    background: rgba(201, 169, 97, 0.06);
    color: var(--rwr-gold);
    border-left-color: var(--rwr-gold);
}
.rwr-notice-error {
    background: rgba(220, 53, 69, 0.08);
    color: #e57373;
    border-left-color: #c44545;
}

/* ─── Welcome banner ────────────────────────────────────────────── */

.rwr-welcome {
    padding: 36px 0 36px;
    margin-bottom: 56px;
    border-bottom: 1px solid var(--rwr-border);
    animation: rwrFadeIn 0.6s ease-out;
}
.rwr-welcome-eyebrow {
    font-size: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--rwr-gold);
    margin-bottom: 14px;
}
.rwr-welcome-title {
    font-family: var(--rwr-font-serif);
    font-size: 32px;
    font-weight: 400;
    color: #fff;
    margin: 0 0 12px;
    line-height: 1.3;
    letter-spacing: -0.3px;
}
.rwr-welcome-title em {
    color: var(--rwr-gold);
    font-style: italic;
}
.rwr-welcome-body {
    color: var(--rwr-text-muted);
    margin: 0;
    font-size: 15px;
    line-height: 1.7;
    max-width: 640px;
}
@keyframes rwrFadeIn {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ─── Page header ───────────────────────────────────────────────── */

.rwr-header {
    margin-bottom: 56px;
}
.rwr-page-title {
    font-family: var(--rwr-font-serif);
    font-size: 42px;
    font-weight: 400;
    color: #fff;
    margin: 0 0 14px;
    line-height: 1.15;
    letter-spacing: -0.5px;
}
.rwr-page-intro {
    color: var(--rwr-text-muted);
    margin: 0;
    font-size: 16px;
    line-height: 1.7;
    max-width: 620px;
}

/* ─── Sections ──────────────────────────────────────────────────── */

.rwr-section {
    margin-bottom: 56px;
}
.rwr-section-eyebrow { margin-bottom: 12px; }

.rwr-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 18px;
    margin-bottom: 28px;
    border-bottom: 1px solid var(--rwr-border);
}
.rwr-section-title {
    font-family: var(--rwr-font-serif);
    font-size: 22px;
    font-weight: 400;
    color: #fff;
    margin: 0;
    letter-spacing: -0.2px;
}
.rwr-section-meta {
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--rwr-gold);
}
.rwr-section-meta .woocommerce-Price-amount,
.rwr-section-meta bdi { color: var(--rwr-gold); }

/* ─── Referral link ─────────────────────────────────────────────── */

.rwr-link-row {
    display: flex;
    align-items: stretch;
    border: 1px solid var(--rwr-border);
    background: var(--rwr-surface);
    margin-bottom: 16px;
}
.rwr-link-input {
    flex: 1;
    min-width: 0;
    background: transparent;
    border: none;
    padding: 18px 22px;
    font-size: 14px;
    color: var(--rwr-text);
    font-family: var(--rwr-font-mono);
    letter-spacing: 0.4px;
    outline: none;
}
.rwr-link-copy {
    background: var(--rwr-gold);
    color: var(--rwr-bg);
    border: none;
    padding: 0 36px;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 2.5px;
    cursor: pointer;
    text-transform: uppercase;
    font-family: var(--rwr-font-sans);
    transition: background 0.2s;
    min-width: 100px;
}
.rwr-link-copy:hover { background: #d4b56a; }

.rwr-share-nav {
    display: flex;
    flex-wrap: wrap;
}
.rwr-share-link {
    color: var(--rwr-text-muted);
    text-decoration: none;
    padding: 10px 18px;
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 500;
    border-right: 1px solid var(--rwr-border);
    transition: color 0.2s;
}
.rwr-share-link:first-child { padding-left: 0; }
.rwr-share-link:last-child { border-right: none; }
.rwr-share-link:hover { color: var(--rwr-gold); }

/* ─── Stats grid ────────────────────────────────────────────────── */

.rwr-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--rwr-border);
    border: 1px solid var(--rwr-border);
    margin-bottom: 56px;
}
.rwr-stat {
    background: var(--rwr-bg);
    padding: 32px 28px;
}
.rwr-stat-accent { /* No extra background — the accent is in the gold figure */ }
.rwr-stat-label {
    font-size: 10px;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--rwr-text-faint);
    margin-bottom: 18px;
    font-weight: 500;
}
.rwr-stat-accent .rwr-stat-label { color: var(--rwr-gold); }
.rwr-stat-figure {
    font-family: var(--rwr-font-serif);
    font-size: 36px;
    font-weight: 400;
    color: #fff;
    line-height: 1;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}
.rwr-stat-accent .rwr-stat-figure { color: var(--rwr-gold); }
.rwr-stat-figure .woocommerce-Price-amount,
.rwr-stat-figure bdi { font-family: inherit; color: inherit; }
.rwr-stat-figure .woocommerce-Price-currencySymbol { font-size: 0.7em; margin-right: 2px; }
.rwr-stat-hint {
    font-size: 11px;
    color: var(--rwr-text-dim);
    letter-spacing: 0.3px;
}
.rwr-stat-accent .rwr-stat-hint { color: var(--rwr-gold-soft); }

/* ─── Forms ─────────────────────────────────────────────────────── */

.rwr-form-field { margin-bottom: 24px; }
.rwr-form-field label {
    display: block;
    margin-bottom: 12px;
}
.rwr-form textarea {
    width: 100%;
    min-height: 140px;
    background: var(--rwr-surface);
    border: 1px solid var(--rwr-border);
    padding: 18px 22px;
    color: var(--rwr-text);
    font-family: var(--rwr-font-sans);
    font-size: 14px;
    line-height: 1.8;
    resize: vertical;
    transition: border-color 0.2s;
}
.rwr-form textarea:focus {
    outline: none;
    border-color: var(--rwr-gold);
}
.rwr-form textarea::placeholder {
    color: var(--rwr-text-dim);
    line-height: 1.8;
}

.rwr-btn-primary {
    background: var(--rwr-gold);
    color: var(--rwr-bg);
    border: none;
    padding: 18px 40px;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 2.5px;
    cursor: pointer;
    text-transform: uppercase;
    font-family: var(--rwr-font-sans);
    transition: background 0.2s;
}
.rwr-btn-primary:hover { background: #d4b56a; }
.rwr-btn-primary .woocommerce-Price-amount,
.rwr-btn-primary bdi { color: var(--rwr-bg); font-family: inherit; font-size: inherit; }

/* ─── Info messages ─────────────────────────────────────────────── */

.rwr-info {
    padding: 24px 28px;
    background: var(--rwr-surface);
    border-left: 2px solid var(--rwr-gold);
    color: var(--rwr-text-muted);
    font-size: 14px;
    line-height: 1.7;
}
.rwr-info strong { color: var(--rwr-gold); font-weight: 500; }
.rwr-info .woocommerce-Price-amount,
.rwr-info bdi { color: var(--rwr-gold); }

/* ─── Tables ────────────────────────────────────────────────────── */

.rwr-table-wrap { overflow-x: auto; }
.rwr-table {
    width: 100%;
    border-collapse: collapse;
}
.rwr-table th {
    text-align: left;
    padding: 0 16px 16px 0;
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--rwr-text-faint);
    font-weight: 500;
    border-bottom: 1px solid var(--rwr-border);
}
.rwr-table td {
    padding: 22px 16px 22px 0;
    font-size: 14px;
    color: var(--rwr-text);
    border-bottom: 1px solid var(--rwr-border-soft);
}
.rwr-table th.rwr-text-right,
.rwr-table td.rwr-text-right { padding-right: 0; padding-left: 16px; }
.rwr-table td.rwr-mono { color: var(--rwr-text-muted); }
.rwr-table tbody tr:last-child td { border-bottom: none; }

/* ─── Status pills (subtle, editorial) ──────────────────────────── */

.rwr-status {
    display: inline-block;
    font-size: 10px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    font-weight: 500;
}
.rwr-status-pending,
.rwr-status-requested { color: #d4b56a; }
.rwr-status-approved  { color: var(--rwr-gold); }
.rwr-status-paid      { color: #8bbd7a; }
.rwr-status-rejected,
.rwr-status-reversed  { color: #c98a8a; }

.rwr-empty {
    color: var(--rwr-text-dim);
    font-style: italic;
    margin: 0;
    padding: 32px 0;
    font-size: 14px;
}

/* ─── Login prompt ──────────────────────────────────────────────── */

.rwr-login-prompt {
    padding: 80px 40px;
    text-align: center;
    background: var(--rwr-bg);
    color: var(--rwr-text);
    font-family: var(--rwr-font-sans);
}
.rwr-login-prompt h2 {
    font-family: var(--rwr-font-serif);
    font-size: 32px;
    font-weight: 400;
    color: #fff;
    margin: 0 0 14px;
    letter-spacing: -0.3px;
}
.rwr-login-prompt p {
    color: var(--rwr-text-muted);
    margin: 0 0 32px;
    font-size: 15px;
    line-height: 1.7;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}
.rwr-login-prompt .button {
    display: inline-block;
    margin: 0 6px;
    padding: 16px 32px;
    background: var(--rwr-gold);
    color: var(--rwr-bg) !important;
    text-decoration: none;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 11px;
    transition: background 0.2s;
}
.rwr-login-prompt .button:hover { background: #d4b56a; }

/* ─── Responsive ────────────────────────────────────────────────── */

@media (max-width: 900px) {
    .rwr-stats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 700px) {
    .rwr-app { padding: 40px 0 56px; }
    .rwr-app-inner { padding: 0 24px; }
    .rwr-page-title { font-size: 32px; }
    .rwr-welcome-title { font-size: 24px; }
    .rwr-stat-figure { font-size: 28px; }
    .rwr-stat { padding: 24px 20px; }
    .rwr-section-title { font-size: 18px; }
    .rwr-link-row { flex-direction: column; }
    .rwr-link-input { padding: 16px 18px; }
    .rwr-link-copy { padding: 16px; width: 100%; }
    .rwr-share-link:first-child { padding-left: 0; }
    .rwr-table th, .rwr-table td { font-size: 12px; padding-right: 10px; padding-left: 10px; }
}
@media (max-width: 480px) {
    .rwr-stats { grid-template-columns: 1fr; }
}

/* ─── Join program CTA on dashboard ─────────────────────────── */

.rwr-join-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 24px 28px;
    background: var(--rwr-surface);
    border: 1px solid var(--rwr-border);
    border-left: 3px solid var(--rwr-gold);
    margin-bottom: 40px;
}
.rwr-join-cta-text { flex: 1; }
.rwr-join-cta-btn {
    flex-shrink: 0;
    background: var(--rwr-gold);
    color: var(--rwr-bg) !important;
    padding: 14px 28px;
    text-decoration: none !important;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: background 0.2s;
    font-family: var(--rwr-font-sans);
    white-space: nowrap;
}
.rwr-join-cta-btn:hover { background: #d4b56a; color: var(--rwr-bg) !important; }

@media (max-width: 600px) {
    .rwr-join-cta { flex-direction: column; align-items: flex-start; gap: 16px; }
    .rwr-join-cta-btn { width: 100%; text-align: center; }
}
