/* ==========================================================================
   VIC TOURING CLUB - Mobile-First Modern Stylesheet
   Designed for smartphone viewing with high contrast, touch ergonomics,
   and premium motorcycle club aesthetic.
   ========================================================================== */

:root {
  --bg-primary: #0b0f19;
  --bg-secondary: #131b2e;
  --bg-tertiary: #1e293b;
  --bg-card: rgba(26, 34, 52, 0.85);
  --bg-card-hover: rgba(36, 48, 74, 0.95);
  --border-color: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(245, 158, 11, 0.35);

  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --text-inverse: #0b0f19;

  --accent-amber: #f59e0b;
  --accent-orange: #f97316;
  --accent-gradient: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
  --accent-blue: #38bdf8;
  --accent-emerald: #10b981;
  --accent-rose: #f43f5e;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 16px 36px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 20px rgba(245, 158, 11, 0.25);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --bottom-nav-height: 68px;
}

[data-theme="light"] {
  --bg-primary: #f8fafc;
  --bg-secondary: #f1f5f9;
  --bg-tertiary: #e2e8f0;
  --bg-card: #ffffff;
  --bg-card-hover: #f8fafc;
  --border-color: rgba(0, 0, 0, 0.08);
  --border-highlight: rgba(217, 119, 6, 0.4);

  --text-main: #0f172a;
  --text-muted: #475569;
  --text-dim: #64748b;
  --text-inverse: #ffffff;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 8px 20px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 16px 32px rgba(0, 0, 0, 0.12);
  --shadow-glow: 0 0 20px rgba(245, 158, 11, 0.2);
}

/* Base resets & box-sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  padding-bottom: calc(var(--bottom-nav-height) + 24px);
  -webkit-font-smoothing: antialiased;
}

/* Container */
.app-container {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 16px;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(11, 15, 25, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-color);
  padding: 12px 16px;
  transition: all 0.3s ease;
}

[data-theme="light"] .app-header {
  background-color: rgba(248, 250, 252, 0.92);
}

.header-content {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-main);
}

.brand-plate-box {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-plate-img {
  height: 38px;
  width: auto;
  max-width: 68px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(245, 158, 11, 0.4);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
  object-fit: contain;
  background: #000000;
  transition: transform 0.2s ease;
}

.header-brand:hover .brand-plate-img {
  transform: scale(1.05);
}

.brand-icon-box {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-glow);
  font-size: 1.35rem;
}

.brand-title-group {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: linear-gradient(135deg, #ffffff 40%, var(--accent-amber) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  white-space: nowrap;
}

[data-theme="light"] .brand-title {
  background: linear-gradient(135deg, #0f172a 40%, var(--accent-orange) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--accent-amber);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-color);
  background: var(--bg-tertiary);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-icon:hover {
  background: var(--bg-card-hover);
  color: var(--text-main);
  border-color: var(--border-highlight);
}

/* --------------------------------------------------------------------------
   Hero & Highlights
   -------------------------------------------------------------------------- */
.hero-banner {
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.12) 0%, transparent 100%),
              radial-gradient(circle at top right, rgba(234, 88, 12, 0.15), transparent 70%);
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin: 16px 0 20px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.hero-badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  letter-spacing: 0.02em;
}

.badge-amber {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-blue {
  background: rgba(56, 189, 248, 0.18);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.35);
}

.badge-emerald {
  background: rgba(16, 185, 129, 0.18);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.35);
}

.badge-purple {
  background: rgba(168, 85, 247, 0.18);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.35);
}

.hero-title {
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 8px;
}

.hero-subtitle {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.5;
}

.hero-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.stat-box {
  background: rgba(0, 0, 0, 0.25);
  border-radius: var(--radius-sm);
  padding: 10px;
  text-align: center;
  border: 1px solid var(--border-color);
}

[data-theme="light"] .stat-box {
  background: rgba(255, 255, 255, 0.6);
}

.stat-label {
  font-size: 0.7rem;
  color: var(--text-dim);
  font-weight: 600;
  margin-bottom: 2px;
  display: block;
}

.stat-value {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-main);
}

.stat-value.highlight {
  color: var(--accent-amber);
}

/* --------------------------------------------------------------------------
   Tab Navigation & Content Panels
   -------------------------------------------------------------------------- */
.tab-content-panel {
  display: none;
  animation: fadeIn 0.25s ease forwards;
}

.tab-content-panel.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* --------------------------------------------------------------------------
   Search & Filter Bar
   -------------------------------------------------------------------------- */
