/* =========================================
   GLOBAL
========================================= */

.plp-btn,
button.plp-btn,
.plp-save-pred {
    background: #0073aa;
    color: #fff;
    border: none;
    padding: 8px 14px;
    border-radius: 4px;
    cursor: pointer;
    transition: 0.2s;
    min-height: 40px;
}

.plp-btn:hover,
.plp-save-pred:hover {
    background: #005f8a;
}

.plp-error {
    color: #d63638;
    margin-top: 10px;
}

.plp-success {
    color: #2ecc71;
    margin-top: 10px;
}

.plp-subtext {
    color: #666;
    margin-bottom: 10px;
}

.plp-action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 12px 0;
}

.plp-action-row .plp-btn,
.plp-action-row button.plp-btn {
    text-align: center;
}

.plp-install-btn {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 9999;
    border-radius: 999px;
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.2);
    font-weight: 700;
}

/* =========================================
   SIGNUP PAGE
========================================= */

.plp-signup-container {
    max-width: 420px;
    margin: 40px auto;
    padding: 25px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
}

.plp-signup-container h2 {
    margin-bottom: 10px;
}

#plp-signup-form label,
#plp-login-form label,
#plp-home-login-form label {
    display: block;
    margin-top: 15px;
    font-weight: 600;
}

#plp-signup-form input,
#plp-login-form input,
#plp-home-login-form input {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border-radius: 4px;
    border: 1px solid #ccc;
}

.plp-hint {
    margin-top: 20px;
    text-align: center;
    color: #888;
}

/* =========================================
   HOME PAGE
========================================= */

.plp-home-shell {
    width: 100%;
    max-width: 1200px;
    margin: 24px auto;
    padding: 28px;
    box-sizing: border-box;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
}

.plp-home-section {
    margin-top: 16px;
}

.plp-home-divider {
    margin: 20px 0;
}

.plp-home-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 6px;
}

.plp-home-actions .plp-btn,
.plp-home-actions button.plp-btn {
    width: 100%;
}

.plp-home-panel {
    background: #f8fafc;
    border: 1px solid #e8eef4;
    border-radius: 10px;
    padding: 14px;
}

.plp-home-shell h2 {
    margin-bottom: 6px;
}

.plp-home-shell h3 {
    margin: 0 0 8px 0;
}

#plp-home-login-form {
    margin-top: 6px;
}

#plp-home-login-form .plp-btn {
    margin-top: 12px;
    width: 100%;
}

/* =========================================
   DASHBOARD
========================================= */

.plp-dashboard {
    max-width: 900px;
    margin: 20px auto;
    padding: 10px;
}

.plp-welcome {
    margin-bottom: 20px;
    color: #444;
}

/* =========================================
   SUMMARY PANEL
========================================= */

.plp-summary {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 25px;
}

.plp-summary-box {
    flex: 1;
    min-width: 150px;
    background: #f7f7f7;
    padding: 15px;
    border-radius: 6px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.plp-summary-box h3 {
    margin-bottom: 8px;
    font-size: 15px;
    color: #555;
}

.plp-summary-box div {
    font-size: 22px;
    font-weight: bold;
}

/* =========================================
   MINI LEADERBOARD
========================================= */

.plp-mini-leaderboard {
    margin-bottom: 25px;
}

.plp-mini-leaderboard ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.plp-mini-leaderboard li {
    display: flex;
    justify-content: space-between;
    padding: 8px 12px;
    border-bottom: 1px solid #eee;
}

.plp-mini-leaderboard li.plp-leader {
    background: #e8f7ff;
    font-weight: bold;
}

/* =========================================
   PAYMENT HIGHLIGHT CARDS
========================================= */

.plp-payment-card {
    border: 2px solid #d7eaf7;
    border-radius: 10px;
    padding: 16px;
    background: linear-gradient(135deg, #f7fbff 0%, #eef7ff 100%);
    box-shadow: 0 3px 10px rgba(0, 50, 90, 0.08);
}

.plp-payment-card h3 {
    margin-top: 0;
    margin-bottom: 10px;
    color: #004b73;
}

.plp-payment-card-weekly {
    border-color: #bfe5cc;
    background: linear-gradient(135deg, #f4fff8 0%, #e9f9ef 100%);
}

.plp-payment-card-wallet {
    border-color: #c6dcf3;
}

.plp-payment-card .plp-btn {
    font-weight: 700;
}

.plp-prize-highlight {
    margin: 0 0 14px 0;
    padding: 16px 18px;
    border-radius: 12px;
    border: 2px solid #1d5b87;
    background: linear-gradient(135deg, #08304d 0%, #0f4f7a 100%);
    box-shadow: 0 6px 14px rgba(6, 42, 70, 0.25);
    color: #fff;
}

.plp-prize-highlight h3 {
    margin: 0 0 6px 0;
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: #d8efff;
}

.plp-prize-value {
    margin: 0;
    font-size: 34px;
    font-weight: 800;
    line-height: 1.1;
    color: #ffffff;
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.2);
}

.plp-prize-note {
    margin: 8px 0 0 0;
    font-size: 13px;
    color: #dcecff;
}

.plp-prize-highlight-weekly {
    border-color: #2f8f4f;
    background: linear-gradient(135deg, #185f33 0%, #2b8d4c 100%);
}

.plp-prize-highlight-season {
    border-color: #1d5b87;
    background: linear-gradient(135deg, #08304d 0%, #0f4f7a 100%);
}

/* Dashboard prediction CTA variants */
.plp-btn.plp-btn-edit {
    background: #ef6c00;
}

.plp-btn.plp-btn-edit:hover {
    background: #cf5d00;
}

.plp-btn.plp-btn-enter {
    background: #2e7d32;
}

.plp-btn.plp-btn-enter:hover {
    background: #256628;
}

/* =========================================
   FIXTURE ROWS (PREDICTIONS)
========================================= */

.plp-fixture-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fafafa;
    padding: 12px;
    margin-bottom: 10px;
    border-radius: 6px;
    border: 1px solid #eee;
    transition: 0.2s;
}

.plp-fixture-row.plp-saved {
    background: #e8ffe8;
}

.plp-fixture-teams {
    flex: 1;
    font-weight: 600;
}

.plp-fixture-kickoff {
    width: 120px;
    text-align: center;
    color: #666;
}

.plp-live-score {
    min-width: 88px;
    text-align: center;
    font-weight: 700;
    color: #124a72;
}

.plp-pred-inputs {
    display: flex;
    gap: 6px;
    align-items: center;
}

.plp-pred-inputs input {
    width: 45px;
    padding: 6px;
    text-align: center;
    border-radius: 4px;
    border: 1px solid #ccc;
}

#plp-entry-form input[type="text"] {
    width: 240px;
}

#plp-entry-form select {
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.plp-locked {
    color: #d63638;
    font-weight: bold;
}

.plp-locked-line {
    display: flex;
    align-items: center;
    gap: 8px;
}

.plp-pred-chip {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 999px;
    background: #eef3f8;
    color: #3a4a5a;
    font-size: 13px;
    font-weight: 600;
}

/* =========================================
   MATRIX TABLE
========================================= */

.plp-matrix-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 14px;
}

#plp-matrix-container,
#plp-season-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.plp-table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.plp-live-scores-table td {
    font-weight: 600;
}

/* Top-menu logout item injected by PLP */
.menu-item-plp-logout > a {
    font-weight: 600;
}

.plp-matrix-table th,
.plp-matrix-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
}

