html {
    margin: 0;
    overflow-x: hidden;
}

body {
    margin: 0;
    background: linear-gradient(180deg, #02BBEE 0%, #041A88 38.94%, #5975FF 70.01%, #C0CBFF 100%);
    background-repeat: no-repeat;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Page-specific backgrounds */
body.login-page,
body.register-page,
body.chat-page,
body.trip-form-page {
    background: linear-gradient(180deg, #02BBEE 0%, #5975FF 100%);
}


body.chat-page .content {
    height: calc(100vh - 140px);
    overflow: visible;
    margin-top: 20px;
}


body.login-page .hero-section,
body.register-page .hero-section,
body.trip-form-page .hero-section {
    height: calc(100% - 100px);
    margin-top: 0;
    justify-content: center;
    align-items: center;
    display: flex;
}

body.chat-page .hero-section {
    height: calc(100% - 100px);
    margin-top: 0;
    justify-content: center;
    align-items: center;
    display: flex;
}

body.login-page .login-section,
body.register-page .login-section,
body.trip-form-page .login-section {
    margin-top: -200px;
    margin-left: 0;
    margin-right: 0;
}

body.trip-form-page .login-section {
    width: 800px;
    max-width: 90vw;
    padding: 35px;
    z-index: 100;
    position: relative;
}

body.login-page footer,
body.register-page footer,
body.chat-page footer,
body.trip-form-page footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    margin-top: 0;
    z-index: 200;
    height: 60px;
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(5px);
}

body.login-page footer h1,
body.register-page footer h1,
body.trip-form-page footer h1 {
    margin: 0;
    padding: 20px;
    text-align: center;
    color: #FFF;
    font-family: "DM Sans", sans-serif;
    font-size: 14px;
    border-top: 2px solid rgba(255, 255, 255, 0.2);
}

body.chat-page footer h1 {
    margin: 0;
    padding: 20px;
    text-align: center;
    color: #FFF;
    font-family: "DM Sans", sans-serif;
    font-size: 14px;
    border-top: none;
}

.chat-title {
    display: none;
    position: absolute;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 200;
    text-align: center;
    width: 100%;
}

/* Hide chat title on large screens */
@media (min-width: 1200px) {
    .chat-title {
        display: none;
    }
    
    /* Fix loading container centering on large screens */
    .loading-container {
        margin-top: 0 !important;
        justify-content: center !important;
    }
}

/* Mac screen optimizations (MacBook Air/Pro 13-14 inch) */
@media (min-width: 1024px) and (max-width: 1680px) and (min-height: 801px) {
    #testimonialWrapper {
        margin-left: 50px !important;
        padding-bottom: 50px !important;
    }
    
    #testimonials {
        margin-left: -50px !important;
        padding-bottom: 50px !important;
    }
    
    /* Move trip form up on Mac screens */
    body.trip-form-page .login-section {
        transform: translateY(-100px) !important;
    }
    
    /* Move login box down on Mac screens */
    body.login-page .login-section {
        transform: translateY(200px) !important;
    }
    
    /* Move loading screen up on Mac screens */
    .loading-container {
        transform: translateY(-100px) !important;
    }
    
    /* Mobile paywall adjustments */
    .paywall-content {
        padding: 25px !important;
        max-width: 90% !important;
    }
    
    .paywall-content h2 {
        font-size: 22px !important;
    }
    
    .amount {
        font-size: 36px !important;
    }
    
    /* Adjust chatbox on Mac screens */
    body.chat-page .hero-section .chat-section .chat-window {
        transform: translateY(-200px) !important;
        height: 750px !important;
        width: 1000px !important;
        max-width: 1000px !important;
    }
}

/* Larger screens - reset testimonials positioning */
@media (min-width: 1681px) {
    #testimonialWrapper {
        margin-left: 100px !important;
        padding-bottom: 0 !important;
    }
    
    #testimonials {
        margin-left: 0 !important;
        padding-bottom: 0 !important;
    }
    
    /* Move all forms down on larger screens */
    body.login-page .login-section,
    body.register-page .login-section,
    body.trip-form-page .login-section {
        transform: translateY(200px) !important;
    }
    
    /* Ensure loading screen is properly styled on larger screens */
    .loading-container {
        transform: translateY(0) !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        z-index: 1000 !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        height: 100vh !important;
    }
    
    .loading {
        color: #FFF !important;
        font-family: "DM Sans" !important;
        font-size: 24px !important;
        font-weight: 600 !important;
        text-align: center !important;
        margin-top: 20px !important;
    }
    
    .loading-spinner {
        border: 8px solid #f3f3f3 !important;
        border-top: 8px solid #3498db !important;
        border-radius: 50% !important;
        width: 60px !important;
        height: 60px !important;
        animation: spin 2s linear infinite !important;
    }
    
    /* Ensure first message data dump is hidden on larger screens */
    .hidden-first-message {
        display: none !important;
    }
    
    /* Prevent scrolling down on chatbox for larger screens */
    body.chat-page {
        overflow: hidden !important;
    }
    
    body.chat-page .chat-messages {
        overflow-y: auto !important;
        max-height: calc(100vh - 200px) !important;
    }
}

.chat-title h2 {
    color: #FFF;
    font-family: "DM Sans";
    font-size: 60px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    margin: 0;
}

/* Paywall Overlay Styling */
.paywall-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    backdrop-filter: blur(10px);
}

.paywall-content {
    background: linear-gradient(180deg, #02BBEE 0%, #041A88 100%);
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    animation: paywallSlideIn 0.5s ease-out;
}

@keyframes paywallSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.paywall-content h2 {
    color: #FFF;
    font-family: "DM Sans";
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.3;
}

.paywall-content p {
    color: #FFF;
    font-family: "DM Sans";
    font-size: 16px;
    margin-bottom: 25px;
    opacity: 0.9;
}

.paywall-pricing {
    margin: 30px 0;
}

.price-tag {
    display: inline-flex;
    align-items: baseline;
    gap: 5px;
    background: rgba(255, 255, 255, 0.2);
    padding: 15px 25px;
    border-radius: 15px;
    margin-bottom: 25px;
}

.currency {
    color: #FFF;
    font-family: "DM Sans";
    font-size: 24px;
    font-weight: 600;
}

.amount {
    color: #FFF;
    font-family: "DM Sans";
    font-size: 48px;
    font-weight: 700;
}

.period {
    color: #FFF;
    font-family: "DM Sans";
    font-size: 16px;
    font-weight: 400;
    opacity: 0.8;
}

.paywall-btn {
    background: #FFF;
    color: #041A88;
    border: none;
    padding: 15px 40px;
    border-radius: 30px;
    font-family: "DM Sans";
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 20px;
    width: 100%;
    max-width: 300px;
}

.paywall-btn:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.paywall-features {
    color: #FFF;
    font-family: "DM Sans";
    font-size: 14px;
    line-height: 1.6;
    opacity: 0.9;
    margin-top: 20px;
    text-align: left;
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 10px;
}

.navbar {
    text-decoration: none;
    z-index: 5;
    display: flex;
    align-items: center;
    padding: 0 10px;
    gap: 15px;
    margin-right: 20px;
    margin-left: 20px;
}

.navbar .logo {
    height: 35px;
    width: auto;
}

#titleText {
    color: #FFF;
    font-family: "DM Sans";
    font-size: 32px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
}

