:root {
  --eztopup-bg: #0E0E13;
  --eztopup-surface: #17171F;
  --eztopup-surface-2: #1D1D27;
  --eztopup-border: #2A2A36;
  --eztopup-text: #F4F4F7;
  --eztopup-muted: #9A9AA8;
  --eztopup-accent: #FF6A3D;
  --eztopup-accent-2: #2FE6A6;
}

.eztopup-grid,
.eztopup-topup {
  font-family: 'Plus Jakarta Sans', 'Noto Sans Thai', 'Noto Sans Lao', system-ui, sans-serif;
  color: var(--eztopup-text);
  box-sizing: border-box;
}
.eztopup-grid *,
.eztopup-topup * {
  box-sizing: border-box;
}

.eztopup-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 20px;
}
.eztopup-card {
  display: block;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  color: var(--eztopup-text);
  transition: transform .15s ease, border-color .15s ease;
}
.eztopup-card:hover {
  transform: translateY(-4px);
  border-color: var(--eztopup-accent);
}
.eztopup-card-tile {
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #0E0E13;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.eztopup-card-body {
  padding: 14px 16px;
}
.eztopup-card-name {
  font-size: 14px;
  font-weight: 700;
}

.eztopup-skeleton-tile,
.eztopup-skeleton-line {
  background: linear-gradient(100deg, var(--eztopup-surface) 30%, var(--eztopup-surface-2) 50%, var(--eztopup-surface) 70%);
  background-size: 200% 100%;
  animation: eztopup-shimmer 1.4s ease-in-out infinite;
}
.eztopup-skeleton-line {
  height: 12px;
  border-radius: 4px;
  margin: 14px 16px;
  width: 65%;
}
@keyframes eztopup-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
@media (prefers-reduced-motion: reduce) {
  .eztopup-skeleton-tile,
  .eztopup-skeleton-line {
    animation: none;
  }
}

.eztopup-topup {
  background: var(--eztopup-bg);
  padding: 32px clamp(16px, 5vw, 80px) 80px;
  border-radius: 20px;
}
.eztopup-header h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 28px;
  margin: 0 0 24px;
  color: var(--eztopup-text);
}
.eztopup-game-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 32px;
}
.eztopup-game-header h1 {
  margin: 0;
}
.eztopup-game-icon {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
  border-radius: 16px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 22px;
  color: #0E0E13;
}
.eztopup-layout {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  align-items: flex-start;
}
.eztopup-steps {
  flex: 1 1 560px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.eztopup-summary {
  flex: 0 1 340px;
  min-width: 280px;
  position: sticky;
  top: 24px;
}

.eztopup-card-panel {
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 16px;
  padding: 24px;
}
.eztopup-step-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.eztopup-step-num {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--eztopup-accent);
  color: #0E0E13;
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.eztopup-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}
.eztopup-field-label {
  font-size: 12px;
  color: var(--eztopup-muted);
  font-weight: 600;
}
.eztopup-input {
  background: var(--eztopup-surface-2);
  border: 1px solid var(--eztopup-border);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--eztopup-text);
  font-size: 14px;
  font-family: inherit;
  width: 100%;
}
.eztopup-success-banner {
  margin-top: 8px;
  padding: 10px 14px;
  background: rgba(47, 230, 166, .1);
  border: 1px solid var(--eztopup-accent-2);
  border-radius: 10px;
  color: var(--eztopup-accent-2);
  font-size: 13px;
  font-weight: 600;
}

.eztopup-packages {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 14px;
}
.eztopup-package {
  border: 1px solid var(--eztopup-border);
  background: var(--eztopup-surface-2);
  border-radius: 12px;
  padding: 14px;
  cursor: pointer;
}
.eztopup-package.is-selected {
  border: 2px solid var(--eztopup-accent);
}
.eztopup-package-name {
  font-size: 14px;
  font-weight: 700;
}
.eztopup-package-price {
  font-size: 13px;
  font-weight: 700;
  color: var(--eztopup-accent);
  margin-top: 8px;
}

