/**
 * @version     CVS: 1.0.0
 * @package     com_alertas
 * @subpackage  mod_alertas
 * @copyright   2026 Railson Rodrigues leite
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 * @author      Railson Rodrigues leite <railsonrdr@hotmail.com>
 */

:root {
    --alert-primary: #0f6cf1;
    --alert-ghost: #f0f4ff;
    --alert-border: #e4e6ed;
    --alert-bg: #f8f9fb;
    --metric-label: #5b6170;
    --metric-hint: #8d93a5;
    --badge-recall: #e53935;
    --badge-warning: #f9a825;
    --card-bg: #ffffff;
    --text-default: #1f2333;
}

#central-de-alertas {
    padding: 32px;
}

/* onda superior */
#central-de-alertas::before {
    content: "";
    position: absolute;
    top: -118px;
    left: 0;
    width: 100%;
    height: 120px;
    background-color: var(--iq-wave-bg);
    pointer-events: none;
    z-index: 0;
    -webkit-mask-image: var(--wave-mask-svg);
    mask-image: var(--wave-mask-svg);
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
}

.alert-center-header{
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 36px;
    justify-content: space-between;
}


.alert-center-eyebrow i{
    font-size: 30px;
    color: rgba(223, 32, 32, 1);
    padding: 14px;
    background-color: rgba(223, 32, 32, 0.1);
    border: 1px solid rgba(223, 32, 32, 0.2);
    display: inline-block;
    height: 60px;
    width: 60px;
    border-radius: 16px;;
}

.alert-center-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #ffe1cc;
    color: #c54100;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.alert-center-header h2 {
    margin: 0 0 8px;
    font-size: 30px;
    color: var(--text-default);
    font-weight: bold;
}

.alert-center-lead {
    margin: 0;
    color: var(--metric-label);
    max-width: 560px;
    line-height: 1.5;
    font-size: 18px;
}

.alert-center-actions {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.alert-center-action.primary {
    background: var(--alert-primary);
    color: #fff;
    box-shadow: 0 10px 20px rgba(15, 108, 241, 0.25);
}

.alert-center-action.ghost {
    background: var(--alert-ghost);
    color: var(--alert-primary);
}

.alert-center-action{
    background-color: rgba(13, 81, 191, 1);
    padding: 10px 20px;
    color: #fff;
    border-radius: 4px;
    margin: 10px 0;
    border: 0px;
    text-align: center;
}

.alert-center-action:hover {
    transform: translateY(-1px);
}

.alert-center-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.metric-card {
    background: #fff;
    padding: 15px;
    border-radius: 16px;
    border: 1px solid rgba(220, 223, 229, 1);   
}

.metric-card-label {
    margin: 0 0 6px;
    font-size: 14px;    
}

.metric-card-value {
    margin: 0;
    font-size: 30px;
    font-weight: 700;
}

.metric-card-hint {
    margin: 4px 0 0;
    font-size: 12px;
}

.metric-card-hint.success {
    color: #1ca67a;
    font-weight: 600;
}

.alert-center-list {
    border: 1px solid var(--alert-border);
    border-radius: 16px;
    background: #fff;
}

.alert-list-header {
    display: flex;
    /* justify-content: ; */
    gap: 10px;
    align-items: center;
    padding: 10px 30px;
    background:rgba(234, 237, 240, 0.3);
    border-bottom: 1px solid var(--alert-border);
}

.alert-list-header h3 {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
}


.alert-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.alert-card {
    display: flex;
    align-items: center;
    padding: 8px 30px;
    border-top: 1px solid rgba(220, 223, 229, 1);
    position: relative;
    cursor: pointer;
    transition: box-shadow 0.2s ease;
}

.alert-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.alert-badge {
    background: rgba(13, 81, 191, 1);
    color: #FFF;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 13px;
    line-height: 16px;
    font-weight: 400;
}

.critico .alert-badge {
    background: var(--bs-danger);
    color: var(--bs-white);
}
.alto .alert-badge {
    background: var(--bs-yellow);
    color: var(--bs-black);
}
.medio .alert-badge {
    background: rgba(13, 81, 191, 1);
    color: var(--bs-white);
}
.baixo .alert-badge {
    background: rgba(13, 81, 191, 0.6);
    color: var(--bs-white);
}

.alert-card-body {
    flex: 1;
}

.alert-card-meta {
    font-size: 14px;
    color: var(--metric-hint);
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
    margin: 10px 0;
}

.alert-card-meta-items {
    display: flex;
    gap: 12px;
    align-items: center;
}

.alert-card-product{
    color: rgba(103, 111, 126, 1);
    line-height: 2em;
    font-size: 18px;
}

.alert-card-body h4 {
    margin: 6px 0;
    font-size: 16px;
}

.alert-card-body p {
    margin: 0;
    color: var(--metric-label);
    font-size:20px
}

.alert-card-link {
    border: none;
    background: transparent;
    font-size: 30px;
    cursor: pointer;
    color: #676F7E;
}

.alert-list-footer {
    text-align: left;
    margin-top: 16px;
    background: rgb(234, 237, 240, 0.3);
    padding: 10px 30px;
}

.alert-list-footer a {
    color: var(--alert-primary);    
    text-decoration: none;
    font-size: 1.2em;
}

@media (max-width: 768px) {
    .alert-center {
        padding: 20px;
    }

    .alert-center-header {
        flex-direction: column;
    }

    .alert-center-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .alert-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .alert-card-link {
        align-self: flex-end;
    }
}
