@use '../../../styles/variables' as *;
@use '../../../styles/mixins' as *;

.awt-page-title {
    position: relative;
    overflow: hidden;
    width: 100%;
    padding-top: 5rem;
    padding-bottom: 7rem;
    background-color: var(--awt-page-title-bg, rgba(0, 198, 255, 0.1));
    box-sizing: border-box;

    *,
    *::before,
    *::after {
        box-sizing: inherit;
    }

    &__wave {
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        overflow: hidden;
        line-height: 0;
        z-index: 1;
        pointer-events: none;

        svg {
            display: block;
            width: 100%;
            height: auto;
        }
    }

    &__container {
        @include awt-container;
        position: relative;
        z-index: 10;
        text-align: center;
    }

    &__box {
        max-width: 48rem;
        margin-left: auto;
        margin-right: auto;
    }

    &__badge {
        display: inline-block;
        font-size: 0.75rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.15em;
        margin-bottom: 1rem;
    }

    &__heading {
        line-height: 1.15;
        margin: 0 0 1rem 0;
    }

    &__subtitle {
        margin: 0 auto;
        line-height: 1.6;
    }

    // --- FUN VARIANT STYLES ---
    &--fun {
        background-color: var(--awt-page-title-bg, rgba(0, 198, 255, 0.1));

        .awt-page-title__heading {
            font-family: $awt-font-sans;
            font-size: clamp(2.25rem, 5vw, 4rem);
            font-weight: 900;
            color: var(--awt-page-title-heading-color, $awt-color-navy);
            letter-spacing: -0.02em;
        }

        .awt-page-title__subtitle {
            font-size: 1.25rem;
            color: var(--awt-page-title-text-color, rgba(38, 70, 83, 0.8));
            max-width: 36rem;
        }
    }

    // --- ELEGANT VARIANT STYLES ---
    &--elegant {
        background-color: var(--awt-page-title-bg, #f8fafc);
        padding-top: 5rem;
        padding-bottom: 6rem;

        .awt-page-title__badge {
            color: #64748b;
        }

        .awt-page-title__heading {
            font-family: $awt-font-serif;
            font-size: clamp(2.25rem, 5vw, 4rem);
            font-weight: 700;
            color: var(--awt-page-title-heading-color, #1e293b);
            letter-spacing: -0.01em;
            margin-bottom: 1.5rem;
        }

        .awt-page-title__subtitle {
            font-family: $awt-font-sans;
            font-size: 1.25rem;
            font-weight: 300;
            color: var(--awt-page-title-text-color, #64748b);
            max-width: 42rem;
            line-height: 1.7;
        }
    }

    // --- AUTHOR PRO VARIANT STYLES ---
    &--author-pro {
        background-color: var(--awt-page-title-bg, #f8fafc);
        padding-top: 5rem;
        padding-bottom: 5rem;
        border-bottom: 1px solid #f1f5f9;

        .awt-page-title__box {
            max-width: 56rem;
        }

        .awt-page-title__badge {
            color: var(--awt-color-accent, #ea580c);
        }

        .awt-page-title__heading {
            font-family: $awt-font-serif;
            font-size: clamp(2rem, 4.5vw, 3.5rem);
            font-weight: 700;
            color: var(--awt-page-title-heading-color, #0f172a);
            margin-bottom: 1.25rem;
        }

        .awt-page-title__subtitle {
            font-size: 1.125rem;
            color: var(--awt-page-title-text-color, #475569);
            max-width: 42rem;
            line-height: 1.7;
        }
    }
}
