/* 訂單查詢頁面專用樣式 */
.order-lookup-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}

/* 修正麵包屑導航文字對比度 */
.breadcrumb-item a {
    color: #495057 !important;
    text-decoration: none;
}

.breadcrumb-item a:hover {
    color: #333 !important;
}

.breadcrumb-item.active {
    color: #495057 !important;
}

/* 頁面標題 */
.page-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding-top: 6rem;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.page-description {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.breadcrumb-item a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
}

.breadcrumb-item a:hover {
    color: white;
}

.breadcrumb-item.active {
    color: white;
}

/* 查詢表單區域 */
.lookup-form-section {
    background: transparent;
}

.lookup-form-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

.lookup-form-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #667eea, #764ba2);
}

.form-header {
    margin-bottom: 2rem;
}

.icon-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: white;
}

.form-header h3 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

/* 表單樣式 */
.lookup-form .form-label {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.lookup-form .form-control {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.lookup-form .form-control:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.lookup-form .form-control-lg {
    padding: 1rem 1.25rem;
    font-size: 1.1rem;
}

.form-text {
    font-size: 0.875rem;
    color: #495057;
    margin-top: 0.25rem;
}

/* 驗證方式選擇 */
.verification-tabs {
    display: flex;
    gap: 2rem;
    margin-top: 0.5rem;
}

.form-check-inline {
    margin-right: 0;
}

.form-check-input:checked {
    background-color: #667eea;
    border-color: #667eea;
}

.form-check-label {
    font-weight: 500;
    color: #333;
    cursor: pointer;
}

/* 查詢按鈕 */
.lookup-form .btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 10px;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.lookup-form .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

.lookup-form .btn-primary:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.lookup-form .btn-primary:hover:before {
    left: 100%;
}

/* 查詢說明 */
.lookup-help {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1.5rem;
    border-left: 4px solid #667eea;
}

.lookup-help h6 {
    color: #333;
    font-weight: 600;
    margin-bottom: 1rem;
}

.help-list {
    margin: 0;
    padding-left: 1.5rem;
}

.help-list li {
    margin-bottom: 0.5rem;
    color: #495057;
    font-size: 0.9rem;
}

/* 查詢結果區域 */
.lookup-results-section {
    background: transparent;
}

.results-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.results-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #28a745, #20c997);
}

.results-header {
    text-align: center;
    margin-bottom: 2rem;
}

.results-header h4 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

/* 訂單詳細資訊卡片 */
.order-details-card {
    background: #f8f9fa;
    border-radius: 15px;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 2rem;
}

.order-details-card .card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px 15px 0 0;
    padding: 1.5rem;
    border: none;
    display: flex;
    justify-content: between;
    align-items: center;
}

.order-details-card .card-header h5 {
    margin: 0;
    font-weight: 600;
}

.order-status {
    font-size: 0.9rem;
    font-weight: 500;
}

.order-details-card .card-body {
    padding: 2rem;
}

/* QR Code 卡片 */
.qr-code-card {
    background: white;
    border-radius: 15px;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 1rem;
}

.qr-code-card .card-header {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    border-radius: 15px 15px 0 0;
    padding: 1rem 1.5rem;
    border: none;
}

.qr-code-card .card-header h5 {
    margin: 0;
    font-weight: 600;
    font-size: 1.1rem;
}

.qr-code-card .card-body {
    padding: 2rem;
}

.qr-code-container {
    margin-bottom: 1.5rem;
}

.qr-code-container canvas {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    display: block;
    margin: 0 auto;
}

/* QR Code載入動畫 */
.qr-code-loading .spinner-border {
    width: 2rem;
    height: 2rem;
}

/* QR Code錯誤狀態 */
.qr-code-error {
    padding: 2rem;
    color: #6c757d;
}

.qr-code-error .btn {
    margin-top: 1rem;
}