.nav-group {
    z-index: 5;
    display: flex;
    gap: 35px;
    margin-left: auto;
    margin-right: 10px;
    text-decoration: none;
}

.navItem {
    color: #FFF;
    text-decoration: none;
    font-family: "DM Sans";
    font-size: 24px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
    cursor: pointer;
    a {
        text-decoration: none;
        color: #FFF;
    }
}

.hero-section {

    margin-top: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    flex: 1;                      /* take remaining height */
    display: flex;
    justify-content: center;       /* horizontal center */
    align-items: center;
}

.hero-text {
    color: #FFF;
    text-align: center;
    font-family: "DM Sans";
    font-size: 30px;
    font-style: normal;
    font-weight: 500;
    line-height: 20px;
}

.hero-search {
    z-index: 10;
    width: 591px;
    height: 42px;
    flex-shrink: 0;
    background: #FFFCF8;
    display: flex;
    padding: 10px;
    border-radius: 30px;
    box-shadow: 0 0 30px 5px rgba(0, 0, 0, 0.25);
}

.search-form {
    display: flex;
    gap: 0px;
    width: 100%;
    align-items: center;
    position: relative;
}

.search-form input[type="text"] {
    flex-grow: 1;
    background: inherit;
    font-size: 18px;
    border-radius: 30px;
    border: none;
    padding: 10px 90px 10px 20px;
    text-indent: 0;
    width: 100%;
}

.search-form input[type="submit"] {
    position: absolute;
    right: 5px;
    border-radius: 25px;
    background: #659CFF;
    width: 80px;
    height: 36px;
    font-size: 16px;
    border: none;
    color: #FFF;
    cursor: pointer;
}

.details {
    display: flex;
    position: relative;
}

.content {
    height: 100%;
    z-index: 3;
    position: relative;
    padding-bottom: 35px;
}

#earthWrapper {
    pointer-events: none;
    z-index: 1;
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    width: 2836.171px;
    height: 2826.405px;
    overflow: visible;
}

#earth {
    pointer-events: none;
    width: 100%;
    height: 100%;
    background-image: url("earth_lossless.webp"); /* ensure path is right */
    background-size: cover;
    background-position: center;
    transform-origin: 50% 50%;
    will-change: transform;
    backface-visibility: hidden;
    /* no base transform here — let the keyframes own transform */
    animation: spin 200s linear infinite;
    image-rendering: crisp-edges;
}

#earthWrapper2 {
    pointer-events: none;
    z-index: -1;
    position: fixed;
    top: -200px;
    right: -1200px;
    width: 2836.171px;
    height: 2826.405px;
    overflow: visible;
}

#sun {
    z-index: 1;
    position: absolute;
    top: 10%;
    right: 5%;
    animation: spin 100s linear infinite;
}

#moon {
    z-index: 1;
    position: absolute;
    top: 2000px;
    left: 5%;
    animation: spin 200s linear infinite;
}
#cloud1 {
    z-index: 2;
    position: absolute;
    width: 120px;
    height: 71px;
    top: 100px;
    left: 20%;
}

#cloud2 {
    z-index: 2;
    position: absolute;
    width: 220px;
    height: 141px;
    top: 20px;
    right: 25%;
}

#cloud3 {
    z-index: 2;
    position: absolute;
    width: 180px;
    height: 141px;
    top: -50px;
    right: 50%;
}

#cloud4 {
    z-index: 2;
    position: absolute;
    width: 200px;
    height: 141px;
    top: 500px;
    left: 20%;
}

#cloud5 {
    z-index: 2;
    position: absolute;
    width: 250px;
    height: 141px;
    top: 250px;
    left: 5%;
}

#cloud6 {
    z-index: 2;
    position: absolute;
    width: 190px;
    height: 141px;
    top: 600px;
    left: 3%;
}

#cloud7 {
    z-index: 2;
    position: absolute;
    width: 200px;
    height: 141px;
    top: 300px;
    right: 11%;
}

#cloud8 {
    z-index: 2;
    position: absolute;
    width: 350px;
    height: 141px;
    top: 250px;
    right: 0%;
}

#cloud9 {
    z-index: 2;
    position: absolute;
    width: 350px;
    height: 141px;
    top: 700px;
    right: 0%;
}

.mid-section {
    margin-top: 680px;
    display: flex;
    align-items: center;
    gap: 20px;
    position: absolute;
    top: 350px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.boxes {
    display: flex;
    flex-direction: row;
    z-index: 3;
    gap: 100px;
}

#box1, #box2, #box3 {
    display: flex;
    align-items: center;
    flex-direction: column;
    width: 400px;
    height: 500px;
    border-radius: 50px;
    background: rgba(237, 237, 237, 0.97);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);

    img {
        margin-top: 40px;
    }

    h3 {
        margin-bottom: 10px;
        color: #046E9C;
        text-align: center;
        font-family: "DM Sans";
        font-size: 30px;
        font-style: normal;
        font-weight: 700;
        line-height: normal;
    }

    h4 {
        margin-top: 10px;
        color: #001D2A;
        text-align: center;
        font-family: "DM Sans";
        font-size: 20px;
        font-style: normal;
        font-weight: 500;
        line-height: normal;
        padding-left: 50px;
        padding-right: 50px;
    }
}
@-moz-keyframes spin {
    100% { -moz-transform: rotate(360deg); }
}

@-webkit-keyframes spin {
    100% { -webkit-transform: rotate(360deg); }
}

