body{
    margin: 0;
    display: flex;
    min-height: 100vh;
    min-width: 100vh;
}
.container {
    display: grid;
    grid-template-columns: 220px 1fr;   /* nav fijo, contenido ocupa el resto */
    grid-template-rows: auto 1fr;
    grid-template-areas:
        "t t"
        "n c";
    width: 100%;
    min-height: 100vh;
}
.top{
    grid-area: t;
    background: whitesmoke;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-right: 1rem;
    
}
.nav{
    
    background-color: rgb(14, 35, 55);
    grid-area: n;
    
}
.content{
    grid-area: c;
    background: gainsboro;
    padding: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-start;
    align-content: flex-start;
    justify-content: flex-start;
}
ul{
     list-style-type: none;
  margin: 0;
  padding: 0;
}
li:hover{
background-color: rgb(70,175,195);    
  
}
li a {
  display: block;
  color: rgb(216, 216, 216);
  padding: 8px 16px;
  text-decoration: none;
}
li a:hover{
    color: rgb(255, 255, 255);
}

.logo{
    width: 5rem;
}
.user{ 
    width: 3rem;

}

/* ====== ESTILO FORMULARIOS (insertar / editar) ====== */
/* Usamos ".content > form" (hijo directo) para NO afectar al formulario
   de filtros de bienes, que va dentro de .nav-bienes */

.content > form {
    background-color: #ffffff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    width: 100%;
    max-width: 600px;
    box-sizing: border-box;
}

.content > h2 {
    width: 100%;
    color: #111827;
    margin-bottom: 0.5rem;
}

.content > form h3 {
    margin-top: 0;
    margin-bottom: 1.2rem;
    color: #111827;
    border-bottom: 2px solid rgb(14, 35, 55);
    padding-bottom: 0.5rem;
}

.content > form h4 {
    margin-bottom: 0.75rem;
    color: #374151;
}

.content > form label {
    display: block;
    margin-bottom: 1rem;
    color: #374151;
    font-size: 0.95rem;
    font-weight: 500;
}

.content > form input[type="text"],
.content > form input[type="number"],
.content > form input[type="email"],
.content > form input[type="password"],
.content > form input[type="file"],
.content > form select {
    width: 100%;
    padding: 0.55rem 0.7rem;
    margin-top: 0.35rem;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    box-sizing: border-box;
    font-size: 0.95rem;
    background-color: #fff;
    font-family: inherit;
}

/* Resalte al hacer foco */
.content > form input:focus,
.content > form select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

/* Bloques de subtipo (vivienda, local, nave, solar) */
.content > form .tipo {
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 1rem 1.2rem;
    margin-bottom: 1.2rem;
    background-color: #f9fafb;
}

.content > form .tipo h4 {
    margin-top: 0;
}

/* Botones de enviar */
.content > form button,
.content > form input[type="submit"] {
    padding: 0.65rem 1.6rem;
    background-color: #3b82f6;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    margin-top: 0.5rem;
    transition: background-color 0.2s ease;
}

.content > form button:hover,
.content > form input[type="submit"]:hover {
    background-color: #2563eb;
}

/* Enlace "Cancelar" junto al botón */
.content > form a {
    color: #6b7280;
    text-decoration: none;
    font-size: 0.95rem;
}

.content > form a:hover {
    color: #374151;
    text-decoration: underline;
}
/* ====== ESTILO TABLA DE CLIENTES ====== */

.tabla-clientes {
  width: 100%;
  border-collapse: collapse;
  border-radius: 8px;
  overflow: hidden;
  font-family: Arial, sans-serif;
  background-color: #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.tabla-clientes thead {
  background-color: #3b82f6; /* azul tipo Tailwind */
  color: white;
}

.tabla-clientes th,
.tabla-clientes td {
  text-align: left;
  padding: 12px 15px;
  font-size: 15px;
}
s
.tabla-clientes th {
  font-weight: bold;
}

.tabla-clientes tbody tr:nth-child(even) {
  background-color: #f8fafc; /* gris muy claro para filas alternas */
}

.tabla-clientes tbody tr:hover {
  background-color: #e0f2fe; /* celeste suave al pasar el ratón */
  transition: background-color 0.2s ease;
}

.tabla-clientes td {
  border-top: 1px solid #e5e7eb;
}

