/* GD Bookings - Frontend */
/* Aggressive reset to override Pro Theme / X / Cornerstone and similar themes */

@font-face {
    font-family: 'CircularXX';
    src: url('https://gabrieldesign.swiss/wp-content/uploads/CircularXXWeb-Book.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* ============================================================
   FULL RESET - Override any theme styles
   ============================================================ */
#gdb-booking-widget,
#gdb-booking-widget *,
#gdb-booking-widget *::before,
#gdb-booking-widget *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    border: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
    text-decoration: none;
    text-transform: none;
    letter-spacing: 0;
    word-spacing: normal;
    line-height: inherit;
    color: inherit;
    background: transparent;
    box-shadow: none;
    text-shadow: none;
    float: none;
    clear: none;
    max-width: none;
    min-width: 0;
    min-height: 0;
    outline: none;
    list-style: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    transition: none;
}

/* ============================================================
   BASE
   ============================================================ */
#gdb-booking-widget {
    font-family: 'CircularXX', -apple-system, BlinkMacSystemFont, sans-serif !important;
    max-width: 640px;
    margin: 0 auto;
    color: #333;
    font-size: 15px;
    line-height: 1.5;
    text-align: left;
    position: relative;
    display: block;
}

#gdb-booking-widget p {
    margin: 0;
    padding: 0;
    font-size: 15px;
    line-height: 1.5;
}

#gdb-booking-widget a {
    color: #333;
    text-decoration: none;
    cursor: pointer;
}

#gdb-booking-widget strong,
#gdb-booking-widget b {
    font-weight: 600;
}

/* ============================================================
   STEPS PROGRESS BAR
   ============================================================ */
#gdb-booking-widget .gdb-steps {
    display: flex !important;
    flex-direction: row;
    gap: 0;
    margin: 0 0 24px 0;
    padding: 0 0 0 0;
    border: 0;
    border-bottom: 2px solid #e0e0e0;
    list-style: none;
    background: transparent;
}

#gdb-booking-widget .gdb-step {
    flex: 1;
    display: block;
    text-align: center;
    padding: 10px 4px;
    font-size: 13px;
    font-weight: 400;
    color: #999;
    border: 0;
    border-bottom: 2px solid transparent;
    margin: 0 0 -2px 0;
    cursor: default;
    background: transparent;
    transition: color 0.2s, border-color 0.2s;
}

#gdb-booking-widget .gdb-step.active {
    color: #333;
    font-weight: 600;
    border-bottom-color: #333;
}

#gdb-booking-widget .gdb-step.completed {
    color: #666;
    border-bottom-color: #999;
}

#gdb-booking-widget .gdb-step-num {
    display: inline-block;
    width: 22px;
    height: 22px;
    line-height: 22px;
    border-radius: 50%;
    background: #e0e0e0;
    color: #666;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    margin: 0 4px 0 0;
    vertical-align: middle;
}

#gdb-booking-widget .gdb-step.active .gdb-step-num {
    background: #333;
    color: #fff;
}

#gdb-booking-widget .gdb-step.completed .gdb-step-num {
    background: #999;
    color: #fff;
}

/* ============================================================
   PANELS
   ============================================================ */
#gdb-booking-widget .gdb-panel {
    display: block;
    position: relative;
    min-height: 80px;
}

#gdb-booking-widget .gdb-panel-title,
#gdb-booking-widget h3.gdb-panel-title {
    font-size: 17px !important;
    font-weight: 600 !important;
    color: #333 !important;
    margin: 0 0 16px 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    line-height: 1.3 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
}

/* ============================================================
   SERVICES
   ============================================================ */
#gdb-booking-widget .gdb-services-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

#gdb-booking-widget .gdb-service-item {
    padding: 16px 20px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    transition: background 0.15s, border-color 0.15s;
}

#gdb-booking-widget .gdb-service-item:hover {
    background: #f8f8f8;
    border-color: #333;
}

#gdb-booking-widget .gdb-service-name {
    font-weight: 500;
    font-size: 15px;
}