@keyframes spin {
    from { transform: translateZ(0) rotate(0deg); }
    to   { transform: translateZ(0) rotate(360deg); }
}
@keyframes float {
    0% {
        transform: translateY(0); /* Start floating */
    }
    50% {
        transform: translateY(-10px); /* Small vertical movement */
    }
    100% {
        transform: translateY(0); /* Return */
    }
}

#cloud1, #cloud2, #cloud3, #cloud4, #cloud5, #cloud6, #cloud7, #cloud8, #cloud9 {
    animation: float 10s ease-in-out infinite;
    animation-delay: 2s; /* Stagger animations dynamically */
    will-change: auto; /* Reduce unnecessary hints */
}

.starfield {
    position: absolute;
    top: 1500px;   /* push them further down */
    left: 0;
    width: 100%;
    height: 1000px; /* adjust coverage */
    pointer-events: none;
    z-index: 0;
}


.starfield i {
    position: absolute;
    width: 2px;
    height: 2px;
    border-radius: 50%;
    background: #ffffff;
    opacity: 0.6;
    will-change: auto;
    animation: twinkle var(--tw, 3s) ease-in-out infinite;
}
.starfield i.s4 {
    width: 4px;
    height: 4px;
    opacity: 0.9;
    filter: drop-shadow(0 0 3px rgba(255,255,255,0.8));
}

/* size/brightness variety */
.starfield i.s1 { width: 1px; height: 1px; opacity: 0.4; }
.starfield i.s2 { width: 2px; height: 2px; opacity: 0.6; }
.starfield i.s3 { width: 3px; height: 3px; opacity: 0.8; filter: drop-shadow(0 0 2px rgba(255,255,255,0.6)); }

@keyframes twinkle {
    0%,100% { transform: scale(1);   opacity: var(--op, 0.6); }
    50%     { transform: scale(1.15); opacity: 1; }
}


#whySection {
    display: flex;
    position: relative;
    margin-top: 2000px;
    margin-left: 100px;
    justify-content: flex-start;

    #phoneWoman {
        margin-top: -10px;
        height:600px;
    }
    #whyInfo {
        border-color: black;
        border-style: solid;
        border-width: 1px;
        border-radius: 15px;
        padding: 50px;
        margin-left: 100px;
        color: #FFF;
        font-family: "DM Sans";
        font-style: normal;
        margin-top: 0px;
        text-align: left;
        display: flex;
        flex-direction: column;
        margin-right: 200px;
        backdrop-filter: blur(6px);
        background: rgba(255,255,255,0.08);
        border: 1px solid rgba(255,255,255,0.16);
        border-radius: 24px;
        padding: clamp(24px, 5vw, 40px);
        box-shadow: 0 10px 30px rgba(0,0,0,0.12);
        h3 {
            margin: 0;
            padding: 0;
            font-size: 60px;
            font-weight: 700;
        }
        h4 {
            color: #D7D7D7;
            margin-top: 50px;
            padding: 0;
            font-size: 20px;
            font-weight: 500;

        }
    }
}

#buttons {
    display: flex;
    flex-direction: row;
    z-index: 3;
    gap: 20px;
    #plan_button {
        border-radius: 30px;
        background: #659CFF;
        width: 151px;
        height: 46px;
        font-size: 18px;
        flex-shrink: 0;
        border: none;
        color: #FFF;
        cursor: pointer;
    }
    #view_button {
        border-radius: 30px;
        background: transparent;
        border-color: white;
        border-style: solid;
        border-width: 1px;
        width: 151px;
        height: 46px;
        font-size: 18px;
        flex-shrink: 0;
        color: #FFF;
        cursor: pointer;
    }
}
#testimonialWrapper {
    margin-top: 120px;
    margin-left: 100px;
    h3 {
        color: #FFF;
        font-family: "DM Sans";
        font-size: 60px;
        font-style: normal;
        font-weight: 700;
        line-height: normal;
        padding-left: 0px;
        text-align: left;
    }
}
#testimonials {
    margin-top: 100px;
    display: flex;
    flex-direction: row;
    z-index: 3;
    justify-content: center;
    text-align: center;
    gap: 200px;
    img {
        border-radius: 300px;
        border: 5px solid;
        border-color: #0a74b9 #0a74b9 #0a74b9 #0a74b9;
        margin-top: -50px;
    }
    #testimonial1, #testimonial2, #testimonial3 {
        width: 350px;
        flex-shrink: 0;
        border-radius: 50px;
        background: #FFF;
        .testimonial__stars {
            margin-top: -30px;
            color: #FFD700;
            font-size: 20px;
            letter-spacing: 2px;
            margin-bottom: 16px;
        }
        h5 {
            margin-top: 10px;
            color: #747474;
            text-align: center;
            font-family: "DM Sans";
            font-size: 20px;
            font-style: normal;
            font-weight: 700;
            line-height: normal;
        }
        h4 {
            margin-top: 20px;
            color: #046E9C;
            text-align: center;
            font-family: "DM Sans";
            font-size: 30px;
            font-style: normal;
            font-weight: 700;
            line-height: normal;
            padding-left: 70px;
            padding-right: 70px;
        }
    }
}

footer {
    z-index: 99;
    h1 {
        margin-top: -50px;
        padding: 20px;
        text-align: center;
        color: #FFF;
        font-family: "DM Sans", sans-serif;
        font-size: 14px;
        border-top: 2px solid rgba(255, 255, 255, 0.2);
    }
}
.hero-text h2:first-child { font-weight: 400; opacity: 0.9; }
.hero-text h2:last-child { font-weight: 700; font-size: 42px; }
#plan_button:hover, #view_button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
}

#box1, #box2, #box3,
#testimonial1, #testimonial2, #testimonial3 {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
#box1:hover, #box2:hover, #box3:hover,
#testimonial1:hover, #testimonial2:hover, #testimonial3:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.15);
}
.hero-search {
    width: clamp(280px, 70%, 600px);
}



