﻿/* ============================================
   拉萨供灯 · 藏式设计系统 v1.0
   Design: 藏红 + 金色 + 温暖奶油底
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #8B1A1A;
  --primary-dark: #6B1010;
  --primary-light: #A52A2A;
  --gold: #C9A84C;
  --gold-light: #E8D5A3;
  --gold-dark: #A88830;
  --bg: #FDF6EC;
  --bg-card: #FFFFFF;
  --text: #2C1810;
  --text-secondary: #7A6A5E;
  --text-light: #9E8E82;
  --border: #E8D5A3;
  --border-light: #F0E6D0;
  --cta: #C0392B;
  --cta-hover: #A93226;
  --success: #27AE60;
  --warning: #E67E22;
  --info: #2980B9;
  --font-heading: 'Noto Serif SC', 'Songti SC', 'SimSun', serif;
  --font-body: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 2px 12px rgba(139,26,26,0.08);
  --shadow-lg: 0 4px 24px rgba(139,26,26,0.12);
  --max-width: 480px;
  --safe-bottom: env(safe-area-inset-bottom, 16px);
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* --- Container --- */
.app-container {
  max-width: var(--max-width);
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  padding-bottom: 80px;
}

/* --- Header / Top Bar --- */
.top-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--primary);
  color: #fff;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.top-bar .back-btn {
  background: none;
  border: none;
  color: #fff;
  font-size: 22px;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  opacity: 0.9;
  transition: opacity 0.2s;
}
.top-bar .back-btn:hover { opacity: 1; }

.top-bar .page-title {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 1px;
}

.top-bar .page-subtitle {
  font-size: 12px;
  opacity: 0.8;
  margin-top: 1px;
}

/* --- Home Hero --- */
.home-hero {
  position: relative;
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
  padding: 40px 20px 48px;
  text-align: center;
  color: #fff;
  overflow: hidden;
}

.home-hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background:
    radial-gradient(circle at 30% 40%, rgba(201,168,76,0.15) 0%, transparent 50%),
    radial-gradient(circle at 70% 60%, rgba(255,255,255,0.05) 0%, transparent 40%);
  animation: heroGlow 8s ease-in-out infinite alternate;
}

@keyframes heroGlow {
  0% { transform: translate(0, 0); }
  100% { transform: translate(-5%, -5%); }
}

.home-hero .hero-icon {
  font-size: 48px;
  margin-bottom: 12px;
  position: relative;
  display: inline-block;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.2));
}

.home-hero h1 {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 2px;
  position: relative;
}

.home-hero p {
  font-size: 14px;
  opacity: 0.85;
  margin-top: 8px;
  line-height: 1.5;
  position: relative;
}

.home-hero .deco-line {
  width: 60px;
  height: 2px;
  background: var(--gold);
  margin: 16px auto;
  border-radius: 1px;
  position: relative;
}

.home-hero .trust-badges {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 20px;
  position: relative;
  flex-wrap: wrap;
}

.home-hero .trust-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  opacity: 0.9;
}

.home-hero .trust-badge .badge-icon {
  width: 18px;
  height: 18px;
  background: rgba(255,255,255,0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
}

/* --- Section Headers --- */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 16px 12px;
}

.section-header h2 {
  font-family: var(--font-heading);
  font-size: 18px;
  color: var(--text);
  font-weight: 600;
}

.section-header .more-link {
  font-size: 13px;
  color: var(--text-secondary);
  text-decoration: none;
}

/* --- Temple Cards --- */
.temple-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0 16px 24px;
}

.temple-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
  color: inherit;
  display: block;
}

.temple-card:active {
  transform: scale(0.98);
}

.temple-card .card-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

.temple-card .card-image-placeholder {
  width: 100%;
  height: 180px;
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  color: var(--gold);
}

.temple-card .card-body {
  padding: 14px 16px;
}

.temple-card .temple-name {
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}

.temple-card .temple-name .price-range {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--primary);
  font-weight: 500;
  margin-left: auto;
}

