/******************************************************
All the default css will place here...
******************************************************/
*,
*::after,
*::before {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

// Add here 

.btn {
    padding: 15px 20px;
    background: #0d4c62;
    border-radius: 3px;
    font-weight: 600;
    font-size: 16px;
    line-height: 21px;
    color: #f8f9fa;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    transition: all 0.3s ease;
    cursor: pointer;
    /* width: 21px; */
    height: 50px;
    white-space: nowrap;

    svg {
        margin-left: 10px;
    }

    &.btn-secondary {
        padding: 5px 15px;
        background: #7f54b3;
        border-radius: 4px;
    }

    &.btn-xl {
        padding: 15px 100px;
    }

    &.btn-lg {
        padding: 15px 50px;
    }

    &.btn-md {
        padding: 15px 30px;
    }

    &.btn-manage {
        color: #ffffff;
        background-color: #3858E9;

        &:hover,
        &:focus {
            background-color: darken($color: #3858E9, $amount: 10px);
        }
    }

    &.add-new-table-btn {
        font-style: normal;
        font-weight: 600;
        font-size: 16px;
        line-height: 21px;
        color: #939393;
        border: 1px dashed #bdc8c4;
        background-color: white;

        svg {
            margin-right: 10px;
        }

        &:hover {
            box-shadow: rgb(240, 242, 248) 0px 0px 0px 5px;
            color: #939393;
            background-color: white;
        }

        &:focus {
            color: #939393;
            border: 1px dashed #bdc8c4;
            box-shadow: none;
            outline: none;
        }
    }

    &.ctaBtn {
        padding: 5px 15px;
        background: #7f54b3;
        border-radius: 4px;
        font-weight: 600;
        font-size: 14px;
        line-height: 19px;
        color: #f8f8f8;

        &:hover {
            color: white;
            background-color: darken($color: #7f54b3, $amount: 10%);
        }
    }

    &:hover {
        color: white;
        background-color: darken($color: #2bb885, $amount: 10%);
    }

    &:focus {
        color: white;
        border: none;
        box-shadow: none;
        outline: none;
    }
}

// Delete button from dashboard
.table-delete {
    max-width: 15px;
    width: 100%;
    height: 15px;
    outline: none;
    border: none;
    box-shadow: none;
    padding: 0;
    background: transparent;
    display: inline-block;
    cursor: pointer;

    svg {
        path {
            transition: all 0.3s ease;
        }
    }

    &:hover {
        animation: delete-shake 0.82s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
        transform: translate3d(0, 0, 0);
        backface-visibility: hidden;
        perspective: 1000px;

        svg {
            path {
                fill: #d63638;
            }
        }
    }

    &:focus {
        outline: none;
        border: none;
        box-shadow: none;
    }
}

// Edit button from dashboard
.table-edit {
    margin-right: 32px;
    // max-width: 15px;
    width: 100%;
    height: 15px;
    display: inline-block;
    outline: none;
    border: none;
    box-shadow: none;
    transition: all 0.3s ease;
    text-decoration: none;

    // zoom the font 
    /* &:hover {
        transform: scale(1.1);
    } */

    &:focus {
        outline: none;
        border: none;
        box-shadow: none;
    }

    h4.simpleform-title.h4 {
        &:hover {
            color: #2271b1 !important;
        }
    }
}

// Shortcode button from dashboard
.btn-shortcode {
    padding: 6px 15px;
    font-weight: 400;
    font-size: 14px;
    line-height: 21px;
    color: #1e1e1e;
    background: #ffffff;
    border: 1px solid #e1e4ea;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    cursor: pointer;
    transition: box-shadow 0.2s ease-out 0s;

    svg {
        margin-right: 6px;
    }

    &:hover {
        box-shadow: rgb(240, 242, 248) 0px 0px 0px 5px !important;
        color: #cc09e0;

        svg {
            fill: #FF7E47;
        }
    }

    &:focus {
        color: #1e1e1e;
        border: 1px solid #e1e4ea;
        box-shadow: none;
        outline: none;
    }
}

//Input Styles
input[type="text"],
input[type="search"] {
    padding: 14px 16px 12px 20px;
    background: #ffffff;
    border: 1px solid #edeff1;
    border-radius: 4px;
    font-style: normal;
    font-weight: 400;
    font-size: 14px;
    line-height: 21px;
    color: #666873;
    outline: none;
    width: 100%;
    height: 50px;

    &:focus {
        border: 1px solid #edeff1;
        outline: none;
        box-shadow: none;
    }
}

::-webkit-input-placeholder {
    /* Edge */
    font-style: normal;
    font-weight: 400;
    font-size: 14px;
    line-height: 21px;
    color: #666873;
}

:-ms-input-placeholder {
    /* Internet Explorer 10-11 */
    font-style: normal;
    font-weight: 400;
    font-size: 14px;
    line-height: 21px;
    color: #666873;
}

::placeholder {
    font-style: normal;
    font-weight: 400;
    font-size: 14px;
    line-height: 21px;
    color: #666873;
}
// Import Analytics Styles
@import '_analytics';

// Import Custom Theme Creator Styles
@import '_custom-theme-creator';

// Import Confirm Modal Styles
@import '_confirm-modal';

// Import Auth Forms Styles
@import '_auth-forms';

// Import Auth Settings Styles
@import '_auth-settings';

// Import Integrations Styles
@import '_integrations';

// Import Quizzes Styles
@import '_quizzes';

// Quiz and Poll Results Styles
.quiz-results-container,
.poll-results-container {
    padding: 20px;

    .quiz-results-header,
    .poll-results-header {
        margin-bottom: 30px;

        .back-btn {
            display: inline-flex;
            align-items: center;
            gap: 8px;
            padding: 8px 16px;
            background: #f3f4f6;
            border: none;
            border-radius: 6px;
            cursor: pointer;
            font-size: 14px;
            color: #374151;
            margin-bottom: 20px;
            transition: background 0.2s;

            &:hover {
                background: #e5e7eb;
            }
        }

        .header-content {
            h1 {
                display: flex;
                align-items: center;
                gap: 12px;
                font-size: 28px;
                color: #111827;
                margin: 0;

                svg {
                    color: #4a6cf7;
                }
            }
        }
    }

    .quiz-stats-cards,
    .poll-stats-cards {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 20px;
        margin-bottom: 30px;

        .stat-card {
            background: white;
            border: 1px solid #e5e7eb;
            border-radius: 8px;
            padding: 20px;
            display: flex;
            align-items: center;
            gap: 16px;

            .stat-icon {
                width: 50px;
                height: 50px;
                border-radius: 10px;
                background: #eff6ff;
                display: flex;
                align-items: center;
                justify-content: center;

                svg {
                    color: #4a6cf7;
                    font-size: 28px;
                }
            }

            .stat-content {
                h3 {
                    font-size: 32px;
                    font-weight: 700;
                    color: #111827;
                    margin: 0 0 4px 0;
                }

                p {
                    font-size: 14px;
                    color: #6b7280;
                    margin: 0;
                }
            }
        }
    }

    .no-results {
        text-align: center;
        padding: 60px 20px;
        background: white;
        border: 1px solid #e5e7eb;
        border-radius: 8px;

        .no-results-icon {
            font-size: 64px;
            color: #d1d5db;
            margin-bottom: 16px;
        }

        h3 {
            font-size: 20px;
            color: #374151;
            margin: 0 0 8px 0;
        }

        p {
            font-size: 14px;
            color: #6b7280;
            margin: 0;
        }
    }

    .submissions-table {
        background: white;
        border: 1px solid #e5e7eb;
        border-radius: 8px;
        overflow: hidden;

        h2 {
            padding: 20px;
            margin: 0;
            border-bottom: 1px solid #e5e7eb;
            font-size: 18px;
            color: #111827;
        }

        table {
            width: 100%;
            border-collapse: collapse;

            thead {
                background: #f9fafb;

                th {
                    padding: 12px 16px;
                    text-align: left;
                    font-size: 12px;
                    font-weight: 600;
                    color: #6b7280;
                    text-transform: uppercase;
                    letter-spacing: 0.5px;
                }
            }

            tbody {
                tr {
                    border-top: 1px solid #e5e7eb;

                    &:hover {
                        background: #f9fafb;
                    }

                    td {
                        padding: 12px 16px;
                        font-size: 14px;
                        color: #374151;
                    }
                }
            }

            .status-badge {
                display: inline-flex;
                align-items: center;
                gap: 4px;
                padding: 4px 12px;
                border-radius: 12px;
                font-size: 12px;
                font-weight: 500;

                &.passed {
                    background: #d1fae5;
                    color: #065f46;
                }

                &.failed {
                    background: #fee2e2;
                    color: #991b1b;
                }

                svg {
                    font-size: 14px;
                }
            }
        }
    }

    .poll-results-chart {
        background: white;
        border: 1px solid #e5e7eb;
        border-radius: 8px;
        padding: 20px;
        margin-bottom: 30px;

        h2 {
            font-size: 18px;
            color: #111827;
            margin: 0 0 20px 0;
        }

        .results-bars {
            display: flex;
            flex-direction: column;
            gap: 16px;

            .result-bar-item {
                .result-label {
                    display: flex;
                    justify-content: space-between;
                    align-items: center;
                    margin-bottom: 8px;

                    .answer-text {
                        font-size: 14px;
                        font-weight: 500;
                        color: #374151;
                    }

                    .answer-stats {
                        font-size: 13px;
                        color: #6b7280;
                    }
                }

                .result-bar-container {
                    width: 100%;
                    height: 32px;
                    background: #f3f4f6;
                    border-radius: 6px;
                    overflow: hidden;

                    .result-bar-fill {
                        height: 100%;
                        background: linear-gradient(90deg, #4a6cf7, #3c57d0);
                        border-radius: 6px;
                        transition: width 0.5s ease;
                        display: flex;
                        align-items: center;
                        justify-content: flex-end;
                        padding-right: 12px;
                        color: white;
                        font-size: 12px;
                        font-weight: 600;
                        min-width: 40px;
                    }
                }
            }
        }
    }
}

.quiz-results-loading,
.poll-results-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;

    .spinner {
        border: 4px solid rgba(0, 0, 0, 0.1);
        width: 40px;
        height: 40px;
        border-radius: 50%;
        border-left-color: #4a6cf7;
        animation: spin 1s linear infinite;
        margin-bottom: 16px;
    }

    p {
        font-size: 14px;
        color: #6b7280;
    }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
