* {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: linear-gradient(135deg, #2d5016 0%, #4a7c23 50%, #3d6b1a 100%);
  min-height: 100vh;
  margin: 0;
  padding: 20px;
}

.container {
  max-width: 600px;
  margin: 0 auto;
  background: #f5e6c8;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  border: 4px solid #8b4513;
}

h1 {
  margin: 0 0 8px;
  color: #2d5016;
  font-size: 28px;
  text-align: center;
}

.dino {
  font-size: 32px;
}

.subtitle {
  text-align: center;
  color: #5a3d1a;
  margin: 0 0 24px;
  font-style: italic;
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

li {
  display: flex;
  align-items: center;
  padding: 16px;
  border-bottom: 2px dashed #c4a574;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

li:last-child {
  border-bottom: none;
}

li.fading {
  opacity: 0;
  transform: scale(0.8);
}

.item-dino {
  font-size: 24px;
  margin-right: 12px;
}

a {
  color: #2d5016;
  text-decoration: none;
  flex: 1;
  margin-right: 16px;
  font-weight: 500;
}

a:hover {
  text-decoration: underline;
  color: #1a3009;
}

button {
  background: linear-gradient(180deg, #e85d04 0%, #c44200 100%);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 20px;
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  transition: transform 0.1s ease;
}

button:hover {
  transform: scale(1.05);
  background: linear-gradient(180deg, #f97316 0%, #e85d04 100%);
}

button:active {
  transform: scale(0.95);
}

.hidden {
  display: none;
}

#empty-message {
  text-align: center;
  color: #5a3d1a;
  padding: 24px;
  font-size: 18px;
}

.footer-dino {
  text-align: center;
  font-size: 48px;
  margin-top: 24px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.add-link {
  display: block;
  text-align: center;
  color: rgba(255, 255, 255, 0.3);
  font-size: 24px;
  text-decoration: none;
  margin-top: 16px;
  transition: color 0.2s ease;
}

.add-link:hover {
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
}

/* Modal */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal.hidden {
  display: none;
}

.modal-content {
  background: #f5e6c8;
  border-radius: 12px;
  padding: 24px;
  width: 90%;
  max-width: 400px;
  border: 4px solid #8b4513;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 16px;
  font-size: 28px;
  color: #5a3d1a;
  cursor: pointer;
}

.modal-close:hover {
  color: #2d5016;
}

.modal-content h2 {
  margin: 0 0 16px;
  color: #2d5016;
  text-align: center;
}

.modal-content input,
.modal-content textarea {
  width: 100%;
  padding: 12px;
  margin-bottom: 12px;
  border: 2px solid #c4a574;
  border-radius: 8px;
  font-size: 16px;
  font-family: inherit;
}

.modal-content textarea {
  height: 100px;
  resize: vertical;
}

.modal-content input:focus,
.modal-content textarea:focus {
  outline: none;
  border-color: #2d5016;
}

#modal-submit {
  width: 100%;
  margin-top: 8px;
}

#modal-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.modal-error {
  color: #c44200;
  text-align: center;
  margin: 12px 0 0;
  font-size: 14px;
}

/* Confirm Modal */
.confirm-modal-content {
  text-align: center;
}

.confirm-modal-content h2 {
  margin-bottom: 12px;
}

#confirm-item-name {
  font-weight: bold;
  color: #2d5016;
  margin: 0 0 8px;
  font-size: 16px;
}

.confirm-text {
  color: #5a3d1a;
  margin: 0 0 20px;
}

.confirm-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.confirm-cancel {
  background: #888;
  padding: 10px 24px;
}

.confirm-cancel:hover {
  background: #666;
  transform: none;
}

.confirm-yes {
  padding: 10px 24px;
}

/* Mobile styles */
@media (max-width: 480px) {
  body {
    padding: 12px;
  }

  .container {
    padding: 16px;
    border-radius: 8px;
    border-width: 3px;
  }

  h1 {
    font-size: 22px;
  }

  .dino {
    font-size: 26px;
  }

  .subtitle {
    font-size: 14px;
    margin-bottom: 16px;
  }

  li {
    flex-direction: column;
    align-items: flex-start;
    padding: 12px;
    gap: 10px;
  }

  .item-dino {
    display: none;
  }

  a {
    margin-right: 0;
    font-size: 15px;
    line-height: 1.4;
  }

  button {
    padding: 8px 16px;
    font-size: 12px;
    align-self: flex-end;
  }

  .footer-dino {
    font-size: 36px;
    margin-top: 16px;
  }

  .modal-content {
    padding: 16px;
    width: 95%;
  }
}