.temple-card .temple-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.temple-card .temple-items-preview {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.temple-card .item-tag {
  font-size: 11px;
  padding: 3px 10px;
  background: var(--border-light);
  border-radius: 20px;
  color: var(--text-secondary);
}

/* --- Temple Detail Page --- */
.temple-cover {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

.temple-cover-placeholder {
  width: 100%;
  height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
}

.temple-intro {
  padding: 16px;
  background: var(--bg-card);
  margin: 0 0 20px;
  border-radius: var(--radius);
  position: relative;
  box-shadow: var(--shadow);
}

.temple-intro h2 {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 600;
  color: var(--text);
}

.temple-intro .temple-location {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.temple-intro p {
  font-size: 14px;
  color: var(--text-secondary);
  margin-top: 8px;
  line-height: 1.7;
}

/* --- Offering Items --- */
.items-section {
  padding: 0 12px 80px;
}

.items-section .items-header {
  font-family: var(--font-heading);
  font-size: 16px;
  padding: 0 4px 14px;
  color: var(--text);
  font-weight: 600;
}

.offering-item {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
  border: 1px solid var(--border-light);
  display: block;
  text-decoration: none;
  color: inherit;
}

.offering-item:active {
  transform: scale(0.98);
}

.offering-item .item-header {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.offering-item .item-icon {
  font-size: 32px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

.offering-item .item-info {
  flex: 1;
  min-width: 0;
}

.offering-item .item-name {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.offering-item .item-name .badge {
  font-family: var(--font-body);
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 500;
  letter-spacing: 0.5px;
}

.badge-hot {
  background: #FDE8E0;
  color: #C0392B;
}

.badge-rec {
  background: #FEF3D0;
  color: #A88830;
}

.badge-full {
  background: #E8F5E9;
  color: #27AE60;
}

.offering-item .item-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.offering-item .item-price {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 700;
  color: var(--primary);
  margin-top: 6px;`r`n  }

.offering-item .item-price .price-unit {
  font-size: 13px;
  font-weight: 400;
}

.offering-item .item-price .price-note {
  font-size: 12px;
  font-weight: 400;
  color: var(--success);
  margin-left: 8px;
}

.offering-item .item-details {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.offering-item .item-detail-tag {
  font-size: 11px;
  padding: 3px 10px;
  background: var(--bg);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  color: var(--text-secondary);
}

.offering-item .item-arrow {
  color: var(--text-light);
  font-size: 18px;
  margin-top: 4px;
  flex-shrink: 0;
}

/* --- Order Form --- */
.order-form {
  padding: 16px;
}

.order-summary-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
  border: 1px solid var(--border-light);
}

.order-summary-card .os-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.order-summary-card .os-icon {
  font-size: 28px;
}

.order-summary-card .os-info h3 {
  font-size: 16px;
  font-weight: 600;
}

.order-summary-card .os-info p {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.order-summary-card .os-price {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary);
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-light);
}

.order-summary-card .os-price .os-price-unit {
  font-size: 14px;
  font-weight: 400;
}

/* --- Form Styles --- */
.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 6px;
}

.form-group label .required {
  color: var(--cta);
  margin-left: 2px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 14px;
  font-size: 15px;
  font-family: var(--font-body);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,168,76,0.15);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.form-group .hint {
  font-size: 12px;
  color: var(--text-light);
  margin-top: 4px;
}

/* --- Submit Button (Sticky Bottom) --- */
.sticky-bottom {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px 16px;
  padding-bottom: var(--safe-bottom);
  background: var(--bg-card);
  border-top: 1px solid var(--border-light);
  z-index: 50;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.05);
}

.sticky-bottom .inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.btn-primary {
  display: block;
  width: 100%;
  padding: 14px 24px;
  background: var(--cta);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  letter-spacing: 0.5px;
}

.btn-primary:active {
  transform: scale(0.98);
  background: var(--cta-hover);
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary.gold {
  background: var(--gold);
  color: var(--text);
}

.btn-secondary {
  display: block;
  width: 100%;
  padding: 12px 24px;
  background: var(--bg-card);
  color: var(--text);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
  text-align: center;
  text-decoration: none;
}

.btn-secondary:active {
  background: var(--border-light);
}

.btn-small {
  padding: 8px 16px;
  font-size: 13px;
  display: inline-block;
  width: auto;
}

/* --- Payment Page --- */
.payment-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 24px 16px;
  margin: 16px;
  box-shadow: var(--shadow);
  text-align: center;
  border: 1px solid var(--border-light);
}

.payment-card .pay-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.payment-card h3 {
  font-family: var(--font-heading);
  font-size: 18px;
  margin-bottom: 4px;
}

.payment-card .pay-amount {
  font-size: 36px;
  font-weight: 700;
  color: var(--primary);
  margin: 12px 0;
}

.payment-card .pay-amount .unit {
  font-size: 16px;
  font-weight: 400;
}

.payment-card .qr-placeholder {
  width: 200px;
  height: 200px;
  margin: 16px auto;
  background: var(--bg);
  border: 2px dashed var(--border);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 64px;
}

.payment-card .qr-placeholder .qr-hint {
  font-size: 12px;
  color: var(--text-light);
}

.payment-card .pay-instructions {
  text-align: left;
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-top: 16px;
}

.payment-card .pay-instructions li {
  font-size: 13px;
  color: var(--text-secondary);
  padding: 4px 0;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.payment-card .pay-instructions li::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--gold);
  border-radius: 50%;
  flex-shrink: 0;
}

.payment-card .order-id-display {
  font-size: 13px;
  color: var(--text-light);
  margin-top: 12px;
}

/* --- Status Page --- */
.status-page {
  padding: 16px;
}

.status-search {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 20px 16px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}

.status-search h3 {
  font-family: var(--font-heading);
  font-size: 16px;
  margin-bottom: 12px;
}

.status-result {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 20px 16px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
}

.status-result .sr-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.status-result .sr-header .order-num {
  font-size: 13px;
  color: var(--text-light);
}

.status-result .status-tag {
  font-size: 12px;
  padding: 3px 12px;
  border-radius: 20px;
  font-weight: 500;
}

.status-result .sr-detail {
  font-size: 14px;
  line-height: 1.8;
}

.status-result .sr-detail .sr-row {
  display: flex;
  padding: 4px 0;
  border-bottom: 1px solid var(--border-light);
}

.status-result .sr-detail .sr-row:last-child {
  border-bottom: none;
}

.status-result .sr-detail .sr-label {
  color: var(--text-secondary);
  width: 80px;
  flex-shrink: 0;
}

.status-result .sr-detail .sr-value {
  flex: 1;
  color: var(--text);
}

.status-result .sr-photos {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-light);
}

.status-result .sr-photos h4 {
  font-size: 14px;
  margin-bottom: 8px;
  color: var(--text);
}

.status-result .photo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.status-result .photo-grid img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

/* --- Admin Page --- */
.admin-login {
  padding: 40px 16px;
  max-width: 360px;
  margin: 0 auto;
}

.admin-login h2 {
  font-family: var(--font-heading);
  text-align: center;
  margin-bottom: 20px;
  color: var(--text);
}

.admin-dashboard {
  padding: 12px;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}

.admin-stat-card {
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  padding: 12px;
  text-align: center;
  box-shadow: var(--shadow);
}

.admin-stat-card .stat-number {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary);
}

