.batch-panel {
  background: linear-gradient(180deg, rgba(229, 242, 238, 0.35), rgba(255, 253, 248, 0));
}

.batch-title h2 {
  margin: 0;
  font-size: clamp(22px, 3.4vw, 30px);
  line-height: 1.15;
  font-family: "Cormorant Garamond", serif;
}

.batch-title p {
  margin: 2px 0 0;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.35;
}

.batch-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
  align-items: center;
}

.batch-tools input[type="file"] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 9px 12px;
  font-size: 13px;
  color: var(--ink-soft);
  background: #fff;
}

.batch-textarea {
  width: 100%;
  min-height: 120px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 11px 12px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink);
  background: #fffefb;
}

.batch-textarea::placeholder {
  color: #6b8780;
}

.batch-table-wrap {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffefb;
  overflow: hidden;
}

.batch-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.batch-table thead {
  background: #eef7f4;
}

.batch-table th,
.batch-table td {
  padding: 8px 8px;
  border-bottom: 1px solid #e3eeeb;
  font-size: 12px;
  text-align: left;
  vertical-align: middle;
}

.batch-table tbody tr:last-child td {
  border-bottom: 0;
}

.batch-table th:nth-child(2),
.batch-table td:nth-child(2) {
  width: 116px;
  text-align: center;
}

.batch-table th:nth-child(3),
.batch-table td:nth-child(3) {
  width: 130px;
  text-align: center;
}

.batch-table th:nth-child(4),
.batch-table td:nth-child(4) {
  width: 180px;
  text-align: center;
}

.batch-email-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  border: 0;
  background: transparent;
  padding: 0;
  border-radius: 0;
  color: var(--ink);
  font-weight: 600;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.batch-email-index {
  flex: 0 0 auto;
  min-width: 28px;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid #d9e8e3;
  background: #f5faf8;
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
}

.batch-email-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.batch-email-btn:hover {
  color: var(--accent-strong);
}

.batch-code {
  font-family: "Cormorant Garamond", serif;
  font-size: 23px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.08em;
  color: var(--ink);
}

.batch-empty {
  text-align: center;
  color: var(--ink-soft);
  font-style: italic;
}

.batch-status-badge {
  display: inline-block;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
  line-height: 1.2;
  border: 1px solid #c8dcd6;
  color: var(--ink-soft);
  background: #f7fbf9;
}

.batch-status-badge.ok {
  border-color: #bde3d3;
  color: #165f43;
  background: #f2fbf6;
}

.batch-status-badge.error {
  border-color: #e6bdb6;
  color: #8f3023;
  background: #fff3f0;
}

.batch-copy-btn {
  min-width: 62px;
}

.batch-row-refresh-btn {
  min-width: 68px;
}

.batch-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  align-items: center;
}

@media (max-width: 680px) {
  .batch-tools {
    grid-template-columns: 1fr;
  }

  .batch-table-wrap {
    overflow-x: auto;
  }

  .batch-table {
    min-width: 620px;
  }
}