#gdb-booking-widget .gdb-service-desc {
    font-size: 13px;
    color: #666;
    margin-top: 2px;
}

#gdb-booking-widget .gdb-service-duration {
    color: #666;
    font-size: 14px;
    white-space: nowrap;
    margin-left: 16px;
}

/* ============================================================
   MONTH NAV
   ============================================================ */
#gdb-booking-widget .gdb-date-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 16px 0;
}

#gdb-booking-widget .gdb-btn-nav,
#gdb-booking-widget button.gdb-btn-nav {
    display: inline-block;
    background: #fff !important;
    border: 1px solid #e0e0e0 !important;
    border-radius: 6px;
    padding: 6px 14px !important;
    cursor: pointer;
    font-size: 16px;
    color: #333;
    line-height: 1;
    transition: background 0.15s;
}

#gdb-booking-widget .gdb-btn-nav:hover {
    background: #f8f8f8 !important;
}

#gdb-booking-widget .gdb-btn-nav:disabled {
    opacity: 0.3;
    cursor: default;
}

#gdb-booking-widget .gdb-month-label {
    font-weight: 600;
    font-size: 16px;
    color: #333;
}

/* ============================================================
   DATE LIST
   ============================================================ */
#gdb-booking-widget .gdb-dates-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
    max-height: 400px;
    overflow-y: auto;
}

#gdb-booking-widget .gdb-date-item {
    padding: 12px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    cursor: pointer;
    background: #fff;
    font-size: 15px;
    transition: background 0.15s, border-color 0.15s;
}

#gdb-booking-widget .gdb-date-item:hover {
    background: #f8f8f8;
    border-color: #333;
}

#gdb-booking-widget .gdb-no-dates {
    text-align: center;
    padding: 30px;
    color: #666;
    font-size: 14px;
}

/* ============================================================
   SELECTED DATE & SLOTS
   ============================================================ */
#gdb-booking-widget .gdb-selected-date,
#gdb-booking-widget p.gdb-selected-date {
    font-weight: 500;
    margin: 0 0 16px 0;
    padding: 10px 14px;
    background: #f8f8f8;
    border-radius: 6px;
    font-size: 14px;
    color: #333;
}

#gdb-booking-widget .gdb-slots-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 8px;
}

#gdb-booking-widget .gdb-slot-item {
    padding: 10px 8px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    cursor: pointer;
    text-align: center;
    font-weight: 500;
    font-size: 14px;
    background: #fff;
    color: #333;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}

#gdb-booking-widget .gdb-slot-item:hover {
    background: #f8f8f8;
    border-color: #333;
}

#gdb-booking-widget .gdb-slot-item.selected {
    background: #333;
    color: #fff;
    border-color: #333;
}

/* ============================================================
   SUMMARY
   ============================================================ */
#gdb-booking-widget .gdb-summary {
    background: #f8f8f8;
    border-radius: 6px;
    padding: 12px 16px;
    margin: 0 0 20px 0;
    font-size: 14px;
}

#gdb-booking-widget .gdb-summary-line {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
}

#gdb-booking-widget .gdb-summary-label { color: #666; }
#gdb-booking-widget .gdb-summary-value { font-weight: 500; color: #333; }

/* ============================================================
   FORM
   ============================================================ */
#gdb-booking-widget .gdb-form,
#gdb-booking-widget form.gdb-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
}

#gdb-booking-widget .gdb-form-row {
    display: flex;
    gap: 12px;
    margin: 0;
}

#gdb-booking-widget .gdb-form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
}

#gdb-booking-widget .gdb-form-group.gdb-full-width {
    flex: 1 1 100%;
}

#gdb-booking-widget .gdb-form-group.gdb-half-width {
    flex: 0 0 calc(50% - 6px) !important;
    max-width: calc(50% - 6px) !important;
}

#gdb-booking-widget .gdb-form-group.gdb-half-width select {
    width: 100% !important;
}

