/* ==================== DETAIL HEADER ==================== */
.detail-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.detail-header h2 {
    font-size: 18px;
    font-weight: 600;
}

/* ==================== DETAIL HERO ==================== */
.detail-hero {
    position: relative;
    background: linear-gradient(var(--hero-overlay), rgba(0,0,0,0.8)), url('https://images.unsplash.com/photo-1585747860715-2ba37e788b70?w=600') center/cover;
    border-radius: 15px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
}

body.female-theme .detail-hero {
    background: linear-gradient(var(--hero-overlay), rgba(74, 44, 58, 0.8)), url('https://images.unsplash.com/photo-1560066984-138dadb4c035?w=600') center/cover;
}

.wait-time-circle {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid var(--accent-primary);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    background: rgba(0,0,0,0.3);
}

body.female-theme .wait-time-circle {
    background: rgba(255,255,255,0.9);
}

.wait-time-circle.large {
    width: 140px;
    height: 140px;
    border-width: 5px;
}

.wait-time-number {
    font-size: 36px;
    font-weight: 700;
    color: var(--text-primary);
}

body.female-theme .wait-time-number {
    color: var(--accent-primary);
}

.wait-time-circle.large .wait-time-number {
    font-size: 48px;
}

.wait-time-label {
    font-size: 14px;
    color: var(--text-secondary);
}

.barber-count {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 14px;
}

.favorite-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 24px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.favorite-btn:hover {
    color: var(--accent-red);
}

/* ==================== BARBER SELECTOR ==================== */
.barber-selector {
    margin-bottom: 20px;
}

.barber-selector h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent-primary);
    border-radius: 50%;
}

/* الحاوية الرئيسية - جعلناها relative لتكون نقطة ارتكاز القائمة المنسدلة */
.selector-dropdown {
    background-color: var(--bg-card);
    border-radius: 10px;
    border: 1px solid var(--border-color);
    position: relative; 
}

.selector-selected {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    cursor: pointer;
}

.barber-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.selector-selected span:nth-child(2) {
    flex: 1;
    font-weight: 500;
    text-align: right;
}

.wait-time-small {
    font-size: 13px;
    color: var(--text-secondary);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-dot.green { background-color: var(--accent-secondary); }
.status-dot.red { background-color: var(--accent-red); }

.selector-selected i.fa-chevron-down {
    color: var(--text-muted);
    transition: transform 0.3s ease;
}

/* دوران السهم عند الفتح */
.selector-dropdown.open .selector-selected i.fa-chevron-down {
    transform: rotate(180deg);
}

/* القائمة المنسدلة - جعلناها absolute لتطفو فوق الخدمات */
.selector-options {
    display: none;
    position: absolute;
    top: calc(100% + 8px); /* تظهر تحت الزر بمسافة 8 بكسل */
    left: 0;
    right: 0;
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    z-index: 1000; /* قيمة عالية لتظهر فوق كل شيء في الصفحة */
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    max-height: 250px;
    overflow-y: auto;
}

body.female-theme .selector-options {
    box-shadow: 0 10px 25px rgba(212, 120, 168, 0.2);
}

.selector-options.show {
    display: block;
}

.selector-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    cursor: pointer;
    border-bottom: 1px solid var(--border-color);
    transition: background-color 0.2s;
}

.selector-option:last-child {
    border-bottom: none;
}

.selector-option:hover {
    background-color: var(--bg-input);
}


/* ==================== SERVICE CATEGORIES ==================== */
.service-categories {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    margin-bottom: 20px;
    padding-bottom: 5px;
}

.category-btn {
    flex-shrink: 0;
    padding: 10px 20px;
    border: 1px solid var(--border-color);
    background: none;
    color: var(--text-secondary);
    border-radius: 25px;
    font-size: 14px;
    font-family: inherit;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.category-btn.active {
    background-color: var(--bg-card);
    color: var(--text-primary);
    border-color: var(--accent-primary);
}

body.female-theme .category-btn.active {
    background-color: var(--accent-primary);
    color: #ffffff;
}

/* ==================== SERVICES LIST & ADD ==================== */
.services-list { margin-bottom: 20px; }
.service-item {
    background-color: var(--bg-card);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 10px;
    cursor: pointer;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

body.female-theme .service-item { box-shadow: 0 2px 8px rgba(0,0,0,0.05); }
.service-item:hover { border-color: var(--accent-primary); }
.service-item.selected {
    border: 1px solid var(--accent-primary);
    background-color: rgba(212, 168, 83, 0.05);
}

body.female-theme .service-item.selected { background-color: rgba(212, 120, 168, 0.1); }

.service-radio {
    width: 20px;
    height: 20px;
    border: 2px solid var(--text-muted);
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-item.selected .service-radio { border-color: var(--accent-primary); background-color: var(--accent-primary); }
.service-radio i { font-size: 12px; color: var(--bg-primary); display: none; }
body.female-theme .service-radio i { color: #ffffff; }
.service-item.selected .service-radio i { display: block; }

.service-info { flex: 1; }
.service-info h4 { font-size: 16px; font-weight: 600; margin-bottom: 4px; }
.service-info p { font-size: 13px; color: var(--text-secondary); line-height: 1.5; }

.service-price { font-size: 16px; font-weight: 600; color: var(--text-primary); white-space: nowrap; }
body.female-theme .service-price { color: var(--accent-primary); }

.add-services h4, .add-services-confirm h4 { font-size: 16px; font-weight: 600; margin-bottom: 12px; }
.add-service-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
}
.add-service-item:last-child { border-bottom: none; }
.add-service-checkbox {
    width: 20px;
    height: 20px;
    border: 2px solid var(--text-muted);
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.add-service-item.selected .add-service-checkbox { border-color: var(--accent-primary); background-color: var(--accent-primary); }
.add-service-checkbox i { font-size: 12px; color: var(--bg-primary); display: none; }
body.female-theme .add-service-checkbox i { color: #ffffff; }
.add-service-item.selected .add-service-checkbox i { display: block; }

.add-service-info { flex: 1; }
.add-service-info h5 { font-size: 14px; font-weight: 500; margin-bottom: 2px; }
.add-service-price { font-size: 14px; color: var(--text-secondary); }

/* ==================== CONFIRM ORDER PAGE ==================== */
.confirm-content { padding-bottom: 20px; }
.note { color: var(--text-secondary); font-size: 14px; margin-bottom: 20px; }

.order-summary {
    background-color: var(--bg-card);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
}

body.female-theme .order-summary { box-shadow: 0 2px 8px rgba(0,0,0,0.05); }
.order-summary h3 { font-size: 20px; font-weight: 700; margin-bottom: 5px; }
.order-summary > p { color: var(--text-secondary); font-size: 14px; margin-bottom: 15px; }

.order-items { border-top: 1px solid var(--border-color); padding-top: 15px; }
.order-item { margin-bottom: 15px; }
.order-item:last-child { margin-bottom: 0; }
.order-item h4 { font-size: 16px; font-weight: 600; margin-bottom: 4px; }
.order-item p { font-size: 13px; color: var(--text-secondary); }
.order-item .price {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    float: left;
}
body.female-theme .order-item .price { color: var(--accent-primary); }