.search-filter-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 18px;
  box-shadow: var(--shadow-sm);
}

.search-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.search-input-wrap .search-icon {
  position: absolute;
  left: 12px;
  color: var(--text-dim);
  font-size: 1.05rem;
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 10px 12px 10px 38px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-tertiary);
  color: var(--text-main);
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--accent-amber);
  background: var(--bg-secondary);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.filter-pills-row {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.filter-pills-row::-webkit-scrollbar {
  display: none;
}

.filter-pill {
  white-space: nowrap;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--bg-tertiary);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-pill:hover,
.filter-pill.active {
  background: var(--accent-gradient);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 2px 10px rgba(245, 158, 11, 0.3);
}

/* --------------------------------------------------------------------------
   Touring Cards & Feed
   -------------------------------------------------------------------------- */
.section-header-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-color);
}

.section-header-title h2 {
  font-size: 1.15rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-count-badge {
  font-size: 0.78rem;
  background: var(--bg-tertiary);
  color: var(--accent-amber);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-weight: 700;
}

.touring-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: all 0.25s ease;
}

.touring-card:hover {
  border-color: var(--border-highlight);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.touring-card.featured {
  border: 1px solid rgba(245, 158, 11, 0.45);
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.05) 0%, var(--bg-card) 60px);
}

.card-header-bar {
  padding: 14px 16px 10px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.card-date-badge {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--accent-amber);
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 4px;
}

.touring-card-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.35;
}

.card-amount-box {
  text-align: right;
  flex-shrink: 0;
}

.amount-label {
  font-size: 0.68rem;
  color: var(--text-dim);
  display: block;
}

.amount-price {
  font-size: 1.15rem;
  font-weight: 800;
  color: #fbbf24;
}

.card-body-info {
  padding: 0 16px 12px;
}

.info-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--text-muted);
  margin-bottom: 6px;
  line-height: 1.4;
}

.info-row .info-icon {
  color: var(--accent-amber);
  font-size: 0.95rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.info-row strong {
  color: var(--text-main);
}

.observer-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  color: #c084fc;
  background: rgba(168, 85, 247, 0.15);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-top: 4px;
}

.memo-box {
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-top: 8px;
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
  border-left: 3px solid var(--accent-amber);
}

.memo-box pre, .memo-box p {
  white-space: pre-wrap;
  word-break: break-word;
}

/* Card Action / Expand button */
.card-toggle-btn {
  width: 100%;
  padding: 10px 16px;
  border: none;
  border-top: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.card-toggle-btn:hover {
  background: rgba(245, 158, 11, 0.08);
  color: var(--accent-amber);
}

.card-toggle-btn .arrow-icon {
  transition: transform 0.25s ease;
}

.card-toggle-btn.expanded .arrow-icon {
  transform: rotate(180deg);
}

/* Expandable Details Container */
.card-expanded-details {
  display: none;
  padding: 14px 16px;
  background: rgba(0, 0, 0, 0.18);
  border-top: 1px dashed var(--border-color);
}

[data-theme="light"] .card-expanded-details {
  background: rgba(0, 0, 0, 0.02);
}

.card-expanded-details.open {
  display: block;
  animation: fadeIn 0.2s ease;
}

/* --------------------------------------------------------------------------
   Responsive Table Styling
   -------------------------------------------------------------------------- */
.table-responsive-wrapper {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 8px 0;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
}

.vic-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  text-align: left;
  white-space: nowrap;
}

.vic-table th {
  background: var(--bg-tertiary);
  color: var(--text-muted);
  font-weight: 700;
  padding: 8px 10px;
  border-bottom: 1px solid var(--border-color);
}

.vic-table td {
  padding: 8px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  color: var(--text-main);
}

[data-theme="light"] .vic-table td {
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.vic-table tr:last-child td {
  border-bottom: none;
}

.vic-table tr.total-row {
  background: rgba(245, 158, 11, 0.08);
  font-weight: 800;
}

.vic-table tr.total-row td {
  color: var(--accent-amber);
  border-top: 1px solid var(--border-highlight);
}

.text-right { text-align: right; }
.text-center { text-align: center; }

/* --------------------------------------------------------------------------
   Accounting & Fee Dashboard
   -------------------------------------------------------------------------- */
.year-selector-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 6px 0 14px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.year-selector-scroll::-webkit-scrollbar {
  display: none;
}

.year-btn {
  white-space: nowrap;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.year-btn.active {
  background: var(--accent-gradient);
  color: #ffffff;
  border-color: transparent;
  box-shadow: var(--shadow-glow);
}

.accounting-summary-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

@media (min-width: 600px) {
  .accounting-summary-cards {
    grid-template-columns: repeat(4, 1fr);
  }
}

.acc-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px;
  text-align: center;
}

.acc-card .card-title {
  font-size: 0.72rem;
  color: var(--text-dim);
  font-weight: 700;
  margin-bottom: 4px;
}

.acc-card .card-val {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
}

.acc-card.highlight {
  border-color: var(--border-highlight);
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.08) 0%, var(--bg-card) 100%);
}