.admin-stat-card .stat-label {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.admin-tabs {
  display: flex;
  gap: 4px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 4px;
  margin-bottom: 12px;
}

.admin-tab {
  flex: 1;
  padding: 8px;
  text-align: center;
  font-size: 13px;
  border: none;
  background: none;
  cursor: pointer;
  border-radius: 6px;
  color: var(--text-secondary);
  transition: all 0.2s;
}

.admin-tab.active {
  background: var(--bg-card);
  color: var(--primary);
  font-weight: 600;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.admin-order-card {
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  padding: 14px;
  margin-bottom: 8px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
}

.admin-order-card .aoc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.admin-order-card .aoc-id {
  font-size: 12px;
  color: var(--text-light);
}

.admin-order-card .aoc-info {
  font-size: 13px;
  line-height: 1.7;
}

.admin-order-card .aoc-info .aoc-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.admin-order-card .aoc-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border-light);
}

.admin-order-card .aoc-actions button {
  flex: 1;
  padding: 6px 12px;
  font-size: 12px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.admin-order-card .aoc-actions button:active {
  background: var(--border-light);
}

.admin-order-card .aoc-actions .btn-action-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.admin-order-card .aoc-actions .btn-action-success {
  background: var(--success);
  color: #fff;
  border-color: var(--success);
}

.admin-order-card .aoc-actions .btn-action-danger {
  background: var(--text-light);
  color: #fff;
  border-color: var(--text-light);
}

.empty-state {
  text-align: center;
  padding: 40px 16px;
  color: var(--text-light);
}

.empty-state .empty-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.empty-state p {
  font-size: 14px;
}

/* --- Bottom Navigation --- */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border-light);
  display: flex;
  padding: 6px 0;
  padding-bottom: var(--safe-bottom);
  z-index: 50;
}

