/**
 * Enhanced Tour Pricing Options - Responsive & Modern Design
 * Optimized for mobile, tablet, and desktop
 */

/* ========================================
   CONTAINER & LAYOUT
   ======================================== */
.enhanced-pricing-section {
    width: 100%;
    max-width: 100%;
    margin: 40px 0;
}

.pricing-outer-container {
    width: 100%;
}

/* ========================================
   ACCORDION PANELS - MODERN DESIGN
   ======================================== */
.pricing-outer-container .container {
    width: 100%;
    max-width: 100%;
    padding: 0;
}

.pricing-outer-container .panel {
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    margin-bottom: 20px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.pricing-outer-container .panel:hover {
    border-color: #3554D1;
    box-shadow: 0 4px 12px rgba(53, 84, 209, 0.1);
    transform: translateY(-2px);
}

.pricing-outer-container .panel.active {
    border-color: #3554D1;
    box-shadow: 0 8px 24px rgba(53, 84, 209, 0.15);
}

/* ========================================
   PANEL HEADER - CLICKABLE TITLE
   ======================================== */
.pricing-outer-container .setting-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    cursor: pointer;
    background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
    transition: all 0.3s ease;
    user-select: none;
}

.pricing-outer-container .panel.active .setting-title {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border-bottom: 2px solid #e5e7eb;
}

.pricing-outer-container .setting-title:hover {
    background: linear-gradient(135deg, #eff6ff 0%, #f0f9ff 100%);
}

.pricing-outer-container .setting-title i.fa:first-child {
    font-size: 24px;
    color: #3554D1;
    margin-right: 16px;
    flex-shrink: 0;
}

.pricing-outer-container .setting-title h3 {
    flex: 1;
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #1f2937;
    display: flex;
    align-items: center;
    gap: 12px;
}

.pricing-outer-container .accordion-arrow {
    font-size: 18px;
    color: #6b7280;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

.pricing-outer-container .panel.active .accordion-arrow {
    transform: rotate(180deg);
    color: #3554D1;
}

/* ========================================
   PANEL CONTENT - COLLAPSIBLE
   ======================================== */
.pricing-outer-container .setting-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: #ffffff;
}

.pricing-outer-container .panel.active .setting-content {
    max-height: 5000px;
    padding-bottom: 24px;
}

/* ========================================
   RESPONSIVE TABLES
   ======================================== */

.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 16px 0;
}

.table-responsive table {
    width: 100%;
    min-width: 600px;
    border-collapse: separate;
    border-spacing: 0;
}

.table-responsive th {
    font-weight: 600;
    font-size: 14px;
    color: #374151;
    white-space: nowrap;
}

.table-responsive td {
    font-size: 14px;
    color: #1f2937;
}

/* ========================================
   MOBILE PRICING CARDS
   ======================================== */
.pricing-card {
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
    transition: all 0.3s ease;
}

.pricing-card:hover {
    border-color: #3554D1;
    box-shadow: 0 4px 12px rgba(53, 84, 209, 0.1);
}

