/* ============================================================
   iOS-STYLE BOOKING FORM - MODERN APPLE-INSPIRED DESIGN
   ============================================================ */

/* Modal Overlay */
.ios-booking-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 10000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.ios-booking-overlay.show {
    display: flex;
    opacity: 1;
}

/* Modal Container - Bottom Sheet on Mobile, Centered on Desktop */
.ios-booking-modal {
    position: fixed;
    background: #ffffff;
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.2);
    max-height: 90vh;
    overflow-y: auto;
    width: 100%;
    bottom: 0;
    left: 0;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.32, 0.72, 0, 1);
    -webkit-overflow-scrolling: touch;
}

.ios-booking-overlay.show .ios-booking-modal {
    transform: translateY(0);
}

/* Desktop Centered Modal */
@media (min-width: 768px) {
    .ios-booking-overlay {
        align-items: center;
        justify-content: center;
        padding: 20px;
    }

    .ios-booking-modal {
        position: relative;
        max-width: 500px;
        width: 100%;
        bottom: auto;
        left: auto;
        border-radius: 20px;
        max-height: 85vh;
        transform: scale(0.9);
        opacity: 0;
    }

    .ios-booking-overlay.show .ios-booking-modal {
        transform: scale(1);
        opacity: 1;
    }
}

/* Modal Header */
.ios-modal-header {
    position: sticky;
    top: 0;
    background: #ffffff;
    border-bottom: 1px solid #e5e5e5;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 10;
    border-radius: 20px 20px 0 0;
}

.ios-modal-title {
    font-size: 20px;
    font-weight: 600;
    color: #000000;
    margin: 0;
}

.ios-close-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f2f2f7;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 20px;
    color: #8e8e93;
}

.ios-close-btn:hover {
    background: #e5e5ea;
}

/* Modal Body */
.ios-modal-body {
    padding: 20px;
}

/* Collapsible Section */
.ios-section {
    background: #f2f2f7;
    border-radius: 12px;
    margin-bottom: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.ios-section-header {
    padding: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    user-select: none;
    background: #ffffff;
    border-bottom: 1px solid #e5e5e5;
}

.ios-section.collapsed .ios-section-header {
    border-bottom: none;
}

.ios-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
    font-weight: 500;
    color: #000000;
}

.ios-section-title i {
    font-size: 18px;
    color: #007aff;
}

.ios-section-chevron {
    font-size: 14px;
    color: #8e8e93;
    transition: transform 0.3s ease;
}

.ios-section.expanded .ios-section-chevron {
    transform: rotate(180deg);
}

.ios-section-content {
    padding: 16px;
    background: #ffffff;
    display: none;
}

.ios-section.expanded .ios-section-content {
    display: block;
}

/* Selected Services Summary */
.ios-service-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f2f2f7;
}

.ios-service-item:last-child {
    border-bottom: none;
}

.ios-service-name {
    font-size: 15px;
    color: #000000;
    font-weight: 500;
}

.ios-service-qty {
    font-size: 14px;
    color: #8e8e93;
}

.ios-service-price {
    font-size: 15px;
    font-weight: 600;
    color: #007aff;
}

.ios-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: #f2f2f7;
    border-radius: 8px;
    margin-top: 8px;
}

.ios-total-label {
    font-size: 16px;
    font-weight: 600;
    color: #000000;
}

.ios-total-price {
    font-size: 20px;
    font-weight: 700;
    color: #007aff;
}

/* Date & Time Picker */
.ios-datetime-preview {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: #f2f2f7;
    border-radius: 8px;
    font-size: 15px;
    color: #000000;
}

.ios-datetime-preview i {
    color: #007aff;
}

.ios-date-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 8px;
    margin-bottom: 16px;
}

