*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: #f0f2f5;
  color: #1a1a1a;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px 16px;
}

.entry-card {
  width: 100%;
  max-width: 420px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
  padding: 48px 32px 40px;
  text-align: center;
}

.brand-logo {
  display: block;
  width: 120px;
  height: auto;
  max-height: 120px;
  margin: 0 auto 24px;
  object-fit: contain;
}

.countdown-wrap {
  position: relative;
  width: 120px;
  height: 120px;
  margin: 0 auto 28px;
}

.countdown-ring {
  width: 120px;
  height: 120px;
  transform: rotate(-90deg);
}

.ring-bg {
  fill: none;
  stroke: #e8eaed;
  stroke-width: 4;
}

.ring-progress {
  fill: none;
  stroke: #1677ff;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 339.292;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 0.15s linear;
}

.countdown-inner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.countdown-seconds {
  font-size: 40px;
  font-weight: 600;
  line-height: 1;
  color: #1a1a1a;
}

.countdown-unit {
  font-size: 14px;
  color: #8c8c8c;
  margin-top: 4px;
}

.brand-title {
  font-size: 20px;
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 12px;
  line-height: 1.4;
}

.brand-slogan {
  font-size: 14px;
  color: #8c8c8c;
  line-height: 1.8;
  margin-bottom: 8px;
}

.brand-slogan p + p {
  margin-top: 2px;
}

.status-text {
  font-size: 13px;
  color: #8c8c8c;
  min-height: 20px;
  margin-bottom: 24px;
}

.status-text.status-ok {
  color: #52c41a;
}

.status-text.status-error {
  color: #ff4d4f;
}

.status-text[hidden] {
  display: none;
}

.line-results {
  text-align: left;
  margin-bottom: 20px;
}

.line-results[hidden] {
  display: none;
}

.line-results-title {
  font-size: 15px;
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 12px;
  text-align: center;
}

.line-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.line-item {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 4px 12px;
  padding: 12px 14px;
  border-radius: 10px;
  background: #fafafa;
  border: 1px solid #f0f0f0;
  font-size: 13px;
  line-height: 1.5;
}

.line-item--ok {
  border-color: #d9f7be;
  background: #f6ffed;
}

.line-item--fail {
  border-color: #ffccc7;
  background: #fff2f0;
}

.line-item--pending {
  border-color: #e8e8e8;
  background: #fafafa;
}

.line-status--pending {
  color: #8c8c8c;
}

.line-pending {
  color: #8c8c8c;
}

.line-name {
  grid-column: 1;
  grid-row: 1;
  font-weight: 600;
  color: #1a1a1a;
}

.line-status {
  grid-column: 2;
  grid-row: 1;
  font-weight: 500;
  white-space: nowrap;
}

.line-item--ok .line-status {
  color: #52c41a;
}

.line-item--fail .line-status {
  color: #ff4d4f;
}

.line-meta {
  grid-column: 1 / -1;
  grid-row: 2;
  color: #595959;
}

.line-speed {
  color: #1677ff;
  font-weight: 500;
}

.line-sep {
  color: #bfbfbf;
}

.line-action {
  border: none;
  background: none;
  padding: 0;
  font: inherit;
  color: #1677ff;
  font-weight: 500;
  cursor: pointer;
  text-decoration: underline;
}

.line-action:hover {
  color: #4096ff;
}

.line-report {
  color: #8c8c8c;
}

.line-report-link {
  color: #1677ff;
  text-decoration: underline;
}

.line-report-link:hover {
  color: #4096ff;
}

.btn-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.btn-go {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 280px;
  height: 44px;
  padding: 0 16px;
  border: none;
  border-radius: 8px;
  background: #1677ff;
  color: #fff;
  font-size: 16px;
  font-weight: 500;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s, opacity 0.2s;
}

.btn-go--fastest {
  background: #52c41a;
}

.btn-go--fastest .btn-fastest-label,
.btn-go--fastest .btn-fastest-countdown {
  font: inherit;
  color: inherit;
}

.btn-go--fastest .btn-fastest-countdown {
  margin-left: 8px;
}

.btn-go--fastest .btn-fastest-sec {
  font: inherit;
  color: inherit;
}

.btn-go:hover:not(:disabled) {
  background: #4096ff;
}

.btn-go--fastest:hover:not(:disabled) {
  background: #73d13d;
}

.btn-go:active:not(:disabled) {
  background: #0958d9;
}

.btn-go--fastest:active:not(:disabled) {
  background: #389e0d;
}

.btn-go:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-go--fastest[hidden] {
  display: none;
}

.entry-card.is-failed .ring-progress {
  stroke: #ffccc7;
}

.entry-card.is-success .ring-progress {
  stroke: #52c41a;
}

@media (max-width: 380px) {
  .entry-card {
    padding: 40px 20px 32px;
  }

  .countdown-seconds {
    font-size: 36px;
  }
}
