/* ============================================================
   新途旅行 - 基础样式 (base.css)
   包含：设计令牌、Bootstrap覆盖、基础重置、导航、页脚、移动TabBar、通用工具
   ============================================================ */

/* ------ 设计令牌 (Design Tokens) ------ */
:root {
    --ota-primary: #f97316;
    --ota-primary-dark: #ea580c;
    --ota-primary-light: #ffedd5;
    --ota-primary-lighter: #fff7ed;
    --ota-accent: #f59e0b;
    --ota-accent-dark: #d97706;
    --ota-accent-light: #fef3c7;
    --ota-danger: #ef4444;
    --ota-success: #10b981;
    --ota-warning: #f59e0b;
    --ota-info: #3b82f6;
    --ota-dark: #0f172a;
    --ota-gray-900: #1e293b;
    --ota-gray-700: #334155;
    --ota-gray-500: #64748b;
    --ota-gray-400: #94a3b8;
    --ota-gray-300: #cbd5e1;
    --ota-gray-200: #e2e8f0;
    --ota-gray-100: #f1f5f9;
    --ota-gray-50: #f8fafc;
    --ota-white: #ffffff;
    --ota-font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
    --ota-radius-sm: 8px;
    --ota-radius-md: 12px;
    --ota-radius-lg: 16px;
    --ota-radius-full: 9999px;
    --ota-shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    --ota-shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --ota-shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
    --ota-shadow-hover: 0 12px 36px rgba(0,0,0,0.15);
    --ota-transition: all 0.3s ease;
    --ota-transition-fast: all 0.15s ease;
}