.ios-date-pill {
    padding: 12px 8px;
    background: #f2f2f7;
    border-radius: 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.ios-date-pill:hover {
    background: #e5e5ea;
}

.ios-date-pill.selected {
    background: #007aff;
    color: #ffffff;
    border-color: #007aff;
}

.ios-date-day {
    font-size: 12px;
    font-weight: 500;
    display: block;
    margin-bottom: 4px;
    text-transform: uppercase;
}

.ios-date-num {
    font-size: 18px;
    font-weight: 600;
    display: block;
}

.ios-time-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.ios-time-slot {
    padding: 12px;
    background: #f2f2f7;
    border-radius: 8px;
    text-align: center;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.ios-time-slot:hover {
    background: #e5e5ea;
}

.ios-time-slot.selected {
    background: #007aff;
    color: #ffffff;
    border-color: #007aff;
}

.ios-time-slot.disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* Form Inputs */
.ios-input {
    width: 100%;
    padding: 12px 16px;
    background: #f2f2f7;
    border: 1px solid transparent;
    border-radius: 10px;
    font-size: 15px;
    color: #000000;
    transition: all 0.2s;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.ios-input:focus {
    outline: none;
    background: #ffffff;
    border-color: #007aff;
}

.ios-input::placeholder {
    color: #8e8e93;
}

textarea.ios-input {
    resize: vertical;
    min-height: 80px;
}

.ios-input-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: #8e8e93;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Image Upload */
.ios-image-upload {
    border: 2px dashed #c7c7cc;
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.ios-image-upload:hover {
    border-color: #007aff;
    background: #f2f2f7;
}

.ios-image-upload i {
    font-size: 40px;
    color: #007aff;
    margin-bottom: 12px;
}

.ios-upload-text {
    font-size: 15px;
    color: #000000;
    font-weight: 500;
    margin-bottom: 4px;
}

.ios-upload-hint {
    font-size: 13px;
    color: #8e8e93;
}

.ios-image-previews {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.ios-image-preview {
    position: relative;
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
    background: #f2f2f7;
}

.ios-image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ios-image-remove {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 24px;
    height: 24px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border: none;
    border-radius: 50%;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.ios-image-remove:hover {
    background: rgba(255, 59, 48, 0.8);
}

/* Address Section */
.ios-address-btn {
    width: 100%;
    padding: 16px;
    background: #ffffff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 12px;
}

.ios-address-btn:hover {
    background: #f2f2f7;
}

.ios-address-main {
    flex: 1;
}

.ios-address-label {
    font-size: 13px;
    color: #8e8e93;
    font-weight: 500;
    margin-bottom: 4px;
}

.ios-address-text {
    font-size: 15px;
    color: #000000;
    font-weight: 500;
}

.ios-address-icon {
    width: 40px;
    height: 40px;
    background: #f2f2f7;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #007aff;
}

.ios-add-address-btn {
    width: 100%;
    padding: 16px;
    background: #007aff;
    color: #ffffff;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.ios-add-address-btn:hover {
    background: #0051d5;
}

/* Map Container */
.ios-map-container {
    width: 100%;
    height: 300px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 12px;
    background: #f2f2f7;
    position: relative;
    border: 1px solid #e5e5e5;
}

#iosMap {
    width: 100%;
    height: 100%;
}

.ios-location-btn {
    width: 100%;
    padding: 12px 16px;
    background: #007aff;
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.ios-location-btn:hover {
    background: #0051d5;
}

.ios-location-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.ios-location-search {
    position: relative;
    margin-bottom: 12px;
}

.ios-search-input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    background: #f2f2f7;
    border: 1px solid transparent;
    border-radius: 10px;
    font-size: 15px;
}

.ios-search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #8e8e93;
}

.ios-search-results {
    background: #ffffff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    margin-top: 8px;
    max-height: 200px;
    overflow-y: auto;
}

.ios-search-item {
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.2s;
    border-bottom: 1px solid #f2f2f7;
}

.ios-search-item:last-child {
    border-bottom: none;
}

.ios-search-item:hover {
    background: #f2f2f7;
}

/* Confirm Button */
.ios-confirm-btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #007aff 0%, #0051d5 100%);
    color: #ffffff;
    border: none;
    border-radius: 14px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
    margin-top: 20px;
}

.ios-confirm-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 122, 255, 0.4);
}

.ios-confirm-btn:active {
    transform: translateY(0);
}

.ios-confirm-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Loading State */
.ios-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.ios-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: ios-spin 0.8s linear infinite;
}

