:root {
  --brand-primary: #2563EB;
  --brand-primary-rgb: 37, 99, 235;
  --brand-text: #333333;
  --brand-text-light: #666666;
  --brand-text-muted: #888888;
  --brand-border: #e0e0e0;
  --brand-bg: #ffffff;
  --brand-bg-alt: #f8f9fa;
  --font: 'Noto Sans TC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

html, body { height: 100%; }

body {
  font-family: var(--font);
  background: var(--brand-bg);
  color: var(--brand-text);
  line-height: 1.6;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 20px;
}

/* ── Card container ── */
.container {
  max-width: 700px;
  width: 100%;
  background: var(--brand-bg);
  border-radius: 8px;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

/* ── Logo section ── */
.logo-section {
  background: var(--brand-bg-alt);
  padding: 24px 40px;
  border-bottom: 1px solid var(--brand-border);
}

.brand-logo {
  height: 40px;
  width: auto;
  max-width: 220px;
  object-fit: contain;
  display: block;
}

/* ── Content area ── */
.content {
  padding: 40px;
}

/* ── Title ── */
.title {
  font-size: 1.75rem;
  font-weight: 500;
  color: #1a1a1a;
  margin-bottom: 32px;
  line-height: 1.3;
}

.policy-tag {
  font-weight: 400;
  color: var(--brand-text-light);
}

/* ── Message section ── */
.message-section {
  margin-bottom: 32px;
}

/* Primary message — shown in brand color, large */
.message-main {
  font-size: 1.125rem;
  color: var(--brand-primary);
  margin-bottom: 20px;
  font-weight: 500;
}

/* Inline site name highlight */
.message-main #blocked-site,
.message-main .site-highlight {
  word-break: break-all;
  background: rgba(var(--brand-primary-rgb), 0.08);
  padding: 2px 8px;
  border-radius: 4px;
}

/* Contact info — left-border callout */
.contact-callout {
  font-size: 1.125rem;
  color: var(--brand-primary);
  margin-bottom: 24px;
  padding: 16px 20px;
  background: rgba(var(--brand-primary-rgb), 0.05);
  border-left: 4px solid var(--brand-primary);
  border-radius: 0 4px 4px 0;
}

.contact-meta-line {
  font-size: 1rem;
  color: var(--brand-primary);
  margin-top: 6px;
  margin-bottom: 0;
}

.contact-meta-line a {
  color: inherit;
  text-decoration: none;
}

.contact-meta-line a:hover { text-decoration: underline; }

.message-en {
  font-size: 1rem;
  color: var(--brand-text-light);
}

/* ── DNS badge ── */
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  vertical-align: middle;
  margin-left: 8px;
}

.badge-dns  { background: #3b82f6; color: #fff; }
.badge-http { background: rgba(var(--brand-primary-rgb), 0.12); color: var(--brand-primary); }

/* ── Details section ── */
.details-section {
  display: none;
  background: var(--brand-bg-alt);
  border: 1px solid var(--brand-border);
  border-radius: 6px;
  padding: 20px;
  margin-bottom: 24px;
}

.details-section h3 {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--brand-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

.details-table {
  width: 100%;
  font-size: 0.875rem;
  border-collapse: collapse;
}

.details-table td {
  padding: 8px 0;
  vertical-align: top;
}

.details-table td:first-child {
  width: 140px;
  color: var(--brand-text-muted);
  font-weight: 500;
}

.details-table td:last-child {
  color: var(--brand-text);
  word-break: break-all;
}

.details-table tr:not(:last-child) td {
  border-bottom: 1px solid var(--brand-border);
}

/* ── Footer ── */
.footer {
  text-align: center;
  padding-top: 24px;
  border-top: 1px solid var(--brand-border);
}

.footer p {
  font-size: 0.8125rem;
  color: var(--brand-text-muted);
}

.footer a {
  color: var(--brand-primary);
  text-decoration: none;
}

.footer a:hover { text-decoration: underline; }

/* ── Responsive ── */
@media (max-width: 600px) {
  body {
    align-items: flex-start;
    padding: 10px;
  }

  .container { margin-top: 20px; }

  .logo-section { padding: 16px 24px; }

  .brand-logo { height: 32px; }

  .content { padding: 24px; }

  .title { font-size: 1.375rem; margin-bottom: 24px; }

  .message-main,
  .contact-callout { font-size: 1rem; }

  .contact-callout { padding: 12px 16px; }

  .details-table td:first-child { width: 110px; }
}

/* ── Print ── */
@media print {
  body { background: white; }
  .container { box-shadow: none; border: 1px solid #ddd; }
}