.login-section {
        border-color: black;
        border-style: solid;
        border-width: 1px;
        border-radius: 15px;
        padding: 50px;
        margin-left: 100px;
        color: #FFF;
        font-family: "DM Sans";
        font-style: normal;
        margin-top: 0px;
        display: flex;
        flex-direction: column;
        backdrop-filter: blur(10px);
        background: rgba(234, 234, 234, 0.64);
        border: 1px solid rgba(255,255,255,0.16);
        border-radius: 24px;
        padding: clamp(24px, 5vw, 40px);
        box-shadow: 0 10px 30px rgba(0,0,0,0.12);
}
.login-section {
    padding: 60px;
    padding-left:80px;
    padding-right: 80px;
    margin-top: -200px;
    position: relative; z-index: 5;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 24px;
    h2 {
        color: #009EC9;
        text-align: center;
        font-family: "DM Sans";
        font-size: 40px;
        font-style: normal;
        font-weight: 700;
        line-height: normal;
    }
    h3 {
        margin-top: -30px;
        color: #004E63;
        text-align: center;
        font-family: "DM Sans";
        font-size: 20px;
        font-style: normal;
        font-weight: 500;
        line-height: normal;
        padding-bottom: 20px;
    }
    .login-form {
        display: flex;
        flex-direction: column;
        text-align: left;
        label {
            text-align: left;
            color: #006986;
            font-family: "DM Sans";
            font-size: 20px;
            font-style: normal;
            font-weight: 500;
            line-height: normal;
            margin-bottom: 5px;
        }

        input {
            width: 317px;
            height: 32px;
            flex-shrink: 0;
            border-radius: 10px;
            border: 3px solid #D9D9D9;
            background: #FFF;
            margin-bottom: 15px;
        }


        a {
            color: #006986;
            text-align: center;
            font-family: "DM Sans";
            font-size: 17px;
            font-style: normal;
            font-weight: 500;
            line-height: normal;
        }
        h4 {
            color: #7B8386;
            text-align: center;
            font-family: "DM Sans";
            font-size: 17px;
            font-style: normal;
            font-weight: 500;
            line-height: normal;
        }
        button {
            width: 325px;
            height: 45px;
            flex-shrink: 0;
            border-radius: 10px;
            border: none;
            background: #006986;
            color: #FFF;
            text-align: center;
            font-family: "DM Sans";
            font-size: 15px;
            font-style: normal;
            font-weight: 700;
            line-height: normal;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        button:hover {
            background: #005470;
            transform: translateY(-1px);
        }
        #forgot_password {
            margin-left: 180px;
            margin-top: -5px;
            padding-bottom: 20px;
        }
    }
}

.login-form {
    x-index: 10;
}


#cloud10 {
    z-index: -1;
    position: absolute;
    width: 170px;
    height: 101px;
    top: 50px;
    left: 5%;
    pointer-events: none;
}
#cloud11 {
    z-index: -1;
    position: absolute;
    width: 340px;
    height: 242px;
    top: 500px;
    left: 7%;
    pointer-events: none;
}
#cloud12 {
    z-index: -1;
    position: absolute;
    width: 220px;
    height: 101px;
    top: 80px;
    right: 27%;
    pointer-events: none;
}
#cloud13 {
    z-index: -1;
    position: absolute;
    width: 220px;
    height: 111px;
    top: 700px;
    right: 45%;
    pointer-events: none;
}
#cloud14 {
    z-index: -1;
    position: absolute;
    width: 250px;
    height: 141px;
    top: 200px;
    right: 5%;
    pointer-events: none;
}
#cloud15 {
    z-index: -1;
    position: absolute;
    width: 250px;
    height: 121px;
    top: 200px;
    left: 20%;
    pointer-events: none;
}

.chat-section {
    display: flex;
    z-index: 100;
    padding: 50px;
    color: #FFF;
    font-family: "DM Sans";
    font-style: normal;
    margin-top: 0px;
    justify-content: center;
    backdrop-filter: blur(10px);
    align-items: center;
    height: 100%;
    position: relative;
}

.chat-window {
    width: 800px;
    height: 650px;
    margin-bottom: 30px;
    padding: 20px;
    border-color: black;
    border-style: solid;
    border-width: 1px;
    border-radius: 15px;
    color: #000000;
    font-family: "DM Sans";
    font-style: normal;
    background: #FBFBFB;
    border: 1px solid rgba(255,255,255,0.16);
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.12);
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1000;
}
.chat-messages {
    padding: 20px;
    padding-top: 30px;
    padding-bottom: 40px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    overflow-y: auto;
    overflow-x: hidden;
    height: 420px;
    margin-top: 20px;
    scroll-behavior: smooth;
}

.user-message {
    align-self: flex-end;
    background: #EBEBEB;
    text-align: right;
    max-width: 70%;
    padding: 12px 16px;
    border-radius: 20px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.user-message h5 {
    font-size: 11px;
    margin: 0 0 6px 0;
    opacity: 0.7;
}

.user-message h4 {
    margin: 0;
    line-height: 1.4;
    font-weight: normal;
}

.agent-message {
    align-self: flex-start;
    background: #006BB3;
    color: white;
    text-align: left;
    max-width: 70%;
    padding: 12px 16px;
    border-radius: 20px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.agent-message h5 {
    font-size: 11px;
    margin: 0 0 6px 0;
    opacity: 0.7;
}

.agent-message h4 {
    margin: 0;
    line-height: 1.4;
    font-weight: normal;
}

.agent-message a {
    color: #FFF;
    text-decoration: underline;
    font-weight: 600;
}

.agent-message a:hover {
    opacity: 0.85;
}

.chat-header {
    background: #F3F3F3;
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    z-index: 10;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.chat-box {
    position: absolute;
    bottom: 20px;
    left: 20px;
    right: 20px;
    display: flex;
    gap: 10px;
    align-items: center;
}

.chat-box input {
    flex: 1;
    height: 40px;
    padding: 10px 15px;
    border-radius: 20px;
    border: 2px solid #DDD;
    background: #FFF;
    font-family: "DM Sans";
    font-size: 14px;
    outline: none;
    box-sizing: border-box;
}

.chat-box input:focus {
    border-color: #006BB3;
}

.chat-box button {
    width: 80px;
    height: 40px;
    border-radius: 20px;
    background: #659CFF;
    border: 2px solid #659CFF;
    color: white;
    font-family: "DM Sans";
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
    box-sizing: border-box;
}

.chat-box button:hover {
    background: #5a8bf0;
}

/* Typing indicator - iMessage style */
.typing-indicator {
    align-self: flex-start;
    background: #E5E5EA;
    color: #8E8E93;
    text-align: left;
    padding: 8px 12px;
    border-radius: 18px;
    margin-bottom: 4px;
    width: auto;
    min-width: 40px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.typing-indicator .typing-dots {
    display: flex;
    align-items: center;
    gap: 3px;
}

.typing-indicator .typing-dots span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #8E8E93;
    animation: typing 1.4s infinite ease-in-out;
}

.typing-indicator .typing-dots span:nth-child(1) {
    animation-delay: 0s;
}

.typing-indicator .typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator .typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.4;
    }
    30% {
        transform: translateY(-4px);
        opacity: 1;
    }
}

/* Trip Form Styling */
.trip-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 800px;
    margin: 0 auto;
}