.plp-matrix-table th {
    background: #f0f0f0;
    font-weight: 600;
}

.plp-th-stack {
    display: inline-block;
    line-height: 1.15;
}

.plp-fixture-live-score {
    display: inline-block;
    margin-top: 2px;
    font-size: 11px;
    font-weight: 700;
    color: #124a72;
}

.plp-history-team-col {
    min-width: 120px;
}

.plp-leader-row {
    background: #e8f7ff !important;
}

.plp-empty {
    color: #bbb;
}

/* Points colour coding */
.plp-points-0 {
    background: #ffecec;
}

.plp-points-2 {
    background: #fff8d9;
}

.plp-points-5 {
    background: #e8ffe8;
}

.plp-total {
    font-weight: bold;
    background: #f7f7f7;
}

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

@media (max-width: 700px) {
    .plp-signup-container {
        margin: 16px;
        padding: 16px;
    }

    .plp-home-shell {
        max-width: none;
        margin: 10px;
        padding: 12px;
    }

    .plp-dashboard {
        padding: 12px;
    }

    .plp-action-row {
        flex-direction: column;
    }

    .plp-action-row .plp-btn,
    .plp-action-row button.plp-btn {
        width: 100%;
    }

    .plp-install-btn {
        right: 10px;
        left: 10px;
        bottom: 10px;
        width: calc(100% - 20px);
    }

    .plp-home-actions {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .plp-home-panel {
        padding: 10px;
    }

    .plp-fixture-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding: 14px;
    }

    .plp-fixture-kickoff {
        width: 100%;
        text-align: left;
    }

    .plp-live-score {
        min-width: 0;
        text-align: left;
    }

    .plp-pred-inputs {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .plp-pred-inputs input {
        width: 56px;
        min-height: 42px;
        font-size: 16px;
    }

    .plp-locked-line {
        flex-wrap: wrap;
    }

    .plp-save-pred,
    .plp-btn,
    button.plp-btn {
        min-height: 40px;
        padding: 7px 10px;
        font-size: 14px;
    }

    .plp-summary {
        flex-direction: column;
    }

    #plp-entry-form {
        flex-direction: column;
        align-items: stretch;
    }

    #plp-entry-form input[type="text"] {
        width: 100%;
    }

    #plp-topup-form {
        flex-direction: column;
        align-items: stretch;
    }

    .plp-matrix-table {
        font-size: 11px;
        min-width: 460px;
    }

    .plp-matrix-table th,
    .plp-matrix-table td {
        padding: 6px;
    }

    .plp-mini-leaderboard li {
        font-size: 14px;
    }

    .menu-item-plp-logout > a {
        min-height: 40px;
        display: inline-flex;
        align-items: center;
    }
}

@media (max-width: 430px) {
    .plp-home-shell {
        margin: 6px;
        padding: 10px;
        border-radius: 8px;
    }

    .plp-home-shell h2 {
        font-size: 24px;
    }

    .plp-home-shell h3 {
        font-size: 18px;
    }

    .plp-subtext {
        font-size: 13px;
    }
}
