@use "../utils/variables";

/**=====================
      Card CSS Start
==========================**/
.card {
    border: variables.$card-border-width;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
    border-radius: variables.$card-border-radius;
    box-shadow: variables.$card-box-shadow;

    &:empty {
        display: none;
    }

    &:has(.header-img) {
        border-radius: 0.375rem;
        box-shadow: rgba(29, 35, 39, 0.04) 0px 4px 16px;

        .card-header {
            border-bottom: 1px solid variables.$white-dark;
            display: flex;
            align-items: center;
            justify-content: space-between;
            background-color: variables.$white;
            padding: 16px 20px;
        }
    }

    &.payment-card {
        box-shadow: none;
        height: 100%;
        display: block;

        .card-header {
            display: block;
            background-color: #f8f8f87a;
            border: 1px solid rgba(variables.$white-dark, 0.612);
            border-radius: 10px;
            height: 100%;

            .top-payment {
                display: flex;
                align-items: center;
                flex-direction: row-reverse;
                justify-content: space-between;
                gap: 14px;

                .header-img {
                    gap: 10px;
                    align-items: flex-start;

                    img {
                        width: 88px;
                        background-color: #fff;
                        height: 53px;
                        object-fit: contain;
                        padding: 6px;
                        border-radius: 5px;
                        border: 1px solid rgba(238, 238, 238, 0.6117647059);
                    }

                    .header-name {
                        width: calc(100% - 88px - 10px);

                        p {
                            font-size: 15px;
                            margin-bottom: 3px;
                            font-weight: 500;
                            color: #222;
                        }

                        .badge {
                            background-color: var(--primary-color);
                            width: max-content;
                            height: auto;
                            border-radius: 2px;
                            font-size: 11px;
                        }
                    }
                }
            }

            .contain {
                border-top: 1px solid variables.$white-dark;
                margin-top: 13px;
                padding-top: 13px;

                p {
                    font-size: 15px;
                    line-height: 1.5;
                    margin: 0;
                    letter-spacing: 0.3px;
                }

                .payment-keys {
                    display: grid;
                    gap: 3px;

                    li {
                        font-size: 14px;
                        color: #777;
                        position: relative;
                        padding-left: 23px;
                        line-height: 1.9;

                        i {
                            position: absolute;
                            top: 5px;
                            line-height: 1;
                            left: 0;
                            font-size: 16px;
                        }

                        span {
                            color: #222;
                            font-weight: 500;
                        }
                    }
                }
            }
        }

        .footer {
            border-top: 1px solid variables.$white-dark;
            padding-top: 20px;

            .btn {
                background-color: transparent;
                border: 1px solid var(--primary-color);
                color: var(--primary-color);
                padding: 10px 17px;
                letter-spacing: 0.8px;

                &:hover {
                    background-color: var(--primary-color);
                    color: #fff;
                    border-color: transparent;
                }
            }
        }
    }
}

.header-img {
    display: flex;
    align-items: center;
    gap: 5px;

    img {
        width: 62px;
        height: auto;
    }

    h5 {
        margin: 0;
        font-size: 17px;
        font-weight: 500;
        line-height: 1.3;
    }
}

.status-div {
    display: flex;
    align-items: center;
    gap: 8px;

    label {
        margin: 0;
    }
}

.widget-card-box {
    .widget-card {
        display: flex;
        align-items: center;
        flex-direction: row;
        gap: 12px;
        margin-bottom: 0;
        border-radius: 12px;
        background: variables.$white;
        letter-spacing: 0.5px;
        padding: 20px;
        overflow: hidden;
        position: relative;

        h6 {
            font-size: calc(14px + (16 - 14) * ((100vw - 320px) / (1920 - 320)));
            line-height: 1.2;
            margin-bottom: 7px;
            font-weight: 500;
            color: variables.$grey;
        }

        h2 {
            font-size: calc(21px + .0025*(100vw - 320px));
            font-weight: 600;
            color: variables.$dark-font;
            display: flex;
            align-items: flex-end;
            line-height: 1;
            text-transform: capitalize;
            margin: 0;
        }

        .widget-icon {
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 10px;
            border-radius: 4px;
            width: calc(44px + .005*(100vw - 320px));
            height: calc(44px + .005*(100vw - 320px));


            i {
                font-size: 24px;
            }
        }

        .widget-bg-icon {
            position: absolute;
            right: -10px;
            opacity: .05;
            transform: rotate(10deg);
            filter: grayscale(1);
            transition: all .5s ease;

            i {
                font-size: 60px;
                color: variables.$dark-color;
            }
        }
    }

    &:nth-child(1) {
        .widget-card {
            .widget-icon {
                background-color: rgba(variables.$primary-color, 0.1);

                i {
                    color: var(--primary-color);
                }
            }
        }
    }

    &:nth-child(2) {
        .widget-card {
            .widget-icon {
                background-color: rgba(variables.$secondary-color, 0.1);

                i {
                    color: variables.$secondary-color;
                }
            }
        }
    }

    &:nth-child(3) {
        .widget-card {
            .widget-icon {
                background-color: rgba(variables.$warning-color, 0.1);

                i {
                    color: variables.$warning-color;
                }
            }
        }
    }

    &:nth-child(4) {
        .widget-card {
            .widget-icon {
                background-color: rgba(variables.$success-color, 0.1);

                i {
                    color: variables.$success-color;
                }
            }
        }
    }

    &:nth-child(5) {
        .widget-card {
            .widget-icon {
                background-color: rgba(variables.$badge-danger, 0.1);

                i {
                    color: variables.$badge-danger;
                }
            }
        }
    }

    &:nth-child(6) {
        .widget-card {
            .widget-icon {
                background-color: rgba(variables.$tertiary-color, 0.1);

                i {
                    color: variables.$tertiary-color;
                }
            }
        }
    }

    &:nth-child(7) {
        .widget-card {
            .widget-icon {
                background-color: rgba(variables.$info-color, 0.1);

                i {
                    color: variables.$info-color;
                }
            }
        }
    }

    &:nth-child(8) {
        .widget-card {
            .widget-icon {
                background-color: rgba(variables.$dark-color, 0.1);

                i {
                    color: variables.$dark-color;
                }
            }
        }
    }
}