/* ------ Bootstrap Primary 色覆盖 ------ */
:root {
    --bs-primary: #f97316;
    --bs-primary-rgb: 249, 115, 22;
    --bs-link-color: #f97316;
    --bs-link-hover-color: #ea580c;
    --bs-link-color-rgb: 249, 115, 22;
    --bs-link-hover-color-rgb: 234, 88, 12;
}
.btn-primary { --bs-btn-bg: #f97316; --bs-btn-border-color: #f97316; --bs-btn-hover-bg: #ea580c; --bs-btn-hover-border-color: #ea580c; --bs-btn-active-bg: #c2410c; --bs-btn-active-border-color: #c2410c; --bs-btn-disabled-bg: #f97316; --bs-btn-disabled-border-color: #f97316; --bs-btn-focus-shadow-rgb: 249, 115, 22; }
.btn-outline-primary { --bs-btn-color: #f97316; --bs-btn-border-color: #f97316; --bs-btn-hover-bg: #f97316; --bs-btn-hover-border-color: #f97316; --bs-btn-active-bg: #f97316; --bs-btn-active-border-color: #f97316; --bs-btn-focus-shadow-rgb: 249, 115, 22; }
.bg-primary { background-color: #f97316 !important; }
.text-primary { color: #f97316 !important; }
.border-primary { border-color: #f97316 !important; }
.list-group-item.active { background-color: #f97316; border-color: #f97316; }
.nav-pills .nav-link.active { background-color: #f97316; }
.page-link.active, .active > .page-link { background-color: #f97316; border-color: #f97316; }
.form-check-input:checked { background-color: #f97316; border-color: #f97316; }
.form-control:focus, .form-select:focus { border-color: #f97316; box-shadow: 0 0 0 0.25rem rgba(249, 115, 22, 0.25); }

/* ------ 基础重置 ------ */
body { font-family: var(--ota-font-family); color: var(--ota-gray-700); line-height: 1.6; background: var(--ota-white); -webkit-font-smoothing: antialiased; }
a { color: var(--ota-primary); text-decoration: none; transition: var(--ota-transition-fast); }
a:hover { color: var(--ota-primary-dark); }
img { max-width: 100%; height: auto; }

/* ============================================================
   导航头部
   ============================================================ */
.ota-header { background: var(--ota-white); border-bottom: 1px solid var(--ota-gray-200); transition: box-shadow 0.3s ease; z-index: 1030; }
.ota-header--scrolled { box-shadow: var(--ota-shadow-md); border-bottom-color: transparent; }
.ota-logo { font-weight: 800; font-size: 1.375rem; color: #431407 !important; display: flex; align-items: center; gap: 0.625rem; }
.ota-logo .ota-logo-block { width: 36px; height: 36px; border-radius: 12px; background: linear-gradient(90deg, #F97316, #EA580C); display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 1.125rem; }
.ota-logo:hover { color: #431407 !important; }
.ota-nav-link { color: var(--ota-gray-700) !important; font-weight: 500; font-size: 0.95rem; padding: 0.5rem 0.85rem !important; border-radius: var(--ota-radius-sm); transition: var(--ota-transition-fast); position: relative; }
.ota-nav-link:hover { color: var(--ota-primary) !important; background: var(--ota-primary-lighter); }
.ota-nav-link.active { color: var(--ota-primary) !important; background: var(--ota-primary-light); font-weight: 600; }
.ota-header-search { position: relative; max-width: 280px; }
.ota-header-search .form-control { border-radius: var(--ota-radius-full); border: 1.5px solid var(--ota-gray-300); padding: 0.4rem 2.5rem 0.4rem 1rem; font-size: 0.875rem; background: var(--ota-gray-50); transition: var(--ota-transition); height: 38px; }
.ota-header-search .form-control:focus { border-color: var(--ota-primary); box-shadow: 0 0 0 3px rgba(249,115,22,0.1); background: var(--ota-white); }
.ota-header-search .btn-search { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); border: none; background: none; color: var(--ota-gray-500); padding: 0.25rem 0.5rem; cursor: pointer; }
.ota-header-search .btn-search:hover { color: var(--ota-primary); }
.ota-mobile-search { background: var(--ota-white); border-top: 1px solid var(--ota-gray-200); padding: 0.75rem 0; }
.ota-mobile-search .form-control { border-radius: var(--ota-radius-full); border: 1.5px solid var(--ota-gray-300); padding: 0.5rem 1rem; font-size: 0.9rem; }
.ota-mobile-search .btn { border-radius: var(--ota-radius-full); }
.ota-header-user .btn { font-size: 0.875rem; border-radius: var(--ota-radius-full); padding: 0.35rem 1rem; }

/* ============================================================
   信赖板块 & Footer
   ============================================================ */
.ota-trust-section { padding: 3.5rem 0; background: var(--ota-white); border-top: 1px solid var(--ota-gray-200); }
.ota-trust-item { text-align: center; padding: 1.5rem 1rem; }
.ota-trust-icon { width: 64px; height: 64px; border-radius: 50%; background: linear-gradient(135deg, #F97316, #EA580C); color: var(--ota-white); display: flex; align-items: center; justify-content: center; font-size: 1.6rem; margin: 0 auto 0.85rem; box-shadow: 0 4px 12px rgba(249,115,22,0.25); }
.ota-trust-title { font-size: 1.05rem; font-weight: 700; color: var(--ota-gray-900); margin-bottom: 0.35rem; }
.ota-trust-desc { font-size: 0.85rem; color: var(--ota-gray-500); line-height: 1.5; }
.ota-footer { background: #431407; color: rgba(255,255,255,0.7); padding: 3rem 0 0; }
.ota-footer a { color: #FBBF24; text-decoration: none; transition: var(--ota-transition-fast); }
.ota-footer a:hover { color: var(--ota-white); }
.ota-footer-brand { font-size: 1.25rem; font-weight: 800; color: var(--ota-white) !important; display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; }
.ota-footer-brand .ota-logo-block { width: 28px; height: 28px; border-radius: 8px; background: linear-gradient(90deg, #F97316, #EA580C); display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 0.875rem; }
.ota-footer-copy { font-size: 0.75rem; color: #FDBA74; }
.ota-footer h6 { color: var(--ota-white); font-weight: 600; font-size: 1rem; margin-bottom: 1rem; }
.ota-footer-links { list-style: none; padding: 0; margin: 0; }
.ota-footer-links li { margin-bottom: 0.55rem; }
.ota-footer-links li i { width: 18px; margin-right: 0.35rem; opacity: 0.7; }
.ota-footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); margin-top: 2.5rem; padding: 1.25rem 0; font-size: 0.85rem; }
footer { background: #431407; color: rgba(255,255,255,0.7); }
footer a { color: #FBBF24; text-decoration: none; }

/* ============================================================
   移动端 Tab Bar
   ============================================================ */
.ota-bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; z-index: 1040; display: flex; background: var(--ota-white); border-top: 1px solid var(--ota-gray-200); box-shadow: 0 -2px 10px rgba(0,0,0,0.06); padding: 0.4rem 0 env(safe-area-inset-bottom, 0.2rem); }
.ota-bottom-nav-item { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0.35rem 0; color: var(--ota-gray-500); text-decoration: none; font-size: 0.65rem; transition: var(--ota-transition-fast); gap: 0.15rem; }
.ota-bottom-nav-item i { font-size: 1.25rem; }
.ota-bottom-nav-item.active, .ota-bottom-nav-item:hover { color: var(--ota-primary); }
.ota-bottom-nav-item.active i { font-weight: 700; }
body { padding-bottom: 3.8rem; }
@media (min-width: 768px) { .ota-bottom-nav { display: none; } body { padding-bottom: 0; } }

/* 旧版兼容 */
.section-title { font-weight: 700; font-size: 1.5rem; margin-bottom: 1.5rem; padding-left: 12px; border-left: 4px solid var(--ota-primary); }
.category-nav .nav-link { color: var(--ota-gray-700); border-radius: 20px; padding: 0.4rem 1rem; margin: 0.2rem; transition: var(--ota-transition-fast); }
.category-nav .nav-link:hover, .category-nav .nav-link.active { background: var(--ota-primary); color: var(--ota-white); }
.pagination .page-link { border-radius: var(--ota-radius-sm); border: 1px solid var(--ota-gray-300); color: var(--ota-gray-700); margin: 0 2px; font-size: 0.9rem; transition: var(--ota-transition-fast); }
.pagination .page-link:hover { background: var(--ota-primary-light); color: var(--ota-primary); border-color: var(--ota-primary-light); }
.pagination .page-item.active .page-link { background: var(--ota-primary); border-color: var(--ota-primary); color: var(--ota-white); }

/* ============================================================
   响应式适配（通用部分）
   ============================================================ */
@media (max-width: 767.98px) {
    .ota-hero--gradient { min-height: auto; padding: 2.5rem 0; }
    .ota-hero-inner { flex-direction: column; gap: 2rem; }
    .ota-hero-text { flex: none; text-align: center; }
    .ota-hero-title { font-size: 1.75rem; }
    .ota-hero-subtitle { font-size: 0.875rem; }
    .ota-hero-right { width: 100%; }
    .ota-search-card { max-width: 100%; }
    .ota-search-input-row { flex-direction: column; height: auto; gap: 0; }
    .ota-dest-input { width: 100%; border-radius: 12px 12px 0 0; height: 44px; }
    .ota-date-input { height: 44px; }
    .ota-search-btn { width: 100%; border-radius: 0 0 12px 12px; height: 44px; }
    .ota-hero--carousel .carousel-item img { min-height: 280px; }
    .ota-search-bar { max-width: 100%; }
    .ota-search-bar input { padding: 0.75rem 1rem; font-size: 0.9rem; }
    .ota-search-bar button { padding: 0.6rem 1rem; font-size: 0.85rem; }
    .ota-section-header-left h2 { font-size: 1.25rem; }
    .ota-section-title { font-size: 1.25rem; }
    .ota-trust-section { padding: 2rem 0; }
    .ota-trust-icon { width: 52px; height: 52px; font-size: 1.3rem; }
    .ota-footer { padding: 2.5rem 0 0; }
}

@media (min-width: 768px) and (max-width: 991.98px) {
    .ota-hero-title { font-size: 2rem; }
}

/* ============================================================
   区块标题（通用）
   ============================================================ */
.ota-section-header { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 1.5rem; }
.ota-section-header-left h2 { font-weight: 800; font-size: 1.5rem; color: #431407; margin-bottom: 0.15rem; line-height: 1.3; }
.ota-section-header-left p { font-size: 0.875rem; color: var(--ota-gray-500); margin-bottom: 0; }
.ota-section-title { font-weight: 700; font-size: 1.5rem; color: var(--ota-gray-900); padding-left: 14px; border-left: 4px solid var(--ota-primary); margin-bottom: 0; line-height: 1.3; }
.ota-section-more { font-size: 0.875rem; color: var(--ota-primary); font-weight: 500; text-decoration: none; white-space: nowrap; }
.ota-section-more:hover { color: var(--ota-primary-dark); }

/* ============================================================
   通用徽章与按钮
   ============================================================ */
.ota-badge-primary { background: var(--ota-primary); font-weight: 500; }
.ota-badge-accent { background: var(--ota-accent); }
.ota-badge-info { background: var(--ota-info); font-weight: 500; }
.ota-btn-gradient { background: linear-gradient(90deg, #F97316, #EA580C); color: #fff; border: none; }
.ota-icon-large { font-size: 4rem; }
.ota-sticky-offset { top: 80px; }