/* Two-column layout for form fields */
.trip-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(3, 1fr);
    gap: 30px 30px;
    align-items: stretch;
}

/* Center the title, heading, and button across both columns */
.login-section h2,
.login-section h3,
.trip-form .form-group:last-child {
    grid-column: 1 / -1;
    justify-self: center;
}

/* Center align form labels/headings */
body.trip-form-page .trip-form label {
    text-align: center !important;
}

/* Make continue button appropriately sized for two-column layout */
body.trip-form-page .trip-form .form-group:last-child button {
    width: 300px !important;
    height: 50px !important;
    font-size: 18px !important;
}

.trip-form .form-group {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    height: 100%;
}

.trip-form label {
    color: #006986;
    font-family: "DM Sans";
    font-size: 15px;
    font-weight: 500;
    margin-bottom: 5px;
    line-height: 1.3;
    width: 100%;
    text-align: center !important;
}

.trip-form input {
    width: 100%;
    height: 36px;
    padding: 8px 15px;
    border-radius: 8px;
    border: 2px solid #D9D9D9;
    background: #FFF;
    font-family: "DM Sans";
    font-size: 15px;
    box-sizing: border-box;
}

.trip-form select {
    width: 100%;
    height: 40px;
    padding: 0 15px;
    border-radius: 8px;
    border: 2px solid #D9D9D9;
    background: #FFF;
    font-family: "DM Sans";
    font-size: 15px;
    box-sizing: border-box;
}

.trip-form input:focus,
.trip-form select:focus {
    border-color: #006986;
    outline: none;
}

.trip-form button {
    width: 100%;
    height: 40px;
    border-radius: 10px;
    background: #006986;
    border: none;
    color: #FFF;
    font-family: "DM Sans";
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    margin-top: 5px;
    z-index: 1000;
    position: relative;
    pointer-events: auto;
    display: block;
}

.trip-form button:hover {
    background: #005470;
}

/* Tablet/laptop screen optimization */
@media (max-width: 1400px) and (min-width: 769px) {
    .boxes {
        gap: 25px !important;
    }
    
    #whySection {
        justify-content: flex-start !important;
        margin-left: -50px !important;
    }
    
    #whyInfo {
        width: 95% !important;
        max-width: none !important;
        margin-left: 20px !important;
        margin-right: 20px !important;
    }
    
    /* Fix testimonials on tablet/laptop screens */
    #testimonials {
        gap: 20px !important;
        padding: 0 20px !important;
    }
    
    #testimonial1, #testimonial2, #testimonial3 {
        width: 380px !important;
        flex-shrink: 1 !important;
    }
    
    #testimonialWrapper h3 {
        text-align: center !important;
        padding: 0 20px !important;
    }
    
    /* Make trip form box narrower on laptop screens */
    body.trip-form-page .login-section {
        width: 700px !important;
        padding: 35px 25px !important;
    }
}

/* Responsive design for smaller screens */
@media (max-height: 800px) {
    /* Keep box reasonable size but reduce padding */
    body.login-page .login-section,
    body.register-page .login-section,
    body.trip-form-page .login-section {
        padding: 10px 15px;
        margin-bottom: 40px;
    }

    /* Chat page responsive - fix scaling and blur issues */
    body.chat-page .chat-section {
        padding: 20px;
        backdrop-filter: blur(10px);
        width: 100% !important;
        height: 100% !important;
    }

    body.chat-page .chat-window {
        width: 350px !important;
        max-width: 350px !important;
        height: 675px !important;
        margin: 50px auto 0 auto !important;
    }

    body.chat-page .chat-messages {
        height: auto !important;
        flex: 1 !important;
        font-size: 14px !important;
    }

    body.chat-page .chat-header {
        font-size: 14px;
    }

    body.chat-page .user-message,
    body.chat-page .agent-message {
        font-size: 12px;
        padding: 10px 14px;
    }

    body.chat-page .user-message h5,
    body.chat-page .agent-message h5 {
        font-size: 10px;
        margin: 0 0 4px 0;
        opacity: 0.8;
    }

    body.chat-page .user-message h4,
    body.chat-page .agent-message h4 {
        font-size: 12px;
        margin: 0;
        line-height: 1.4;
    }

    /* Keep earth visible on smaller screens */
    body.chat-page #earthWrapper {
        z-index: 1;
    }

    /* Extra space for register page due to additional field */
    body.register-page .login-section {
        margin-bottom: 50px;
    }

    /* Smaller headings */
    .login-section h2 {
        font-size: 34px !important;
        margin-bottom: 8px;
    }

    .login-section h3 {
        font-size: 16px !important;
        margin-top: -12px !important;
        margin-bottom: 8px;
    }

    /* Compact form elements */
    .login-form label,
    .trip-form label {
        font-size: 13px;
        margin-bottom: 2px;
        text-align: left !important;
        display: block;
        width: 280px;
        margin-left: auto;
        margin-right: auto;
    }

    .login-form input,
    .trip-form input {
        height: 28px;
        font-size: 13px;
        margin-bottom: 2px !important;
        padding: 6px 10px;
        width: 280px !important;
        box-sizing: border-box;
        margin-left: auto;
        margin-right: auto;
        display: block;
    }

    .trip-form select {
        height: 32px;
        font-size: 13px;
        margin-bottom: 2px !important;
        padding: 6px 10px;
        width: 280px !important;
        box-sizing: border-box;
    }

    /* Ensure trip form inputs override any other CSS */
    body.trip-form-page .trip-form input {
        width: 280px !important;
        height: 28px !important;
        box-sizing: border-box;
    }

    body.trip-form-page .trip-form select {
        width: 280px !important;
        height: 32px !important;
        box-sizing: border-box;
    }

    .login-form button,
    .trip-form button {
        height: 35px;
        font-size: 14px;
        margin-top: 8px;
        margin-left: auto;
        margin-right: auto;
        display: block;
        width: 280px !important;
    }

    /* Ensure trip form button override */
    body.trip-form-page .trip-form button {
        width: 280px !important;
    }

    /* Reduce gap between form elements */
    .trip-form {
        gap: 4px;
    }




