/* === Variables === */
:root {
  --bg: #FAFAF8;
  --text: #2C2C2C;
  --text-light: #6B6B6B;
  --gold: #C9A84C;
  --gold-light: #F5EDD6;
  --silver: #A8A9AD;
  --silver-light: #EEEEF0;
  --card-bg: #FFFFFF;
  --card-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
  --radius: 12px;
  --font: 'Be Vietnam Pro', system-ui, sans-serif;
}

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

/* === Base === */
html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px;
}

/* === Header === */
.header {
  padding: 24px 0 8px;
  text-align: center;
}

.logo img {
  height: 48px;
  width: auto;
}

.tagline {
  font-size: 0.875rem;
  color: var(--text-light);
  font-weight: 300;
  letter-spacing: 0.5px;
  margin-top: 4px;
}

/* === Section Title === */
.section-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  text-align: center;
  margin-bottom: 24px;
}

/* === Hero: World Prices === */
.hero {
  padding: 40px 0 32px;
}

.price-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.price-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--card-shadow);
  text-align: center;
  animation: fadeInUp 0.5s ease both;
}

.price-card:nth-child(2) {
  animation-delay: 0.1s;
}

.price-card__header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 16px;
}

.price-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0;
}

.price-card--gold .price-card__icon {
  background: var(--gold-light);
  color: var(--gold);
}

.price-card--silver .price-card__icon {
  background: var(--silver-light);
  color: var(--silver);
}

.price-card__label {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-light);
}

.price-card__value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
  min-height: 2.4rem;
}

.price-card--gold .price-card__value {
  color: #8B7332;
}

.price-card--silver .price-card__value {
  color: #6E6F73;
}

.price-card__sub {
  font-size: 0.8125rem;
  margin-top: 8px;
  font-weight: 500;
}

.price-card__sub.up {
  color: #2E7D32;
}

.price-card__sub.down {
  color: #C62828;
}

/* === Vietnam Section === */
.vn-section {
  padding: 32px 0 40px;
}

.vn-table-wrapper {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--card-shadow);
  overflow: hidden;
  animation: fadeInUp 0.5s ease 0.2s both;
}

.vn-table {
  width: 100%;
  border-collapse: collapse;
}

.vn-table thead {
  background: #F7F6F3;
}

.vn-table th {
  padding: 14px 16px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: left;
}

.vn-table th:not(:first-child) {
  text-align: right;
}

.vn-table td {
  padding: 14px 16px;
  font-size: 0.9375rem;
  border-top: 1px solid #F0EFEC;
}

.vn-table td:not(:first-child) {
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.vn-table tbody tr:hover {
  background: #FDFCFA;
}

.vn-table td:first-child {
  font-weight: 500;
}

/* === Section Source === */
.section-source {
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-light);
  margin-top: -16px;
  margin-bottom: 20px;
  opacity: 0.6;
}

/* === Update Time === */
.update-time {
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-light);
  margin-top: 12px;
  opacity: 0.7;
}

/* === Footer === */
.footer {
  padding: 48px 0 32px;
  text-align: center;
  border-top: 1px solid #EDECE8;
}

.coming-soon {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.copyright {
  font-size: 0.75rem;
  color: var(--text-light);
}

/* === Loading === */
.loading-dots::after {
  content: '';
  animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
  0%, 20% { content: ''; }
  40% { content: '.'; }
  60% { content: '..'; }
  80%, 100% { content: '...'; }
}

/* === Error === */
.error-msg {
  color: #C62828;
  font-size: 0.875rem;
  font-style: italic;
}

/* === Animations === */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* === Responsive === */
@media (max-width: 480px) {
  .price-cards {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .price-card__value {
    font-size: 1.75rem;
  }

  .price-card {
    padding: 20px 16px;
  }

  .vn-table th,
  .vn-table td {
    padding: 12px;
    font-size: 0.8125rem;
  }
}