.acc-card.highlight .card-val {
  color: var(--accent-amber);
}

/* --------------------------------------------------------------------------
   Members Grid
   -------------------------------------------------------------------------- */
.members-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 550px) {
  .members-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.member-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
  box-shadow: var(--shadow-sm);
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.member-avatar {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-full);
  background: var(--bg-tertiary);
  border: 2px solid var(--accent-amber);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.member-meta {
  flex: 1;
}

.member-name {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
}

.member-status-pill {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
}

.member-bike {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-amber);
  margin: 3px 0;
}

.member-desc {
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* --------------------------------------------------------------------------
   Timeline / History View
   -------------------------------------------------------------------------- */
.timeline-wrap {
  position: relative;
  padding-left: 24px;
  margin-top: 16px;
}

.timeline-wrap::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent-amber) 0%, var(--accent-orange) 50%, var(--border-color) 100%);
}

.timeline-item {
  position: relative;
  margin-bottom: 20px;
}

.timeline-dot {
  position: absolute;
  left: -24px;
  top: 4px;
  width: 14px;
  height: 14px;
  border-radius: var(--radius-full);
  background: var(--accent-amber);
  border: 3px solid var(--bg-primary);
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.6);
}

.timeline-content-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px 14px;
}

.timeline-year {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--accent-amber);
  margin-bottom: 2px;
}

.timeline-title {
  font-size: 0.98rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 4px;
}

.timeline-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* --------------------------------------------------------------------------
   Bottom Navigation Bar (Smartphone First)
   -------------------------------------------------------------------------- */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-nav-height);
  background: rgba(11, 15, 25, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-around;
  z-index: 999;
  padding-bottom: env(safe-area-inset-bottom);
}

[data-theme="light"] .bottom-nav {
  background: rgba(255, 255, 255, 0.94);
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  text-decoration: none;
  background: none;
  border: none;
  padding: 6px 10px;
  font-family: inherit;
  font-size: 0.68rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  flex: 1;
}

.nav-item .nav-icon {
  font-size: 1.35rem;
  margin-bottom: 2px;
  transition: transform 0.2s ease;
}

.nav-item.active {
  color: var(--accent-amber);
}

.nav-item.active .nav-icon {
  transform: translateY(-2px);
  filter: drop-shadow(0 2px 6px rgba(245, 158, 11, 0.4));
}

/* --------------------------------------------------------------------------
   Modal Window (Quick Detail Inspector)
   -------------------------------------------------------------------------- */
.vic-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);
  z-index: 1000;
  display: none;
  align-items: flex-end;
  justify-content: center;
}

@media (min-width: 600px) {
  .vic-modal-backdrop {
    align-items: center;
    padding: 20px;
  }
}

.vic-modal-backdrop.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.vic-modal-box {
  background: var(--bg-secondary);
  width: 100%;
  max-width: 640px;
  max-height: 85vh;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  overflow-y: auto;
  padding: 20px;
  position: relative;
}

@media (min-width: 600px) {
  .vic-modal-box {
    border-radius: var(--radius-lg);
    max-height: 80vh;
  }
}

.modal-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  width: 34px;
  height: 34px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   Print & Accessibility
   -------------------------------------------------------------------------- */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
    padding-bottom: 0 !important;
  }
  .app-header, .bottom-nav, .filter-pills-row, .search-filter-card {
    display: none !important;
  }
  .tab-content-panel {
    display: block !important;
  }
  .touring-card, .timeline-content-card, .acc-card {
    border: 1px solid #ccc !important;
    box-shadow: none !important;
    break-inside: avoid;
  }
}

/* --------------------------------------------------------------------------
   Next Touring Announcement Banner & Schedule Timeline Styles
   -------------------------------------------------------------------------- */
.next-touring-banner {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.22) 0%, rgba(234, 88, 12, 0.15) 100%);
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 20px;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.2);
  position: relative;
  overflow: hidden;
}

