.contact-popup {
    position: fixed;
    bottom: 50px; /* Increased from 20px to make room for triangle */
    right: 30px;
    background-color: #1f396b; /* Keeping the navy blue color */
    color: white;
    border-radius: 20px; /* Increased border radius to match image */
    padding: 20px 20px; /* Increased top/bottom padding */
    width: 280px; /* Wider to match image */
    max-width: 90vw;
    font-family: 'Barlow Semi Condensed', Arial, sans-serif;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    z-index: 1000;
    box-sizing: border-box;
    display: none;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease-in-out, transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    will-change: opacity, transform;
}

.contact-popup.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* Completely redesigned speech bubble pointer to match image */
.contact-popup::after {
    content: "";
    position: absolute;
    bottom: -25px; /* Reduced from -30px to keep it from extending too far */
    left: 50px; /* Adjusted position from left */
    height: 0;
    width: 0;
    border-style: solid;
    border-width: 25px 20px 0 20px; /* Slightly smaller to fit in the space */
    border-color: #1f396b transparent transparent transparent;
    z-index: 990; /* Ensure triangle appears below popup but above other content */
}

.contact-image {
    position: absolute;
    top: -30px; /* Adjusted to align with top edge */
    right: -30px; /* Adjusted to align with right edge */
    width: 70px; /* Increased size */
    height: 70px; /* Increased size */
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid white;
    box-shadow: 0 0 5px rgba(0,0,0,0.2);
}

.contact-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
	background-color:#ffffff;
}

.contact-title {
    font-weight: 600;
    font-size: 25px !important; /* Increased for larger title */
    padding-right: 50px; /* More space for image */
    margin-bottom: 15px; /* More space between title and options */
    line-height: 1.3;
    word-wrap: break-word;
}

.contact-option {
    display: flex;
    align-items: center;
    margin: 10px 0; /* Increased spacing between options */
    font-size: 20px; /* Larger font size */
    cursor: pointer;
    transition: opacity 0.2s, transform 0.3s ease;
}

.contact-option:hover {
    opacity: 0.8;
    transform: translateX(5px);
}

.contact-option i {
    margin-right: 15px; /* More space between icon and text */
    width: 24px; /* Larger icon */
    font-size: 24px; /* Larger icon */
    text-align: center;
    transition: transform 0.3s ease;
}

.contact-option:hover i {
    transform: translateX(3px);
}

.popup-toggle {
    position: fixed;
    bottom: 20px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: #1f396b;
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    z-index: 999;
    font-size: 24px;
    transform-origin: center;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), background-color 0.3s ease;
}

.popup-toggle:hover {
    background-color: #2a4985;
    transform: scale(1.15) rotate(5deg);
}

.popup-toggle.clicked {
    transform: scale(0.1) rotate(180deg);
    opacity: 0;
}

.contact-option a {
    color: white;
    text-decoration: none;
    display: block;
    width: 100%;
    cursor: pointer;
}

/* Form styles for callback request */
.callback-form {
    display: none;
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.4s ease-in-out, transform 0.4s ease-out;
}

.callback-form.active {
    display: block;
    opacity: 1;
    transform: translateX(0);
}

#mainView {
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.4s ease-in-out, transform 0.4s ease-out;
}

#mainView.hiding {
    opacity: 0;
    transform: translateX(-30px);
}

.callback-form-field {
    margin-bottom: 15px;
}

.callback-form-field label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
}

.callback-form-field input {
    width: 100%;
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ccc;
    box-sizing: border-box;
    font-family: 'Barlow Semi Condensed', Arial, sans-serif;
}

.callback-form-field input {
    color: gray; /* default when empty */
}

.callback-form-field input:focus {
    color: black; /* turns black on focus */
}

.callback-form-field input:not(:placeholder-shown) {
    color: black; /* stays black if text is entered */
}

.callback-form-field textarea {
    width: 100%;
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ccc;
    box-sizing: border-box;
    font-family: 'Barlow Semi Condensed', Arial, sans-serif;
    resize: vertical;
    min-height: 80px;
}

.callback-form-field textarea:focus {
    outline: none;
    border-color: #25b0e6;
    box-shadow: 0 0 3px rgba(37, 176, 230, 0.3);
}

.callback-submit {
    background-color: #25b0e6;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    font-size: 16px;
    cursor: pointer;
    font-family: 'Barlow Semi Condensed', Arial, sans-serif;
    width: 50%;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.callback-submit:hover {
    background-color: #1c8db8;
    transform: translateY(-2px);
}

.form-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
	gap:10px;
	text-align:center;
}

.form-cancel {
    background-color: #6c757d;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    font-size: 16px;
    cursor: pointer;
    font-family: 'Barlow Semi Condensed', Arial, sans-serif;
    width: 48%;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.form-cancel:hover {
    background-color: #5a6268;
    transform: translateY(-2px);
}

.form-success {
    display: none;
    color: #ffffff;
    text-align: center;
    margin-top: 10px;
    padding: 8px;
    background-color: #233C69;
    border-radius: 4px;
    animation: fadeInUp 0.5s ease forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media screen and (max-width: 768px) {
    .contact-popup {
        width: 150px;
    }
}

@media screen and (max-width: 480px) {
    .contact-popup {
        bottom: 10px;
        right: 10px;
        padding: 15px;
        width: calc(100% - 100px);
    }

    .contact-image {
        width: 50px;
        height: 50px;
        top: -15px;
        right: -10px;
    }

    .contact-title {
        font-size: 16px !important;
        margin-bottom: 10px;
    }

    .contact-option {
        font-size: 14px;
        margin: 10px 0;
    }
}

.popup-close {
    position: absolute;
    top: -5px;
    left: -10px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1001;
    color: black;
    font-size: 16px;
    opacity: 0.8;
    transition: all 0.3s ease;
    background: white;
    border-radius: 20px;
}

.popup-close:hover {
    opacity: 1;
    transform: rotate(90deg);
}