:root {
    --cartola-primary: #ae2828;
    --cartola-gold: #ffc437;
    --cartola-dark: #262b2e;
}

.fi-topbar-ctn .fi-topbar {
    background-color: var(--cartola-primary) !important;
    border-bottom: 0;
    box-shadow: none;
    --tw-ring-shadow: 0 0 #0000;
}

.fi-topbar-ctn .fi-topbar .fi-icon-btn,
.fi-topbar-ctn .fi-topbar .fi-topbar-item-btn,
.fi-topbar-ctn .fi-topbar .fi-topbar-item-label {
    color: #fff !important;
}

.fi-topbar-ctn .fi-topbar .fi-icon-btn:hover,
.fi-topbar-ctn .fi-topbar .fi-topbar-item-btn:hover {
    background-color: rgb(255 255 255 / 0.12) !important;
}

.fi-topbar-ctn .fi-topbar .fi-logo img {
    max-height: 2.75rem;
    width: auto;
}

.cartola-member-accent-bar {
    height: 4px;
    background: var(--cartola-gold);
}

.fi-sidebar-nav .fi-sidebar-item.fi-active > .fi-sidebar-item-btn {
    background-color: rgb(174 40 40 / 0.08);
}

.member-dashboard {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.member-dashboard-benefits-sections {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.member-dashboard-actions {
    margin-top: 1.25rem;
}

.member-account-details {
    display: grid;
    gap: 0.75rem;
    font-size: 0.875rem;
}

.member-subscription-card {
    border-radius: 0.75rem;
    border: 1px solid rgb(229 231 235);
    padding: 1rem;
}

.member-subscription-card--spaced {
    margin-bottom: 1rem;
}

.member-benefits-content {
    font-size: 0.95rem;
    line-height: 1.65;
    color: var(--cartola-dark);
}

.member-benefits-content p {
    margin: 0 0 1.25rem;
}

.member-benefits-content p:last-child {
    margin-bottom: 0;
}

.member-benefits-content figure + p,
.member-benefits-content .wp-block-image + p {
    margin-top: 1.25rem;
}

.member-benefits-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
}

.member-benefits-content .wp-block-image {
    margin: 0 0 1.25rem;
    text-align: center;
}

.member-benefits-content .wp-block-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin: 1.25rem 0;
}

.member-benefits-content .wp-block-button__link {
    display: block;
    width: 100%;
    padding: 0.85rem 1.25rem;
    border-radius: 9999px;
    text-align: center;
    text-decoration: none;
    font-weight: 600;
    line-height: 1.35;
    transition: opacity 0.15s ease;
}

.member-benefits-content .wp-block-button__link:hover {
    opacity: 0.92;
}

.member-benefits-content .has-vivid-green-cyan-background-color {
    background-color: #00d084 !important;
    color: #fff !important;
}

.member-benefits-content .has-pale-cyan-blue-background-color {
    background-color: #8ed1fc !important;
    color: #000 !important;
    border: 2px solid #000;
}

.member-benefits-content .has-vivid-red-background-color {
    background-color: var(--cartola-primary) !important;
    color: #fff !important;
}

.member-benefits-content .has-luminous-vivid-amber-background-color {
    background-color: var(--cartola-gold) !important;
    color: #000 !important;
}

.member-benefits-content .has-luminous-vivid-orange-background-color {
    background-color: #ff6900 !important;
    color: #fff !important;
}

.member-account-grid {
    display: grid;
    gap: 2rem;
}

@media (min-width: 1024px) {
    .member-account-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Login */
.fi-simple-layout {
    position: relative;
    min-height: 100vh;
    background: #f0f0f0;
    padding-top: 72px;
}

.cartola-site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 20;
    background: var(--cartola-primary);
    padding: 10px 1rem;
    display: flex;
    justify-content: center;
}

.cartola-site-header img {
    max-height: 48px;
    width: auto;
}

.fi-simple-main-ctn {
    position: relative;
    z-index: 1;
}

.fi-simple-main {
    width: 100%;
    max-width: 28rem;
}

.fi-simple-page {
    background: #fff;
    border-radius: 1rem;
    overflow: hidden;
    border-top: 4px solid var(--cartola-gold);
}

.fi-simple-page-content {
    padding: 2rem 2rem 1.5rem;
}

.fi-simple-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.fi-simple-layout .fi-simple-header .fi-logo {
    display: none;
}

.fi-simple-header .fi-logo img {
    max-height: 3.5rem;
    width: auto;
    margin: 0 auto 1rem;
}

.fi-simple-header-heading {
    color: var(--cartola-dark);
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.3;
}

.fi-simple-header-subheading {
    margin-top: 0.5rem;
    color: #6c767c;
    font-size: 0.9rem;
    line-height: 1.5;
    max-width: 22rem;
    margin-left: auto;
    margin-right: auto;
}

