@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&subset=vietnamese&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary:       #3d8b6e;
  --primary-dark:  #2d6b52;
  --primary-light: #5aab8a;
  --accent:        #f0a500;
  --bg:            #f4faf7;
  --bg-card:       #ffffff;
  --bg-subtle:     #eaf5ef;
  --text:          #1c2e26;
  --text-muted:    #6b8f7a;
  --border:        #cde8da;
  --shadow-sm:  0 1px 4px rgba(61,139,110,0.07);
  --shadow-md:  0 4px 16px rgba(61,139,110,0.12);
  --shadow-lg:  0 8px 32px rgba(61,139,110,0.16);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --transition: 0.22s cubic-bezier(0.4,0,0.2,1);
}

[data-theme="dark"] {
  --bg:        #0e1a14;
  --bg-card:   #182a1f;
  --bg-subtle: #1d3327;
  --text:      #e8f5ee;
  --text-muted:#7ab898;
  --border:    #2a4d38;
  --shadow-sm: 0 1px 4px rgba(0,0,0,0.25);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.35);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.45);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Plus Jakarta Sans', 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  transition: background var(--transition), color var(--transition);
  line-height: 1.65;
  font-size: 15px;
}

/* HEADER */
header {
  position: sticky; top: 0; z-index: 100;
  background: var(--primary);
  color: white;
  padding: 0 1.25rem;
  display: flex; align-items: center; justify-content: space-between;
  height: 62px;
  box-shadow: 0 2px 12px rgba(45,107,82,0.3);
  position: relative;
}
header::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
}

.logo { display: flex; flex-direction: column; gap: 1px; }
.logo-title { font-size: 1rem; font-weight: 800; line-height: 1.2; letter-spacing: -0.01em; }
.logo-sub { font-size: 0.62rem; opacity: 0.8; font-weight: 500; letter-spacing: 0.02em; }
.header-actions { display: flex; align-items: center; gap: 0.5rem; }

.btn-icon {
  background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.25);
  color: white; width: 36px; height: 36px;
  border-radius: var(--radius-sm);
  cursor: pointer; font-size: 1rem;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--transition), transform var(--transition);
}
.btn-icon:hover { background: rgba(255,255,255,0.32); transform: scale(1.08); }
.btn-icon:active { transform: scale(0.95); }

/* NAV OVERLAY */
.nav-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(14,26,20,0.6);
  backdrop-filter: blur(3px);
  z-index: 200;
}
.nav-overlay.open { display: block; }

/* NAV DRAWER */
.nav-drawer {
  position: fixed; top: 0; left: -300px;
  width: 280px; height: 100vh;
  background: var(--bg-card);
  z-index: 201;
  transition: left 0.3s cubic-bezier(0.4,0,0.2,1);
  padding: 1.5rem 1.25rem;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}
.nav-drawer.open { left: 0; }

.nav-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1.5rem; padding-bottom: 1rem;
  border-bottom: 2px solid var(--border);
}
.nav-header span { font-weight: 800; color: var(--primary); font-size: 1rem; }

.nav-links { list-style: none; display: flex; flex-direction: column; gap: 0.25rem; }
.nav-links li a {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.75rem 0.875rem;
  color: var(--text); text-decoration: none;
  border-radius: var(--radius-sm);
  transition: background var(--transition), color var(--transition), transform var(--transition);
  font-weight: 600; font-size: 0.95rem;
}
.nav-links li a:hover { background: var(--primary); color: white; transform: translateX(4px); }

/* MAIN */
main { max-width: 800px; margin: 0 auto; padding: 1.25rem 1rem; }