@keyframes ios-spin {
    to {
        transform: rotate(360deg);
    }
}

/* Success/Error Messages */
.ios-message {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
}

.ios-message.success {
    background: #d1f4e0;
    color: #0e6027;
}

.ios-message.error {
    background: #ffdce0;
    color: #c41e3a;
}

/* Optional Badge */
.ios-optional-badge {
    display: inline-block;
    padding: 2px 8px;
    background: #f2f2f7;
    color: #8e8e93;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    margin-left: 8px;
}

/* Smooth Scroll */
.ios-booking-modal {
    scroll-behavior: smooth;
}

/* Custom Scrollbar */
.ios-booking-modal::-webkit-scrollbar {
    width: 6px;
}

.ios-booking-modal::-webkit-scrollbar-track {
    background: transparent;
}

.ios-booking-modal::-webkit-scrollbar-thumb {
    background: #c7c7cc;
    border-radius: 3px;
}

.ios-booking-modal::-webkit-scrollbar-thumb:hover {
    background: #8e8e93;
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {

    .ios-booking-overlay,
    .ios-booking-modal,
    .ios-section,
    * {
        transition: none !important;
        animation: none !important;
    }
}

/* iPhone Notch Safe Area */
@supports (padding: env(safe-area-inset-bottom)) {
    .ios-booking-modal {
        padding-bottom: env(safe-area-inset-bottom);
    }
}

/* Custom Map Marker */
.map-marker {
    cursor: pointer;
    animation: markerBounce 0.5s ease;
}

@keyframes markerBounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* MapTiler controls customization */
.maplibregl-ctrl-bottom-right,
.maplibregl-ctrl-bottom-left {
    bottom: 10px !important;
}

/* ============================================================
   DARK MODE STYLES
   ============================================================ */
body.dark-mode .ios-booking-modal {
    background: #1c1c1e;
}

body.dark-mode .ios-modal-header {
    background: #1c1c1e;
    border-bottom-color: #38383a;
}

body.dark-mode .ios-modal-title {
    color: #ffffff;
}

body.dark-mode .ios-close-btn {
    background: #2c2c2e;
    color: #98989f;
}

body.dark-mode .ios-close-btn:hover {
    background: #3a3a3c;
}

body.dark-mode .ios-section {
    background: #2c2c2e;
}

body.dark-mode .ios-section-header {
    background: #1c1c1e;
    border-bottom-color: #38383a;
}

body.dark-mode .ios-section-title {
    color: #ffffff;
}

body.dark-mode .ios-section-content {
    background: #1c1c1e;
}

body.dark-mode .ios-service-name {
    color: #ffffff;
}

body.dark-mode .ios-service-item {
    border-bottom-color: #38383a;
}

body.dark-mode .ios-total-row {
    background: #2c2c2e;
}

body.dark-mode .ios-total-label {
    color: #ffffff;
}

body.dark-mode .ios-datetime-preview {
    background: #2c2c2e;
    color: #ffffff;
}

body.dark-mode .ios-date-pill {
    background: #2c2c2e;
    color: #ffffff;
}

body.dark-mode .ios-date-pill:hover {
    background: #3a3a3c;
}

body.dark-mode .ios-date-pill.selected {
    background: #0a84ff;
    color: #ffffff;
    border-color: #0a84ff;
}

body.dark-mode .ios-time-slot {
    background: #2c2c2e;
    color: #ffffff;
}

body.dark-mode .ios-time-slot:hover {
    background: #3a3a3c;
}

body.dark-mode .ios-time-slot.selected {
    background: #0a84ff;
    color: #ffffff;
    border-color: #0a84ff;
}

body.dark-mode .ios-input {
    background: #2c2c2e;
    color: #ffffff;
    border-color: #38383a;
}

body.dark-mode .ios-input:focus {
    background: #1c1c1e;
    border-color: #0a84ff;
}

body.dark-mode .ios-input::placeholder {
    color: #98989f;
}

body.dark-mode .ios-input-label {
    color: #98989f;
}

body.dark-mode .ios-image-upload {
    border-color: #48484a;
    background: #1c1c1e;
}

body.dark-mode .ios-image-upload:hover {
    border-color: #0a84ff;
    background: #2c2c2e;
}

body.dark-mode .ios-upload-text {
    color: #ffffff;
}

body.dark-mode .ios-image-preview {
    background: #2c2c2e;
}

body.dark-mode .ios-address-btn {
    background: #1c1c1e;
    border-color: #38383a;
}

body.dark-mode .ios-address-btn:hover {
    background: #2c2c2e;
}

body.dark-mode .ios-address-text {
    color: #ffffff;
}

body.dark-mode .ios-address-icon {
    background: #2c2c2e;
}

body.dark-mode .ios-map-container {
    background: #2c2c2e;
    border-color: #38383a;
}

body.dark-mode .ios-search-input {
    background: #2c2c2e;
    color: #ffffff;
    border-color: #38383a;
}

body.dark-mode .ios-search-results {
    background: #1c1c1e;
    border-color: #38383a;
}

body.dark-mode .ios-search-item {
    color: #ffffff;
    border-bottom-color: #38383a;
}

body.dark-mode .ios-search-item:hover {
    background: #2c2c2e;
}

body.dark-mode .ios-optional-badge {
    background: #2c2c2e;
    color: #98989f;
}

body.dark-mode .ios-message.success {
    background: #1a3a2a;
    color: #34c759;
}

body.dark-mode .ios-message.error {
    background: #3a1a1a;
    color: #ff453a;
}

/* Dark mode scrollbar */
body.dark-mode .ios-booking-modal::-webkit-scrollbar-thumb {
    background: #48484a;
}

body.dark-mode .ios-booking-modal::-webkit-scrollbar-thumb:hover {
    background: #636366;
}

/* ============================================================
   LOGIN POPUP STYLES
   ============================================================ */
.ios-login-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 100000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.ios-login-popup-overlay.show {
    opacity: 1;
}

.ios-login-popup {
    background: #ffffff;
    border-radius: 20px;
    padding: 32px 24px;
    max-width: 360px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

.ios-login-popup-overlay.show .ios-login-popup {
    transform: scale(1);
}

.ios-login-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, #007aff 0%, #0051d5 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ios-login-icon i {
    font-size: 32px;
    color: #ffffff;
}

.ios-login-title {
    font-size: 22px;
    font-weight: 700;
    color: #000000;
    margin: 0 0 12px;
}

.ios-login-message {
    font-size: 15px;
    color: #666666;
    margin: 0 0 24px;
    line-height: 1.5;
}

.ios-login-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ios-login-btn-primary {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #007aff 0%, #0051d5 100%);
    color: #ffffff;
    border: none;
    border-radius: 14px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.ios-login-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 122, 255, 0.4);
}