/* ====== ESTILO BIENES ====== */
.div-bien {
    border: 1px solid black;
    border-radius: 7px;
    background-color: whitesmoke;
    flex: 1 1 18rem;        /* <-- crece para rellenar la fila, mínimo 18rem */
    max-width: 24rem;       /* <-- (opcional) tope para que no se hagan gigantes */
    box-sizing: border-box;
    padding: 1rem;
    height: fit-content;
    overflow: hidden;
}
.preview-bien{
    width: 100%;
    height: 12rem;
    border-radius: 5px;
    object-fit: cover;
    display: block;
}
.detalles-bien{
    width: 100%;
    padding: 0.5rem;
    background-color: #3b82f6;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
}
/* ====== ESTILO NAV BIENES ====== */
.nav-bienes{
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    width: 100%;
}
.filtro-bienes, .añadir-bien{
    padding: 0.5rem 1rem;
    background-color: #3b82f6;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    
    ;
}
.filtro-bienes:hover, .añadir-bien:hover{
    background-color: #2563eb;
}
/* ====== ESTILO LOGIN ====== */
.login-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    background-color: #f3f4f6; /* gris claro */
    width: 100%;
}
.login-form {
    background-color: #ffffff; /* blanco */
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    width: 300px;
}
.login-form h2 {
    margin-bottom: 1.5rem;
    color: #111827; /* gris oscuro */
    text-align: center;
}
.login-form label {
    display: block;
    margin-bottom: 0.5rem;
    color: #374151; /* gris medio */
}
.login-form input {
    width: 100%;
    padding: 0.5rem;
    margin-bottom: 1rem;
    border: 1px solid #d1d5db; /* gris claro */
    border-radius: 4px;
    box-sizing: border-box;
}
.login-form button {
    width: 100%;
    padding: 0.75rem;
    background-color: #3b82f6; /* azul tipo Tailwind */
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
}
.login-form button:hover {
    background-color: #2563eb; /* azul más oscuro al pasar el ratón */
}

/* ====== DETALLES BIEN ====== */
.detalleBien-wrap {
      max-width: 100%;
      margin: 20px auto;
      padding: 0 16px;
    }

    .detalleBien-breadcrumbs {
      margin-bottom: 20px;
      border: 1px dashed #ccc;
      padding: 10px;
    }

    .detalleBien-hero {
      display: flex;
      gap: 20px;
      margin-bottom: 20px;
    }

    .detalleBien-hero img {
      width: 48%;
      height: 280px;
      border: 1px solid #bbb;
      object-fit: cover;
    }

    .detalleBien-hero-info {
      flex: 1;
      border: 1px solid #bbb;
      padding: 15px;
    }

    .detalleBien-grid {
      display: grid;
      grid-template-columns: 2fr 1fr;
      gap: 20px;
      margin-bottom: 20px;
    }

    .card-detalleBien {
      border: 1px solid #bbb;
      padding: 15px;
      background: #fff;
    }

    .card-detalleBien-subtipo {
      border: 1px solid #bbb;
      padding: 15px;
      margin-top: 20px;
      background: #fff;
    }

    .detalleBien-placeholder {
      color: #555;
      font-style: italic;
    }
    
    /* ====== PERFIL DE USUARIO ====== */
.perfil-card {
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 2rem;
    width: 100%;
    max-width: 480px;
    box-sizing: border-box;
}

.perfil-header {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 1.2rem;
    margin-bottom: 1.2rem;
}

.perfil-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background-color: #3b82f6;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: bold;
    flex-shrink: 0;
}

.perfil-nombre {
    margin: 0 0 0.35rem 0;
    font-size: 1.4rem;
    color: #111827;
}

.perfil-rol {
    display: inline-block;
    background-color: #e0f2fe;
    color: #0369a1;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.2rem 0.7rem;
    border-radius: 999px;
}

.perfil-datos {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    margin-bottom: 1.5rem;
}

.perfil-dato {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.95rem;
}

.perfil-label {
    color: #6b7280;
    font-weight: 500;
}

.perfil-valor {
    color: #111827;
    text-align: right;
}

.perfil-acciones {
    display: flex;
    justify-content: flex-end;
}

.perfil-btn-secundario {
    padding: 0.55rem 1.3rem;
    background-color: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.95rem;
    transition: background-color 0.2s ease;
}

.perfil-btn-secundario:hover {
    background-color: #e5e7eb;
}

/* ====== AVATAR DE LA BARRA SUPERIOR ====== */
.user-avatar {
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background-color: #3b82f6;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.1rem;
    text-decoration: none;
    cursor: pointer;
    flex-shrink: 0;
}
.user-avatar:hover {
    background-color: #2563eb;
}

/* Filtros vista cliente */
.filtros-clientes {
    display: flex;
    flex-wrap: nowrap;
    gap: 12px;
    align-items: flex-end;
    flex: 1 1 100%;             /* fuerza ancho completo dentro del .content flex */
    box-sizing: border-box;
    margin: 16px 0;
    padding: 12px 16px;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 8px;
}

.filtros-clientes label {
    display: flex;
    flex-direction: column;
    font-size: 0.9rem;
    gap: 4px;
    
}

.filtros-clientes select {
    padding: 6px 8px;
}

.filtros-clientes button,
.filtros-clientes .limpiar-filtros,
.filtros-clientes .boton-añadir-cli {
    padding: 7px 14px;
    text-decoration: none;
    white-space: nowrap;
}

/* Barra de filtros de bienes (recuadro completo) */
.nav-bienes {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 14px;
    margin: 16px 0;
    padding: 14px 18px;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 8px;
}

.form-filtros {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 14px;
}

.form-filtros label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.9rem;
    color: #333;
}

