@keyframes blink {
  from, to { opacity: 1 }
  50% { opacity: 0; }
}

body {
  background-color: #fcfcfc;
  color: #333333;
  font-family: 'Inter', sans-serif;
  font-size: 1.1rem;
  line-height: 1.7;
  margin: 0;
  padding: 2rem 2rem 5rem 2rem;
}

#app-container {
  max-width: 65ch;
  margin: auto;
}

h1, h2 {
  margin: 0;
  font-weight: normal;
  font-size: 1em;
}

h1 {
  text-align: center;
  margin-bottom: 2rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

h2 {
  margin-bottom: 2rem;
  text-transform: capitalize;
}

p {
  margin: 0;
}

button {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
}

.interactive-word {
  color: #333333;
  text-decoration: none;
  transition: color 0.2s ease-in-out;
}

.interactive-word:hover {
  color: #0056b3;
  text-decoration: underline;
}

.footer-text {
  font-size: 0.9em;
  color: #888;
  margin: 0;
}

.footer-text a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease-in-out;
}

.footer-text a:hover {
  color: #0056b3;
  text-decoration: underline;
}

.ascii-art {
  font-family: monospace;
  text-align: left;
  white-space: pre;
  color: #888;
  margin: 2rem 0;
  line-height: 1.1;
  font-size: 0.8em;
}

.blinking-cursor {
  animation: blink 1s step-end infinite;
}

.search-container {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 3rem;
}

.search-form {
  flex-grow: 1;
}

.search-input {
  width: 100%;
  padding: 0.5rem 0.2rem;
  font: inherit;
  color: inherit;
  border: none;
  border-bottom: 2px solid #ccc;
  background-color: transparent;
  box-sizing: border-box;
  outline: none;
  transition: border-color 0.3s ease;
}

.search-input:focus {
  border-color: #0056b3;
}

.search-input:disabled {
  color: #ccc;
  border-color: #eee;
  cursor: not-allowed;
}

.search-input::placeholder {
  color: #999;
}

.random-button {
  background: none;
  border: none;
  padding: 0.5rem 0;
  font: inherit;
  font-weight: 500;
  color: #333;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.random-button:hover:not(:disabled) {
  color: #0056b3;
}

.random-button:disabled {
  color: #ccc;
  cursor: not-allowed;
}

.sticky-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  text-align: center;
  padding: 1.5rem 0;
  background-color: #fcfcfc;
  border-top: 1px solid #eee;
}

.error-box {
  border: 1px solid #cc0000;
  padding: 1rem;
  color: #cc0000;
}

.error-box .error-title {
  font-weight: 500;
}

.error-box .error-message {
  margin-top: 0.5rem;
}

.hidden {
  display: none;
}

.skeleton-bar {
    height: 1rem;
    background-color: #e0e0e0;
    margin-bottom: 0.75rem;
}

@media (max-width: 600px) {
  body {
    padding: 1.5rem;
    font-size: 1rem;
  }
  .sticky-footer {
    position: static;
    border-top: none;
    padding: 2rem 0 1rem 0;
  }
  .search-container {
    margin-bottom: 2rem;
  }
}