#gdb-booking-widget .gdb-form-group label,
#gdb-booking-widget .gdb-form-group > label,
#gdb-booking-widget label {
    font-size: 14px !important;
    font-weight: 500 !important;
    margin: 0 0 4px 0 !important;
    padding: 0 !important;
    display: block !important;
    color: #333 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    line-height: 1.4 !important;
    float: none !important;
    width: auto !important;
    background: transparent !important;
    border: 0 !important;
}

#gdb-booking-widget .gdb-required { color: #c53030 !important; }
#gdb-booking-widget .gdb-optional { color: #666 !important; font-weight: 400 !important; }

#gdb-booking-widget input[type="text"],
#gdb-booking-widget input[type="email"],
#gdb-booking-widget input[type="tel"],
#gdb-booking-widget select,
#gdb-booking-widget textarea {
    padding: 10px 12px !important;
    border: 1px solid #e0e0e0 !important;
    border-radius: 6px !important;
    font-size: 15px !important;
    font-family: 'CircularXX', -apple-system, BlinkMacSystemFont, sans-serif !important;
    color: #333 !important;
    width: 100% !important;
    background: #fff !important;
    margin: 0 !important;
    height: auto !important;
    line-height: 1.4 !important;
    box-shadow: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    transition: border-color 0.15s !important;
}

#gdb-booking-widget select,
#gdb-booking-widget select#gdb-salutation,
#gdb-booking-widget .gdb-form-group select {
    border: 1px solid #e0e0e0 !important;
    border-width: 1px !important;
    border-style: solid !important;
    border-color: #e0e0e0 !important;
    background-color: #fff !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23666' stroke-width='1.5' fill='none'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 12px center !important;
    padding-right: 36px !important;
    cursor: pointer !important;
    outline: none !important;
}

#gdb-booking-widget input[type="text"]:focus,
#gdb-booking-widget input[type="email"]:focus,
#gdb-booking-widget input[type="tel"]:focus,
#gdb-booking-widget select:focus,
#gdb-booking-widget textarea:focus {
    outline: none !important;
    border-color: #333 !important;
    box-shadow: none !important;
}

#gdb-booking-widget input.gdb-error,
#gdb-booking-widget select.gdb-error,
#gdb-booking-widget textarea.gdb-error {
    border-color: #c53030 !important;
}

#gdb-booking-widget .gdb-form-error {
    background: #fff5f5;
    color: #c53030;
    padding: 12px 16px;
    border: 1px solid #fed7d7;
    border-radius: 6px;
    font-size: 14px;
}

/* ============================================================
   NAV BUTTONS
   ============================================================ */
#gdb-booking-widget .gdb-nav-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 16px 0 0 0;
    gap: 12px;
}

/* ============================================================
   BUTTONS
   ============================================================ */
#gdb-booking-widget .gdb-btn,
#gdb-booking-widget button.gdb-btn,
#gdb-booking-widget a.gdb-btn,
#gdb-booking-widget input[type="submit"].gdb-btn,
#gdb-booking-widget .gdb-btn-primary,
#gdb-booking-widget button.gdb-btn-primary,
#gdb-booking-widget a.gdb-btn-primary {
    display: inline-block !important;
    padding: 10px 24px !important;
    border-radius: 6px !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    font-family: 'CircularXX', -apple-system, BlinkMacSystemFont, sans-serif !important;
    cursor: pointer !important;
    border: 1px solid #e0e0e0 !important;
    background: #fff !important;
    color: #333 !important;
    text-align: center !important;
    line-height: 1.4 !important;
    text-decoration: none !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    box-shadow: none !important;
    transition: background 0.15s, border-color 0.15s !important;
    white-space: nowrap !important;
}

#gdb-booking-widget .gdb-btn:hover,
#gdb-booking-widget button.gdb-btn:hover,
#gdb-booking-widget a.gdb-btn:hover {
    background: #f8f8f8 !important;
}

