/* General */
body {
  margin: 0;
  font-family: 'Segoe UI', sans-serif;
  background:#332f2e;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 40px 20px;
}

/* Logo */
.logo {
  display: block;
  margin: 0 auto 20px auto;
  width: 100px;
}

/* Contenedor principal */
.container {
  background: white;
  border-radius: 15px;
  padding: 30px;
  max-width: 1200px;
  width: 1200px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

/* Encabezado */
h1 {
  text-align: center;
  margin-bottom: 20px;
  font-size:16px;
}

a {
  text-decoration: none;
}

/* Formulario */
.form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 20px;
}

input[type="text"],
input[type="url"],
.search-box {
  padding: 10px;
  font-size: 16px;
  width: 250px;
  border-radius: 6px;
  border: 1px solid #ccc;
}

button,
.btn {
  padding: 10px 14px;
  margin:4px;
  font-weight: bold;
  font-size: 15px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  text-align: center;
}

/* Botones de colores */
.btn-primary { background-color: #007bff; color: white; }
.btn-success { background-color: #28a745; color: white; }
.btn-warning { background-color: #ffc107; color: black; }
.btn-danger  { background-color: #dc3545; color: white; }
.btn-secondary { background-color: #6c757d; color: white; }

/* Tabla */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
  background: #fff;
}

th, td {
  padding: 10px;
  text-align: left;
  border-bottom: 1px solid #ddd;
}

thead {
  background-color: #f9c480;
  color: #332f2e;
}

img {
  max-width: 100%;
}

/* Responsive */
@media screen and (max-width: 868px) {

  /* Formulario vertical */
  .form {
    flex-direction: column;
    align-items: center;
  }

  .form input,
  .form button,
  .search-box {
    width: 100%;
  }

  /* Tabla como tarjetas */
  table thead {
    display: none;
  }

  table, tbody, tr, td {
    display: block;
    width: 100%;
  }

  tr {
    margin-bottom: 20px;
    border: 1px solid #ccc;
    border-radius: 10px;
    padding: 10px;
    background: #fff;
  }

  td {
    padding: 10px 5px;
    position: relative;
    text-align: left;
  }

  td::before {
    content: attr(data-label);
    font-weight: bold;
    display: block;
    margin-bottom: 5px;
    color: #333;
  }

  /* Botones de acciones mejor distribuidos */
  td[data-label="Acciones"] {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-start;
    margin-top: 10px;
  }

  td[data-label="Acciones"] .btn {
    flex: 1 1 45%;
    font-size: 14px;
    padding: 10px;
  }
}
