:root {
  color-scheme: light;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  margin: 0;
  padding: 24px;
  background: #f6f6f6;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  box-sizing: border-box;
}

@media (max-height: 840px) {
  body {
    align-items: flex-start;
  }
}

main {
  width: 100%;
  display: flex;
  justify-content: center;
}

.card {
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 10px;
  padding: 18px;
  max-width: 1160px;
  width: min(1160px, 100%);
}

.page-title {
  margin: 0 0 6px 0;
  font-size: 24px;
}

.preview-section {
  margin-top: 16px;
}

.preview-title {
  margin: 0 0 8px 0;
  font-size: 16px;
}

.row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 14px;
}

button {
  appearance: none;
  border: 0;
  background: #6f1d1b;
  color: #fff;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 700;
  transition:
    background-color 140ms ease,
    transform 140ms ease,
    opacity 140ms ease;
}

button:not(:disabled):hover {
  background: #5f1716;
}

button:not(:disabled):active {
  transform: translateY(1px);
}

button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

button.secondary {
  background: #2b2b2b;
}

button.secondary:not(:disabled):hover {
  background: #1f1f1f;
}

.hint {
  color: #555;
  font-size: 13px;
  margin: 8px 0 0 0;
}

.mono {
  font-family:
    ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono',
    'Courier New', monospace;
}

iframe {
  width: 100%;
  height: 320px;
  min-height: 280px;
  border: 1px solid #eee;
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

label {
  display: block;
  font-size: 12px;
  color: #555;
  margin: 0 0 6px 0;
}

input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 10px 10px;
  font-size: 14px;
  transition:
    border-color 140ms ease,
    box-shadow 140ms ease;
}

/* Requested: remove visible focus styling (note: reduces keyboard accessibility) */
input:focus,
button:focus {
  outline: none;
  box-shadow: none;
}

input:hover {
  border-color: #cfcfcf;
}

@media (prefers-reduced-motion: reduce) {
  button,
  input {
    transition: none;
  }

  button:not(:disabled):active {
    transform: none;
  }
}

fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
}

legend {
  display: block;
  font-weight: 700;
  font-size: 14px;
  margin: 14px 0 6px 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.status {
  margin-top: 10px;
  font-size: 13px;
  color: #333;
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 12px;
  margin-top: 14px;
}

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