.bottom-nav .nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 4px;
  text-decoration: none;
  color: var(--text-light);
  font-size: 11px;
  gap: 2px;
  transition: color 0.2s;
}

.bottom-nav .nav-item.active {
  color: var(--primary);
}

.bottom-nav .nav-item .nav-icon {
  font-size: 20px;
}

/* --- Toast / Notification --- */
.toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-100%);
  background: var(--text);
  color: #fff;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  z-index: 999;
  transition: transform 0.3s ease;
  max-width: calc(100% - 32px);
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.toast.show {
  transform: translateX(-50%) translateY(0);
}

.toast.success { background: var(--success); }
.toast.error { background: var(--cta); }

/* --- Loading --- */
.loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  color: var(--text-light);
  font-size: 14px;
}

.loading::after {
  content: '';
  width: 20px;
  height: 20px;
  border: 2px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-left: 8px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* --- Misc --- */
.text-center { text-align: center; }
.mt-8 { margin-top: 6px;`r`n  }
.mt-16 { margin-top: 16px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.gap-8 { gap: 8px; }
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }

.no-service-fee {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  padding: 2px 8px;
  background: #E8F5E9;
  color: #2E7D32;
  border-radius: 10px;
  font-weight: 500;
}

.divider {
  height: 1px;
  background: var(--border-light);
  margin: 16px 0;
}

/* --- Success Page (after order) --- */
.success-page {
  text-align: center;
  padding: 40px 16px;
}

.success-page .success-icon {
  font-size: 64px;
  margin-bottom: 16px;
}

.success-page h2 {
  font-family: var(--font-heading);
  font-size: 22px;
  color: var(--text);
  margin-bottom: 8px;
}

.success-page p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.success-page .order-ref {
  font-size: 13px;
  color: var(--text-light);
  margin-top: 16px;
  padding: 12px;
  background: var(--bg);
  border-radius: var(--radius-sm);
}

/* --- Responsive --- */
@media (min-width: 768px) {
  .temple-card .card-image {
    height: 240px;
  }

  .temple-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
}

/* --- Animations --- */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-in-up {
  animation: fadeInUp 0.4s ease forwards;
}

.fade-in-up:nth-child(2) { animation-delay: 0.05s; }
.fade-in-up:nth-child(3) { animation-delay: 0.1s; }
.fade-in-up:nth-child(4) { animation-delay: 0.15s; }
.fade-in-up:nth-child(5) { animation-delay: 0.2s; }
.fade-in-up:nth-child(6) { animation-delay: 0.25s; }

/* --- About / trust section --- */
.trust-section {
  padding: 0 16px 24px;
}

.trust-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 20px 16px;
  text-align: center;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
}

.trust-card h3 {
  font-family: var(--font-heading);
  font-size: 16px;
  color: var(--text);
  margin-bottom: 8px;
}

.trust-card .steps {
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-align: left;
  margin-top: 12px;
}

.trust-card .step {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.trust-card .step-number {
  width: 24px;
  height: 24px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  flex-shrink: 0;
}

.trust-card .step-text {
  font-size: 13px;
  color: var(--text-secondary);
  padding-top: 3px;
}

.trust-card .step-text strong {
  color: var(--text);
}

/* --- Page transition --- */
.page {
  display: none;
}
.page.active {
  display: block;
}

.temple-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 14px;
  padding-top: 13px;
  border-top: 1px solid var(--border-light);
}
.temple-highlights[hidden], .temple-culture-detail[hidden] { display: none; }
.temple-highlights span {
  padding: 4px 10px;
  color: var(--primary);
  border: 1px solid var(--gold-light);
  border-radius: 2px;
  background: #fbf4e6;
  font-size: 11px;
}
.temple-culture-detail {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-top: 14px;
}
.temple-culture-detail > div {
  padding: 12px 14px;
  border-left: 3px solid var(--gold);
  background: #f9f1e2;
}
.temple-culture-detail span {
  color: var(--gold-dark);
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
}
.temple-culture-detail p { margin-top: 5px; font-size: 12px; line-height: 1.8; }

