.profile-circle {
    margin: 0;
    position: relative;
    left: 25px;
    width: 45px;
    height: 45px;
    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;

    font-weight: 600;
    font-size: 0.95rem;
    color: #ffffff;

    background: linear-gradient(135deg,
            #16a34a,
            #22c55e,
            #4ade80);

    box-shadow: 0 6px 14px rgba(34, 197, 94, 0.25);
    cursor: pointer;
    transition: all 0.2s ease;
}

/*
html,
body {
    overscroll-behavior: auto;
    overflow-x: hidden;
}*/

html,
body {
    overflow-x: hidden;
}


.profile-circle:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 18px rgba(34, 197, 94, 0.35);
}

/* Container */
.profile-container {
    display: flex;
    align-items: center;
    margin: 0;
    transform: translate(-45px, 50px);
    z-index: 3;
}

/* Name label */
.profile-name {
    background: #ffffff;
    color: #374151;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;

    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);

    opacity: 0;
    transform: translateX(10px);
    pointer-events: none;

    transition: all 0.25s ease;
    white-space: nowrap;
}

.battery-icon {
    animation: pulseBattery 2.5s infinite ease-in-out;
}

/*
@media (max-width: 768px) {
    #title-container {
        margin-top: 60%;
    }
}*/


/* Hide floating balls on small screens (mobile) */
@media (max-width: 768px) {
    #floatingBallsContainer {
        display: none;
    }

    body {
        /* Dotted pattern using radial gradient */
        background-image: radial-gradient(#cbd5e1 1.5px, transparent 1.5px);
        background-size: 24px 24px;
        margin: 0;
    }

    .card,
    .add-card {
        width: 90%;
        margin: 0 auto;
        border: 0px solid #16161611 !important;
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.116) !important;
    }

    /* --- FIX FOR AUTO-ZOOM --- */
    /* Font size MUST be at least 16px to stop mobile browsers from zooming in */
    .form-floating>.form-control,
    .form-floating>.form-control[readonly],
    #companySelect {
        font-size: 16px !important;
        /* CRITICAL: Must be 16px or higher */
        min-height: 50px !important;
        height: 50px !important;
        padding: 18px 10px 4px !important;
        background-color: #ffffff !important;
        opacity: 1 !important;
        touch-action: manipulation;
        /* Prevents double-tap zoom on mobile */
    }

    /* Keep the floating label neat and aligned */
    .form-floating>label {
        padding: 12px 10px !important;
        font-size: 14px !important;
        background-color: transparent !important;
        background: none !important;
    }

    /* Adjust label position when input is focused or filled */
    .form-floating>.form-control:focus~label,
    .form-floating>.form-control:not(:placeholder-shown)~label {
        font-size: 11px !important;
        transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
    }

    .main_title {
        border: none;
        background-color: #ffffff25 !important;
        box-shadow: 1px 10px 25px rgba(0, 0, 0, 0.062);
        /* Uses the offset & blur values with a soft shadow color */
        border-radius: 16px;
        padding: 15px;
    }
}

@keyframes pulseBattery {

    0%,
    100% {
        opacity: 0.9;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }
}

/* Visible state */
.profile-container.active .profile-name {
    opacity: 1;
    pointer-events: auto;
}


/*New*/
.btn-refresh {
    background: linear-gradient(135deg, #16a34a, #22c55e, #4ade80);
    border: none;
    border-radius: 10px;
    color: white;
    padding: 10px 20px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.2);
}

.btn-refresh:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(34, 197, 94, 0.3);
    color: white;
}

.btn-refresh:active {
    transform: translateY(0);
}

