/* =========================================
   WhatsApp Chatbot Section (From test.html)
   ========================================= */
.wa-chatbot-section {
    max-width: 1152px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    padding-top: 40px;
    padding-bottom: 60px;
}

.wa-chatbot-header-row {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    z-index: 10;
    padding-left: 8px;
    padding-right: 24px;
    padding-bottom: 0px;
}

.wa-chatbot-title-box {
    max-width: 900px;
    padding-bottom: 40px;
}

.wa-chatbot-subtitle {
    color: #40AA60;
    font-weight: 500;
    font-size: 16px;
    margin-bottom: 8px;
    font-family: 'Inter', sans-serif;
}

.wa-chatbot-title {
    font-size: 40px;
    font-weight: 600;
    color: #393737;
    line-height: 52px;
    letter-spacing: 0%;
    vertical-align: middle;
    font-family: 'Rethink Sans', sans-serif;
}

@media (max-width: 1024px) {
    .wa-chatbot-title {
        font-size: 36px;
    }
}

@media (max-width: 768px) {
    .wa-chatbot-title {
        font-size: 30px;
    }

    .wa-chatbot-subtitle {
        font-size: 14px;
    }

    .wa-chatbot-title-box {
        padding-bottom: 24px;
    }
}

.wa-chatbot-mascot-box {
    width: 176px;
    position: absolute;
    right: 0;
    bottom: -15px;
    transform: translateY(2px);
    z-index: 20;
    pointer-events: none;
    display: block;
}

@media (max-width: 1024px) {
    .wa-chatbot-mascot-box {
        width: 128px;
        right: 16px;
    }
}

@media (max-width: 768px) {
    .wa-chatbot-mascot-box {
        display: none;
    }
}

.wa-chatbot-mascot-img {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 13px rgba(0, 0, 0, 0.03)) drop-shadow(0 8px 5px rgba(0, 0, 0, 0.08));
}