/* ============================================
   供奉项目图片统一
   ============================================ */
.offering-item .item-header { align-items: stretch; }
.offering-item .item-media {
  width: 112px;
  min-height: 136px;
  flex: 0 0 112px;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(169,123,54,.2);
  border-radius: 9px;
  background: #e8dcc4;
}
.offering-item .item-media img {
  width: 100%;
  height: 100%;
  min-height: 136px;
  display: block;
  object-fit: cover;
  object-position: center;
  filter: saturate(.9) contrast(.96);
  transition: transform .35s ease;
}
.offering-item:hover .item-media img { transform: scale(1.04); }
.offering-item .item-media-symbol {
  position: absolute;
  left: 8px;
  bottom: 8px;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(250,243,224,.92);
  color: #8f2c20;
  font-size: 16px;
  box-shadow: 0 2px 8px rgba(48,30,15,.2);
}

@media (max-width: 420px) {
  .offering-item { padding: 12px; }
  .offering-item .item-header { gap: 10px; }
  .offering-item .item-media { width: 92px; flex-basis: 92px; min-height: 128px; }
  .offering-item .item-media img { min-height: 128px; }
  .offering-item .item-details { gap: 5px; }
  .offering-item .item-detail-tag { padding: 2px 7px; }
}

/* ============================================
   云上拉萨 · 文化视觉首页
   ============================================ */
.cultural-home {
  --ink: #34241a;
  --paper: #f7f0df;
  --paper-deep: #eadcbb;
  --vermilion: #9f2d1f;
  --bronze: #a97b36;
  background: #d9cfb8;
  color: var(--ink);
}

.cultural-home::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .17;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180' viewBox='0 0 180 180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.24'/%3E%3C/svg%3E");
}