#gdb-booking-widget .gdb-btn-primary,
#gdb-booking-widget button.gdb-btn-primary,
#gdb-booking-widget a.gdb-btn-primary {
    background: #333 !important;
    color: #fff !important;
    border-color: #333 !important;
}

#gdb-booking-widget .gdb-btn-primary:hover,
#gdb-booking-widget button.gdb-btn-primary:hover,
#gdb-booking-widget a.gdb-btn-primary:hover {
    background: #555 !important;
    color: #fff !important;
}

#gdb-booking-widget .gdb-btn-primary:disabled {
    opacity: 0.5 !important;
    cursor: default !important;
}

#gdb-booking-widget .gdb-btn-back,
#gdb-booking-widget button.gdb-btn-back {
    background: transparent !important;
    border: 0 !important;
    color: #666 !important;
    padding-left: 0 !important;
}

#gdb-booking-widget .gdb-btn-back:hover,
#gdb-booking-widget button.gdb-btn-back:hover {
    background: transparent !important;
    color: #333 !important;
}

/* ============================================================
   CONFIRMATION
   ============================================================ */
#gdb-booking-widget .gdb-confirmation {
    text-align: center;
    padding: 20px 0;
}

#gdb-booking-widget .gdb-confirmation-icon {
    display: block;
    width: 56px;
    height: 56px;
    line-height: 56px;
    border-radius: 50%;
    background: #2d7a3a;
    color: #fff;
    font-size: 28px;
    margin: 0 auto 16px;
    text-align: center;
}

#gdb-booking-widget .gdb-confirmation .gdb-panel-title {
    text-align: center !important;
}

#gdb-booking-widget .gdb-confirmation .gdb-summary {
    text-align: left;
    margin-bottom: 20px;
}

#gdb-booking-widget .gdb-confirmation p {
    margin: 0 0 8px 0;
}

#gdb-booking-widget .gdb-confirmation-actions {
    margin-top: 20px;
}

/* ============================================================
   PRIVACY CHECKBOX
   ============================================================ */
#gdb-booking-widget .gdb-privacy-row {
    margin-top: 4px;
}

#gdb-booking-widget .gdb-checkbox-label {
    display: flex !important;
    align-items: flex-start !important;
    gap: 8px;
    font-size: 14px !important;
    font-weight: 400 !important;
    cursor: pointer;
    line-height: 1.4 !important;
}

#gdb-booking-widget .gdb-checkbox-label input[type="checkbox"] {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    margin: 1px 0 0 0 !important;
    padding: 0 !important;
    border: 1px solid #e0e0e0 !important;
    border-radius: 3px !important;
    background: #fff !important;
    cursor: pointer !important;
    -webkit-appearance: checkbox !important;
    appearance: checkbox !important;
    flex-shrink: 0;
}

#gdb-booking-widget .gdb-checkbox-label input[type="checkbox"].gdb-error {
    border-color: #c53030 !important;
    outline: 2px solid rgba(197, 48, 48, 0.2) !important;
}

#gdb-booking-widget .gdb-checkbox-label a {
    color: #333 !important;
    text-decoration: underline !important;
}

#gdb-booking-widget .gdb-checkbox-label a:hover {
    color: #000 !important;
}

/* ============================================================
   LOADING
   ============================================================ */
#gdb-booking-widget .gdb-loading {
    text-align: center;
    padding: 30px;
    color: #666;
    font-size: 14px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 480px) {
    #gdb-booking-widget .gdb-form-row { flex-direction: column; }
    #gdb-booking-widget .gdb-slots-list { grid-template-columns: repeat(2, 1fr); }
    #gdb-booking-widget .gdb-dates-list { grid-template-columns: 1fr; }
    #gdb-booking-widget .gdb-steps { font-size: 12px; }
    #gdb-booking-widget .gdb-step-num { width: 18px; height: 18px; line-height: 18px; font-size: 10px; }
    #gdb-booking-widget .gdb-form-group.gdb-half-width { flex: 1 1 100% !important; max-width: 100% !important; }
}