.flash-message {
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 5px;
    color: #fff;
    text-align: center;
}

.flash-success {
    background-color: #28a745;
}

.flash-danger {
    background-color: #dc3545;
}

.flash-warning {
    background-color: #ffc107;
    color: #000;
}

.flash-info {
    background-color: #17a2b8;
}

.password-container {
    position: relative;
}


.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
}

.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
}

.loading-spinner {
    border: 8px solid #f3f3f3;
    border-top: 8px solid #3498db;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 2s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading {
    color: #FFF;
    font-family: "DM Sans";
    font-style: normal;
    font-size: 24px;
    font-weight: 600;
    text-align: center;
    margin-top: 20px;
}

/* Hide the first user message in the chat */
.hidden-first-message {
    display: none;
}

/* Carousel Navigation Styling - General (hidden by default, shown on mobile) */
.carousel-nav {
    display: none;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
    z-index: 10;
    position: relative;
}

.carousel-prev,
.carousel-next {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid #006BB3;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 20px;
    font-weight: bold;
    color: #006BB3;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    pointer-events: auto;
    z-index: 1002;
    position: relative;
}

.carousel-prev:hover,
.carousel-next:hover {
    background: #006BB3;
    color: white;
    transform: scale(1.1);
}

.carousel-prev:active,
.carousel-next:active {
    transform: scale(0.95);
}

.carousel-dots {
    display: flex;
    gap: 8px;
    align-items: center;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: 2px solid #006BB3;
    cursor: pointer;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
    pointer-events: auto;
    z-index: 1002;
    position: relative;
}

.dot.active {
    background: #006BB3;
    transform: scale(1.2);
}

.dot:hover {
    background: rgba(0, 107, 179, 0.7);
}

/* Carousel containers */
.boxes-carousel-container {
    position: relative;
    width: 100%;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    /* Mobile viewport optimization */
    html {
        background-color: #02BBEE;
        height: 100%;
        height: 100dvh; /* Dynamic viewport height */
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
        overflow-x: hidden !important;
        width: 100% !important;
        max-width: 100vw !important;
    }

    body {
        background-color: #02BBEE;
    }
    
    /* Hide some clouds on mobile - keep only a few */
    #cloud2, #cloud3, #cloud4, #cloud5, #cloud6, #cloud7, #cloud8, #cloud9 {
        display: block !important;
    }
    
    /* Hide moon and stars on mobile */
    #moon, .starfield {
        display: none !important;
    }
    
    /* Disable heavy animations on mobile for better scrolling - except earth */
    #cloud1, #cloud2, #cloud3, #cloud4, #cloud5, #cloud6, #cloud7, #cloud8, #cloud9, .starfield i {
        animation: none !important;
    }
    
    /* Keep earth rotation animation */
    #earth {
        animation: spin 200s linear infinite !important;
    }
    
    /* Prevent horizontal scrolling */
    .content, .hero-section, .details {
        overflow-x: hidden !important;
        max-width: 100vw !important;
        box-sizing: border-box !important;
    }
    

    



    
    body.login-page .hero-section, body.register-page .hero-section {
        margin-top: 0 !important;
        justify-content: center !important;
        align-items: center !important;
        display: flex !important;
    }
    
    /* Move login box down on mobile */
    body.login-page .login-section, body.register-page .login-section {
        margin-top: 100px !important;
        z-index: 1000 !important;
        position: relative !important;
    }
    

    
    /* Hide phonewoman image on mobile */
    #phoneWoman {
        display: none !important;
    }
    
    /* Center "Why Trip Hunt" section on mobile */
    #whySection {
        margin-left: 0 !important;
        margin-right: 0 !important;
        justify-content: center !important;
        padding: 0 20px !important;
        transform: translateY(-150px) !important;
    }
    
    #whyInfo {
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100% !important;
        max-width: 90% !important;
        text-align: center !important;
    }
    
    /* Move entire testimonial wrapper up and style heading */
    #testimonialWrapper {
        transform: translateY(-150px) !important;
    }
    
    #testimonialWrapper h3 {
        font-size: 36px !important;
    }
    
    /* Mobile chat title */
    .chat-title h2 {
        font-size: 36px !important;
    }
    
    /* Mobile testimonials optimization - back to vertical stacking */
    #testimonials {
        flex-direction: column !important;
        gap: 30px !important;
        align-items: center !important;
        margin-top: 50px !important;
    }
    
    #testimonial1, #testimonial2, #testimonial3 {
        width: 85% !important;
        max-width: 300px !important;
        padding: 20px 15px !important;
        display: grid !important;
        grid-template-columns: 50px 1fr !important;
        grid-template-rows: auto auto auto !important;
        gap: 8px !important;
        align-items: center !important;
        text-align: center !important;
    }
    
    /* Position profile image */
    #testimonials img {
        width: 40px !important;
        height: 40px !important;
        margin: 0 !important;
        grid-column: 1 !important;
        grid-row: 1 / 3 !important;
        justify-self: center !important;
    }
    
    
    /* Position name */
    #testimonials h5 {
        font-size: 14px !important;
        margin: 0 !important;
        grid-column: 2 !important;
        grid-row: 1 !important;
        text-align: left !important;
        align-self: end !important;
    }
    
    /* Position stars */
    .testimonial__stars {
        font-size: 12px !important;
        margin: 0 !important;
        grid-column: 2 !important;
        grid-row: 2 !important;
        text-align: left !important;
        align-self: start !important;
    }
    
    /* Position testimonial content */
    #testimonials h4 {
        font-size: 12px !important;
        padding: 10px 10px 0 10px !important;
        line-height: 1.3 !important;
        margin: 0 !important;
        text-align: left !important;
        grid-column: 1 / 3 !important;
        grid-row: 3 !important;
    }
    
    /* Stack boxes vertically on mobile - keep as fallback */
    .boxes {
        flex-direction: column !important;
        gap: 20px !important;
        align-items: center;
        transform: translateY(-100px) !important;
        position: relative;
    }
    
    /* Mobile box styling - smaller vertical size */
    #box1, #box2, #box3 {
        width: 95% !important;
        height: 300px !important;
        padding: 15px 20px 20px 20px !important;
        justify-content: flex-start !important;
    }
    
    /* Adjust text and icon size for mobile */
    #box1 .noteIcon, #box2 .noteIcon, #box3 .noteIcon {
        width: 40px !important;
        height: 40px !important;
        margin: 0 0 10px 0 !important;
    }
    
    #box1 h3, #box2 h3, #box3 h3 {
        font-size: 18px !important;
        margin: 10px 0 !important;
        width: 100% !important;
        text-align: center !important;
    }
    
    #box1 h4, #box2 h4, #box3 h4 {
        font-size: 14px !important;
        line-height: 1.4 !important;
        margin: 0 !important;
        width: 100% !important;
        text-align: center !important;
    }

    /* Show carousel navigation on mobile */
    .carousel-nav {
        display: flex !important;
        z-index: 1000 !important;
        position: relative !important;
    }

    /* Move boxes carousel navigation up 100px */
    .boxes-nav {
        transform: translateY(-100px) !important;
    }



    #cloud1 {
    z-index: 2;
    position: absolute;
    width: 120px;
    height: 141px;
    top: 50px;
    left: 10%;
    }
    #cloud2 {
    z-index: 2;
    position: absolute;
    width: 220px;
    height: 141px;
    top: -30px;
    right: 30%;
    }

    #sun {
        display: none;
    }

    
    /* Navbar mobile optimization */
    .navbar {
        padding: 0 10px 50px 10px;
        flex-wrap: nowrap;
        gap: 8px;
        height: 80px;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 1000;
    }
    
    .navbar .logo {
        height: 35px;
        width: auto;
    }
    
    .navbar #titleText {
        font-size: 20px;
        margin: 0;
    }
    
    .navbar .nav-group {
        gap: 12px;
    }
    
    .navbar .navItem {
        font-size: 16px;
    }
    
    .navbar .navItem a {
        padding: 8px 12px;
        border-radius: 6px;
        background: rgba(255, 255, 255, 0.1);
        text-decoration: none;
        transition: background-color 0.2s ease;
    }
    
    .navbar .navItem a:hover {
        background: rgba(255, 255, 255, 0.2);
    }
    
    /* Touch-friendly interactions */
    button, input[type="submit"], .btn {
        min-height: 44px;
        min-width: 44px;
        touch-action: manipulation;
    }
    
    /* Prevent text selection on UI elements */
    .navbar, .chat-header, button {
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
    }
    
    /* Improve tap targets */
    a, button {
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    }
    
    /* Better mobile scrolling */
    .chat-messages {
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }
    
    /* Prevent zoom on inputs */
    input, textarea, select {
        font-size: 16px !important;
    }
    
    /* Mobile-optimized send button - show text only */
    body.chat-page .chat-box button {
        font-size: 12px !important;
        position: relative;
    }
    
    body.chat-page .chat-box button::after {
        display: none !important;
    }
}

