/* ── ISO 證書查詢 前台樣式 ── */
.icl-wrap {
  max-width: 640px;
  margin: 2rem auto;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* 搜尋框 */
.icl-search-box label {
  display: block;
  font-size: 0.9rem;
  color: #555;
  margin-bottom: 0.5rem;
}

.icl-input-row {
  display: flex;
  gap: 0.5rem;
}

.icl-input-row input {
  flex: 1;
  padding: 0.65rem 1rem;
  border: 2px solid #d1d5db;
  border-radius: 8px;
  font-size: 1rem;
  outline: none;
  transition: border-color 0.2s;
}

.icl-input-row input:focus {
  border-color: #2563eb;
}

.icl-input-row button {
  padding: 0.65rem 1.5rem;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.icl-input-row button:hover:not(:disabled) {
  background: #1d4ed8;
}

.icl-input-row button:disabled {
  background: #93c5fd;
  cursor: not-allowed;
}

/* 結果區 */
.icl-result {
  margin-top: 1.5rem;
}

/* 讀取中 */
.icl-loading {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #6b7280;
  padding: 1.5rem;
}

.icl-spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid #d1d5db;
  border-top-color: #2563eb;
  border-radius: 50%;
  animation: icl-spin 0.7s linear infinite;
}

@keyframes icl-spin { to { transform: rotate(360deg); } }

/* 錯誤 */
.icl-error {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 1.25rem;
  background: #fef2f2;
  border: 1px solid #fca5a5;
  border-radius: 8px;
  color: #dc2626;
}

.icl-error-icon {
  font-style: normal;
  font-weight: bold;
  width: 20px;
  height: 20px;
  background: #dc2626;
  color: #fff;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  flex-shrink: 0;
}

/* 結果卡片 */
.icl-card {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.icl-card-header {
  background: linear-gradient(135deg, #1e3a5f 0%, #2563eb 100%);
  color: #fff;
  padding: 1.25rem 1.5rem;
}

.icl-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.4rem;
}

.icl-standard {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.icl-company {
  font-size: 1rem;
  opacity: 0.9;
}

/* 狀態 Badge */
.icl-status {
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  flex-shrink: 0;
}

.icl-status.active    { background: #dcfce7; color: #15803d; }
.icl-status.expired   { background: #fee2e2; color: #b91c1c; }
.icl-status.suspended { background: #fef3c7; color: #b45309; }

/* 資料欄位 */
.icl-card-body {
  padding: 1.25rem 1.5rem;
  background: #fff;
}

.icl-row {
  display: flex;
  gap: 1rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid #f3f4f6;
}

.icl-row:last-child {
  border-bottom: none;
}

.icl-label {
  flex-shrink: 0;
  width: 80px;
  color: #6b7280;
  font-size: 0.85rem;
  padding-top: 2px;
}

.icl-val {
  color: #111827;
  font-size: 0.95rem;
  line-height: 1.5;
  word-break: break-word;
}

.icl-val.mono {
  font-family: "Courier New", monospace;
  font-weight: 600;
  letter-spacing: 0.5px;
}
