* {
  box-sizing: border-box;
}

:root {
  font-family: "Inter", "Noto Sans JP", system-ui, -apple-system, sans-serif;
  line-height: 1.5;
  color: #0f172a;
  background-color: #f8fafc;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #f8fafc;
  padding: 1.5rem clamp(1rem, 4vw, 2.5rem);
}

.container {
  max-width: 960px;
  margin: 0 auto;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  box-shadow: 0 8px 40px rgba(15, 23, 42, 0.05);
}

header h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.8rem, 4vw, 2.4rem);
}

#updated-at {
  color: #475569;
  margin: 0;
}

.controls {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  align-items: center;
}

button,
.refresh-btn {
  border: none;
  border-radius: 999px;
  padding: 0.5rem 1.2rem;
  font-size: 0.95rem;
  background: #2563eb;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s ease;
}

button:hover {
  background: #1d4ed8;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
}

thead th {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  border-bottom: 1px solid #e2e8f0;
}

th,
td {
  padding: 0.9rem 1rem;
  text-align: left;
}

tbody tr:nth-child(even) {
  background: #f8fafc;
}

tbody tr:not(:last-child) td {
  border-bottom: 1px solid #e2e8f0;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border-radius: 999px;
  padding: 0.2rem 0.8rem;
  font-size: 0.8rem;
  background: #e0f2fe;
  color: #0369a1;
}

.ip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.ip-chip {
  padding: 0.35rem 0.8rem;
  border-radius: 12px;
  background: #ecfccb;
  border: 1px solid #bef264;
  font-family: "JetBrains Mono", "SFMono-Regular", ui-monospace, monospace;
  font-size: 0.85rem;
}

.empty {
  text-align: center;
  padding: 2rem 1rem;
  color: #64748b;
  border: 1px dashed #cbd5f5;
  border-radius: 12px;
  background: #f8fafc;
}

.cards {
  display: none;
}

@media (max-width: 720px) {
  .container {
    padding: 1.2rem;
  }

  table {
    display: none;
  }

  .cards {
    display: grid;
    gap: 1rem;
  }

  .card {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1rem;
    background: #fff;
  }

  .card-row {
    margin-bottom: 0.4rem;
  }

  .card-label {
    display: block;
    font-size: 0.8rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
  }
}