.total-tickets-widget {
    margin-bottom: -26px;

    .tickets-widget-card {
        border: 1px solid variables.$white-dark;
        border-radius: 4px;
        padding: 10px;
        font-size: calc(14px + (16 - 14) * ((100vw - 320px) / (1920 - 320)));
        font-weight: 400;
        color: rgba(variables.$dark-color, 0.8);
        line-height: 1.5;
        background-color: variables.$white !important;
        display: flex;
        align-items: center;
        justify-content: space-between;

        h5 {
            margin: 0;
        }

        .badge {
            width: max-content;
            width: 22px;
            height: 22px;
            border-radius: 4px;
            font-size: 13px;
            line-height: 1;

        }
    }

    .info {
        display: flex;
        align-items: center;
        justify-content: start;
        margin-bottom: 16px;

        li {
            padding: 4px calc(6px + (10 - 6) * ((100vw - 320px) / (1920 - 320)));
            background: linear-gradient(180deg, #e1e1e2 0%, rgba(#e1e1e2, 0.04) 100%);
            border-radius: 5px;
            margin-right: calc(8px + (12 - 8) * ((100vw - 320px) / (1920 - 320)));
            position: relative;
            text-align: center;
            min-width: calc(76px + (100 - 76) * ((100vw - 320px) / (1920 - 320)));

            h5 {
                margin: 0;
                font-size: calc(12px + (14 - 12) * ((100vw - 320px) / (1920 - 320)));
                font-weight: 500;
                opacity: 0.8;
                line-height: 1.1;
            }

            span {
                font-size: calc(12px + (14 - 12) * ((100vw - 320px) / (1920 - 320)));
                font-weight: 600;
                color: variables.$dark-color;
            }

            +li {
                padding-left: calc(8px + (12 - 8) * ((100vw - 320px) / (1920 - 320)));
                margin-left: calc(8px + (12 - 8) * ((100vw - 320px) / (1920 - 320)));

                &:before {
                    content: "";
                    top: 50%;
                    background-color: rgba(variables.$dark-color, 0.1);
                    transform: translate(-15px, -50%);
                    left: calc(6px + (2 - 6) * ((100vw - 320px) / (1920 - 320)));
                    position: absolute;
                    height: 30px;
                    width: 1px;
                }
            }
        }
    }
}

.form-field-box {
    padding: 16px;
    background-color: #f9f9f9;
    border-radius: 6px;
    box-shadow: rgba(29, 35, 39, 0.03) 0px 4px 12px;

    .form-title {
        padding-bottom: 11px;
        margin-bottom: 14px;
        border-bottom: 1px solid variables.$white-dark;

        h4 {
            margin: 0;
            font-weight: 500;
        }
    }

    .form-content-list {
        display: grid;
        gap: 5px;

        li {
            font-size: 16px;

            span {
                color: variables.$grey;
            }
        }
    }

    .from-btn-group {
        margin-top: 16px;
        display: flex;
        padding-top: 13px;
        border-top: 1px solid variables.$white-dark;
        gap: 15px;

        .btn {
            display: block !important;
            font-size: 15px !important;
            padding: 8px 20px;

            &.edit-btn {
                background-color: transparent;
                color: var(--primary-color);
                border: 1px solid var(--primary-color);

                &:hover {
                    background-color: var(--primary-color);
                    color: variables.$white;
                    border-color: transparent;
                }
            }

            &.delete-btn {
                background-color: transparent;
                color: variables.$danger-color;
                border: 1px solid variables.$danger-color;

                &:hover {
                    background-color: variables.$danger-color;
                    color: variables.$white;
                    border-color: transparent;
                }
            }
        }
    }
}