.next-touring-banner::after {
  content: '';
  position: absolute;
  top: -24px;
  right: -24px;
  width: 96px;
  height: 96px;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.3) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.btn-popup-open {
  width: 100%;
  background: var(--accent-gradient);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-size: 0.9rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.35);
  transition: all 0.2s ease;
  font-family: inherit;
}

.btn-popup-open:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(245, 158, 11, 0.5);
}

.schedule-step-list {
  position: relative;
  padding-left: 20px;
  margin: 16px 0;
}

.schedule-step-list::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent-amber) 0%, var(--accent-orange) 60%, var(--border-color) 100%);
}

.schedule-step {
  position: relative;
  margin-bottom: 18px;
}

.schedule-step-dot {
  position: absolute;
  left: -20px;
  top: 4px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent-amber);
  border: 3px solid var(--bg-secondary);
  box-shadow: 0 0 6px rgba(245, 158, 11, 0.6);
}

.schedule-step-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 3px;
  flex-wrap: wrap;
}

.schedule-time-badge {
  font-size: 0.8rem;
  font-weight: 800;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.15);
  padding: 2px 7px;
  border-radius: var(--radius-sm);
}

.schedule-step-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
}

.schedule-step-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.45;
  margin-bottom: 6px;
}

.schedule-route-info {
  font-size: 0.76rem;
  color: var(--accent-blue);
  background: rgba(56, 189, 248, 0.1);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  display: inline-block;
  margin: 2px 0 6px;
}

.map-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.74rem;
  font-weight: 700;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.3);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  text-decoration: none;
  transition: all 0.2s ease;
  margin-top: 3px;
}

.map-btn:hover {
  background: rgba(56, 189, 248, 0.25);
  border-color: #38bdf8;
  color: #ffffff;
}

.schedule-image-container {
  margin-top: 14px;
  padding: 10px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  text-align: center;
}

.schedule-image-container img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

/* --------------------------------------------------------------------------
   Day Tabs & Course Route Map Button Styles
   -------------------------------------------------------------------------- */
.schedule-day-tabs {
  display: flex;
  gap: 8px;
  background: var(--bg-tertiary);
  padding: 4px;
  border-radius: var(--radius-full);
  margin-bottom: 16px;
  border: 1px solid var(--border-color);
}

.day-tab-btn {
  flex: 1;
  padding: 9px 12px;
  border-radius: var(--radius-full);
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.86rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.day-tab-btn.active {
  background: var(--accent-gradient);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(245, 158, 11, 0.35);
}

.btn-course-route {
  width: 100%;
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff;
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-size: 0.88rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.3);
  transition: all 0.2s ease;
  margin-bottom: 14px;
}

.btn-course-route:hover {
  background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(2, 132, 199, 0.45);
}

.day-schedule-content {
  display: none;
  animation: fadeIn 0.25s ease;
}

.day-schedule-content.active {
  display: block;
}

/* --------------------------------------------------------------------------
   Videos Theater & YouTube Gallery Styles
   -------------------------------------------------------------------------- */
.video-theater-card {
  background: var(--bg-card);
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);
  margin-bottom: 24px;
}

.video-player-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  background: #000000;
}

.video-player-wrap iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.video-theater-info {
  padding: 16px;
}

.video-theater-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.video-theater-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.35;
  margin-bottom: 8px;
}

.video-theater-desc {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 14px;
}

.btn-youtube-external {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #cc0000;
  color: #ffffff;
  padding: 8px 14px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(204, 0, 0, 0.4);
}

.btn-youtube-external:hover {
  background: #e60000;
  transform: translateY(-1px);
}

/* Video Cards Grid */
.video-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

@media (min-width: 640px) {
  .video-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
}

.video-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
}

.video-card:hover {
  border-color: var(--border-highlight);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.video-card.active-playing {
  border-color: #ef4444;
  box-shadow: 0 0 16px rgba(239, 68, 68, 0.35);
}

.video-thumb-container {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  background: #111;
  overflow: hidden;
}

.video-thumb-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.video-card:hover .video-thumb-img {
  transform: scale(1.05);
}

.video-play-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.video-card:hover .video-play-overlay {
  background: rgba(0, 0, 0, 0.15);
}

.play-badge-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(220, 38, 38, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.25rem;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  transition: transform 0.2s ease;
}

.video-card:hover .play-badge-icon {
  transform: scale(1.12);
  background: #ef4444;
}

.video-card-body {
  padding: 12px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.video-card-title {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.35;
  margin-bottom: 6px;
}

.video-card-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.45;
  flex: 1;
}

.video-playing-indicator {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: 800;
  color: #ef4444;
  background: rgba(239, 68, 68, 0.15);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  margin-top: 8px;
  align-self: flex-start;
}

/* R2 Photo Storage Card */
.r2-gallery-card {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.12) 0%, rgba(99, 102, 241, 0.08) 100%);
  border: 1px dashed rgba(14, 165, 233, 0.4);
  border-radius: var(--radius-md);
  padding: 16px;
  position: relative;
}

