/* =============================================
   Agendamento Studio - Amelia Style UI
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --agst-primary: #ec4899;
    --agst-secondary: #fdf2f8;
    --agst-primary-hover: #db2777;
    --agst-bg-page: #f8f9fa;
    --agst-bg-card: #ffffff;
    --agst-text-main: #202124;
    --agst-text-muted: #5f6368;
    --agst-border: #dadce0;
    --agst-radius: 12px;
    --agst-shadow: 0 1px 3px rgba(60, 64, 67, 0.3),
        0 4px 8px 3px rgba(60, 64, 67, 0.15);
    --agst-shadow-hover: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.agst-booking-page-wrapper {
    font-family: 'Inter', sans-serif;
    background-color: var(--agst-bg-page);
    min-height: 100vh;
    padding: 60px 20px;
    color: var(--agst-text-main);
}

.agst-booking-container {
    max-width: 1000px;
    margin: 0 auto;
    background: var(--agst-bg-card);
    border-radius: var(--agst-radius);
    box-shadow: var(--agst-shadow);
    display: grid;
    grid-template-columns: 280px 1fr;
    min-height: 600px;
    overflow: hidden;
}

@media (max-width: 850px) {
    .agst-booking-container {
        grid-template-columns: 1fr;
    }
}

/* Sidebar / Stepper Style Amelia */
.agst-sidebar {
    background: var(--agst-secondary);
    padding: 40px 30px;
    border-right: 1px solid var(--agst-border);
}

@media (max-width: 850px) {
    /* Transform sidebar into a top horizontal header/stepper */
    .agst-sidebar {
        display: block;
        padding: 24px 20px;
        border-right: none;
        border-bottom: 1px solid var(--agst-border);
        background: #fff;
    }

    /* Center the logo in sidebar on mobile (if any image is added there) */
    .agst-sidebar img, 
    .agst-sidebar .agst-logo {
        display: block;
        margin: 0 auto 20px auto;
        max-width: 140px;
    }

    /* Wrap steps in a horizontal flex container to look like a progress bar */
    .agst-sidebar .agst-steps-wrapper {
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 15px; /* Spacing between steps */
        position: relative;
    }
    
    /* Draw a connecting line behind the steps */
    .agst-sidebar .agst-steps-wrapper::before {
        content: "";
        position: absolute;
        top: 14px; /* Half of circle height (28px) */
        left: 20px;
        right: 20px;
        height: 2px;
        background: var(--agst-border);
        z-index: 0;
    }

    .agst-step-sidebar-item {
        margin-bottom: 0;
        flex-direction: column;
        gap: 6px;
        position: relative;
        z-index: 1; /* Stay above the connecting line */
        background: #fff; /* Hide the line behind the circle */
        padding: 0 4px; /* Give the circle some breathing room from the line */
    }

    /* Hide the text labels on mobile to save space, show only numbered circles */
    .agst-step-sidebar-item .agst-step-label {
        display: none;
    }

    /* Make the active step pop a bit more */
    .agst-step-sidebar-item.active {
        transform: scale(1.1);
    }
}

.agst-step-sidebar-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    opacity: 0.5;
    transition: all 0.3s ease;
}

.agst-step-sidebar-item.active {
    opacity: 1;
}

.agst-step-number {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--agst-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.agst-step-sidebar-item.active .agst-step-number {
    background: var(--agst-primary);
    border-color: var(--agst-primary);
    color: #fff;
    box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.15); /* Soft pink halo */
}

.agst-step-label {
    font-size: 14px;
    font-weight: 500;
}

/* Main Content Area */
.agst-booking-content-inner {
    padding: 50px;
    position: relative;
}

@media (max-width: 600px) {
    .agst-booking-content-inner {
        padding: 30px 20px;
    }
}

.agst-booking-header {
    margin-bottom: 40px;
}

.agst-booking-header h1 {
    font-size: 28px;
    font-weight: 600;
    margin: 0 0 10px;
}

.agst-booking-header p {
    color: var(--agst-text-muted);
    font-size: 15px;
}

/* Club Banner */
.agst-club-banner-manage {
    transition: all 0.3s ease;
}

@media (max-width: 480px) {
    .agst-club-banner-manage div[style*="display: flex"] {
        flex-direction: column !important;
        align-items: flex-start !important;
    }
    .agst-club-banner-manage p {
        text-align: left !important;
    }
}

/* Cards Style Amelia */
.agst-services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.agst-service-card {
    border: 1px solid var(--agst-border);
    border-radius: var(--agst-radius);
    padding: 24px;
    transition: all 0.3s ease;
    cursor: pointer;
    background: #fff;
    display: flex;
    align-items: center;
    gap: 20px;
}