/* HERO */
.hero {
  background: linear-gradient(140deg, var(--primary) 0%, var(--primary-dark) 60%, #1e4d38 100%);
  color: white; border-radius: var(--radius-lg);
  padding: 2.25rem 1.75rem; margin-bottom: 1.25rem;
  text-align: center; position: relative; overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.hero::before {
  content: ''; position: absolute; top: -40px; right: -40px;
  width: 180px; height: 180px; background: rgba(255,255,255,0.06); border-radius: 50%;
}
.hero::after {
  content: ''; position: absolute; bottom: -60px; left: -30px;
  width: 220px; height: 220px; background: rgba(255,255,255,0.04); border-radius: 50%;
}
.hero h1 { font-size: 1.6rem; font-weight: 800; margin-bottom: 0.5rem; letter-spacing: -0.02em; position: relative; z-index: 1; }
.hero p { opacity: 0.88; font-size: 0.9rem; margin-bottom: 1.5rem; position: relative; z-index: 1; }

.hero-badges { display: flex; gap: 0.6rem; justify-content: center; flex-wrap: wrap; margin-bottom: 1.5rem; position: relative; z-index: 1; }
.badge {
  background: rgba(255,255,255,0.18); border: 1px solid rgba(255,255,255,0.3);
  padding: 0.35rem 0.85rem; border-radius: 20px; font-size: 0.82rem; font-weight: 600;
  transition: background var(--transition), transform var(--transition);
}
.badge:hover { background: rgba(255,255,255,0.3); transform: translateY(-2px); }

.hero-btns { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; position: relative; z-index: 1; }
.btn {
  padding: 0.6rem 1.3rem; border-radius: var(--radius-sm); border: none; cursor: pointer;
  font-weight: 700; font-size: 0.875rem; text-decoration: none;
  transition: transform var(--transition), box-shadow var(--transition);
  display: inline-flex; align-items: center; gap: 0.4rem;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.22); }
.btn:active { transform: translateY(0); }
.btn-white { background: white; color: var(--primary-dark); }
.btn-outline { background: rgba(255,255,255,0.12); color: white; border: 2px solid rgba(255,255,255,0.6); }
.btn-outline:hover { background: rgba(255,255,255,0.25); }

/* SECTION */
.section {
  background: var(--bg-card); border-radius: var(--radius-md);
  padding: 1.375rem; margin-bottom: 1rem;
  border: 1px solid var(--border); box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition), transform var(--transition);
}
.section:hover { box-shadow: var(--shadow-md); }

.section-title {
  font-size: 1rem; font-weight: 800; color: var(--primary-dark);
  margin-bottom: 1rem; display: flex; align-items: center; gap: 0.5rem;
  padding-bottom: 0.625rem; border-bottom: 2px solid var(--border);
  letter-spacing: -0.01em;
}

/* ROUTE GROUP — signature: lift + border-color on hover */
.route-group {
  margin-bottom: 1rem; border-radius: var(--radius-sm);
  border: 1px solid var(--border); overflow: hidden;
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
}
.route-group:last-child { margin-bottom: 0; }
.route-group:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); border-color: var(--primary-light); }

.route-title {
  font-weight: 700; color: white; font-size: 0.88rem;
  display: flex; align-items: center; gap: 0.4rem;
  background: linear-gradient(90deg, var(--primary-dark), var(--primary));
  padding: 0.6rem 0.875rem;
}

.price-table { width: 100%; border-collapse: collapse; font-size: 0.84rem; }
.price-table th {
  background: var(--bg-subtle); color: var(--primary-dark);
  padding: 0.45rem 0.75rem; text-align: left;
  font-weight: 700; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em;
}
.price-table td { padding: 0.45rem 0.75rem; border-bottom: 1px solid var(--border); transition: background var(--transition); }
.price-table tr:last-child td { border-bottom: none; }
.price-table tr:hover td { background: var(--bg-subtle); }
.price-tag { color: var(--primary-dark); font-weight: 700; }
.point-tag { color: #c05621; font-weight: 700; font-size: 0.8rem; }
.route-note { font-size: 0.76rem; color: var(--text-muted); padding: 0.4rem 0.75rem 0.5rem; background: var(--bg-subtle); border-top: 1px solid var(--border); font-style: italic; }

/* RULES */
.rule-list { list-style: none; }
.rule-item {
  padding: 0.625rem 0.375rem; border-bottom: 1px solid var(--border);
  font-size: 0.875rem; display: flex; gap: 0.6rem; align-items: flex-start;
  transition: background var(--transition); border-radius: 4px;
}
.rule-item:hover { background: var(--bg-subtle); }
.rule-item:last-child { border-bottom: none; }
.rule-num { color: var(--primary); font-weight: 700; min-width: 22px; flex-shrink: 0; }

/* INFO GRID */
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
.info-card {
  background: var(--bg-subtle); border-radius: var(--radius-sm);
  padding: 0.875rem 0.75rem; border: 1px solid var(--border); text-align: center;
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
}
.info-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); border-color: var(--primary-light); }
.info-card .ic-val { font-size: 1.15rem; font-weight: 800; color: var(--primary); letter-spacing: -0.02em; }
.info-card .ic-label { font-size: 0.73rem; color: var(--text-muted); margin-top: 0.2rem; font-weight: 500; }