/* --------------------------------------------------------------------------
   Local & Fallback Video Player Styles
   -------------------------------------------------------------------------- */
.video-file-preview-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  background: #000000;
  cursor: pointer;
  overflow: hidden;
}

.video-file-preview-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.video-file-preview-wrap:hover .video-file-preview-img {
  transform: scale(1.04);
}

.video-file-play-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #ffffff;
  transition: background 0.2s ease;
}

.video-file-preview-wrap:hover .video-file-play-overlay {
  background: rgba(0, 0, 0, 0.25);
}

.big-red-play-btn {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  background: #cc0000;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 22px rgba(204, 0, 0, 0.6);
  font-size: 2rem;
  padding-left: 5px;
  transition: transform 0.2s ease;
}

.video-file-preview-wrap:hover .big-red-play-btn {
  transform: scale(1.12);
  background: #e60000;
}

.video-action-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 10px;
}

.btn-video-primary {
  flex: 1;
  min-width: 200px;
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 11px 16px;
  font-size: 0.88rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.35);
  transition: all 0.2s ease;
  font-family: inherit;
}

.btn-video-primary:hover {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  transform: translateY(-1px);
}

.btn-video-secondary {
  background: var(--bg-tertiary);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.btn-video-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-highlight);
}

.local-protocol-notice {
  background: rgba(245, 158, 11, 0.1);
  border: 1px dashed rgba(245, 158, 11, 0.35);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-top: 12px;
  font-size: 0.74rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* --------------------------------------------------------------------------
   Kyushu Photo Gallery & Lightbox Styles
   -------------------------------------------------------------------------- */
.gallery-segmented-tabs {
  display: flex;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  padding: 4px;
  gap: 6px;
  margin-bottom: 20px;
}

.gallery-segmented-btn {
  flex: 1;
  padding: 10px 14px;
  border-radius: var(--radius-full);
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.gallery-segmented-btn.active {
  background: var(--accent-gradient);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(245, 158, 11, 0.35);
}

.photo-controls-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 10px 14px;
  border-radius: var(--radius-md);
}

.photo-filter-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-bottom: 24px;
}

@media (min-width: 600px) {
  .photo-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }
}

@media (min-width: 900px) {
  .photo-grid {
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
  }
}

.photo-thumb-card {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: #111827;
  cursor: pointer;
  border: 1px solid var(--border-color);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.photo-thumb-card:hover {
  transform: scale(1.03);
  border-color: var(--accent-amber);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  z-index: 2;
}

.photo-thumb-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: opacity 0.2s ease;
}

.photo-thumb-badge {
  position: absolute;
  bottom: 4px;
  right: 4px;
  background: rgba(0, 0, 0, 0.75);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: var(--radius-full);
  pointer-events: none;
}

.photo-highlight-star {
  position: absolute;
  top: 4px;
  left: 4px;
  background: rgba(245, 158, 11, 0.95);
  color: #ffffff;
  font-size: 0.66rem;
  padding: 2px 6px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  gap: 2px;
  font-weight: 800;
  pointer-events: none;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

/* Lightbox Modal */
.lightbox-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 2000;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 16px 12px;
}

.lightbox-backdrop.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.lightbox-header {
  width: 100%;
  max-width: 900px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #ffffff;
  padding: 4px 6px;
}

.lightbox-title-text {
  font-size: 0.95rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
}

.lightbox-img-wrap {
  position: relative;
  max-width: 920px;
  max-height: 75vh;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  flex: 1;
}

.lightbox-img-wrap img {
  max-width: 100%;
  max-height: 75vh;
  object-fit: contain;
  border-radius: var(--radius-sm);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
}

.lightbox-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(15, 23, 42, 0.85);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 10;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
}

.lightbox-nav-btn:hover {
  background: var(--accent-gradient);
  color: #ffffff;
  transform: translateY(-50%) scale(1.08);
}

.lightbox-prev {
  left: 6px;
}

.lightbox-next {
  right: 6px;
}

.lightbox-footer {
  width: 100%;
  max-width: 900px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 6px;
  flex-wrap: wrap;
  gap: 8px;
}
