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

:root {
  color-scheme: dark;
  --bg-1: #0b1017;
  --bg-2: #131b26;
  --card: #161e29;
  --card-border: #232d3b;
  --text: #c9d1dc;
  --text-strong: #f1f5f9;
  --text-muted: #8391a5;
  --surface: #1c2532;
  --surface-border: #2c3747;
  --accent: #60a5fa;
  --accent-soft: rgba(96, 165, 250, 0.12);
  --accent-text: #bfdbfe;
  --ok: #4ade80;
  --ok-bg: rgba(34, 197, 94, 0.10);
  --ok-border: rgba(74, 222, 128, 0.30);
  --warn: #fca5a5;
  --warn-icon: #f87171;
  --warn-bg: rgba(239, 68, 68, 0.10);
  --warn-border: rgba(248, 113, 113, 0.35);
}

html, body {
  min-height: 100%;
  margin: 0;
  background: linear-gradient(135deg, var(--bg-1) 0%, var(--bg-2) 100%) fixed;
  background-color: var(--bg-1);
  font-family: -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
}

body { display: flex; justify-content: center; align-items: flex-start; padding: 16px; min-height: 100vh; }

.card {
  width: 100%;
  max-width: 520px;
  background: var(--card);
  border: 1px solid var(--card-border);
  padding: 28px 20px;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45), 0 1px 3px rgba(0, 0, 0, 0.3);
  text-align: center;
}

.brand { margin-bottom: 20px; }

.lang-hint { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 10px 0 12px; color: var(--text-muted); font-size: 0.78em; font-weight: 500; }
.lang-hint svg { width: 14px; height: 14px; stroke: var(--text-muted); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; animation: bounce-down 1.5s ease infinite; }

@keyframes bounce-down {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(3px); }
}

.lang-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-bottom: 28px; padding: 0 4px; }

.lang-btn {
  display: flex; align-items: center; gap: 5px;
  padding: 6px 10px;
  border: 1.5px solid var(--surface-border);
  border-radius: 8px;
  background: var(--surface);
  cursor: pointer;
  transition: 0.2s;
  font-size: 12px; font-family: inherit; font-weight: 500; line-height: 1;
  color: var(--text-muted);
}
.lang-btn:hover { border-color: rgba(96, 165, 250, 0.6); background: var(--accent-soft); color: var(--accent-text); transform: translateY(-1px); }
.lang-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.lang-btn.active { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-text); font-weight: 600; box-shadow: 0 0 0 2px rgba(96, 165, 250, 0.2); }
.lang-btn svg.flag { width: 22px; height: 15px; border-radius: 2px; box-shadow: 0 0 0 0.5px rgba(255, 255, 255, 0.2); flex-shrink: 0; overflow: hidden; }

h1 { font-weight: 600; font-size: 1.15em; margin: 0 0 18px; color: var(--text-strong); }

#main-text { font-size: 0.92em; line-height: 1.7; margin-bottom: 8px; color: var(--text); }
#main-text-body { display: block; }

.reward { display: inline-block; margin: 14px 0 4px; color: var(--ok); font-weight: 600; font-size: 0.95em; background: var(--ok-bg); border: 1px solid var(--ok-border); padding: 8px 16px; border-radius: 8px; }

.warning { display: flex; align-items: flex-start; gap: 10px; background: var(--warn-bg); border: 1px solid var(--warn-border); color: var(--warn); padding: 12px 14px; font-size: 0.82em; line-height: 1.55; border-radius: 10px; margin: 18px 0; text-align: start; }
.warning-icon { flex-shrink: 0; width: 18px; height: 18px; margin-top: 1px; stroke: var(--warn-icon); }

.contact-section { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--card-border); }
.contact-label { font-size: 0.7em; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 14px; font-weight: 600; }

.msg-btn { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; padding: 14px 20px; color: #fff; border: none; border-radius: 12px; font-size: 0.95em; font-weight: 600; font-family: inherit; cursor: pointer; text-decoration: none; transition: 0.2s; }
.msg-btn svg { width: 22px; height: 22px; flex-shrink: 0; }
.msg-btn.wa svg { fill: #fff; }
.msg-btn.zalo svg { fill: none; }

.msg-btn.wa { background: #1fa855; box-shadow: 0 2px 10px rgba(37, 211, 102, 0.18); }
.msg-btn.wa:hover { background: #25d366; transform: translateY(-1px); color: #fff; text-decoration: none; }

.msg-btn.zalo { background: #0068ff; box-shadow: 0 2px 10px rgba(0, 104, 255, 0.2); margin-top: 8px; }
.msg-btn.zalo:hover { background: #1f7cff; transform: translateY(-1px); color: #fff; text-decoration: none; }

.contact-row { display: flex; gap: 8px; margin-top: 10px; }
.contact-card { flex: 1 1 0%; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 10px; border: 1.5px solid var(--surface-border); border-radius: 10px; text-decoration: none; color: var(--text); font-size: 0.82em; font-weight: 500; transition: 0.2s; background: var(--surface); }
.contact-card:hover { border-color: rgba(96, 165, 250, 0.6); background: var(--accent-soft); color: var(--accent-text); text-decoration: none; transform: translateY(-1px); }
.contact-card svg { width: 16px; height: 16px; flex-shrink: 0; }

a { color: var(--accent); text-decoration: none; font-weight: 500; }
a:hover { text-decoration: underline; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

@media (max-width: 380px) {
  .card { padding: 20px 14px; }
  .lang-btn { padding: 5px 7px; font-size: 11px; gap: 4px; }
  .lang-btn svg.flag { width: 18px; height: 12px; }
  h1 { font-size: 1.05em; }
  #main-text { font-size: 0.86em; }
  .msg-btn { font-size: 0.88em; padding: 12px 16px; }
  .contact-card { font-size: 0.78em; padding: 10px 6px; }
  .contact-row { flex-direction: column; }
}

@media (min-height: 900px) {
  body { align-items: center; }
}

@media (min-width: 600px) {
  .card { padding: 36px 32px; }
  .lang-btn { padding: 7px 12px; font-size: 13px; }
  .lang-btn svg.flag { width: 24px; height: 16px; }
  .lang-grid { gap: 8px; margin-bottom: 32px; }
  h1 { font-size: 1.3em; margin-bottom: 20px; }
  #main-text { font-size: 1em; }
  .reward { font-size: 1em; }
  .warning { font-size: 0.88em; padding: 14px 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .lang-hint svg { animation: none; }
  .lang-btn, .msg-btn, .contact-card { transition: none; }
}