.agst-service-image {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.agst-service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.agst-service-card:hover {
    border-color: var(--agst-primary);
    box-shadow: var(--agst-shadow-hover);
    transform: translateY(-2px);
}

.agst-service-card.selected {
    background: rgba(26, 115, 232, 0.04);
    border-color: var(--agst-primary);
    border-width: 2px;
}

.agst-service-info {
    flex: 1;
    min-width: 0;
}

.agst-service-info h4 {
    margin: 0 0 12px;
    font-size: 18px;
    font-weight: 600;
}

.agst-service-meta {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    color: var(--agst-text-muted);
}

/* Calendar */
.agst-calendar-section {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 40px;
}

.agst-calendar-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.agst-cal-month-year {
    font-size: 18px;
    font-weight: 600;
    text-transform: capitalize;
}

.agst-cal-prev,
.agst-cal-next {
    background: #f8f9fa;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.agst-cal-prev:hover,
.agst-cal-next:hover {
    background: var(--agst-border);
}

.agst-cal-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--agst-text-muted);
    margin-bottom: 12px;
}

.agst-cal-body {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
}

.agst-cal-day-btn {
    aspect-ratio: 1;
    border-radius: 50%;
    background: transparent;
    border: 1px solid transparent;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--agst-text-main);
}

.agst-cal-day-btn:not(.disabled):not(.empty):hover {
    border-color: var(--agst-primary);
    color: var(--agst-primary);
}

.agst-cal-day-btn.selected {
    border: 2px solid var(--agst-primary);
    color: var(--agst-primary);
    background: transparent;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.agst-cal-day-btn.disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.agst-cal-day-btn.empty {
    visibility: hidden;
}

@media (max-width: 850px) {
    .agst-calendar-section {
        grid-template-columns: 1fr;
    }
}

.agst-time-slots-section {
    background: #f8f9fa;
    padding: 24px;
    border-radius: var(--agst-radius);
}

.agst-slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 10px;
}

.agst-slot-btn {
    background: #fff;
    border: 1px solid var(--agst-border);
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.agst-slot-btn:hover {
    border-color: var(--agst-primary);
    color: var(--agst-primary);
}

.agst-slot-btn.selected {
    border: 2px solid var(--agst-primary);
    color: var(--agst-primary);
    background: transparent;
}

/* Buttons */
.agst-btn-next,
.agst-btn-confirm,
.agst-btn-pay {
    background: var(--agst-primary);
    color: #fff;
    border: none;
    padding: 14px 32px;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: filter 0.2s;
}

.agst-btn-next:hover {
    filter: brightness(1.1);
}

.agst-btn-back {
    background: transparent;
    border: 1px solid var(--agst-border);
    padding: 14px 32px;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
}

/* Form Management View */
.agst-management-summary {
    background: #fff8e1;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    border-left: 4px solid #ffc107;
}

.agst-btn-cancel {
    background: #f44336;
    color: #fff;
    border: none;
    padding: 14px 32px;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
}

.agst-btn-whatsapp {
    background: #25d366;
    color: #fff;
    text-decoration: none;
    padding: 14px 32px;
    border-radius: 25px;
    font-weight: 600;
    display: inline-block;
}

/* Progress Spinner */
.agst-loading-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid rgba(26, 115, 232, 0.2);
    border-top-color: var(--agst-primary);
    border-radius: 50%;
    animation: agstSpin 0.8s linear infinite;
    display: inline-block;
}

@keyframes agstSpin {
    to {
        transform: rotate(360deg);
    }
}

/* Minimalist Form Fields */
.agst-form-group {
    margin-bottom: 24px;
}

.agst-form-group label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--agst-text-muted);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.agst-form-group input,
.agst-form-group select,
.agst-form-group textarea,
.agst-input {
    width: 100%;
    padding: 16px 20px;
    font-size: 16px;
    border: 1px solid var(--agst-border);
    border-radius: var(--agst-radius);
    background: #fff;
    color: var(--agst-text-main);
    box-sizing: border-box;
    transition: all 0.2s ease;
    font-family: inherit;
    font-weight: 400;
}

.agst-form-group input:focus,
.agst-form-group select:focus,
.agst-form-group textarea:focus,
.agst-input:focus {
    outline: none;
    border-color: var(--agst-primary);
    box-shadow: 0 0 0 4px rgba(26, 115, 232, 0.1);
}

.agst-form-group input::placeholder,
.agst-form-group textarea::placeholder {
    color: #b0b3b8;
    font-weight: 300;
}

/* Floating Socials */
.agst-floating-socials {
    position: fixed;
    bottom: 60px;
    right: 25px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.agst-float-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    color: #fff;
    text-decoration: none;
    overflow: hidden;
}

.agst-float-btn:hover {
    transform: scale(1.1) translateY(-5px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.agst-float-wa {
    background-color: #25d366;
}

.agst-float-ig {
    background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285aeb 90%);
}

.agst-float-btn svg {
    width: 20px;
    height: 20px;
}

.agst-float-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 600px) {
    .agst-floating-socials {
        bottom: 20px;
        right: 20px;
        gap: 10px;
    }

    .agst-float-btn {
        width: 40px;
        height: 40px;
    }
}