/* perfect-bubbles.css */
@import url('../css/settings.css');

@font-face {
    font-family: 'Cormorant-BoldItalic';
    src: url('../../assets/fonts/Cormorant-BoldItalic.ttf') format('truetype');
    font-weight: bold;
    font-style: italic;
    font-display: swap;
}

.perfect-bubbles {
    position: relative;
    width: 100dvw;
    height: 100dvh;
    overflow: hidden;
    background-color: #1a1a1a;
}

.perfect-bubbles::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../../assets/site-media/womanstan.webp');
    background-size: cover;
    background-position: center;
    opacity: 0.6;
    z-index: 1;
}

.perfect-bubbles__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.perfect-bubbles__header {
    position: relative;
    z-index: 3;
    text-align: center;
    padding: 2rem 0;
}

.perfect-bubbles__title {
    font-family: 'Cormorant-BoldItalic', serif;
    font-size: clamp(2rem, 4vw, 3rem);
    color: #ffffff;
    margin-bottom: 1rem;
}

.perfect-bubbles__stars {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
}

.perfect-bubbles__container {
    position: relative;
    z-index: 3;
    display: flex;
    justify-content: space-between;
    gap: clamp(1rem, 4vw, 4rem);
    padding: 0 clamp(1rem, 3vw, 3rem);
    height: calc(100% - 120px);
}

.perfect-bubbles__column {
    flex: 1;
    overflow: hidden;
    position: relative;
    max-width: 500px;
}

.perfect-bubbles__wrapper {
    position: absolute;
    width: 100%;
    animation: scrollUp 60s linear infinite; /* Increased from 30s to 60s */
    display: flex;
    flex-direction: column;
}

.perfect-bubbles__column--right .perfect-bubbles__wrapper {
    animation: scrollDown 60s linear infinite; /* Increased from 30s to 60s */
}

.bubble {
    position: relative;
    margin-bottom: 2.5rem;
    padding: 2rem;
    border-radius: 30px;
    max-width: 100%;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.bubble--left {
    background-color: #DEE8DF;
    transform: none;
}

.bubble--right {
    background-color: #233539;
    color: #ffffff;
    transform: none;
}

.bubble--left::after,
.bubble--right::after {
    content: '';
    position: absolute;
    bottom: -20px;
    width: 40px;
    height: 20px;
    clip-path: polygon(50% 100%, 0 0, 100% 0);
}

.bubble--left::after {
    left: 30px;
    background-color: #DEE8DF;
}

.bubble--right::after {
    right: 30px;
    background-color: #233539;
}

.bubble__content {
    position: relative;
}

.bubble__name {
    font-family: 'Amsterdam-Four', serif;
    font-size: clamp(1.25rem, 2vw, 1.75rem);
    margin-bottom: 0.75rem;
    text-align: center;
}

.bubble__text {
    font-family: 'Cormorant', serif;
    font-size: clamp(0.875rem, 1.5vw, 1.125rem);
    line-height: 1.6;
    text-align: center;
}

@keyframes scrollUp {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(-50%); /* Only scroll by 50% since we have duplicate content */
    }
}

@keyframes scrollDown {
    0% {
        transform: translateY(-50%); /* Start from halfway point */
    }
    100% {
        transform: translateY(0);
    }
}

.perfect-bubbles__column:hover .perfect-bubbles__wrapper {
    animation-play-state: paused;
}

@media (max-width: 47.9375em) {
    .perfect-bubbles::before {
        background-image: url('../../assets/site-media/womanstanding.webp');
    }

    .perfect-bubbles__container {
        flex-direction: row;
        padding: 0 0.5rem;
        gap: 1rem;
    }

    .perfect-bubbles__column {
        height: calc(100% - 120px);
        width: 50%;
    }

    .bubble {
        padding: 1.5rem;
        margin-bottom: 2rem;
    }

    .bubble__name {
        font-size: clamp(1rem, 4vw, 1.25rem);
    }

    .bubble__text {
        font-size: clamp(0.75rem, 3vw, 0.875rem);
    }
}

@media (hover: hover) {
    .bubble {
        transition: transform 0.3s ease;
    }

    .bubble:hover {
        transform: scale(1.02);
    }
}

@media (prefers-reduced-motion: reduce) {
    .perfect-bubbles__wrapper {
        animation: none;
    }
}
/* RTL Support */
[dir="rtl"] .perfect-bubbles__title {
    text-align: right;
}

[dir="rtl"] .bubble__content {
    text-align: right;
    direction: rtl;
}

[dir="rtl"] .bubble--left {
    margin-right: auto;
    margin-left: 2rem;
}

[dir="rtl"] .bubble--right {
    margin-left: auto;
    margin-right: 2rem;
}

[dir="rtl"] .perfect-bubbles__column--left {
    transform: scaleX(-1);
}

[dir="rtl"] .perfect-bubbles__column--right {
    transform: scaleX(-1);
}

[dir="rtl"] .bubble__content {
    transform: scaleX(-1);
}