.eztopup-payments {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.eztopup-payment {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px;
  border-radius: 12px;
  cursor: pointer;
  border: 1px solid var(--eztopup-border);
  background: var(--eztopup-surface-2);
}
.eztopup-payment.is-selected {
  border: 1.5px solid var(--eztopup-accent);
}
.eztopup-payment-left {
  display: flex;
  align-items: center;
  gap: 12px;
}
.eztopup-payment-tag {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}
.eztopup-payment-name {
  font-size: 14px;
  font-weight: 700;
}
.eztopup-payment-sub {
  font-size: 12px;
  color: var(--eztopup-muted);
}

.eztopup-summary-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.eztopup-summary-icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: 10px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 12px;
  color: #0E0E13;
}
.eztopup-summary-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 700;
}
.eztopup-summary-subtitle {
  font-size: 12px;
  font-weight: 700;
  color: var(--eztopup-muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin: 4px 0 12px;
}
.eztopup-summary-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
  margin-bottom: 10px;
}
.eztopup-summary-divider {
  border-top: 1px solid var(--eztopup-border);
  margin: 12px 0;
}
.eztopup-summary-total {
  font-size: 16px;
  font-weight: 700;
  color: var(--eztopup-accent);
}

.eztopup-btn {
  border: none;
  border-radius: 10px;
  padding: 12px 20px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.eztopup-btn-primary {
  background: var(--eztopup-accent);
  color: #0E0E13;
}
.eztopup-btn-primary:disabled {
  opacity: .4;
  cursor: not-allowed;
}
.eztopup-btn-ghost {
  background: transparent;
  color: var(--eztopup-text);
  border: 1px solid var(--eztopup-border);
}
.eztopup-btn-ghost:hover {
  border-color: var(--eztopup-accent);
}
.eztopup-btn-block {
  width: 100%;
  margin-top: 8px;
}

.eztopup-pending {
  max-width: 560px;
  margin: 40px auto;
  text-align: center;
}
.eztopup-pending-icon {
  display: flex;
  justify-content: center;
}
.eztopup-pending-icon .eztopup-summary-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  font-size: 20px;
}
.eztopup-pending h1 {
  font-family: 'Space Grotesk', sans-serif;
}
.eztopup-pending-details {
  text-align: left;
  margin-top: 20px;
}
.eztopup-pending-instructions {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--eztopup-border);
  font-size: 13px;
  color: var(--eztopup-muted);
  line-height: 1.6;
}

@media (max-width: 640px) {
  .eztopup-summary {
    position: static;
  }
}

/* ---------- Homepage (templates/homepage.php) ---------- */

body.eztopup-home-body {
  background: var(--eztopup-bg) !important;
  margin: 0;
}
.eztopup-home {
  font-family: 'Plus Jakarta Sans', 'Noto Sans Thai', 'Noto Sans Lao', system-ui, sans-serif;
  color: var(--eztopup-text);
  background: var(--eztopup-bg);
  min-height: 100vh;
}
.eztopup-home * {
  box-sizing: border-box;
}
.eztopup-home a {
  text-decoration: none;
  color: inherit;
}

.eztopup-home-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 20px clamp(16px, 5vw, 80px);
  border-bottom: 1px solid var(--eztopup-border);
}
.eztopup-home-nav-left {
  display: flex;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
}
.eztopup-home-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.02em;
}
.eztopup-home-logo span.accent {
  color: var(--eztopup-accent);
}
.eztopup-home-logo span.muted {
  color: var(--eztopup-muted);
  font-weight: 500;
}
.eztopup-home-nav-links {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
}
.eztopup-home-nav-links a {
  color: var(--eztopup-muted);
  font-size: 14px;
  font-weight: 500;
}
.eztopup-home-nav-links a:hover {
  color: var(--eztopup-text);
}
.eztopup-home-nav-links a.active {
  color: var(--eztopup-accent);
  position: relative;
}
.eztopup-home-nav-links a.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 2px;
  border-radius: 1px;
  background: var(--eztopup-accent);
}
.eztopup-home-nav-right {
  display: flex;
  gap: 12px;
  align-items: center;
}
.eztopup-lang-switch {
  display: flex;
  gap: 2px;
  align-items: center;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 10px;
  padding: 3px;
}
.eztopup-lang-pill {
  padding: 6px 10px;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 700;
  color: var(--eztopup-muted);
}
.eztopup-lang-pill:hover {
  color: var(--eztopup-text);
}
.eztopup-lang-pill.is-active {
  background: var(--eztopup-surface-2);
  color: var(--eztopup-accent);
}

