:root {
  --bg: #0b1220;
  --card: #121a2b;
  --line: #243049;
  --text: #e8eefc;
  --muted: #93a0b8;
  --accent: #3d8bff;
  --ok: #3dd68c;
  --warn: #ffc857;
  --bad: #ff6b7a;
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--text); font-family: "Segoe UI", Tahoma, Arial, sans-serif; }
.hero { max-width: 920px; margin: 0 auto; padding: 48px 20px 24px; text-align: center; }
.brand { color: var(--accent); font-weight: 700; letter-spacing: 0.08em; }
h1 { font-size: clamp(1.6rem, 3vw, 2.4rem); margin: 12px 0; }
.lead { color: var(--muted); max-width: 640px; margin: 0 auto 24px; }
.search { display: flex; gap: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 8px; }
.search input { flex: 1; background: transparent; border: 0; color: var(--text); font-size: 1rem; padding: 10px 16px; outline: none; }
.search button, .actions button { background: var(--accent); color: #fff; border: 0; border-radius: 999px; padding: 10px 20px; font-weight: 700; cursor: pointer; }
.actions button.ghost { background: transparent; border: 1px solid var(--line); color: var(--text); }
.error { color: var(--bad); }
main { max-width: 1080px; margin: 0 auto; padding: 8px 20px 64px; }
.toolbar { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: end; margin-bottom: 16px; }
.muted { color: var(--muted); }
.grid.mods { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; margin-bottom: 20px; }
.mod { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 10px; font-size: 0.85rem; }
.mod.ok { border-color: #245c43; }
.mod.error { border-color: #5c2430; }
.mod.skipped { border-color: #5c4a24; }
.rank-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.rank-box { background: #1b2740; border-radius: 12px; padding: 16px; text-align: center; }
.rank-box span { display: block; color: var(--muted); font-size: 0.85rem; margin-bottom: 8px; }
.rank-box strong { font-size: 1.4rem; }
@media (max-width: 800px) { .rank-grid { grid-template-columns: 1fr; } }
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 16px;
}
.tabs button {
  background: #1b2740;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  font-weight: 600;
}
.tabs button.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.tab-panel { display: none; }
.tab-panel.active { display: block; }
.remain {
  color: #e53935;
  font-weight: 800;
  font-size: 1.15rem;
  display: inline-block;
}
.date-full { display: block; margin-top: 4px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 14px; }
.card h3 { margin: 0 0 12px; }
table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
td, th { border-bottom: 1px solid var(--line); padding: 8px 4px; text-align: right; vertical-align: top; }
.alert { background: #3a2a12; border: 1px solid var(--warn); color: var(--warn); padding: 12px 16px; border-radius: 10px; margin-bottom: 12px; }
pre { white-space: pre-wrap; word-break: break-word; background: #0a101c; padding: 12px; border-radius: 8px; font-size: 0.8rem; color: #c9d4ea; max-height: 280px; overflow: auto; }
.hint { display: inline-block; background: #1b2740; border-radius: 999px; padding: 4px 10px; margin: 4px; font-size: 0.85rem; }
footer { color: var(--muted); text-align: center; padding: 28px 20px 36px; font-size: 0.85rem; border-top: 1px solid var(--line); }
footer .legal { margin: 0 0 16px; }
footer .credit { margin: 0; color: var(--text); font-weight: 700; font-size: 1rem; }
footer .credit-link { margin: 6px 0 0; }
footer .credit-link a { color: var(--accent); text-decoration: none; }
footer .credit-link a:hover { text-decoration: underline; }
.myip {
  max-width: 1100px;
  margin: 0 auto 32px;
  padding: 24px;
  background: #163a5c;
  border-radius: 16px;
}
.myip-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr 1.1fr;
  gap: 20px;
  align-items: start;
}
.myip h2, .myip h3 { margin: 0 0 12px; }
.ip-row {
  background: #1e4a73;
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.ip-label {
  background: #2d9bf0;
  color: #fff;
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.8rem;
}
.ip-meta { margin: 0; }
.ip-meta div { display: flex; gap: 10px; margin: 6px 0; }
.ip-meta dt { color: #b9d4ea; min-width: 70px; }
.ip-meta dd { margin: 0; font-weight: 700; }
.expose { text-align: center; font-weight: 700; }
.hide-btn {
  display: block;
  width: 100%;
  background: #e53935;
  color: #fff;
  border: 0;
  border-radius: 8px;
  padding: 14px;
  font-weight: 800;
  cursor: pointer;
}
.tips { color: #d7e8f7; font-size: 0.9rem; line-height: 1.6; }
.linkish {
  background: none;
  border: 0;
  color: #7dffb3;
  cursor: pointer;
  display: block;
  margin: 12px auto 0;
  text-decoration: underline;
}
.myip-map iframe {
  width: 100%;
  height: 220px;
  border: 0;
  border-radius: 10px;
  background: #0d2236;
}
.map-note { text-align: center; color: #b9d4ea; font-size: 0.85rem; }
@media (max-width: 900px) {
  .myip-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .search { flex-direction: column; border-radius: 16px; }
}
