/* RideAndGoo Style Pickers - Glassmorphism Brand Theme */
:root {
    --rg-orange: #f27025;
    --rg-pink: #ff2d78;
    --rg-gradient: linear-gradient(135deg, #f27025 0%, #ff2d78 100%);
    --rg-dark-orange: #d94e00;
    --rg-light-orange: rgba(242, 112, 37, 0.1);
    --rg-orange-border: rgba(242, 112, 37, 0.2);
    --rg-text-grey: #94a3b8;
    --rg-light-grey: rgba(255, 255, 255, 0.05);
    --rg-disabled: #475569;
    --rg-active-bg: rgba(255, 255, 255, 0.1);
    --rg-scroll-bg: rgba(0, 0, 0, 0.2);
}

/* === MODAL & OVERLAY === */
.rg-picker-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.rg-picker-overlay.active {
    display: flex;
    opacity: 1;
}

.rg-picker-modal {
    background: #ffffff;
    /* White theme */
    border-radius: 16px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.25);
    max-width: 95%;
    width: auto;
    overflow: hidden;
    position: relative;
    border: none;
    transform: translateY(20px);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.rg-picker-overlay.active .rg-picker-modal {
    transform: translateY(0);
}

/* === CALENDAR STYLES === */
.rg-calendar-container {
    padding: 0;
    min-width: 300px;
}

@media (min-width: 768px) {
    .rg-calendar-dual {
        display: flex;
        gap: 0;
        /* Header spans across */
    }

    .rg-cal-month-wrap {
        padding: 0 10px;
    }
}

.rg-cal-header {
    background: var(--rg-gradient);
    color: white;
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.rg-cal-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    text-transform: capitalize;
}

.rg-cal-nav {
    display: flex;
    gap: 15px;
}

.rg-cal-nav button,
.rg-prev-month,
.rg-next-month {
    background: transparent !important;
    border: 1px solid rgba(255, 255, 255, 0.4) !important;
    color: white !important;
    font-size: 14px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    outline: none !important;
}

.rg-cal-nav button:hover,
.rg-prev-month:hover,
.rg-next-month:hover {
    background: rgba(255, 255, 255, 0.2) !important;
    border-color: white !important;
}

.rg-cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    padding: 15px 20px;
    background: #ffffff;
}

.rg-cal-days-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    padding: 15px 20px 0;
    font-size: 12px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
}

.rg-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #1e293b;
    border-radius: 50%;
    transition: all 0.2s;
}

.rg-day:hover:not(.disabled) {
    background: #fff7ed;
    color: var(--rg-orange);
}

.rg-day.today {
    border: 1px solid var(--rg-orange);
    color: var(--rg-orange);
    font-weight: 700;
}

.rg-day.selected {
    background: var(--rg-gradient) !important;
    color: white !important;
    border-color: var(--rg-orange) !important;
}

.rg-day.disabled {
    color: #cbd5e1;
    cursor: not-allowed;
}

.rg-cal-footer {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 15px 20px 20px;
    border-top: 1px solid #f1f5f9;
    background: #ffffff;
}

.rg-btn-quick {
    padding: 10px 20px;
    background: transparent;
    border: 1px solid var(--rg-orange);
    color: var(--rg-orange);
    border-radius: 12px;
    font-weight: 600;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.rg-btn-quick:hover {
    background: var(--rg-light-orange);
}

.rg-btn-cancel {
    padding: 10px 20px;
    background: #f1f5f9;
    border: none;
    color: #475569;
    border-radius: 12px;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s;
}

.rg-btn-cancel:hover {
    background: #e2e8f0;
}

/* === TIME PICKER STYLES === */
.rg-time-picker {
    padding: 0;
    width: 320px;
    background: #ffffff;
}

.rg-time-picker-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

.rg-time-picker-header h4 {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
}

.rg-time-close {
    background: #f1f5f9;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #64748b;
    transition: background 0.2s;
}

.rg-time-close:hover {
    background: #e2e8f0;
}

.rg-time-labels {
    display: flex;
    justify-content: space-around;
    padding: 0 20px 10px;
}

.rg-time-label {
    font-size: 10px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.rg-time-cols {
    display: flex;
    justify-content: center;
    gap: 15px;
    padding: 0 20px;
    height: 220px;
    position: relative;
    mask-image: linear-gradient(to bottom, transparent, black 15%, black 85%, transparent);
    -webkit-mask-image: linear-gradient(to bottom, transparent, black 15%, black 85%, transparent);
}

.rg-time-col {
    flex: 1;
    overflow-y: scroll;
    padding: 88px 0;
    scrollbar-width: none;
    scroll-snap-type: y mandatory;
    position: relative;
    z-index: 1;
}

.rg-time-col::-webkit-scrollbar {
    display: none;
}

.rg-time-item {
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: #64748b;
    font-weight: 500;
    cursor: pointer;
    scroll-snap-align: center;
    transition: all 0.2s;
}

.rg-time-item.selected {
    color: #1e293b;
    font-weight: 700;
}

.rg-time-selection-box {
    position: absolute;
    top: 50%;
    left: 20px;
    right: 20px;
    transform: translateY(-50%);
    height: 44px;
    background: var(--rg-gradient);
    border-radius: 8px;
    z-index: 0;
    pointer-events: none;
}

.rg-time-col-wrap {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.rg-time-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: #94a3b8;
    height: 30px;
    width: 100%;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
    z-index: 10;
}

.rg-time-arrow:hover {
    color: var(--rg-pink);
    background: rgba(255, 45, 120, 0.05);
}

.rg-time-arrow.up {
    margin-bottom: 5px;
}

.rg-time-arrow.down {
    margin-top: 5px;
}

.rg-time-separator {
    display: flex;
    align-items: center;
    font-size: 20px;
    font-weight: 700;
    color: #cbd5e1;
}

.rg-time-item.active-in-box {
    color: #ffffff !important;
    font-weight: 700;
    z-index: 1;
}

.rg-time-footer {
    padding: 20px;
}

.rg-btn-ok {
    width: 100%;
    padding: 14px;
    background: var(--rg-gradient);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
}

.rg-btn-ok:hover {
    transform: scale(1.02);
}

/* Mobile responsive fixes */
@media (max-width: 500px) {
    .rg-calendar-container {
        min-width: 100%;
    }

    .rg-cal-month-wrap {
        padding: 0 5px;
    }

    .rg-calendar-dual {
        flex-direction: column;
        gap: 0;
    }

    .rg-picker-modal {
        width: 100%;
        border-radius: 20px 20px 0 0;
        bottom: 0;
        transform: translateY(100%);
        max-width: 100%;
        position: fixed; /* Ensure it stays at bottom */
    }

    .rg-picker-overlay.active .rg-picker-modal {
        transform: translateY(0);
        margin-top: auto;
    }
}