.ios-login-btn-secondary {
    width: 100%;
    padding: 14px;
    background: #f2f2f7;
    color: #000000;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.ios-login-btn-secondary:hover {
    background: #e5e5ea;
}

.ios-login-signup {
    font-size: 14px;
    color: #8e8e93;
    margin: 20px 0 0;
}

.ios-login-signup a {
    color: #007aff;
    text-decoration: none;
    font-weight: 500;
}

/* ============================================================
   TOAST NOTIFICATION STYLES
   ============================================================ */
.ios-added-toast {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: #1c1c1e;
    color: #ffffff;
    padding: 14px 24px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    font-weight: 500;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
    z-index: 100001;
    opacity: 0;
    transition: all 0.3s ease;
}

.ios-added-toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.ios-added-toast i {
    color: #34c759;
    font-size: 18px;
}

/* ============================================================
   LOGIN POPUP - DARK MODE
   ============================================================ */
body.dark-mode .ios-login-popup {
    background: #1c1c1e;
}

body.dark-mode .ios-login-title {
    color: #ffffff;
}

body.dark-mode .ios-login-message {
    color: #98989f;
}

body.dark-mode .ios-login-btn-secondary {
    background: #2c2c2e;
    color: #ffffff;
}

body.dark-mode .ios-login-btn-secondary:hover {
    background: #3a3a3c;
}

