/* ========================================================
   hub.localgovtech.org — Landing Page
   LocalGovTech Smart SAO 5.0 — Product Selector
   ======================================================== */

@import url('https://fonts.googleapis.com/css2?family=Sarabun:wght@400;600;700;800&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --blue:    #1d4ed8;
  --green:   #16a34a;
  --white:   #ffffff;
  --gray-2:  #e2e8f0;
  --gray-6:  #475569;
  --gray-8:  #1e293b;
  --radius:  16px;
  --shadow:  0 4px 24px rgba(0,0,0,.18);
}

html, body {
  height: 100%;
  font-family: 'Sarabun', 'Noto Sans Thai', sans-serif;
  font-size: 16px;
  color: var(--gray-8);
}

.bg-image {
  position: fixed; inset: 0; z-index: 0;
  background: url('assets/countryside-bg.jpg') center/cover no-repeat;
}
.overlay {
  position: fixed; inset: 0; z-index: 1;
  background: linear-gradient(160deg,
    rgba(15,23,42,.65) 0%,
    rgba(15,23,42,.45) 50%,
    rgba(15,23,42,.70) 100%);
}

.container {
  position: relative; z-index: 2;
  min-height: 100dvh;
  display: flex; flex-direction: column;
  align-items: center;
  padding: 32px 16px 24px;
  gap: 24px;
}

/* ---- Hero ---- */
.hero { text-align: center; }

.logo-ring {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  width: 160px; height: 160px;
  margin-bottom: 20px;
}

.ring {
  position: absolute; inset: 0; border-radius: 50%;
  border: 2px solid rgba(96,165,250,.35);
  animation: ripple 3s ease-out infinite;
}
.ring-2 { animation-delay: 1s; inset: -14px; }

@keyframes ripple {
  0%   { transform: scale(1);   opacity: .6; }
  100% { transform: scale(1.25); opacity: 0; }
}

.logo-circle {
  width: 140px; height: 140px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue) 0%, #0369a1 100%);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 8px;
  box-shadow: 0 0 40px rgba(59,130,246,.5);
}
.hero-img { width: 88px; height: 88px; object-fit: contain; flex-shrink: 0; }
.logo-text { text-align: center; margin-top: 2px; }
.brand-sub  { display: block; font-size: 9px;  color: rgba(255,255,255,.85); letter-spacing: .06em; }
.brand-main { display: block; font-size: 11px; color: #fff; font-weight: 800; }

.headline {
  font-size: 22px; font-weight: 800;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0,0,0,.5);
  margin-bottom: 8px;
}
.subheadline {
  font-size: 14px; line-height: 1.7;
  color: rgba(255,255,255,.85);
}

/* ---- Cards ---- */
.cards {
  display: flex; flex-direction: column;
  gap: 16px; width: 100%; max-width: 480px;
}

.card {
  display: flex; align-items: center; gap: 16px;
  padding: 20px;
  border-radius: var(--radius);
  text-decoration: none;
  transition: transform .15s ease, box-shadow .15s ease;
  box-shadow: var(--shadow);
}
.card:hover, .card:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(0,0,0,.28);
  outline: 3px solid rgba(255,255,255,.4);
}

.card-staff {
  background: linear-gradient(135deg, rgba(29,78,216,.92) 0%, rgba(3,105,161,.92) 100%);
  backdrop-filter: blur(8px);
}
.card-citizen {
  background: linear-gradient(135deg, rgba(21,128,61,.92) 0%, rgba(5,150,105,.92) 100%);
  backdrop-filter: blur(8px);
}

.card-icon {
  flex-shrink: 0;
  width: 52px; height: 52px; border-radius: 14px;
  background: rgba(255,255,255,.18);
  display: flex; align-items: center; justify-content: center;
}
.card-icon svg { width: 26px; height: 26px; color: #fff; }

.card-body { flex: 1; min-width: 0; }
.card-badge {
  display: inline-block;
  font-size: 10px; font-weight: 700; letter-spacing: .05em;
  color: rgba(255,255,255,.7);
  background: rgba(255,255,255,.15);
  padding: 2px 8px; border-radius: 99px;
  margin-bottom: 4px;
}
.card-title   { font-size: 17px; font-weight: 800; color: #fff; margin-bottom: 2px; }
.card-subtitle{ font-size: 12px; font-weight: 600; color: rgba(255,255,255,.75); margin-bottom: 6px; }
.card-desc    { font-size: 12px; line-height: 1.6; color: rgba(255,255,255,.85); }

.card-arrow { flex-shrink: 0; opacity: .6; transition: opacity .15s, transform .15s; }
.card-arrow svg { width: 20px; height: 20px; color: #fff; }
.card:hover .card-arrow { opacity: 1; transform: translateX(4px); }

/* ---- LINE Modal ---- */
.modal-backdrop {
  display: none;
  position: fixed; inset: 0; z-index: 50;
  background: rgba(0,0,0,.65);
  align-items: center; justify-content: center;
  padding: 16px;
}
.modal-backdrop.is-open { display: flex; }

.modal {
  background: #fff;
  border-radius: 24px;
  padding: 32px 24px;
  width: 100%; max-width: 340px;
  text-align: center;
  box-shadow: 0 8px 48px rgba(0,0,0,.4);
  animation: pop-in .2s ease;
}
@keyframes pop-in {
  from { transform: scale(.9); opacity: 0; }
  to   { transform: scale(1);  opacity: 1; }
}

.modal-line-icon { margin-bottom: 16px; }
.modal-line-icon svg { width: 56px; height: 56px; }

.modal-title { font-size: 22px; font-weight: 800; color: var(--gray-8); margin-bottom: 20px; }
.modal-appname { color: var(--green); }

.modal-qr { margin-bottom: 16px; }
.qr-placeholder {
  width: 180px; height: 180px;
  margin: 0 auto;
  border: 3px dashed var(--gray-2);
  border-radius: 12px;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 8px;
  color: var(--gray-6);
  font-size: 14px; font-weight: 600;
}
.qr-sub { font-size: 11px; color: #94a3b8; text-align: center; line-height: 1.6; }

.modal-desc { font-size: 13px; line-height: 1.7; color: var(--gray-6); margin-bottom: 24px; }

.modal-close {
  width: 100%; padding: 14px;
  background: var(--gray-2); color: var(--gray-8);
  border: none; border-radius: 12px;
  font-size: 15px; font-weight: 700;
  cursor: pointer;
}
.modal-close:hover { filter: brightness(.93); }

/* ---- Footer ---- */
.footer { margin-top: auto; }
.footer p { font-size: 11px; color: rgba(255,255,255,.4); text-align: center; }