.cultural-shell { max-width: 1180px; background: var(--paper); box-shadow: 0 0 50px rgba(54,35,17,.16); padding-bottom: 0; }
.cultural-nav { height: 84px; padding: 0 5%; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(169,123,54,.28); background: rgba(247,240,223,.94); }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand-mark { width: 42px; height: 50px; display: grid; place-items: center; border: 1px solid var(--bronze); border-radius: 45% 45% 12px 12px; color: var(--vermilion); font-size: 26px; position: relative; }
.brand-mark::after { content: ''; width: 12px; height: 8px; border-bottom: 2px solid var(--bronze); position: absolute; bottom: -8px; }
.brand strong { display: block; font-family: var(--font-heading); font-size: 22px; letter-spacing: 3px; }
.brand small { display: block; color: #89745d; font-size: 10px; letter-spacing: 2px; margin-top: 2px; }
.record-link { color: var(--ink); text-decoration: none; font-size: 13px; border: 1px solid #b99b6c; border-radius: 20px; padding: 8px 15px; }

.cultural-hero { min-height: 520px; position: relative; display: flex; align-items: center; overflow: hidden; padding: 70px 8%; background: linear-gradient(90deg, rgba(250,244,229,.98) 0%, rgba(248,240,220,.89) 42%, rgba(246,235,211,.15) 72%), url('../images/butter-lamp.jpg') 85% center/cover no-repeat; }
.cultural-hero::before { content: '༄༅། །བཀྲ་ཤིས།'; position: absolute; top: 30px; right: 5%; color: rgba(127,82,34,.22); letter-spacing: 8px; font-size: 18px; }
.hero-copy { position: relative; z-index: 2; max-width: 520px; }
.eyebrow { color: var(--bronze); text-transform: uppercase; font-size: 12px; letter-spacing: 3px; }
.hero-copy h1 { font-family: var(--font-heading); font-weight: 600; font-size: clamp(42px, 6vw, 72px); line-height: 1.2; letter-spacing: 6px; margin: 18px 0; }
.hero-copy h1 em { color: var(--vermilion); font-style: normal; }
.hero-copy p { color: #75624e; line-height: 2; font-family: var(--font-heading); font-size: 15px; }
.hero-cta { margin-top: 28px; display: inline-flex; gap: 28px; align-items: center; color: #fff; background: linear-gradient(135deg, #b43b28, #8e241a); padding: 14px 24px; border-radius: 3px; text-decoration: none; box-shadow: 0 8px 25px rgba(132,37,25,.22); }
.hero-seal { position: absolute; right: 5%; top: 28%; z-index: 2; background: rgba(248,233,198,.9); border: 1px solid #bd8c45; color: #70482a; padding: 24px 13px; line-height: 1.65; font-family: var(--font-heading); box-shadow: 5px 7px 20px rgba(75,46,14,.16); transform: rotate(3deg); }
.mountain-line { position: absolute; left: 0; right: 0; bottom: -1px; height: 100px; opacity: .55; background: linear-gradient(145deg, transparent 53%, #d8c396 54% 57%, transparent 58%) 0 0/180px 100%, linear-gradient(215deg, transparent 55%, #bda475 56% 58%, transparent 59%) 80px 0/220px 100%; }

.culture-strip { display: grid; grid-template-columns: repeat(3, 1fr); margin: -1px 5% 0; border: 1px solid #d9c79f; background: rgba(255,252,242,.83); position: relative; z-index: 3; }
.culture-strip > div { min-height: 94px; display: grid; grid-template-columns: 40px auto; align-content: center; padding: 18px 28px; border-right: 1px solid #e0cfaa; }
.culture-strip > div:last-child { border-right: 0; }
.culture-strip span { grid-row: 1/3; color: var(--bronze); font-size: 24px; align-self: center; }
.culture-strip strong { font-family: var(--font-heading); font-size: 15px; letter-spacing: 1px; }
.culture-strip small { color: #998570; font-size: 11px; margin-top: 2px; }

.temple-section, .ritual-section { padding: 72px 5%; }
.cultural-heading { display: flex; justify-content: space-between; align-items: end; margin-bottom: 28px; }
.cultural-heading span { color: var(--bronze); font-size: 11px; letter-spacing: 4px; }
.cultural-heading h2 { font-family: var(--font-heading); font-size: 28px; font-weight: 600; letter-spacing: 3px; margin-top: 6px; }
.cultural-heading p { color: #9a846b; font-size: 12px; }
.cultural-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; padding: 0; }
.cultural-card { border: 1px solid #dbc9a3; border-radius: 2px; background: rgba(255,252,244,.8); box-shadow: none; }
.cultural-card { display: flex; flex-direction: column; height: 100%; }
.cultural-card .card-visual {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  position: relative;
  overflow: hidden;
  flex: 0 0 auto;
  background: #dfd1b4;
}
.cultural-card .card-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  display: block;
  object-fit: cover;
  object-position: 50% 50%;
  filter: saturate(.82) contrast(.96);
  transition: transform .5s ease;
}
.cultural-card .card-visual-jokhang { aspect-ratio: 1 / 1; }
.cultural-card .card-visual-jokhang .card-image { object-position: 50% 0%; }
.cultural-card .card-visual-potala { aspect-ratio: 1 / 1; }
.cultural-card .card-visual-potala .card-image { object-position: 50% 18%; }
.cultural-card .card-visual-zhaksi .card-image { object-position: 50% 51%; }
.cultural-card .card-visual-general .card-image { object-position: 50% 45%; }
.cultural-card:hover .card-image { transform: scale(1.035); }
.card-number, .card-place { position: absolute; color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,.5); }
.card-number { top: 14px; left: 16px; font-family: Georgia, serif; font-size: 14px; border-bottom: 1px solid #fff; }
.card-place { bottom: 12px; left: 16px; font-size: 10px; letter-spacing: 2px; }
.cultural-card .card-body { padding: 18px 20px; display: flex; flex: 1; flex-direction: column; }
.cultural-card .temple-name { font-size: 20px; letter-spacing: 2px; }
.cultural-card .temple-subtitle { min-height: 42px; line-height: 1.7; }
.cultural-card .price-range { color: var(--vermilion); }
.card-action { border-top: 1px solid #e5d8bc; margin-top: auto; padding-top: 12px; color: #8d704d; font-size: 12px; display: flex; justify-content: space-between; }

.popular-section, .culture-library, .faq-section { padding: 0 5% 72px; }
.offering-showcase { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.offering-showcase a { min-height: 282px; display: flex; flex-direction: column; overflow: hidden; text-decoration: none; color: var(--ink); border: 1px solid #dbc9a3; background: rgba(255,252,244,.72); transition: transform .25s, background .25s; }
.offering-showcase a:hover { transform: translateY(-4px); background: #fffaf0; }
.offering-showcase img { width: 100%; height: 145px; display: block; object-fit: cover; object-position: center; filter: saturate(.88) contrast(.96); }
.offering-showcase a > div { padding: 17px 18px; display: flex; flex: 1; flex-direction: column; }
.offering-showcase b { font-family: var(--font-heading); font-size: 17px; letter-spacing: 2px; }
.offering-showcase small { color: #9a846b; font-size: 11px; line-height: 1.6; margin: 7px 0 18px; }
.offering-showcase em { margin-top: auto; color: var(--vermilion); font-size: 13px; font-style: normal; border-top: 1px solid #e4d5b6; padding-top: 12px; }

.prayer-banner { min-height: 320px; margin: 0 5%; display: flex; align-items: center; justify-content: flex-end; padding: 48px 7%; color: #fff; background: linear-gradient(90deg, rgba(33,29,22,.12), rgba(33,25,15,.78)), url('../images/jingfan.jpg') center 45%/cover; position: relative; overflow: hidden; }
.prayer-banner::before { content: '༄  ༄  ༄'; position: absolute; top: 18px; left: 5%; font-size: 36px; color: rgba(255,255,255,.55); letter-spacing: 20px; }
.prayer-copy { width: min(430px, 56%); }
.prayer-copy h2 { font-family: var(--font-heading); font-size: 28px; letter-spacing: 3px; margin: 12px 0; }
.prayer-copy p { font-size: 13px; line-height: 1.9; opacity: .83; }
.prayer-copy a { display: inline-block; color: #f4d798; margin-top: 18px; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 4px; }

.ritual-section { padding-top: 70px; }
.ritual-steps { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid #dbc9a3; background: rgba(255,252,244,.55); }
.ritual-steps > div { padding: 28px 20px; display: flex; gap: 16px; align-items: center; border-right: 1px solid #dfcfaf; }
.ritual-steps > div:last-child { border: 0; }
.ritual-steps b { color: var(--vermilion); font-family: var(--font-heading); font-size: 20px; font-weight: 500; }
.ritual-steps span { font-family: var(--font-heading); font-size: 15px; }
.ritual-steps small { display: block; color: #9a846b; font-family: var(--font-body); font-size: 10px; margin-top: 4px; }

.culture-note { margin: 0 5% 72px; padding: 38px 7%; display: flex; align-items: center; gap: 38px; background: #e9ddc1; border: 1px solid #d4c096; }
.note-symbol { color: var(--bronze); font-size: 58px; }
.culture-note span { color: var(--vermilion); font-size: 11px; letter-spacing: 4px; }
.culture-note h2 { font-family: var(--font-heading); font-size: 22px; margin: 5px 0; }
.culture-note p { color: #806d57; font-size: 12px; line-height: 1.8; }
.culture-articles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.culture-articles article { min-height: 210px; padding: 26px; display: flex; gap: 18px; border-top: 2px solid var(--bronze); background: rgba(235,223,194,.55); }
.culture-articles article > span { flex: 0 0 42px; height: 42px; display: grid; place-items: center; border: 1px solid #b5945b; color: var(--vermilion); font-family: var(--font-heading); font-size: 20px; }
.culture-articles small, .proof-copy > span { color: var(--bronze); letter-spacing: 2px; font-size: 10px; }
.culture-articles h3 { font-family: var(--font-heading); font-size: 17px; line-height: 1.5; margin: 8px 0; }
.culture-articles p { color: #85725c; font-size: 12px; line-height: 1.8; }

.service-proof { margin: 0 5% 72px; padding: 48px 5%; color: #f8eed8; display: grid; grid-template-columns: .9fr 1.1fr; gap: 8%; background: #382a21; position: relative; overflow: hidden; }
.service-proof::after { content: '☸'; position: absolute; right: -35px; bottom: -70px; color: rgba(224,192,126,.08); font-size: 230px; }
.proof-copy h2 { font-family: var(--font-heading); font-size: 28px; letter-spacing: 3px; margin: 9px 0 14px; }
.proof-copy p { color: #cbbda7; font-size: 12px; line-height: 2; }
.proof-list { position: relative; z-index: 1; }
.proof-list > div { display: flex; gap: 18px; padding: 15px 0; border-bottom: 1px solid rgba(225,204,163,.2); }
.proof-list b { color: #d8b56e; font-family: Georgia, serif; font-size: 12px; }
.proof-list span { font-family: var(--font-heading); font-size: 15px; }
.proof-list small { display: block; color: #a99b87; font-family: var(--font-body); font-size: 10px; margin-top: 4px; }
.faq-list { border-top: 1px solid #d6c39d; }
.faq-list details { border-bottom: 1px solid #d6c39d; padding: 0 8px; }
.faq-list summary { cursor: pointer; list-style: none; padding: 20px 0; font-family: var(--font-heading); font-size: 15px; display: flex; justify-content: space-between; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary span { color: var(--bronze); font-family: var(--font-body); font-size: 20px; }
.faq-list details[open] summary span { transform: rotate(45deg); }
.faq-list details p { color: #806d57; font-size: 12px; line-height: 1.9; padding: 0 0 20px; max-width: 760px; }
.cultural-footer { padding: 35px 5%; display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 34px; border-top: 1px solid #d7c5a0; color: #8d7a65; font-size: 11px; }
.cultural-footer a { color: var(--vermilion); text-decoration: none; }
.footer-brand .brand-mark { width: 32px; height: 38px; font-size: 20px; }
.footer-brand strong { font-size: 16px; }
.cultural-bottom-nav { display: none; }

@media (max-width: 700px) {
  .cultural-shell { width: 100%; padding-bottom: 72px; }
  .cultural-nav { height: 70px; padding: 0 18px; }
  .brand strong { font-size: 18px; }
  .record-link { font-size: 11px; padding: 6px 10px; }
  .cultural-hero { min-height: 500px; align-items: flex-start; padding: 68px 26px; background: linear-gradient(180deg, rgba(250,244,229,.97) 0%, rgba(248,240,220,.82) 58%, rgba(62,34,18,.15) 100%), url('../images/butter-lamp.jpg') 63% bottom/cover; }
  .hero-copy h1 { font-size: 42px; }
  .hero-copy p { font-size: 13px; }
  .hero-seal { top: auto; right: 24px; bottom: 45px; }
  .culture-strip { margin: 0; grid-template-columns: 1fr; border-left: 0; border-right: 0; }
  .culture-strip > div { min-height: 76px; border-right: 0; border-bottom: 1px solid #e0cfaa; padding: 12px 26px; }
  .temple-section, .ritual-section { padding: 55px 18px; }
  .cultural-heading { align-items: start; }
  .cultural-heading h2 { font-size: 23px; }
  .cultural-heading p { display: none; }
  .cultural-grid { grid-template-columns: 1fr; }
  .popular-section, .culture-library, .faq-section { padding: 0 18px 55px; }
  .offering-showcase { grid-template-columns: 1fr 1fr; }
  .offering-showcase a { min-height: 250px; }
  .offering-showcase img { height: 120px; }
  .offering-showcase a > div { padding: 14px 12px; }
  .cultural-card .card-visual { height: auto; aspect-ratio: 16 / 9; }
  .cultural-card .card-visual-jokhang { aspect-ratio: 1 / 1; }
  .cultural-card .card-visual-potala { aspect-ratio: 1 / 1; }
  .prayer-banner { margin: 0; min-height: 380px; padding: 40px 26px; justify-content: flex-start; align-items: flex-end; }
  .prayer-copy { width: 100%; }
  .ritual-steps { grid-template-columns: 1fr 1fr; }
  .ritual-steps > div { border-bottom: 1px solid #dfcfaf; padding: 20px 15px; }
  .culture-note { margin: 0 18px 55px; padding: 28px 24px; align-items: flex-start; gap: 18px; }
  .culture-articles { grid-template-columns: 1fr; }
  .culture-articles article { min-height: 0; }
  .service-proof { margin: 0 18px 55px; padding: 34px 25px; grid-template-columns: 1fr; gap: 22px; }
  .note-symbol { font-size: 38px; }
  .cultural-footer { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; padding: 30px 20px; }
  .cultural-bottom-nav { display: flex; max-width: 100%; background: rgba(250,246,235,.96); }
}


/* ============================================