body.dark-mode .ios-login-signup {
    color: #636366;
}

/* ============================================================
   TOAST - LIGHT MODE OVERRIDE
   ============================================================ */
body:not(.dark-mode) .ios-added-toast {
    background: #ffffff;
    color: #000000;
    border: 1px solid #e5e5e5;
}

/* ============================================================
   BOOKING LOADING OVERLAY - Blur with Dots Animation
   ============================================================ */
.booking-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.booking-loading-overlay.show {
    opacity: 1;
}

body.dark-mode .booking-loading-overlay {
    background: rgba(28, 28, 30, 0.9);
}

.booking-loading-content {
    text-align: center;
}

.booking-loading-content p {
    margin-top: 20px;
    font-size: 16px;
    font-weight: 500;
    color: #333;
}

body.dark-mode .booking-loading-content p {
    color: #fff;
}

/* Loading Dots Animation */
.loading-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.loading-dots span {
    width: 12px;
    height: 12px;
    background: #007aff;
    border-radius: 50%;
    animation: loadingDots 1.4s ease-in-out infinite both;
}

.loading-dots span:nth-child(1) {
    animation-delay: -0.32s;
}

.loading-dots span:nth-child(2) {
    animation-delay: -0.16s;
}

.loading-dots span:nth-child(3) {
    animation-delay: 0;
}

@keyframes loadingDots {

    0%,
    80%,
    100% {
        transform: scale(0.6);
        opacity: 0.5;
    }

    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ============================================================
   ORDER CONFIRMATION POPUP
   ============================================================ */
.order-confirmation-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.order-confirmation-overlay.show {
    opacity: 1;
}

.order-confirmation-popup {
    background: #ffffff;
    border-radius: 24px;
    padding: 32px 24px;
    max-width: 380px;
    width: 100%;
    text-align: center;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.order-confirmation-overlay.show .order-confirmation-popup {
    transform: scale(1) translateY(0);
}

body.dark-mode .order-confirmation-popup {
    background: #1c1c1e;
}

/* Close Button */
.order-close-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    background: #f2f2f7;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    color: #8e8e93;
    font-size: 14px;
}

.order-close-btn:hover {
    background: #e5e5ea;
    color: #000;
}

body.dark-mode .order-close-btn {
    background: #2c2c2e;
    color: #98989f;
}

/* Success Icon */
.order-success-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #34c759 0%, #2ab854 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    animation: successPop 0.5s ease;
}

.order-success-icon i {
    font-size: 40px;
    color: #fff;
}

@keyframes successPop {
    0% {
        transform: scale(0);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}

/* Title */
.order-title {
    font-size: 24px;
    font-weight: 700;
    color: #000;
    margin: 0 0 20px;
}

body.dark-mode .order-title {
    color: #fff;
}

/* Order Details */
.order-details {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 20px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
}

body.dark-mode .order-details {
    background: #2c2c2e;
}

.order-id,
.order-amount {
    text-align: center;
}

.order-details .label {
    display: block;
    font-size: 12px;
    color: #8e8e93;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.order-details .value {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: #007aff;
}

/* Message */
.order-message {
    font-size: 14px;
    color: #636366;
    line-height: 1.6;
    margin-bottom: 24px;
}

body.dark-mode .order-message {
    color: #98989f;
}

.order-message strong {
    color: #007aff;
}

/* Countdown Container */
.countdown-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 24px;
}

.countdown-circle {
    position: relative;
    width: 60px;
    height: 60px;
}

.countdown-circle svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.countdown-bg {
    fill: none;
    stroke: #e5e5ea;
    stroke-width: 3;
}

body.dark-mode .countdown-bg {
    stroke: #38383a;
}