.eztopup-support {
  position: relative;
}
.eztopup-support-toggle {
  display: flex;
  align-items: center;
  gap: 4px;
  background: transparent;
  border: none;
  color: var(--eztopup-muted);
  font-size: 14px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  padding: 0;
}
.eztopup-support-toggle:hover {
  color: var(--eztopup-text);
}
.eztopup-support-link {
  color: var(--eztopup-muted);
  font-size: 14px;
  font-weight: 500;
}
.eztopup-support-link:hover {
  color: var(--eztopup-text);
}
.eztopup-support-menu {
  display: none;
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  min-width: 180px;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .4);
  z-index: 50;
}
.eztopup-support.is-open .eztopup-support-menu {
  display: block;
}
.eztopup-support-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--eztopup-text);
  font-size: 14px;
  font-weight: 600;
}
.eztopup-support-menu a:hover {
  background: var(--eztopup-surface-2);
}
.eztopup-support-menu svg {
  color: var(--eztopup-accent);
  flex-shrink: 0;
}

.eztopup-account {
  position: relative;
}
.eztopup-account-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--eztopup-surface-2);
  border: 1px solid var(--eztopup-border);
  border-radius: 999px;
  color: var(--eztopup-text);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  padding: 8px 16px;
}
.eztopup-account-menu {
  display: none;
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  min-width: 180px;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .4);
  z-index: 50;
}
.eztopup-account.is-open .eztopup-account-menu {
  display: block;
}
.eztopup-account-menu-item {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--eztopup-text);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
}
.eztopup-account-menu-item:hover {
  background: var(--eztopup-surface-2);
}

/* Auth modal (Sign in / Register / My Orders) */
.eztopup-auth-view {
  display: none;
}
.eztopup-auth-view.is-active {
  display: block;
}
.eztopup-oauth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  background: #fff;
  color: #1a1a1a;
  border: 1px solid var(--eztopup-border);
  border-radius: 999px;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  margin-bottom: 10px;
  text-decoration: none;
}
.eztopup-oauth-btn:hover {
  opacity: .92;
}
.eztopup-oauth-line {
  background: #06C755;
  color: #fff;
  border-color: #06C755;
}
.eztopup-auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--eztopup-muted);
  font-size: 12px;
  margin: 18px 0;
}
.eztopup-auth-divider::before,
.eztopup-auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--eztopup-border);
}
.eztopup-auth-submit {
  width: 100%;
  margin-top: 4px;
}
.eztopup-auth-switch {
  margin: 18px 0 0;
  text-align: center;
  font-size: 13px;
  color: var(--eztopup-muted);
}
.eztopup-auth-switch button {
  background: transparent;
  border: none;
  color: var(--eztopup-accent);
  font-weight: 700;
  font-size: 13px;
  font-family: inherit;
  cursor: pointer;
  padding: 0;
}
.eztopup-error-banner {
  margin: 4px 0 14px;
  padding: 10px 14px;
  background: rgba(255, 90, 90, .1);
  border: 1px solid #ff5a5a;
  border-radius: 10px;
  color: #ff8a8a;
  font-size: 13px;
  font-weight: 600;
}
.eztopup-order-row {
  border: 1px solid var(--eztopup-border);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 10px;
}
.eztopup-order-row-main {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 4px;
}
.eztopup-order-row-meta {
  font-size: 12px;
  color: var(--eztopup-muted);
  margin-bottom: 8px;
}
.eztopup-order-row-status {
  display: inline-flex;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--eztopup-surface-2);
  color: var(--eztopup-muted);
}
.eztopup-order-row-status.status-fulfilled {
  color: var(--eztopup-accent-2);
  background: rgba(47, 230, 166, .1);
}
.eztopup-order-row-status.status-failed {
  color: #ff8a8a;
  background: rgba(255, 90, 90, .1);
}

