/* =========================================
   RESET BÁSICO
========================================= */

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

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background-color: #f8fafc;
  color: #1a1a1a;
  line-height: 1.6;
}

/* =========================================
   LAYOUT
========================================= */

main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

/* =========================================
   TOPBAR / NAV
========================================= */

.topbar {
  background: #ffffff;
  border-bottom: 1px solid #e5e7eb;
}

.topbar__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand {
  font-weight: 600;
  font-size: 1.2rem;
  text-decoration: none;
  color: #111827;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.nav a {
  text-decoration: none;
  color: #374151;
  font-size: 0.95rem;
}

.nav a:hover {
  color: #111827;
}

.nav__btnlink {
  background: #1f4ed8;
  color: #ffffff !important;
  padding: 0.42rem 0.8rem;
  border-radius: 6px;
  font-size: 0.9rem;
}

.nav__btnlink:hover {
  background: #1b3fb3;
}

.nav__btnlink--soft {
  background: #eef2ff;
  color: #1f4ed8 !important;
  border: 1px solid #c7d2fe;
}

.nav__btnlink--soft:hover {
  background: #e0e7ff;
}

.nav__form {
  display: inline;
  margin: 0;
}

.nav__btn {
  background: #ef4444;
  color: #ffffff;
  border: none;
  padding: 0.45rem 0.85rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
}

.nav__btn:hover {
  background: #dc2626;
}

.nav__badge {
  background: #e5e7eb;
  padding: 0.32rem 0.75rem;
  border-radius: 999px;
  font-size: 0.8rem;
  color: #374151;
}

/* =========================================
   MENSAJES
========================================= */

.messages {
  padding: 1rem;
}

.messages__inner {
  max-width: 1100px;
  margin: 0 auto;
}

.messages__list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.messages__item {
  padding: 0.75rem 1rem;
  border-radius: 6px;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

/* tipos de mensajes */

.messages__item--success {
  background-color: #dcfce7;
  color: #166534;
}

.messages__item--error {
  background-color: #fee2e2;
  color: #991b1b;
}

.messages__item--warning {
  background-color: #fef3c7;
  color: #92400e;
}

.messages__item--info {
  background-color: #e0f2fe;
  color: #075985;
}

/* =========================================
   FORMULARIOS
========================================= */

form {
  margin-top: 1rem;
}

form p {
  margin-bottom: 1rem;
}

input,
select,
textarea {
  width: 100%;
  padding: 0.6rem;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 0.9rem;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #1f4ed8;
}

button {
  background: #1f4ed8;
  color: #ffffff;
  border: none;
  padding: 0.6rem 1rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
}

button:hover {
  background: #1b3fb3;
}

/* =========================================
   FOOTER
========================================= */

.footer {
  border-top: 1px solid #e5e7eb;
  margin-top: 3rem;
  padding: 1.5rem 0;
  background: #ffffff;
}

.footer__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
  text-align: center;
  color: #6b7280;
  font-size: 0.85rem;
}