/* ============================================================
   Pirate Win — Offerwall Widget
   Matches the main Pirate Win page design (dark navy + gold)
   ============================================================ */

:root {
    --offerwall-bg: #0f1729;
    --offerwall-card: #18243b;
    --offerwall-card-light: #1e2a45;

    --offerwall-border: rgba(255, 255, 255, 0.07);

    --offerwall-gold: #f5a623;
    --offerwall-gold-light: #ffc861;

    --offerwall-green: #22c55e;
    --offerwall-red: #ef4444;

    --offerwall-text: #ffffff;
    --offerwall-muted: #94a3b8;
    --offerwall-text-light: #cbd5e1;

    --offerwall-radius: 18px;
    --offerwall-radius-lg: 24px;
}


/* ============================================================
   CONTAINER
   ============================================================ */

.offerwall-wrap {
    width: 100%;
    max-width: 1080px;

    margin: 0 auto;
    padding: 0 0 20px;

    color: var(--offerwall-text);

    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
}


/* ============================================================
   INTRODUCTION
   ============================================================ */

.offerwall-intro {
    position: relative;

    display: flex;
    align-items: center;

    gap: 20px;

    margin-bottom: 24px;
    padding: 24px;

    border-radius: var(--offerwall-radius-lg);

    background: linear-gradient(135deg, rgba(30, 42, 69, 0.9), rgba(24, 36, 59, 0.9));

    border: 1px solid var(--offerwall-border);

    overflow: hidden;
}

.offerwall-intro::after {
    content: "";
    position: absolute;
    width: 180px;
    height: 180px;
    right: -80px;
    top: -100px;
    border-radius: 50%;
    background: rgba(245, 166, 35, 0.08);
    filter: blur(40px);
    pointer-events: none;
}

.offerwall-intro-icon {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: rgba(245, 166, 35, 0.1);
    border: 1px solid rgba(245, 166, 35, 0.25);
    font-size: 25px;
}

.offerwall-intro-content {
    position: relative;
    z-index: 2;
    flex: 1;
}

.offerwall-intro-title {
    margin: 0 0 5px;
    color: var(--offerwall-text);
    font-size: 21px;
    line-height: 1.3;
    font-weight: 800;
}

.offerwall-intro-text {
    margin: 0;
    max-width: 700px;
    color: var(--offerwall-muted);
    font-size: 14px;
    line-height: 1.6;
}

.offerwall-balance {
    position: relative;
    z-index: 2;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    padding-left: 20px;
    border-left: 1px solid var(--offerwall-border);
}

.offerwall-balance-label {
    margin-bottom: 3px;
    color: var(--offerwall-muted);
    font-size: 12px;
}

.offerwall-balance strong {
    color: var(--offerwall-gold-light);
    font-size: 19px;
    font-weight: 800;
}


/* ============================================================
   TABS (Offer Wall / History)
   ============================================================ */

.offerwall-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.offerwall-tab {
    padding: 10px 18px;
    border-radius: 10px;
    border: 1px solid var(--offerwall-border);
    background: transparent;
    color: var(--offerwall-muted);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.offerwall-tab--active {
    color: #1a1206;
    background: linear-gradient(135deg, var(--offerwall-gold-light), var(--offerwall-gold));
    border-color: transparent;
}

.offerwall-panel { display: none; }
.offerwall-panel--active { display: block; }


/* ============================================================
   IFRAME (hosted wall)
   ============================================================ */

.offerwall-iframe {
    width: 100%;
    min-height: 800px;
    border: 1px solid var(--offerwall-border);
    border-radius: var(--offerwall-radius-lg);
    background: var(--offerwall-card);
}


/* ============================================================
   EMPTY STATE
   ============================================================ */

.offerwall-empty {
    padding: 60px 25px;
    text-align: center;
    background: linear-gradient(145deg, rgba(30, 42, 69, 0.7), rgba(24, 36, 59, 0.7));
    border: 1px solid var(--offerwall-border);
    border-radius: var(--offerwall-radius-lg);
    color: var(--offerwall-muted);
}

.offerwall-empty h3 {
    margin: 0 0 8px;
    color: var(--offerwall-text);
    font-size: 19px;
    font-weight: 800;
}

.offerwall-btn--start {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    min-height: 40px;
    border: 0;
    border-radius: 10px;
    color: #1a1206;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    cursor: pointer;
    background: linear-gradient(135deg, var(--offerwall-gold-light), var(--offerwall-gold));
    box-shadow: 0 6px 18px rgba(245, 166, 35, 0.2);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.offerwall-btn--start:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(245, 166, 35, 0.3);
    color: #1a1206;
}


/* ============================================================
   HISTORY TABLE
   ============================================================ */

.offerwall-history-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13.5px;
}

.offerwall-history-table th,
.offerwall-history-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid var(--offerwall-border);
    color: var(--offerwall-text-light);
}

.offerwall-history-table th {
    color: var(--offerwall-muted);
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.offerwall-status-pill {
    display: inline-flex;
    align-items: center;
    padding: 3px 9px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

.offerwall-status--credited {
    color: #86efac;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.offerwall-status--reversed {
    color: #fca5a5;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.offerwall-history-totals {
    margin-bottom: 16px;
    color: var(--offerwall-muted);
    font-size: 14px;
}

.offerwall-history-totals strong {
    color: var(--offerwall-gold-light);
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 600px) {

    .offerwall-intro {
        display: grid;
        grid-template-columns: auto 1fr;
        gap: 15px;
        padding: 18px;
    }

    .offerwall-balance {
        grid-column: 1 / -1;
        align-items: flex-start;
        padding-left: 0;
        padding-top: 14px;
        border-left: 0;
        border-top: 1px solid var(--offerwall-border);
    }

    .offerwall-iframe {
        min-height: 650px;
    }

    .offerwall-history-table {
        font-size: 12px;
    }
}
