/* ------------------ Tipografia ------------------ */
html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    margin-bottom: 60px; /* espaço para footer */
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
}

.table td.description-cell {
    max-width: 300px; /* ajuste conforme desejar */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    table-layout: auto;
}


/* Títulos */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
}

    h1.display-4 {
        font-size: 2rem;
    }

@media (min-width: 768px) {
    h1.display-4 {
        font-size: 3rem;
    }

    .table td.description-cell {
        max-width: 70px; /* ajuste conforme desejar */
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        table-layout: auto;
    }
}

/* ------------------ Navbar ------------------ */
.navbar {
    padding: 0.5rem 1rem;
}

.navbar-text {
    font-size: 0.9rem;
}

@media (max-width: 576px) {
    .navbar {
        flex-direction: column;
        align-items: start;
    }
    #searchBox {
        max-width: 100%;
    }
    .navbar-text {
        margin-top: 0.5rem;
        text-align: left;
    }

    .table td.description-cell {
        max-width: 50px; /* ajuste conforme desejar */
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        table-layout: auto;
    }
}

/* ------------------ Botões ------------------ */
.btn {
    transition: all 0.2s ease;
}

.btn-sm {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus,
.form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

/* ------------------ Inputs ------------------ */
input.form-control, textarea.form-control {
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.form-floating > .form-control-plaintext::placeholder,
.form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder,
.form-floating > .form-control:focus::placeholder {
    text-align: start;
}

dl dd {
    word-wrap: break-word;
    word-break: break-word;
    white-space: normal;
}

/* ------------------ Barra de Pesquisa + Botão ------------------ */
#searchBox {
    max-width: 50%;
}

@media (max-width: 576px) {
    #searchBox {
        max-width: 100%;
    }

    input, textarea {
        font-size: 0.85rem;
        width: 100%;
    }
}

/* ------------------ Tabela ------------------ */
.table {
    font-size: 0.9rem;
}

    .table th, .table td {
        vertical-align: middle;
        padding: 0.5rem 0.75rem;
        word-wrap: break-word; 
        word-break: break-word; 
        white-space: normal;
    }

.table-responsive {
    overflow-x: auto;
}

@media (max-width: 576px) {
    .table th, .table td {
        font-size: 0.8rem;
        padding: 0.3rem 0.5rem;
    }

    input, textarea {
        font-size: 0.85rem;
        width: 100%;
    }
}

/* ------------------ Footer ------------------ */
footer {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 60px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
}

/* ------------------ Responsividade geral ------------------ */
/* Tablets e mobiles */
@media (max-width: 768px) {
    h1.display-4 {
        font-size: 2rem;
    }

    .table td.description-cell {
        max-width: 70px; /* ajuste conforme desejar */
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        table-layout: auto;
    }

    input, textarea {
        font-size: 0.85rem;
        width: 100%;
    }

    .d-flex.flex-md-row {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .gap-2 {
        gap: 0.5rem !important;
    }
}

/* Mobiles menores que 576px */
@media (max-width: 576px) {
    h1.display-4 {
        font-size: 1.5rem;
    }

    .btn-icon-only {
        padding: 0.25rem; /* reduz padding para deixar mais quadrado */
        width: auto; /* garante que o botão não estique */
        min-width: 0; /* remove largura mínima */
    }

    .table td.description-cell {
        max-width: 70px; /* ajuste conforme desejar */
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        table-layout: auto;
    }

    input, textarea {
        width: 100%;
        font-size: 0.8rem;
    }
}