.countdown-progress {
    fill: none;
    stroke: #007aff;
    stroke-width: 3;
    stroke-linecap: round;
    transition: stroke-dashoffset 1s linear;
}

.countdown-number {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 20px;
    font-weight: 700;
    color: #007aff;
}

.countdown-text {
    font-size: 12px;
    color: #8e8e93;
    margin-top: 8px;
}

/* WhatsApp Help Button */
.order-actions {
    margin-top: 16px;
}

.whatsapp-help-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
    color: #fff;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.whatsapp-help-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

.whatsapp-help-btn i {
    font-size: 20px;
}

/* Simple Login Form Styles */
.simple-login-form {
    margin: 20px 0;
}

.simple-login-form .form-group {
    margin-bottom: 12px;
}

.login-input {
    width: 100%;
    padding: 14px 16px;
    background: #f2f2f7;
    border: 1px solid transparent;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.2s;
    box-sizing: border-box;
}

.login-input:focus {
    outline: none;
    background: #fff;
    border-color: #007aff;
}

body.dark-mode .login-input {
    background: #2c2c2e;
    color: #fff;
}

body.dark-mode .login-input:focus {
    background: #1c1c1e;
}

.login-close-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 30px;
    height: 30px;
    background: #f2f2f7;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #8e8e93;
}

body.dark-mode .login-close-btn {
    background: #2c2c2e;
}

/* ============================================================
   CONFETTI ANIMATION
   ============================================================ */
.confetti-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 100000;
    overflow: hidden;
}

.confetti-piece {
    position: absolute;
    width: 10px;
    height: 10px;
    top: -20px;
    border-radius: 2px;
    animation: confettiFall 3s ease-out forwards;
}

.confetti-piece:nth-child(odd) {
    border-radius: 50%;
}

@keyframes confettiFall {
    0% {
        transform: translateY(0) rotate(0deg) scale(1);
        opacity: 1;
    }

    100% {
        transform: translateY(100vh) rotate(720deg) scale(0.5);
        opacity: 0;
    }
}

/* ============================================================
   ENHANCED ORDER CONFIRMATION POPUP
   ============================================================ */
.order-confirmation-popup {
    max-height: 90vh;
    overflow-y: auto;
    padding: 24px 20px;
}

.order-subtitle {
    font-size: 14px;
    color: #636366;
    margin: -12px 0 20px;
}

body.dark-mode .order-subtitle {
    color: #98989f;
}

/* Order Info Card */
.order-info-card {
    background: #f8f9fa;
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 20px;
}

body.dark-mode .order-info-card {
    background: #2c2c2e;
}

.order-info-row {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.order-info-row:last-child {
    margin-bottom: 0;
}

.order-info-item {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    background: #fff;
    border-radius: 12px;
}

.order-info-item.full-width {
    flex: 100%;
}

body.dark-mode .order-info-item {
    background: #1c1c1e;
}

.order-info-item>i {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #007aff 0%, #5856d6 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 14px;
    flex-shrink: 0;
}

.info-content {
    display: flex;
    flex-direction: column;
}

.info-label {
    font-size: 11px;
    color: #8e8e93;
    text-transform: uppercase;
    font-weight: 600;
}

.info-value {
    font-size: 15px;
    font-weight: 600;
    color: #000;
}

.info-value.highlight {
    color: #34c759;
}

body.dark-mode .info-value {
    color: #fff;
}

/* Services Summary */
.order-services-summary {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px;
    background: #fff;
    border-radius: 12px;
    margin-top: 12px;
}

body.dark-mode .order-services-summary {
    background: #1c1c1e;
}

.services-label {
    font-size: 13px;
    font-weight: 600;
    color: #007aff;
}

.services-label i {
    margin-right: 6px;
}

.services-list {
    font-size: 12px;
    color: #636366;
    line-height: 1.4;
}

body.dark-mode .services-list {
    color: #98989f;
}

/* Timeline Steps */
.order-timeline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin: 20px 0;
    padding: 16px 0;
}