/* Responsive design for smaller screens */
@media (max-height: 800px) {
    /* Keep box reasonable size but reduce padding */
    body.login-page .login-section,
    body.register-page .login-section,
    body.trip-form-page .login-section {
        padding: 10px 15px;
        margin-bottom: 40px;
    }
    
    /* Mobile-optimized chat interface */
    body.chat-page {
        height: 100vh;
        height: 100dvh; /* Dynamic viewport height for mobile browsers */
        overflow: hidden;
    }
    
    body.chat-page .content {
        height: calc(100vh - 80px);
        height: calc(100dvh - 80px);
        margin-top: 0;
        padding: 0;
    }
    
    body.chat-page .hero-section {
        height: 100%;
        padding: 0;
        margin: 0;
        flex-direction: column;
    }
    
    body.chat-page .chat-section {
        padding: 10px;
        backdrop-filter: blur(10px);
        width: 100%;
        height: 100vh !important;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        overflow: hidden !important;
    }
    
    body.chat-page .chat-window {
        width: 350px !important;
        height: 675px !important;
        max-width: 350px !important;
        margin: 50px auto 0 auto !important;
        display: flex;
        flex-direction: column;
        background: rgba(255, 255, 255, 0.95);
        border-radius: 24px;
        backdrop-filter: blur(10px);
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
        overflow: hidden;
        padding: 20px 15px !important;
    }
    
    body.chat-page .chat-header {
        font-size: 12px !important;
        padding: 8px 15px !important;
        margin-bottom: 35px !important;
        background: rgba(255, 255, 255, 0.9);
        border-bottom: 1px solid rgba(0, 0, 0, 0.1);
        flex-shrink: 0;
    }
    
    body.chat-page .chat-wrapper {
        flex: 1;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }
    
    body.chat-page .chat-messages {
        flex: 1;
        height: auto !important;
        padding: 15px 20px;
        margin-top: 0px !important;
        font-size: 14px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }
    
    body.chat-page .user-message,
    body.chat-page .agent-message {
        font-size: 14px;
        padding: 12px 16px;
        margin-bottom: 12px;
        border-radius: 12px;
        max-width: none;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    body.chat-page .user-message {
        background: rgba(0, 107, 179, 0.1);
        margin-left: 20px;
        border-bottom-right-radius: 4px;
    }
    
    body.chat-page .agent-message {
        background: #006BB3 !important;
        color: white !important;
        margin-right: 20px;
        border-bottom-left-radius: 4px;
    }
    
    body.chat-page .user-message h5,
    body.chat-page .agent-message h5 {
        font-size: 11px;
        margin: 0 0 4px 0;
        opacity: 0.7;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    
    body.chat-page .user-message h4,
    body.chat-page .agent-message h4 {
        font-size: 14px;
        margin: 0;
        line-height: 1.5;
        font-weight: 400;
    }
    
    body.chat-page .chat-box {
        position: relative;
        bottom: auto;
        left: auto;
        right: auto;
        width: 100%;
        padding: 15px 15px;
        background: transparent !important;
        border-top: none !important;
        display: flex;
        gap: 10px;
        align-items: center;
        flex-shrink: 0;
        box-sizing: border-box;
    }
    
    body.chat-page .chat-box input {
        flex: 1;
        height: 40px;
        padding: 10px 15px;
        border: 2px solid rgba(0, 107, 179, 0.2);
        border-radius: 12px !important;
        background: rgba(255, 255, 255, 0.9);
        font-size: 14px;
        outline: none;
        transition: border-color 0.2s ease;
        box-sizing: border-box;
    }
    
    body.chat-page .chat-box input:focus {
        border-color: #006BB3;
    }
    
    body.chat-page .chat-box button {
        width: 60px;
        height: 40px;
        border-radius: 12px !important;
        background: #006BB3;
        color: white;
        border: none;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        transition: background-color 0.2s ease;
        flex-shrink: 0;
    }
    
    body.chat-page .chat-box button:hover {
        background: #0056a3;
    }
    
    body.chat-page .chat-box button:active {
        background: #004a8c;
        transform: scale(0.98);
    }

    /* Hide earth on mobile for better performance and space */
    body.chat-page #earthWrapper {
        display: none;
    }
    
    /* Typing indicator mobile optimization */
    body.chat-page .typing-indicator {
        margin: 10px 20px 10px 0;
        padding: 12px 16px;
        background: rgba(0, 0, 0, 0.05);
        border-radius: 12px;
        border-bottom-left-radius: 4px;
    }
    
    /* Improve scrollbar on mobile webkit */
    body.chat-page .chat-messages::-webkit-scrollbar {
        width: 4px;
    }
    
    body.chat-page .chat-messages::-webkit-scrollbar-track {
        background: transparent;
    }
    
    body.chat-page .chat-messages::-webkit-scrollbar-thumb {
        background: rgba(0, 0, 0, 0.2);
        border-radius: 2px;
    }
    
    /* Footer adjustments for mobile */
    body.chat-page footer {
        height: 50px;
        padding: 0;
        background: rgba(0, 0, 0, 0.05);
    }
    
    body.chat-page footer h1 {
        font-size: 12px;
        padding: 15px 20px;
        margin: 0;
        text-align: center;
    }
    
    /* Extra space for register page due to additional field */
    body.register-page .login-section {
        margin-bottom: 50px;
    }
    
    /* Smaller headings */
    .login-section h2 {
        font-size: 34px !important;
        margin-bottom: 8px;
    }
    
    .login-section h3 {
        font-size: 16px !important;
        margin-top: -12px !important;
        margin-bottom: 8px;
    }
    
    /* Compact form elements */
    .login-form label,
    .trip-form label {
        font-size: 13px;
        margin-bottom: 2px;
        text-align: left !important;
        display: block;
        width: 280px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .login-form input,
    .trip-form input {
        height: 28px;
        font-size: 13px;
        margin-bottom: 2px !important;
        padding: 6px 10px;
        width: 280px !important;
        box-sizing: border-box;
        margin-left: auto;
        margin-right: auto;
        display: block;
    }
    
    .trip-form select {
        height: 32px;
        font-size: 13px;
        margin-bottom: 2px !important;
        padding: 6px 10px;
        width: 280px !important;
        box-sizing: border-box;
    }
    
    /* Ensure trip form inputs override any other CSS */
    body.trip-form-page .trip-form input {
        width: 280px !important;
        height: 28px !important;
        box-sizing: border-box;
    }
    
    body.trip-form-page .trip-form select {
        width: 280px !important;
        height: 32px !important;
        box-sizing: border-box;
    }
    
    .login-form button,
    .trip-form button {
        height: 35px;
        font-size: 14px;
        margin-top: 8px;
        margin-left: auto;
        margin-right: auto;
        display: block;
        width: 280px !important;
    }
    
    /* Mobile - revert to single column layout */
    .trip-form {
        display: flex !important;
        flex-direction: column !important;
        gap: 4px !important;
        max-width: 380px !important;
    }
    
    /* Make mobile trip form box much smaller */
    body.trip-form-page .login-section {
        width: 380px !important;
        padding: 15px 10px !important;
        margin-top: 75px !important;
    }
    
    /* Smaller mobile trip form titles */
    body.trip-form-page .login-section h2 {
        font-size: 24px !important;
        margin-bottom: 5px !important;
    }
    
    body.trip-form-page .login-section h3 {
        font-size: 14px !important;
        margin-top: -8px !important;
        margin-bottom: 10px !important;
    }
    
    /* Smaller submit button on mobile */
    body.trip-form-page .trip-form button {
        width: 120px !important;
        height: 26px !important;
        font-size: 11px !important;
    }
    
    .trip-form .form-group {
        height: auto !important;
        justify-content: flex-start !important;
    }
    
    /* Reset mobile form labels to left align */
    body.trip-form-page .trip-form label {
        text-align: left !important;
        width: 320px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        display: block !important;
    }
    
    /* Fix mobile input alignment and size */
    body.trip-form-page .trip-form input,
    body.trip-form-page .trip-form select {
        width: 320px !important;
        height: 32px !important;
        font-size: 13px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        display: block !important;
        box-sizing: border-box !important;
        text-align: left !important;
    }
    
    /* Hide some clouds on mobile for trip form pages */
    #cloud12, #cloud13, #cloud14, #cloud15 {
        display: none !important;
    }
    
    /* Reposition and resize bottom cloud on mobile */
    #cloud11 {
        top: 400px !important;
        left: 27% !important;
        width: 240px !important;
        height: 192px !important;
    }
    
    /* Move cloud2 to the right on mobile */
    #cloud2 {
        right: 5% !important;
    }
    
    /* Move cloud10 (first cloud on trip form pages) down on mobile */
    #cloud10 {
        top: 100px !important;
    }
    
    /* Center and wrap loading text on mobile */
    .loading {
        text-align: center !important;
        word-wrap: break-word !important;
        white-space: normal !important;
        padding: 0 20px !important;
        line-height: 1.4 !important;
    }
    
    /* Move loading animation down on mobile */
    .loading-container {
        margin-top: 50px !important;
    }
    
    /* Adjust container heights */
    body.login-page .content,
    body.register-page .content,
    body.trip-form-page .content {
        margin-top: 10px;
    }
    
    body.login-page .hero-section,
    body.register-page .hero-section,
    body.trip-form-page .hero-section {
        padding: 5px 0;
    }
}

.flash-message {
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 5px;
    color: #fff;
    text-align: center;
}

.flash-success {
    background-color: #28a745;
}

.flash-danger {
    background-color: #dc3545;
}

.flash-warning {
    background-color: #ffc107;
    color: #000;
}

.flash-info {
    background-color: #17a2b8;
}

.password-container {
    position: relative;
}


.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
}

.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
}

.loading-spinner {
    border: 8px solid #f3f3f3;
    border-top: 8px solid #3498db;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 2s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading {
    color: #FFF;
    font-family: "DM Sans";
    font-style: normal;
    font-size: 24px;
    font-weight: 600;
    text-align: center;
    margin-top: 20px;
}

/* Hide the first user message in the chat */
.hidden-first-message {
    display: none;
}