.fi-simple-page .fi-fo-field-wrp-label {
    color: var(--cartola-dark);
    font-weight: 600;
}

.fi-simple-page .fi-input-wrp {
    border-radius: 0.5rem;
}

.fi-simple-page .fi-btn.fi-color-primary {
    background-color: var(--cartola-primary) !important;
    border-color: var(--cartola-primary) !important;
    color: #fff !important;
    font-weight: 600;
    padding-block: 0.7rem;
    border-radius: 0.5rem;
    width: 100%;
    justify-content: center;
}

.fi-simple-page .fi-btn.fi-color-primary:hover {
    background-color: #962020 !important;
    border-color: #962020 !important;
}

.cartola-login-footer {
    margin: 1.25rem 0 0;
    padding-top: 1.25rem;
    border-top: 1px solid #e5e7eb;
    text-align: center;
    font-size: 0.875rem;
}

.cartola-login-footer a {
    color: var(--cartola-primary);
    font-weight: 600;
    text-decoration: none;
}

.cartola-login-footer a:hover {
    text-decoration: underline;
}

.member-payments {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.member-payments-table-wrap {
    overflow: visible;
}

.member-payments-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.member-payments-table th,
.member-payments-table td {
    padding: 0.85rem 0.75rem;
    text-align: left;
    vertical-align: middle;
    border-bottom: 1px solid rgb(229 231 235);
    white-space: nowrap;
}

.member-payments-table th {
    color: rgb(107 114 128);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.member-payments-table tbody tr:last-child th,
.member-payments-table tbody tr:last-child td {
    border-bottom: none;
}

.member-payments-table__plan {
    font-weight: 600;
    color: var(--cartola-dark);
    white-space: normal;
    min-width: 160px;
}

.member-payments-table__action {
    text-align: right;
}

.member-payment-badge {
    display: inline-flex;
    align-items: center;
    border-radius: 9999px;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
}

.member-payment-badge--pending {
    background: rgb(255 196 55 / 0.25);
    color: #8a6200;
}

.member-payment-badge--paid {
    background: rgb(0 208 138 / 0.2);
    color: #0a7a2f;
}

.member-pending-alert {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    background: rgb(255 196 55 / 0.18);
    border: 1px solid rgb(255 196 55 / 0.55);
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
}

.member-pending-alert__title {
    margin: 0 0 0.25rem;
    font-weight: 700;
    color: #8a6200;
}

.member-pending-alert__text {
    margin: 0;
    font-size: 0.875rem;
    color: var(--cartola-dark);
}

.member-pending-alert__content {
    min-width: 0;
    flex: 1;
}

.member-account-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
    margin: 0 0 1.5rem;
    padding: 0.85rem 1rem;
    background: #fff;
    border: 1px solid rgb(229 231 235);
    border-radius: 0.75rem;
}

.member-account-nav a {
    color: var(--cartola-dark);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
}

.member-account-nav a:hover,
.member-account-nav a.is-active {
    color: var(--cartola-primary);
    text-decoration: underline;
}

.member-account-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.member-account-form__grid {
    display: grid;
    gap: 1rem;
}

@media (min-width: 768px) {
    .member-account-form__grid {
        grid-template-columns: 1fr 1fr;
    }

    .member-account-form__full {
        grid-column: 1 / -1;
    }
}

.member-account-form label {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--cartola-dark);
}

.member-account-form input {
    width: 100%;
    border: 1px solid rgb(209 213 219);
    border-radius: 0.5rem;
    padding: 0.7rem 0.85rem;
    font-weight: 400;
}

.member-account-form input[readonly] {
    background: #f8f8f8;
}

.member-account-form small {
    font-weight: 400;
    color: #6c767c;
}

@media (max-width: 767px) {
    .member-payments-table,
    .member-payments-table thead,
    .member-payments-table tbody,
    .member-payments-table th,
    .member-payments-table td,
    .member-payments-table tr {
        display: block;
        width: 100%;
    }

    .member-payments-table {
        min-width: 0;
    }

    .member-payments-table thead {
        display: none;
    }

    .member-payments-table tr {
        border: 1px solid rgb(229 231 235);
        border-radius: 0.75rem;
        padding: 0.75rem 1rem;
        margin-bottom: 0.85rem;
    }

    .member-payments-table td {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        gap: 1rem;
        border-bottom: 1px solid rgb(243 244 246);
        padding: 0.65rem 0;
        white-space: normal;
    }

    .member-payments-table td:last-child {
        border-bottom: none;
    }

    .member-payments-table td::before {
        content: attr(data-label);
        font-size: 0.75rem;
        font-weight: 700;
        letter-spacing: 0.02em;
        text-transform: uppercase;
        color: rgb(107 114 128);
        flex: 0 0 42%;
    }

    .member-payments-table__action {
        text-align: right;
    }
}
