/* ============ RESET & BASE ============ */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --blue-900: #06264a;
  --blue-800: #0b3d75;
  --blue-700: #1157a8;
  --blue-600: #1a73d1;
  --blue-500: #2b8bf0;
  --blue-400: #5fa8f5;
  --blue-100: #dceeff;
  --white: #ffffff;
  --red: #e63946;
  --radius: 16px;
  --shadow: 0 8px 30px rgba(6, 38, 74, 0.25);
}
html, body {
  height: 100%;
  font-family: 'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, sans-serif;
  background: linear-gradient(160deg, var(--blue-900), var(--blue-700) 60%, var(--blue-600));
  color: var(--white);
  overflow-x: hidden;
}
.hidden { display: none !important; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: none; }
a { text-decoration: none; color: inherit; }

/* ============ BACKGROUND BLOBS (hiệu ứng nền mượt) ============ */
.bg-blobs { position: fixed; inset: 0; z-index: -1; overflow: hidden; }
.blob {
  position: absolute; border-radius: 50%;
  filter: blur(90px); opacity: 0.45;
  will-change: transform;
  animation: float 18s ease-in-out infinite;
}
.blob-1 { width: 480px; height: 480px; background: var(--blue-500); top: -120px; left: -100px; }
.blob-2 { width: 400px; height: 400px; background: var(--blue-400); bottom: -150px; right: -80px; animation-delay: -6s; }
.blob-3 { width: 340px; height: 340px; background: var(--blue-100); top: 40%; left: 60%; animation-delay: -12s; }
@keyframes float {
  0%, 100% { transform: translate(0,0) scale(1); }
  50% { transform: translate(40px, -30px) scale(1.1); }
}

/* ============ BUTTONS ============ */
.btn {
  padding: 12px 22px; border-radius: 12px; font-weight: 600;
  font-size: 15px; transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
  display: inline-flex; align-items: center; gap: 8px; justify-content: center;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--blue-500); color: #fff; box-shadow: 0 4px 18px rgba(43,139,240,.45); }