.form-filtros select,
.form-filtros input {
    padding: 7px 9px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 0.9rem;
    background: #fff;
}

/* Botón Filtrar (es un <button>) */
.form-filtros button.filtro-bienes {
    padding: 8px 16px;
    border: none;
    border-radius: 5px;
    background: #2563eb;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
}

.form-filtros button.filtro-bienes:hover {
    background: #1d4ed8;
}

/* Enlace Limpiar (es un <a> con la misma clase) */
.form-filtros a.filtro-bienes {
    padding: 8px 14px;
    text-decoration: none;
    color: #555;
}

.form-filtros a.filtro-bienes:hover {
    text-decoration: underline;
}

/* Botón Añadir Propiedad, empujado a la derecha del recuadro */
.añadir-bien {
    margin-left: auto;
    padding: 0;
    border: none;
    border-radius: 5px;
    background: #16a34a;
    cursor: pointer;
}

.añadir-bien a {
    display: inline-block;
    padding: 9px 16px;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
}

.añadir-bien:hover {
    background: #15803d;
}

.galeria-bien {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    margin-top: 16px;
}
.galeria-bien img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #ddd;
}

/* Miniaturas en el formulario de editar */
.fotos-actuales {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    margin: 10px 0 20px;
    max-width: 40%
}
.fotos-actuales .foto-item {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 6px;
    text-align: center;
}
.fotos-actuales .foto-item img {
    width: 100%;
    height: 110px;
    object-fit: cover;
    border-radius: 5px;
}
.fotos-actuales .foto-item label {
    display: block;
    font-size: 0.85rem;
    margin-top: 4px;
    color: #b91c1c;
}

#resultadoBienes {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-content: flex-start;
    width: 100%;
}

/* ====== LANDING PAGE (index.html) ====== */
body.landing {
    flex-direction: column;
    background-color: #f3f4f6;
    font-family: Arial, sans-serif;
}

.landing-header {
    background-color: rgb(14, 35, 55);
    display: flex;
    align-items: center;
    padding: 0.75rem 2rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.landing-header img {
    width: 5rem;
}
.landing-header span {
    color: #d1d5db;
    font-size: 1.25rem;
    font-weight: bold;
    margin-left: 1rem;
    letter-spacing: 0.03em;
}

.landing-hero {
    background: linear-gradient(135deg, rgb(14, 35, 55) 0%, #1e4d8c 100%);
    color: #fff;
    padding: 5rem 2rem 4rem;
    text-align: center;
    flex-shrink: 0;
}
.landing-hero h1 {
    font-size: 2.6rem;
    margin: 0 0 1rem;
    letter-spacing: 0.02em;
}
.landing-hero h1 span {
    color: #60a5fa;
}
.landing-hero p {
    font-size: 1.15rem;
    color: #cbd5e1;
    max-width: 600px;
    margin: 0 auto 2.5rem;
    line-height: 1.7;
}
.btn-hero {
    display: inline-block;
    padding: 0.85rem 2.5rem;
    background-color: #3b82f6;
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: bold;
    transition: background-color 0.2s ease, transform 0.15s ease;
    box-shadow: 0 4px 14px rgba(59,130,246,0.4);
}
.btn-hero:hover {
    background-color: #2563eb;
    transform: translateY(-2px);
}

.landing-features {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    padding: 3.5rem 2rem;
    background-color: #f3f4f6;
}
.feature-card {
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    padding: 1.8rem 1.6rem;
    width: 220px;
    text-align: center;
    flex-shrink: 0;
}
.feature-icon {
    font-size: 2.4rem;
    margin-bottom: 0.8rem;
}
.feature-card h3 {
    margin: 0 0 0.5rem;
    color: rgb(14, 35, 55);
    font-size: 1.05rem;
}
.feature-card p {
    color: #6b7280;
    font-size: 0.9rem;
    line-height: 1.55;
    margin: 0;
}

.landing-login-section {
    background-color: gainsboro;
    padding: 3.5rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.landing-login-section h2 {
    color: rgb(14, 35, 55);
    margin: 0 0 0.5rem;
    font-size: 1.6rem;
}
.landing-login-section p {
    color: #6b7280;
    margin: 0 0 2rem;
    font-size: 0.98rem;
}
.login-card {
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    padding: 2.5rem 2rem;
    width: 300px;
    text-align: center;
}
.login-card .login-card-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}
.login-card p {
    color: #374151;
    font-size: 0.95rem;
    margin: 0 0 1.5rem;
    line-height: 1.55;
}
.btn-login {
    display: block;
    width: 100%;
    padding: 0.75rem;
    background-color: #3b82f6;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: bold;
    text-decoration: none;
    cursor: pointer;
    box-sizing: border-box;
    transition: background-color 0.2s ease;
}
.btn-login:hover {
    background-color: #2563eb;
}

.landing-footer {
    margin-top: auto;
    background-color: rgb(14, 35, 55);
    color: #9ca3af;
    text-align: center;
    padding: 1.2rem;
    font-size: 0.85rem;
}