/* Optional: rotate the icon on hover */
.btn-refresh:hover i {
    animation: spin 1s infinite linear;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.page-indicator-container {
    padding: 2rem 0;
    position: relative;
}

.page-title {
    color: #1f2937;
    /* var(--text-dark) */
    margin-top: 0.5rem;
    letter-spacing: -1px;
}

.tracking-widest {
    letter-spacing: 0.2em;
}

.title-underline {
    height: 4px;
    width: 50px;
    background: linear-gradient(90deg, #16a34a, #4ade80);
    border-radius: 2px;
    margin-top: 10px;
}

/* Optional: subtle animation when page loads */
.page-indicator-container {
    animation: fadeInDown 0.8s ease-out;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

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



/*Battery Visual Display for the View Vehicles Page of the Dashboard*/
.data-card-display {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 12px;
    background: #1414138f;
    color: white;
    width: fit-content;
    font-family: Arial, sans-serif;
}

.data-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bubble {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

.data-info {
    display: flex;
    flex-direction: column;
}

.display-title {
    font-size: 13px;
    opacity: 0.8;
}

.data-value {
    font-size: 18px;
    font-weight: bold;
    margin-top: 6px;
}

.data-status {
    font-size: 18px;
    font-weight: bold;
    margin-top: 6px;
}

/*Preloading Section*/
/*Preloading styling*/

.preloader {
    position: fixed;
    inset: 0; /* Equivalent to top: 0; right: 0; bottom: 0; left: 0; */
    width: 100%;
    height: 100%;
    height: 100dvh; /* Dynamic viewport height fallback for modern mobile browsers */
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    user-select: none;
    touch-action: none;
}

/* Optional backdrop blur for extra isolation */
.preloader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}


.preloader-content {
    text-align: center;
}

.brand-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 30px;
}

.battery-icon {
    font-size: 70px;
    color: #22c55e;
    animation: batteryPulse 1.3s ease-in-out infinite;
}

.brand-name {
    font-size: 42px;
    font-weight: 700;
    color: #222;
    letter-spacing: 1px;
    transform: translateY(-12px);
}


@keyframes batteryPulse {

    0% {
        transform: scale(1);
        opacity: .65;
    }

    50% {
        transform: scale(1.15);
        opacity: 1;
    }

    100% {
        transform: scale(1);
        opacity: .65;
    }

}

/*End of Preloading Section*/




@media (max-width: 768px) {

    .battery-title {
        text-align: center;
        font-size: 10px;
    }

    .battery-voltage {
        font-size: 12px;
        text-align: center;
        font-weight: bold;
        margin-top: 6px;
    }

    .battery-status {
        font-size: 9px;
        font-weight: bold;
        margin-top: 6px;
    }

    .menu_btn {
        font-size: 0.8rem !important;
        /* Forces override if JS attaches inline styles */
        padding: 4px 4px !important;
        font-family: 'Plus Jakarta Sans', sans-serif;
        letter-spacing: 0px;
        text-transform: none;
        font-weight: 600;
    }

    .lot-popup-modal {
        border-radius: 9px;
    }

    .container-fluid {
        background-color: #ffffff00;
    }

    .brand-container {
        margin-bottom: 5px;
    }

    .battery-icon {
        font-size: 40px;
    }

    .brand-name {
        font-size: 22px;
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.25);
        opacity: 0.6;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}


/*Error Notification Box*/
.notification-container {
    position: relative;
    width: min(500px, 90%);
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0 auto 20px auto;
    z-index: 1000;
    cursor: pointer;
}

.error-bubble {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 14px 18px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    color: #ffffff;
    background: linear-gradient(135deg, #e53e3e 0%, #9b2c2c 100%);
    box-shadow: 0 8px 18px rgba(155, 44, 44, 0.2);
    border-left: 4px solid #fff5f5;
    animation: slideIn 0.25s ease forwards;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.error-bubble.fade-out {
    opacity: 0;
    transform: translateY(-10px);
}

.error-bubble-message {
    flex-grow: 1;
    margin-right: 14px;
    line-height: 1.4;
    text-align: center;
    cursor: pointer;
}

.beta-card {
    background: none;
    padding: 10px;
    border-radius: 20px;
    border: 1px solid #ffc8d9;
    font-family: Inter, sans-serif;
    max-width: 500px;
    margin: 0 auto;
}

.beta-card span {
    background: #ff6f9f;
    color: white;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 12px;
}


@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-12px);
    }

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


/* Target devices with touch input capabilities only */
@media (pointer: coarse) {

    html,
    body {
        touch-action: pan-x pan-y;
        -webkit-text-size-adjust: 100%;
        text-size-adjust: 100%;
    }

    input,
    select,
    textarea,
    button {
        touch-action: manipulation;
    }
}