.wa-chatbot-green-card {
    border-radius: 36px;
    padding: 64px 56px;
    position: relative;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    width: 100%;
    z-index: 0;
    background: linear-gradient(90deg, #0B5546 0%, #0F9A7D 100%);
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

@media (max-width: 1024px) {
    .wa-chatbot-green-card {
        flex-direction: column;
        padding: 56px;
    }
}

@media (max-width: 768px) {
    .wa-chatbot-green-card {
        padding: 32px;
    }
}

.wa-chatbot-col-left {
    display: flex;
    flex-direction: row;
    align-items: center;
    width: 50%;
    position: relative;
    z-index: 20;
}

.wa-chatbot-col-right {
    display: flex;
    flex-direction: row;
    align-items: center;
    width: 50%;
    justify-content: flex-end;
    position: relative;
    z-index: 10;
}

@media (max-width: 1024px) {
    .wa-chatbot-col-left {
        flex-direction: column;
        width: 100%;
        gap: 24px;
    }

    .wa-chatbot-col-right {
        flex-direction: column-reverse;
        width: 100%;
        gap: 24px;
        margin-top: 48px;
    }
}

.wa-phone-mockup {
    width: 220px;
    height: 460px;
    border-radius: 36px;
    border: 10px solid black;
    position: relative;
    flex-shrink: 0;
    z-index: 30;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-sizing: border-box;
}

.wa-phone-shadow {
    box-shadow: -15px 20px 40px rgba(0, 0, 0, 0.2);
}

.wa-phone-notch {
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 22px;
    background: black;
    border-radius: 9999px;
    z-index: 30;
}

/* Glassmorphism utility */
.wa-glass-panel {
    background: #FFFFFF2B;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.1);
    border-radius: 16px;
    padding: 32px;
    width: 540px;
    flex-shrink: 0;
    z-index: 10;
    box-sizing: border-box;
}

.wa-glass-left {
    align-self: flex-start;
    margin-top: 32px;
    margin-left: -8px;
}

.wa-glass-right {
    text-align: left;
    align-self: flex-end;
    margin-bottom: 32px;
    margin-right: -8px;
}

@media (max-width: 1280px) {
    .wa-glass-panel {
        width: 450px;
    }
}

@media (max-width: 1024px) {
    .wa-glass-left {
        align-self: center;
        margin-top: 0;
        margin-left: 0;
    }

    .wa-glass-right {
        align-self: center;
        margin-bottom: 0;
        margin-right: 0;
    }

    .wa-glass-panel {
        width: 100%;
        max-width: 280px;
        padding: 24px;
    }
}

.wa-info-title {
    color: white;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
    margin-top: 0;
}

.wa-info-desc {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    line-height: 1.625;
    font-weight: 300;
    margin: 0;
}

/* Fix for browser bug where backdrop-filter blur bleeds past border-radius */
.strict-clip {
    -webkit-mask-image: -webkit-radial-gradient(white, black);
    mask-image: radial-gradient(white, black);
    isolation: isolate;
}

/* =========================================
   WhatsApp UI CSS (Scoped to .wa-app)
   ========================================= */
:root {
    --wa-ios-user: #e2ffc7;
    --wa-ios-bot: #ffffff;
    --wa-bg: #efe7dd;
    --ios-blue: #007aff;
}

.wa-app {
    background: url('https://user-images.githubusercontent.com/15075759/28719144-86dc0f70-73b1-11e7-911d-60d70fcded21.png');
    background-color: var(--wa-bg);
    position: absolute;
    top: 0;
    left: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    width: 350px;
    height: 770px;
    transform: scale(0.5714);
    transform-origin: top left;
    border-radius: 46px;
}

.wa-app .wa-header {
    background: rgba(246, 246, 246, 0.94);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 50px 15px 10px;
    display: flex;
    align-items: center;
    border-bottom: 0.5px solid #bbb;
    z-index: 10;
    border-top-left-radius: 46px;
    border-top-right-radius: 46px;
    box-sizing: border-box;
}

.header-back {
    color: var(--ios-blue);
    font-size: 17px;
    display: flex;
    align-items: center;
    cursor: pointer;
    flex: 0 0 70px;
}

.wa-app .avatar {
    width: 34px;
    height: 34px;
    background: #1ab394;
    border-radius: 50%;
    margin: 0 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.wa-app .chat-area {
    flex: 1;
    padding: 10px 14px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
    scrollbar-width: none;
    padding-bottom: 100px;
}

.wa-app .chat-area::-webkit-scrollbar {
    display: none;
}

.msg {
    max-width: 80%;
    padding: 8px 10px;
    font-size: 15px;
    position: relative;
    animation: fadeIn 0.2s ease-in;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
    line-height: 1.4;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #000;
}

.msg.bot {
    align-self: flex-start;
    background: var(--wa-ios-bot);
    border-radius: 10px;
    margin-left: 5px;
}

.msg.user {
    align-self: flex-end;
    background: var(--wa-ios-user);
    border-radius: 10px;
    margin-right: 5px;
}

.msg::before {
    content: "";
    position: absolute;
    top: 0;
    width: 10px;
    height: 13px;
}

.msg.bot::before {
    left: -7px;
    background: radial-gradient(circle at 0 0, transparent 70%, var(--wa-ios-bot) 71%);
}

.msg.user::before {
    right: -7px;
    background: radial-gradient(circle at 100% 0, transparent 70%, var(--wa-ios-user) 71%);
}

.timestamp {
    font-size: 10px;
    color: #8e8e93;
    float: right;
    margin-top: 6px;
    margin-left: 8px;
}

.ticks {
    color: #34b7f1;
    font-size: 11px;
    margin-left: 3px;
}

.opt-btn {
    color: var(--ios-blue);
    font-weight: 500;
    border-top: 0.5px solid #eee;
    margin-top: 8px;
    padding-top: 8px;
    text-align: center;
    cursor: pointer;
    display: block;
}

/* WhatsApp Native PDF Document Styles */
.wa-pdf-box {
    display: flex;
    align-items: center;
    background: rgba(0, 0, 0, 0.04);
    border-radius: 10px;
    padding: 10px;
    margin-bottom: 6px;
    gap: 12px;
}

.wa-pdf-icon {
    width: 40px;
    height: 48px;
    background: #FF453A;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 22px;
    flex-shrink: 0;
}

.wa-pdf-details {
    flex: 1;
    overflow: hidden;
}

.wa-pdf-title {
    font-size: 15px;
    font-weight: 500;
    color: #000;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
    line-height: 1.2;
}

.wa-pdf-size {
    font-size: 13px;
    color: #8E8E93;
}

/* WhatsApp Location Map Styles */
.wa-map-box {
    width: 220px;
    height: 120px;
    background: url('https://static-maps.yandex.ru/1.x/?lang=en-US&ll=76.30,9.98&z=13&l=map') center/cover;
    border-radius: 8px;
    position: relative;
    margin-bottom: 4px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.wa-map-pin {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -100%);
    color: #ea4335;
    font-size: 28px;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.3));
}

.wa-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    z-index: 20;
    display: none;
}

.bottom-sheet {
    position: absolute;
    bottom: -100%;
    left: 10px;
    right: 10px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 14px;
    z-index: 21;
    transition: bottom 0.4s cubic-bezier(0.17, 0.67, 0.22, 1);
    margin-bottom: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    overflow: hidden;
}

.bottom-sheet.active {
    bottom: 0;
}

.sheet-item {
    padding: 15px 20px;
    border-bottom: 0.5px solid #c6c6c8;
    color: var(--ios-blue);
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
}

.sheet-item:last-child {
    border-bottom: none;
}

.typing {
    align-self: flex-start;
    background: #fff;
    padding: 12px 16px;
    border-radius: 18px;
    display: none;
    margin-left: 5px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
}

.dot {
    height: 7px;
    width: 7px;
    background: #919191;
    border-radius: 50%;
    display: inline-block;
    margin-right: 3px;
    animation: dotPulse 1.2s infinite ease-in-out;
}

.dot:nth-child(2) {
    animation-delay: 0.2s;
}

.dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes dotPulse {

    0%,
    100% {
        opacity: 0.3;
    }

    50% {
        opacity: 1;
    }
}

.input-area {
    background: rgba(246, 246, 246, 0.94);
    padding: 10px 15px 30px;
    display: flex;
    align-items: center;
    gap: 15px;
    position: absolute;
    bottom: 0;
    width: 100%;
    box-sizing: border-box;
    border-top: 0.5px solid #bbb;
    z-index: 10;
}

.input-box {
    background: #fff;
    flex: 1;
    padding: 8px 12px;
    border-radius: 20px;
    border: 0.5px solid #bbb;
    color: #c7c7cc;
    font-size: 16px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.input-area i {
    color: var(--ios-blue);
    font-size: 22px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.msg b {
    font-weight: 600;
}