.pricing-card-header {
    background: linear-gradient(135deg, #3554D1 0%, #2845b8 100%);
    color: white;
    padding: 16px;
}

.pricing-card-header h6 {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 600;
}

.pricing-card-body {
    padding: 16px;
}

.pricing-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.pricing-label {
    font-size: 14px;
    color: #6b7280;
    flex: 1;
}

.pricing-value {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    text-align: right;
}

/* ========================================
   BADGES & LABELS
   ======================================== */
.badge {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    line-height: 1;
}

/* ========================================
   RESIDENCY SELECTOR
   ======================================== */
.residency-selector {
    margin: 16px 0;
}

.btn-group {
    display: inline-flex;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.btn-group .btn {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: 0;
}

.btn-group .btn:first-child {
    border-top-left-radius: 8px;
    border-bottom-left-radius: 8px;
}

.btn-group .btn:last-child {
    border-top-right-radius: 8px;
    border-bottom-right-radius: 8px;
}

.btn-group .btn:hover {
    background: #f3f4f6;
    color: #3554D1;
}

.btn-group .btn.active {
    background: #3554D1;
    color: #ffffff;
    border-color: #3554D1;
}

/* ========================================
   ROOM SELECTION FORM
   ======================================== */
.room-selection-form {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px;
    margin: 24px 20px 20px 20px;
}

.room-selection-form .form-control {
    height: 50px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    padding: 0 16px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.room-selection-form .form-control:focus {
    border-color: #3554D1;
    box-shadow: 0 0 0 3px rgba(53, 84, 209, 0.1);
    outline: none;
}

.room-selection-form label {
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 8px;
    display: block;
}

.price-preview {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 16px;
    margin-top: 16px;
    overflow: visible;
    min-width: 300px;
    width: 100%;
}

/* Fix for price summary elements to prevent truncation */
.fixed-price-summary-wrapper {
    overflow: visible !important;
    min-width: 320px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

.fixed-price-summary-wrapper #price-breakdown-container {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

.fixed-price-summary-wrapper .price-summary-value,
.fixed-price-summary-wrapper #summary-adults-total,
.fixed-price-summary-wrapper #summary-subtotal,
.fixed-price-summary-wrapper #summary-total-price,
.fixed-price-summary-wrapper #summary-addons-total {
    min-width: fit-content !important;
    width: auto !important;
    max-width: none !important;
    white-space: nowrap !important;
    overflow: visible !important;
    text-overflow: clip !important;
    display: inline-block !important;
}

/* ========================================
   RESPONSIVE BREAKPOINTS
   ======================================== */

/* Tablet (768px - 1023px) */
@media (max-width: 1023px) {
    .pricing-outer-container .setting-title {
        padding: 16px 20px;
    }
    
    .pricing-outer-container .setting-title h3 {
        font-size: 18px;
    }
    
    .pricing-outer-container .setting-title i.fa:first-child {
        font-size: 20px;
        margin-right: 12px;
    }
    
    .table-responsive table {
        min-width: 500px;
        font-size: 13px;
    }
    
    .room-selection-form {
        padding: 16px;
        margin: 20px 16px 16px 16px;
    }
}

/* Mobile (max-width: 767px) */
@media (max-width: 767px) {
    .enhanced-pricing-section {
        margin: 24px 0;
    }
    
    .pricing-outer-container .panel {
        border-radius: 12px;
        margin-bottom: 16px;
    }
    
    .pricing-outer-container .setting-title {
        padding: 14px 16px;
        flex-wrap: wrap;
    }
    
    .pricing-outer-container .setting-title h3 {
        font-size: 16px;
        flex: 1 1 calc(100% - 80px);
    }
    
    .pricing-outer-container .setting-title i.fa:first-child {
        font-size: 18px;
        margin-right: 10px;
    }
    
    .pricing-outer-container .accordion-arrow {
        font-size: 16px;
    }
    
    /* Mobile card optimizations */
    .pricing-card {
        border-radius: 10px;
        margin-bottom: 12px;
    }
    
    .pricing-card-header {
        padding: 12px;
    }
    
    .pricing-card-header h6 {
        font-size: 16px;
        margin-bottom: 6px;
    }
    
    .pricing-card-header p {
        font-size: 12px;
    }
    
    .pricing-card-body {
        padding: 12px;
    }
    
    .pricing-row {
        padding: 6px 0;
    }
    
    .pricing-label {
        font-size: 13px;
    }
    
    .pricing-value {
        font-size: 15px;
    }
    
    /* Room selection form mobile */
    .room-selection-form {
        padding: 14px;
        margin: 16px 12px 12px 12px;
        border-radius: 10px;
    }
    
    .room-selection-form h6 {
        font-size: 15px;
        margin-bottom: 14px;
    }
    
    .room-selection-form .form-control {
        height: 46px;
        font-size: 14px;
    }
    
    .room-selection-form label {
        font-size: 13px;
        margin-bottom: 6px;
    }
    
    .room-selection-form .row {
        margin-left: -8px;
        margin-right: -8px;
    }
    
    .room-selection-form .row > [class*="col-"] {
        padding-left: 8px;
        padding-right: 8px;
    }
    
    /* Badge adjustments */
    .badge {
        padding: 4px 10px;
        font-size: 11px;
    }
    
    /* Button group mobile */
    .btn-group .btn {
        padding: 8px 16px;
        font-size: 13px;
    }
}

/* Small mobile (max-width: 480px) */
@media (max-width: 480px) {
    .pricing-outer-container .setting-title h3 {
        font-size: 15px;
    }
    
    .pricing-card-header h6 {
        font-size: 15px;
    }
    
    .pricing-value {
        font-size: 14px;
    }
    
    .room-selection-form .form-control {
        height: 44px;
        font-size: 13px;
    }
    
    .btn-group .btn {
        padding: 7px 12px;
        font-size: 12px;
    }
}

/* ========================================
   UTILITY CLASSES
   ======================================== */
.d-flex {
    display: flex !important;
}

.justify-between {
    justify-content: space-between !important;
}

.items-center {
    align-items: center !important;
}

.gap-10 {
    gap: 10px !important;
}

.text-right {
    text-align: right !important;
}

.mb-0 {
    margin-bottom: 0 !important;
}

.mb-5 {
    margin-bottom: 5px !important;
}

.mb-10 {
    margin-bottom: 10px !important;
}

.mb-15 {
    margin-bottom: 15px !important;
}

.mb-20 {
    margin-bottom: 20px !important;
}

.mt-10 {
    margin-top: 10px !important;
}

.mt-15 {
    margin-top: 15px !important;
}

.mt-20 {
    margin-top: 20px !important;
}

.mt-30 {
    margin-top: 30px !important;
}

.mr-5 {
    margin-right: 5px !important;
}

.mr-8 {
    margin-right: 8px !important;
}

.mr-10 {
    margin-right: 10px !important;
}

.fw-500 {
    font-weight: 500 !important;
}

.fw-600 {
    font-weight: 600 !important;
}

.fw-700 {
    font-weight: 700 !important;
}

.text-success {
    color: #22c55e !important;
}

.text-warning {
    color: #eab308 !important;
}

.text-primary {
    color: #3554D1 !important;
}

.text-light-1 {
    color: #6b7280 !important;
}

/* ========================================
   ANIMATIONS
   ======================================== */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pricing-outer-container .panel.active .setting-content {
    animation: slideDown 0.3s ease-out;
}

/* ========================================
   PRINT STYLES
   ======================================== */
@media print {
    .pricing-outer-container .panel {
        border: 1px solid #000;
        page-break-inside: avoid;
    }
    
    .pricing-outer-container .setting-content {
        max-height: none !important;
        display: block !important;
    }
    
    .pricing-outer-container .accordion-arrow {
        display: none;
    }
}