.eztopup-home-hero {
  padding: clamp(48px, 8vw, 96px) clamp(16px, 5vw, 80px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 48px;
  flex-wrap: wrap;
}
.eztopup-home-hero-copy {
  max-width: 600px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.eztopup-home-eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--eztopup-accent);
  text-transform: uppercase;
}
.eztopup-home-hero h1 {
  margin: 0;
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(32px, 5vw, 52px);
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.eztopup-home-hero p {
  margin: 0;
  color: var(--eztopup-muted);
  font-size: 16px;
  line-height: 1.6;
}
.eztopup-home-search {
  display: flex;
  gap: 10px;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 14px;
  padding: 6px;
}
.eztopup-home-search input {
  flex-grow: 1;
  border: none;
  outline: none;
  background: transparent;
  color: var(--eztopup-text);
  font-size: 14px;
  padding: 10px 14px;
  font-family: inherit;
  min-width: 0;
}
.eztopup-home-badges {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.eztopup-home-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--eztopup-muted);
  font-weight: 600;
}

.eztopup-home-hero-visual {
  position: relative;
  width: 420px;
  height: 340px;
  flex-shrink: 0;
}
.eztopup-hv-1 {
  position: absolute;
  top: 46px;
  left: 30px;
  width: 170px;
  height: 220px;
  background: #5B8CFF;
  border-radius: 20px;
  transform: rotate(-8deg);
  box-shadow: 0 20px 40px rgba(0, 0, 0, .4);
}
.eztopup-hv-2 {
  position: absolute;
  top: 16px;
  left: 115px;
  width: 170px;
  height: 220px;
  background: var(--eztopup-accent);
  border-radius: 20px;
  transform: rotate(4deg);
  box-shadow: 0 20px 40px rgba(0, 0, 0, .4);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 18px;
}
.eztopup-hv-3 {
  position: absolute;
  top: 86px;
  left: 210px;
  width: 150px;
  height: 105px;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 14px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, .5);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.eztopup-home-section {
  padding: 0 clamp(16px, 5vw, 80px) 80px;
}
.eztopup-home-section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}
.eztopup-home-section-head h2 {
  margin: 0;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 26px;
  font-weight: 700;
}
.eztopup-home-viewall {
  font-size: 14px;
  font-weight: 600;
  color: var(--eztopup-accent);
}

.eztopup-home-row {
  margin-bottom: 32px;
}
.eztopup-home-row:last-child {
  margin-bottom: 0;
}
.eztopup-home-row-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--eztopup-accent);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 14px;
  padding-left: 12px;
  border-left: 3px solid var(--eztopup-accent);
}
.eztopup-grid-row {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
@media (max-width: 900px) {
  .eztopup-grid-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 520px) {
  .eztopup-grid-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.eztopup-filter-bar {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 28px;
}
.eztopup-filter-search {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 12px;
  padding: 10px 16px;
  max-width: 360px;
}
.eztopup-filter-search input {
  flex-grow: 1;
  border: none;
  outline: none;
  background: transparent;
  color: var(--eztopup-text);
  font-size: 14px;
  font-family: inherit;
  min-width: 0;
}
.eztopup-filter-letters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.eztopup-filter-chip {
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  color: var(--eztopup-muted);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.eztopup-filter-chip:hover {
  border-color: var(--eztopup-accent);
}
.eztopup-filter-chip.is-active {
  background: var(--eztopup-accent);
  color: #0E0E13;
  border-color: var(--eztopup-accent);
}

.eztopup-home-how {
  background: var(--eztopup-surface);
  border-top: 1px solid var(--eztopup-border);
  border-bottom: 1px solid var(--eztopup-border);
  padding: 64px clamp(16px, 5vw, 80px);
}
.eztopup-home-how h2 {
  text-align: center;
  margin: 0 0 40px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 26px;
  font-weight: 700;
}
.eztopup-home-how-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 32px;
  max-width: 1000px;
  margin: 0 auto;
}
.eztopup-home-how-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}
.eztopup-home-how-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--eztopup-surface-2);
  border: 1px solid var(--eztopup-border);
  display: flex;
  align-items: center;
  justify-content: center;
}
.eztopup-home-how-step strong {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 700;
}
.eztopup-home-how-step span {
  font-size: 13px;
  color: var(--eztopup-muted);
  line-height: 1.6;
  max-width: 260px;
}

