:root {
  --bg: #f9f9f9;
  --card: #ffffff;
  --primary: #007bff;
  --primary-hover: #0056b3;
  --input-border: #ccc;
  --focus-shadow: rgba(0, 123, 255, 0.25);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  padding: 2rem;
  min-height: 100vh;
  margin: 0;
  font-family: 'Segoe UI', Tahoma, sans-serif;
  background: var(--bg);
  color: #333;
  text-align: center;
}

.container {
  background: var(--card);
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  max-width: 800px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

.info-container {
  margin-top: 2.5rem;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
  padding: 1.75rem 2rem;
  max-width: 800px;
  width: 100%;
  color: #444;
  font-size: 1rem;
  line-height: 1.5;
  margin-left: auto;
  margin-right: auto;
}

h1 {
  font-size: 1.75rem;
  text-align: center;
  margin-bottom: 1.5rem;
}

label {
  font-weight: 600;
  display: block;
  margin-top: 1rem;
}

input {
  width: 100%;
  padding: 0.75rem;
  margin-top: 0.3rem;
  border-radius: 4px;
  border: 1px solid var(--input-border);
  font-size: 1rem;
}

input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--focus-shadow);
}

button {
  margin-top: 1.5rem;
  width: 100%;
  padding: 0.75rem;
  font-weight: 700;
  font-size: 1.1rem;
  color: white;
  background-color: var(--primary);
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.25s ease;
}

button:hover {
  background-color: var(--primary-hover);
}

#results {
  margin-top: 2rem;
}

.output-block {
  margin-bottom: 1.5rem;
  position: relative;
}

.output-block strong {
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 700;
}

/* Flex container for code/textarea + button */
.copy-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.3rem;
}

.copy-row code,
.copy-row textarea {
  flex: 1;
  margin: 0;
  font-family: monospace;
  background: #f4f4f4;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 0.5rem;
  font-size: 0.9rem;
  box-sizing: border-box;
  resize: vertical;
  white-space: pre-wrap;
  overflow-wrap: break-word;
}

.copy-row code {
  /* code usually single line, prevent overflow */
  overflow-x: auto;
}

.copy-btn.small {
  flex: 0 0 70px;               /* fixed width */
  padding: 0.35rem 0.8rem;
  font-size: 0.85rem;
  background-color: #0056b3;    /* strong blue */
  color: #fff;                  /* white text */
  border: 1px solid #004494;    /* darker blue border */
  border-radius: 4px;
  cursor: pointer;
  white-space: nowrap;
  height: fit-content;
  box-shadow: 0 2px 6px rgba(0, 86, 179, 0.4);
  transition: background-color 0.25s ease, box-shadow 0.25s ease;
}

.copy-btn.small:hover {
  background-color: #003d82;    /* even darker on hover */
  box-shadow: 0 4px 12px rgba(0, 61, 130, 0.6);
}

.clickable a {
  color: var(--primary);
  font-weight: 500;
  text-decoration: none;
}

.clickable a:hover {
  text-decoration: underline;
}

.error {
  color: red;
  font-weight: bold;
  margin-top: 1rem;
}

.info-container h2 {
  margin-bottom: 1rem;
  font-weight: 700;
  color: #222;
  font-size: 1.5rem;
}

.info-container p {
  margin-bottom: 1rem;
}

.info-container ol {
  padding-left: 1.3rem;
  margin-top: 0.5rem;
  margin-bottom: 1rem;
}

.info-container li {
  margin-bottom: 0.5rem;
}