body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: #d4d3d2;
    color: #222;
    position: relative;
    min-height: 100vh;
}

body::before {
    content: "";
    position: fixed;
    top: 50%;
    left: 50%;
    width: 500px;
    height: 500px;

    background-image: url("/static/Imagen_EstudioJuridico.jpeg");
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;

    transform: translate(-50%, -50%);

    opacity: 0.25;

    pointer-events: none;
    z-index: 0;
}
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar-logo {
    width: 42px;
    height: 42px;
    object-fit: contain;
    border-radius: 4px;
}

.navbar-brand a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    margin-right: 0;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 32px;
    background: #55575a;
}

.navbar a {
    color: white;
    text-decoration: none;
    margin-right: 16px;
}

.container {
    max-width: 1200px;
    margin: 32px auto;
    padding: 0 20px;
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0,0,0,.08);
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.button, button {
    display: inline-block;
    padding: 10px 16px;
    border: 0;
    border-radius: 5px;
    background: #747576;
    color: white;
    text-decoration: none;
    cursor: pointer;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    margin-top: 20px;
}

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

form {
    max-width: 600px;
    background: white;
    padding: 24px;
}

label, input, select,textarea  {
    display: block;
    width: 100%;
    box-sizing: border-box;
}

label {
    margin-top: 14px;
    margin-bottom: 5px;
}

input, select,textarea  {
    padding: 9px;
}

/* Acciones compactas de tablas */
.table-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.table-actions a,
.table-actions button {
    font-size: 13px;
    padding: 4px 8px;
    white-space: nowrap;
}

.table-actions form {
    margin: 0;
}

/* =========================================================
   RESPONSIVE - CELULARES
   ========================================================= */

@media (max-width: 768px) {

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

    .navbar a {
        margin-right: 10px;
        display: inline-block;
    }
      .navbar-brand {
        width: 100%;
    }

    .navbar-logo {
        width: 36px;
        height: 36px;
    }

    .container {
        width: auto;
        margin: 20px auto;
        padding: 0 12px;
    }

    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .cards {
        grid-template-columns: 1fr;
    }

    .card {
        padding: 16px;
    }

    form {
        max-width: none;
        width: 100%;
        box-sizing: border-box;
        padding: 18px;
    }

    input,
    select,
    textarea {
        font-size: 16px;
    }

    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    .table-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .table-actions a,
    .table-actions button {
        text-align: center;
    }

    body::before {
        width: 300px;
        height: 300px;
        opacity: 0.06;
    }
}