.qr-code-info p {
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

/* 聯絡資訊卡片 */
.contact-info-card {
    background: white;
    border-radius: 15px;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

.contact-info-card .card-header {
    background: linear-gradient(135deg, #ffc107 0%, #ff8c00 100%);
    color: white;
    border-radius: 15px 15px 0 0;
    padding: 1rem 1.5rem;
    border: none;
}

.contact-info-card .card-header h6 {
    margin: 0;
    font-weight: 600;
}

.contact-info-card .card-body {
    padding: 1.5rem;
}

/* 訂單操作按鈕 */
.order-actions {
    border-top: 1px solid #e9ecef;
    padding-top: 2rem;
}

.order-actions .btn {
    border-radius: 10px;
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.order-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

/* 載入提示樣式 */
.modal-content {
    border-radius: 15px;
    border: none;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.modal-body {
    text-align: center;
}

.spinner-border {
    width: 3rem;
    height: 3rem;
}

/* 響應式設計 */
@media (max-width: 768px) {
    .page-title {
        font-size: 2rem;
    }
    
    .lookup-form-container {
        padding: 2rem;
        margin: 1rem;
    }
    
    .verification-tabs {
        flex-direction: column;
        gap: 1rem;
    }
    
    .order-details-card .card-body,
    .qr-code-card .card-body {
        padding: 1.5rem;
    }
    
    .results-container {
        padding: 1.5rem;
        margin: 1rem;
    }
}

@media (max-width: 576px) {
    .page-header {
        padding-top: 5rem;
    }
    
    .lookup-form-container {
        padding: 1.5rem;
        margin: 0.5rem;
    }
    
    .icon-circle {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .form-header h3 {
        font-size: 1.5rem;
    }
    
    .lookup-form .form-control-lg {
        padding: 0.875rem 1rem;
        font-size: 1rem;
    }
}

/* 狀態指示器 */
.status-badge {
    display: inline-block !important;
    padding: 0.35rem 0.85rem !important;
    border-radius: 20px;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid transparent;
    white-space: nowrap;
    min-width: 80px;
    text-align: center;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 10;
    position: relative;
}

.status-badge.confirmed {
    background: #d4edda !important;
    color: #155724 !important;
    border-color: #c3e6cb;
}

.status-badge.pending {
    background: #fff3cd !important;
    color: #856404 !important;
    border-color: #ffeaa7;
}

.status-badge.cancelled {
    background: #f8d7da !important;
    color: #721c24 !important;
    border-color: #f5c6cb;
}

.status-badge.completed {
    background: #d1ecf1 !important;
    color: #0c5460 !important;
    border-color: #bee5eb;
}

/* 確保狀態在訂單資訊中正確顯示 */
.order-info-value .status-badge {
    margin-left: auto;
    float: right;
}

/* 付款狀態樣式 */
.payment-status-badge {
    display: inline-block !important;
    padding: 0.35rem 0.85rem !important;
    border-radius: 20px;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid transparent;
    white-space: nowrap;
    min-width: 80px;
    text-align: center;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 10;
    position: relative;
}

.payment-status-badge.payment-pending {
    background: #fff3cd !important;
    color: #856404 !important;
    border-color: #ffeaa7;
}

.payment-status-badge.payment-paid {
    background: #d4edda !important;
    color: #155724 !important;
    border-color: #c3e6cb;
}

.payment-status-badge.payment-refunded {
    background: #d1ecf1 !important;
    color: #0c5460 !important;
    border-color: #bee5eb;
}

.payment-status-badge.payment-failed {
    background: #f8d7da !important;
    color: #721c24 !important;
    border-color: #f5c6cb;
}

.payment-status-badge.payment-cancelled {
    background: #e2e3e5 !important;
    color: #383d41 !important;
    border-color: #d6d8db;
}

/* 訂單詳細資訊樣式 */
.order-info-row {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
}

.order-info-row:last-child {
    border-bottom: none;
}

.order-info-label {
    font-weight: 600;
    color: #333;
    min-width: 120px;
}

.order-info-value {
    color: #495057;
    text-align: right;
}

/* 遮罩樣式 */
.masked-text {
    background: linear-gradient(90deg, #f8f9fa 0%, #e9ecef 50%, #f8f9fa 100%);
    border-radius: 4px;
    padding: 0.25rem 0.5rem;
    font-family: monospace;
    letter-spacing: 1px;
}

/* 動畫效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

.pulse {
    animation: pulse 2s infinite;
}

/* 載入動畫 */
.loading-dots {
    display: inline-block;
}

.loading-dots:after {
    content: '';
    animation: loading-dots 1.5s infinite;
}

@keyframes loading-dots {
    0%, 20% {
        content: '';
    }
    40% {
        content: '.';
    }
    60% {
        content: '..';
    }
    80%, 100% {
        content: '...';
    }
}

/* 分享按鈕特殊樣式 */
.order-actions .btn-outline-success {
    border-color: #06c755;
    color: #06c755;
}

.order-actions .btn-outline-success:hover {
    background-color: #06c755;
    border-color: #06c755;
    color: white;
}

.order-actions .btn-outline-info {
    border-color: #4285f4;
    color: #4285f4;
}

.order-actions .btn-outline-info:hover {
    background-color: #4285f4;
    border-color: #4285f4;
    color: white;
}

/* 聯絡資訊項目樣式 */
.contact-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.contact-info-item:last-child {
    border-bottom: none;
}

.contact-label {
    font-weight: 500;
    color: #495057;
    font-size: 0.9rem;
}

.contact-value {
    font-weight: 600;
    color: #495057;
    font-family: monospace;
    letter-spacing: 1px;
}

/* 分享按鈕圖標動畫 */
.order-actions .btn .fab,
.order-actions .btn .fas {
    transition: transform 0.2s ease;
}

.order-actions .btn:hover .fab,
.order-actions .btn:hover .fas {
    transform: scale(1.1);
}

/* 新增：基本訂單資訊 */
.order-basic-info {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

/* 新增：預約項目區域 */
.reservation-items-section {
    margin-bottom: 2rem;
}

.section-title {
    color: #495057;
    font-weight: 600;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e9ecef;
}

.reservation-item-card {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.reservation-item-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e9ecef;
}

.item-title {
    color: #495057;
    font-weight: 600;
    margin: 0;
}

.item-price {
    color: #007bff;
    font-weight: bold;
    font-size: 1.1rem;
}

.item-details {
    margin-top: 1rem;
}

.detail-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.detail-label {
    font-weight: 500;
    color: #495057;
    margin-right: 0.5rem;
}

.detail-value {
    color: #495057;
}

/* 新增：費用明細區域 */
.price-breakdown-section {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1.5rem;
}

.price-breakdown {
    max-width: 400px;
    margin: 0 auto;
}

.price-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    font-size: 0.95rem;
}

.price-label {
    color: #495057;
}

.price-value {
    color: #495057;
    font-weight: 500;
}

.price-divider {
    height: 1px;
    background: #dee2e6;
    margin: 0.5rem 0;
}

.price-item.total {
    border-top: 2px solid #007bff;
    padding-top: 1rem;
    margin-top: 1rem;
    font-size: 1.1rem;
}

.price-item.total .price-label,
.price-item.total .price-value {
    color: #007bff;
}

/* 訂單查詢頁面特殊樣式覆蓋 - 統一滑動 */
#resultsSection .cart-summary-sidebar {
    position: static !important;
    max-height: none !important;
    overflow-y: visible !important;
    top: auto !important;
}

/* 確保整個結果區域可以統一滑動 */
#resultsSection {
    overflow: visible !important;
}

#resultsSection .container {
    overflow: visible !important;
}

#resultsSection .row {
    overflow: visible !important;
}

/* 移除任何可能造成獨立滑動的樣式 */
#resultsSection .cart-items-container {
    max-height: none !important;
    overflow: visible !important;
}

#resultsSection .summary-section {
    max-height: none !important;
    overflow: visible !important;
}

/* 響應式設計 */
@media (max-width: 768px) {
    .item-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .item-price {
        margin-top: 0.5rem;
    }
    
    .detail-item {
        margin-bottom: 0.75rem;
    }
    
    /* 手機版確保也是統一滑動 */
    #resultsSection .cart-summary-sidebar {
        position: static !important;
        max-height: none !important;
        overflow-y: visible !important;
    }
} 