.timeline-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.timeline-step .step-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #e5e5ea;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: #8e8e93;
    transition: all 0.3s ease;
}

.timeline-step.completed .step-icon {
    background: linear-gradient(135deg, #34c759 0%, #30b855 100%);
    color: #fff;
}

.timeline-step span {
    font-size: 10px;
    color: #8e8e93;
    text-align: center;
    max-width: 70px;
}

.timeline-step.completed span {
    color: #34c759;
    font-weight: 500;
}

.timeline-line {
    width: 30px;
    height: 2px;
    background: #e5e5ea;
    margin: 0 4px;
    margin-bottom: 20px;
}

body.dark-mode .timeline-step .step-icon {
    background: #38383a;
}

body.dark-mode .timeline-line {
    background: #38383a;
}

/* Enhanced Action Buttons */
.order-actions {
    display: flex;
    gap: 10px;
    margin: 16px 0;
}

.view-bookings-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 16px;
    background: #007aff;
    color: #fff;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.view-bookings-btn:hover {
    background: #0051d5;
    transform: translateY(-2px);
}

.whatsapp-help-btn {
    flex: 1;
    padding: 14px 16px;
    font-size: 14px;
}

/* Confirmation Note */
.confirmation-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 12px;
    color: #8e8e93;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #e5e5e5;
}

.confirmation-note i {
    color: #34c759;
}

body.dark-mode .confirmation-note {
    border-top-color: #38383a;
}

/* Enhanced Success Icon */
.order-success-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #34c759 0%, #30b855 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    animation: successPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 8px 25px rgba(52, 199, 89, 0.4);
}

.order-success-icon i {
    font-size: 32px;
    color: #fff;
}

/* Enhanced Title */
.order-title {
    font-size: 22px;
    margin-bottom: 8px;
}

/* Smaller countdown for enhanced version */
.countdown-container {
    margin: 16px 0;
}

.countdown-circle {
    width: 50px;
    height: 50px;
}

.countdown-number {
    font-size: 18px;
}

.countdown-text {
    font-size: 11px;
    margin-top: 6px;
}

/* ============================================================
   AUTO-LOCATION CARD STYLES
   ============================================================ */

.ios-location-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 16px;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.ios-location-status {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #666;
    font-size: 14px;
}

.ios-location-status i {
    color: #1e3a8a;
}

.ios-location-info {
    text-align: center;
}

.ios-location-address {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 8px;
    line-height: 1.4;
}

.ios-location-map-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #1e3a8a;
    font-size: 13px;
    text-decoration: none;
    padding: 6px 12px;
    background: rgba(30, 58, 138, 0.1);
    border-radius: 20px;
    transition: all 0.2s;
}

.ios-location-map-link:hover {
    background: rgba(30, 58, 138, 0.2);
}

.ios-saved-addresses-header {
    font-size: 13px;
    color: #666;
    margin-bottom: 10px;
    padding-top: 12px;
    border-top: 1px solid #e5e5e5;
}

.ios-saved-addresses-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ios-address-details {
    margin-top: 12px;
}

.ios-location-actions {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.ios-location-btn {
    flex: 1;
    padding: 12px 16px;
    border-radius: 12px;
    border: none;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s;
    background: #1e3a8a;
    color: white;
}

.ios-location-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.3);
}

.ios-location-btn.secondary {
    background: #f2f2f7;
    color: #1a1a1a;
}

.ios-location-btn.secondary:hover {
    background: #e5e5ea;
    box-shadow: none;
}

.ios-location-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Dark Mode */
body.dark-mode .ios-location-card {
    background: linear-gradient(135deg, #2c2c2e 0%, #1c1c1e 100%);
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .ios-location-address {
    color: #fff;
}

body.dark-mode .ios-location-status {
    color: #aaa;
}

body.dark-mode .ios-saved-addresses-header {
    color: #aaa;
    border-color: #3a3a3c;
}

body.dark-mode .ios-location-btn.secondary {
    background: #3a3a3c;
    color: #fff;
}