.btn-primary:hover { background: var(--blue-400); box-shadow: 0 6px 24px rgba(43,139,240,.6); }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-outline { background: transparent; border: 1.5px solid var(--blue-400); color: var(--blue-100); }
.btn-outline:hover { background: rgba(95,168,245,.15); }
.btn-danger { background: var(--red); color: #fff; }
.btn-danger:hover { background: #ff5a67; }
.btn-discord { background: #5865F2; color: #fff; width: 100%; }
.btn-discord:hover { background: #6f7bfa; }
.btn-google { background: #fff; color: #222; width: 100%; }
.btn-google:hover { background: #f1f1f1; }

/* ============ NAVBAR ============ */
.navbar { position: sticky; top: 0; z-index: 50; backdrop-filter: blur(14px); background: rgba(6,38,74,.55); border-bottom: 1px solid rgba(255,255,255,.08); }
.navbar-inner { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; padding: 16px 24px; }
.logo { font-size: 22px; font-weight: 800; }
.logo span { color: var(--blue-400); }

.user-menu { position: relative; }
.user-menu-toggle {
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15);
  padding: 8px 14px; border-radius: 10px; display: flex; align-items: center; gap: 8px; color: #fff;
  transition: background .18s;
}
.user-menu-toggle:hover { background: rgba(255,255,255,.16); }
.chevron { transition: transform .2s; }
.user-menu-toggle.open .chevron { transform: rotate(180deg); }
.user-dropdown {
  position: absolute; right: 0; top: calc(100% + 8px); background: var(--blue-800);
  border: 1px solid rgba(255,255,255,.1); border-radius: 12px; overflow: hidden;
  min-width: 180px; box-shadow: var(--shadow); animation: dropdownIn .15s ease;
}
@keyframes dropdownIn { from { opacity: 0; transform: translateY(-6px);} to { opacity:1; transform: translateY(0);} }
.dropdown-item { display: block; width: 100%; text-align: left; padding: 12px 16px; background: none; color: #fff; font-size: 14px; }
.dropdown-item:hover { background: rgba(255,255,255,.08); }
.dropdown-item-danger { color: #ff8b93; }

/* ============ HERO ============ */
.hero { text-align: center; padding: 90px 20px 60px; }
.welcome-text { font-size: clamp(28px, 5vw, 46px); font-weight: 800; letter-spacing: -.5px; }
.welcome-text span { color: var(--blue-400); }
.hero-sub { margin-top: 14px; color: var(--blue-100); font-size: 16px; opacity: .85; }

/* ============ SECTIONS ============ */
.section { max-width: 1200px; margin: 0 auto; padding: 60px 24px; }
.section-alt { background: rgba(255,255,255,.03); border-radius: 24px; }
.section-title { font-size: 30px; font-weight: 800; margin-bottom: 32px; text-align: center; }

.card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.feature-card {
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius); padding: 26px 20px; transition: transform .2s, box-shadow .2s, border-color .2s;
}
.feature-card:hover { transform: translateY(-6px); border-color: var(--blue-400); box-shadow: var(--shadow); }
.feature-icon { font-size: 28px; margin-bottom: 12px; }
.feature-card h3 { margin-bottom: 8px; font-size: 17px; }
.feature-card p { font-size: 14px; color: var(--blue-100); opacity: .85; line-height: 1.5; }

.coming-soon { text-align: center; padding: 50px 0; font-size: 20px; color: var(--blue-100); opacity: .7; }

/* ============ FOOTER ============ */
.footer { border-top: 1px solid rgba(255,255,255,.08); margin-top: 40px; }
.footer-inner { max-width: 1200px; margin: 0 auto; padding: 40px 24px 20px; }
.footer-contact h4 { margin-bottom: 14px; font-size: 16px; }
.footer-contact p { font-size: 14px; margin-bottom: 8px; color: var(--blue-100); display: flex; gap: 8px; align-items: center; }
.footer-icon { display: inline-block; }
.footer-support-time { margin-top: 10px; font-weight: 600; }
.footer-bottom { max-width: 1200px; margin: 0 auto; display: flex; justify-content: space-between; padding: 16px 24px 30px; font-size: 13px; color: var(--blue-100); opacity: .75; }
.footer-tos { font-weight: 600; opacity: 1; }
.footer-tos:hover { text-decoration: underline; }

/* ============ MODAL DÙNG CHUNG ============ */
.modal-overlay, .notice-overlay {
  position: fixed; inset: 0; background: rgba(4,20,40,.75); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center; z-index: 200; padding: 16px;
}
.modal-box, .notice-box {
  background: var(--blue-800); border: 1.5px solid var(--blue-500); border-radius: 20px;
  padding: 28px; width: 100%; max-width: 420px; box-shadow: var(--shadow); position: relative;
  animation: modalIn .2s ease;
}
@keyframes modalIn { from { opacity:0; transform: scale(.95);} to { opacity:1; transform: scale(1);} }
.modal-box-sm { max-width: 360px; text-align: center; }
.modal-title, .notice-title { font-size: 20px; font-weight: 800; margin-bottom: 12px; }
.modal-close { position: absolute; top: 14px; right: 18px; background: none; font-size: 22px; color: #fff; }
.notice-content { color: var(--blue-100); line-height: 1.6; margin-bottom: 22px; }
.notice-actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.login-options { display: flex; flex-direction: column; gap: 12px; margin: 18px 0; }
.login-warning { color: #ff8b93; font-size: 13px; text-align: center; margin-top: 18px; }
.login-step { margin-top: 16px; }
.step-desc { font-size: 13px; color: var(--blue-100); margin-bottom: 10px; }
.input-field {
  width: 100%; padding: 12px 14px; border-radius: 10px; border: 1px solid rgba(255,255,255,.2);
  background: rgba(255,255,255,.06); color: #fff; margin-bottom: 12px; font-size: 14px;
}
.input-field:focus { outline: none; border-color: var(--blue-400); }
.modal-actions { display: flex; gap: 10px; justify-content: center; margin-top: 18px; }

/* ============ RESPONSIVE ============ */
@media (max-width: 1024px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .card-grid { grid-template-columns: 1fr; }
  .navbar-inner { padding: 14px 16px; }
  .footer-bottom { flex-direction: column; gap: 10px; text-align: center; }
  .notice-actions { justify-content: center; }
}