.eztopup-home-pay {
  padding: 48px clamp(16px, 5vw, 80px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}
.eztopup-home-pay-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--eztopup-muted);
  text-transform: uppercase;
}
.eztopup-home-pay-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}
.eztopup-home-pay-tile {
  width: 80px;
  height: 48px;
  border-radius: 10px;
  background: var(--eztopup-surface-2);
  border: 1px solid var(--eztopup-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
}

.eztopup-home-footer {
  border-top: 1px solid var(--eztopup-border);
  padding: 48px clamp(16px, 5vw, 80px) 32px;
}
.eztopup-home-footer-cols {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 32px;
}
.eztopup-home-footer-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.eztopup-home-footer-col strong {
  font-size: 13px;
}
.eztopup-home-footer-col a {
  font-size: 13px;
  color: var(--eztopup-muted);
}
.eztopup-home-footer-col a:hover {
  color: var(--eztopup-text);
}
.eztopup-home-footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 24px;
  margin-top: 24px;
  border-top: 1px solid var(--eztopup-border);
  font-size: 12px;
  color: var(--eztopup-muted);
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 900px) {
  .eztopup-home-footer-cols {
    grid-template-columns: 1fr 1fr;
  }
  .eztopup-home-hero-visual {
    display: none;
  }
}

/* ---------- News (templates/news.php) ---------- */

.eztopup-news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.eztopup-news-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  box-sizing: border-box;
  width: 100%;
  margin: 0;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 16px;
  overflow: hidden;
  color: var(--eztopup-text);
  text-decoration: none;
  text-align: left;
  padding: 0;
  font-family: inherit;
  font-size: inherit;
  line-height: normal;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  transition: transform .15s ease, border-color .15s ease;
}
/* Firefox adds a hidden inner border/padding to <button> that plain
   `padding: 0` above doesn't reach — without this reset the image and
   body content sit a few px off the card's edge in Firefox only. */
.eztopup-news-card::-moz-focus-inner {
  border: 0;
  padding: 0;
}
.eztopup-news-card:hover {
  transform: translateY(-4px);
  border-color: var(--eztopup-accent);
}
.eztopup-news-card-image {
  display: block;
  margin: 0;
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
  background-color: var(--eztopup-surface-2);
}
.eztopup-news-card-body {
  padding: 18px;
}
.eztopup-news-card-source {
  font-size: 12px;
  font-weight: 700;
  color: var(--eztopup-accent);
  text-transform: uppercase;
  letter-spacing: .03em;
  margin-bottom: 8px;
}
.eztopup-news-card-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.35;
}
.eztopup-news-card-excerpt {
  font-size: 13px;
  color: var(--eztopup-muted);
  line-height: 1.6;
  margin-bottom: 14px;
}
.eztopup-news-card-link {
  font-size: 13px;
  font-weight: 700;
  color: var(--eztopup-accent);
}

/* ---------- Articles (templates/blog.php, templates/article.php) ---------- */

.eztopup-blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.eztopup-blog-card {
  display: block;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 16px;
  overflow: hidden;
  color: var(--eztopup-text);
  text-decoration: none;
  transition: transform .15s ease, border-color .15s ease;
}
.eztopup-blog-card:hover {
  transform: translateY(-4px);
  border-color: var(--eztopup-accent);
}
.eztopup-blog-card-image {
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
  background-color: var(--eztopup-surface-2);
}
.eztopup-blog-card-image-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
}
.eztopup-blog-card-body {
  padding: 20px;
}
.eztopup-blog-card-date {
  font-size: 12px;
  color: var(--eztopup-muted);
  margin-bottom: 8px;
}
.eztopup-blog-card-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.3;
}
.eztopup-blog-card-excerpt {
  font-size: 14px;
  color: var(--eztopup-muted);
  line-height: 1.6;
}