/* CONTACT */
.contact-row {
  display: flex; align-items: center; gap: 0.875rem;
  padding: 0.75rem 0.5rem; border-bottom: 1px solid var(--border);
  border-radius: var(--radius-sm); transition: background var(--transition);
}
.contact-row:hover { background: var(--bg-subtle); }
.contact-row:last-child { border-bottom: none; }
.contact-icon {
  font-size: 1.2rem; width: 36px; height: 36px;
  background: var(--bg-subtle); border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--border); flex-shrink: 0;
  transition: background var(--transition), transform var(--transition);
}
.contact-row:hover .contact-icon { background: var(--primary); transform: scale(1.08); }
.contact-info .label { font-size: 0.72rem; color: var(--text-muted); font-weight: 500; text-transform: uppercase; letter-spacing: 0.04em; }
.contact-info .val { font-weight: 700; font-size: 0.95rem; display: flex; align-items: center; gap: 0.4rem; }
.contact-info a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
.contact-info a:hover { color: var(--primary-dark); text-decoration: underline; }

/* NOTICE */
.notice-list { list-style: none; }
.notice-item {
  padding: 0.55rem 0.5rem; border-bottom: 1px solid var(--border);
  font-size: 0.86rem; display: flex; gap: 0.5rem; align-items: flex-start;
  border-radius: 4px; transition: background var(--transition);
}
.notice-item:hover { background: #fff9e6; }
.notice-item:last-child { border-bottom: none; }
.notice-item::before { content: "⚠️"; min-width: 20px; flex-shrink: 0; }

/* PENALTY */
.penalty-item {
  display: flex; gap: 0.6rem; padding: 0.55rem 0.5rem;
  border-bottom: 1px solid var(--border); font-size: 0.85rem; align-items: flex-start;
  border-radius: 4px; transition: background var(--transition);
}
.penalty-item:hover { background: #fff0f0; }
.penalty-item:last-child { border-bottom: none; }
.penalty-icon { min-width: 22px; color: var(--text-muted); font-weight: 700; flex-shrink: 0; }
.penalty-pts { color: #c0392b; font-weight: 800; white-space: nowrap; background: #fff0f0; padding: 0.1rem 0.35rem; border-radius: 4px; font-size: 0.8rem; }

/* QR */
.qr-box { display: flex; flex-direction: column; align-items: center; gap: 1rem; padding: 1rem 0; }
.qr-placeholder {
  width: 160px; height: 160px; background: var(--bg-subtle);
  border: 2px dashed var(--primary-light); border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 0.5rem;
  color: var(--text-muted); font-size: 0.8rem; text-align: center;
  transition: border-color var(--transition), transform var(--transition);
}
.qr-placeholder:hover { border-color: var(--primary); transform: scale(1.03); }

/* FOOTER */
footer {
  background: linear-gradient(135deg, var(--primary-dark), #1a3d2b);
  color: white; text-align: center; padding: 2rem 1rem; margin-top: 2rem;
}
footer .footer-brand { font-size: 1.1rem; font-weight: 800; }
footer .footer-contact { margin-top: 0.4rem; font-size: 0.9rem; opacity: 0.9; }
footer .footer-contact a { color: #86efac; text-decoration: none; font-weight: 600; }
footer p { opacity: 0.6; font-size: 0.75rem; margin-top: 0.875rem; }

/* SCROLLBAR */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--primary-light); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

/* BAN QUAN TRI */
.bqt-list { display: flex; flex-direction: column; gap: 0.6rem; }
.bqt-item {
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  padding: 0.75rem 0.875rem;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
}
.bqt-item:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); border-color: var(--primary-light); }
.bqt-info { display: flex; align-items: center; gap: 0.6rem; flex: 1; min-width: 0; }
.bqt-icon { font-size: 1.1rem; flex-shrink: 0; }
.bqt-name { font-size: 0.875rem; color: var(--text); }
.btn-call {
  background: var(--primary);
  color: white;
  border: none; border-radius: var(--radius-sm);
  padding: 0.45rem 0.9rem;
  font-size: 0.82rem; font-weight: 700;
  text-decoration: none; white-space: nowrap; flex-shrink: 0;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
  display: inline-flex; align-items: center;
}
.btn-call:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-call:active { transform: translateY(0); }

/* SCROLL TO TOP */
#scrollTop {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 44px; height: 44px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  display: flex; align-items: center; justify-content: center;
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity var(--transition), transform var(--transition), background var(--transition);
  z-index: 99;
}
#scrollTop.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
#scrollTop:hover {
  background: var(--primary-dark);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}
#scrollTop:active { transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

@media (max-width: 480px) {
  body { font-size: 14px; }
  .hero { padding: 1.75rem 1.25rem; }
  .hero h1 { font-size: 1.3rem; }
  .price-table { font-size: 0.78rem; }
  main { padding: 1rem 0.75rem; }
}

/* ── QR MODAL ── */
#qrModal { display: none; }
#qrModal.open { display: flex; }
}