.eztopup-pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
}
.eztopup-pagination a {
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid var(--eztopup-border);
  color: var(--eztopup-text);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
.eztopup-pagination a.current {
  background: var(--eztopup-accent);
  color: #0E0E13;
  border-color: var(--eztopup-accent);
}

/* Full-page loading overlay — shown instantly on search submit / pagination
   click, since those are plain full-page navigations with no other visual
   feedback that anything happened until the new page finishes loading. */
.eztopup-page-loading {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(8, 8, 12, .75);
  z-index: 200;
  align-items: center;
  justify-content: center;
}
.eztopup-page-loading.is-active {
  display: flex;
}
.eztopup-page-loading-spinner {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 3px solid var(--eztopup-border);
  border-top-color: var(--eztopup-accent);
  animation: eztopup-spin .8s linear infinite;
}
@keyframes eztopup-spin {
  to { transform: rotate(360deg); }
}

.eztopup-article {
  max-width: 760px;
  margin: 0 auto;
  padding: 40px 20px 100px;
}
.eztopup-article-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--eztopup-muted);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  margin-bottom: 24px;
}
.eztopup-article-back:hover {
  color: var(--eztopup-text);
}
.eztopup-article-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 16px;
  background-size: cover;
  background-position: center;
  margin-bottom: 32px;
}
.eztopup-article-meta {
  font-size: 13px;
  color: var(--eztopup-muted);
  margin-bottom: 12px;
}
.eztopup-article-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 32px;
}
.eztopup-article-content {
  font-size: 16px;
  line-height: 1.8;
  color: var(--eztopup-text);
}
.eztopup-article-content p {
  margin: 0 0 20px;
}
.eztopup-article-content h2,
.eztopup-article-content h3 {
  font-family: 'Space Grotesk', sans-serif;
  margin: 36px 0 16px;
  line-height: 1.3;
}
.eztopup-article-content img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 8px 0 24px;
}
.eztopup-article-content a {
  color: var(--eztopup-accent);
}
.eztopup-article-content ul,
.eztopup-article-content ol {
  margin: 0 0 20px;
  padding-left: 24px;
}
.eztopup-article-content li {
  margin-bottom: 8px;
}

/* ---------- News summary modal (templates/news.php) ---------- */

.eztopup-modal-backdrop,
.eztopup-modal-backdrop * {
  /* Same reasoning as .eztopup-modal-title's color fix below: the auth
     modal renders outside .eztopup-home, which is the only place this site
     resets box-sizing to border-box. Without it, .eztopup-input's
     width:100% + padding overflowed its container (visible as a
     horizontal scrollbar and inputs poking past the card's rounded edge). */
  box-sizing: border-box;
}
.eztopup-modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(8, 8, 12, .75);
  z-index: 100;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.eztopup-modal-backdrop.is-open {
  display: flex;
}
.eztopup-modal {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: 85vh;
  overflow-y: auto;
  background: var(--eztopup-surface);
  border: 1px solid var(--eztopup-border);
  border-radius: 20px;
  /* The auth modal is appended via wp_footer, outside the .eztopup-home
     wrapper that normally sets text color for the page — without this,
     it fell back to the browser/theme default (dark gray on our dark
     background, unreadable). Set explicitly so any modal is correct
     regardless of where in the DOM it's rendered. */
  color: var(--eztopup-text);
  font-family: 'Plus Jakarta Sans', 'Noto Sans Thai', 'Noto Sans Lao', system-ui, sans-serif;
}
.eztopup-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(14, 14, 19, .6);
  color: #fff;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  z-index: 1;
}
.eztopup-modal-image {
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
  background-color: var(--eztopup-surface-2);
  border-radius: 20px 20px 0 0;
}
.eztopup-modal-body {
  padding: 24px;
}
.eztopup-modal-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.35;
  margin: 8px 0 16px;
  /* The theme's block-editor global styles set their own color on heading
     tags (h1-h6) for its light-theme default pages — an explicit rule like
     that beats plain inheritance, which is why this h3 stayed near-black
     and unreadable even after .eztopup-modal got color: var(--eztopup-text)
     (that's an inherited value, not an explicit one, so it loses). */
  color: var(--eztopup-text);
}
.eztopup-modal-summary {
  font-size: 15px;
  line-height: 1.7;
  color: var(--eztopup-text);
  margin: 0 0 24px;
}
