:root {
    --radius: 0.5rem;
    --background: oklch(1.000 0.000 0);
    --foreground: oklch(0.143 0.005 312.890439846176);
    --card: oklch(1.000 0.000 0);
    --card-foreground: oklch(0.143 0.005 312.890439846176);
    --popover: oklch(1.000 0.000 0);
    --popover-foreground: oklch(0.143 0.005 312.890439846176);
    --primary: oklch(0.461 0.234 304.99687744404105);
    --primary-foreground: oklch(0.960 0.004 312.95886325975704);
    --secondary: oklch(0.817 0.041 312.64479899702224);
    --secondary-foreground: oklch(0.203 0.027 312.05700138768356);
    --muted: oklch(0.817 0.041 312.64479899702224);
    --muted-foreground: oklch(0.465 0.086 311.6729331601396);
    --accent: oklch(0.697 0.206 332.2689691118396);
    --accent-foreground: oklch(0.213 0.074 332.8550035168933);
    --destructive: oklch(0.580 0.237 28.43022926835137);
    --border: oklch(0.922 0.003 17.208294632015928);
    --input: oklch(0.922 0.003 17.208294632015928);
    --ring: oklch(0.461 0.234 304.99687744404105);
    --chart-1: oklch(0.461 0.234 304.99687744404105);
    --chart-2: oklch(0.564 0.248 308.0815381775703);
    --chart-3: oklch(0.650 0.170 310.97428841585173);
    --chart-4: oklch(0.337 0.168 305.8265200904588);
    --chart-5: oklch(0.289 0.138 306.8885353830982);
    --sidebar: oklch(0.817 0.041 312.64479899702224);
    --sidebar-foreground: oklch(0.203 0.027 312.05700138768356);
    --sidebar-primary: oklch(0.461 0.234 304.99687744404105);
    --sidebar-primary-foreground: oklch(0.960 0.004 312.95886325975704);
    --sidebar-accent: oklch(0.697 0.206 332.2689691118396);
    --sidebar-accent-foreground: oklch(0.213 0.074 332.8550035168933);
    --sidebar-border: oklch(0.922 0.003 17.208294632015928);
    --sidebar-ring: oklch(0.461 0.234 304.99687744404105);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    background-color: var(--background);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.main-container {
    background: var(--card);
    border-radius: 12px;
    border: 1px solid var(--border);
    width: 100%;
    height: 450px;
    max-width: 450px;
    display: flex;
    flex-direction: column;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 1px 3px 0px, rgba(0, 0, 0, 0.06) 0px 1px 2px 0px;
}

.header {
    padding: 20px;
    color: white;
    text-align: center;
    border-top-left-radius: var(--border-radius);
    border-top-right-radius: var(--border-radius);
}

.header__title {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--foreground);
}

.span-header {
    color: var(--primary);
}

.p-header {
    color: var(--muted-foreground);
    margin-top: 4px;
}

/* Abas */
.tab-container {
    display: flex;
    border-bottom: 1px solid var(--border-color);
    padding: 0 25px;
}

.tab-button {
    flex: 1;
    padding: 7px 4px;
    background-color: transparent;
    cursor: pointer;
    font-size: .9rem;
    color: var(--foreground);
    position: relative;
    width: 150px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    margin: 0 5px 10px 5px;
}

.tab-button.active {
    border-color: var(--primary);
}

.tab-button.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
}

/* Conteúdo das Abas */
.tab-content {
    padding: 25px;
    display: none;
}

.tab-content.active {
    display: block;
}

.p-cep {
    color: var(--foreground);
    font-weight: 500;
}

.source-info {
    color: var(--muted-foreground);
    font-size: 12px;
    margin-bottom: 3rem;
}

.source-info a {
    text-decoration: none;
    color: var(--foreground);
}

.upload-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Área de Drop */
.drop-zone {
    border: 2px dashed var(--border);
    border-radius: var(--radius);
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.drop-zone:hover {
    border-color: var(--primary);
}

.drop-zone__icon {
    font-size: 2.3rem;
    color: var(--primary);
}

.drop-zone__text {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--foreground);
}

.p-formato {
    font-weight: 400;
}

.drop-zone__cta {
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: underline;
}

.drop-zone__input {
    display: none;
}

.drop-zone__filename {
    background-color: var(--muted);
    color: var(--foreground);
    padding: 0px;
    border-radius: 5px;
    font-size: 0.8rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

/* Botão de Ação (CTA) */
.cta-button {
    background-color: var(--primary);
    color: var(--primary-foreground);
    border: none;
    padding: 12px;
    border-radius: var(--radius);
    font-size: .9rem;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    width: 100%;
}

.cta-button:hover {
    background-color:
        color-mix(in oklab, var(--primary) 90%, transparent);
}

/* Seção de CEP */
.search-group {
    margin-bottom: 20px;
    display: flex;
    gap: 10px;
    align-items: center;
}

.search-input-container {
    position: relative;
    flex: 1;
}

.search-input {
    width: 100%;
    padding: 10px 12px 10px 40px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary);
}

.search-icon {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--light-text-color);
}

.search-button {
    width: auto;
    padding: 12px 20px;
}

.separator {
    text-align: center;
    color: var(--muted);
    font-size: 0.9rem;
    margin: -5px 0 20px 0;
    position: relative;
}

.separator::before,
.separator::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40%;
    height: 1px;
    background-color: var(--muted);
}

.separator::before {
    left: 0;
}

.separator::after {
    right: 0;
}

/* Resultado */
.result-box {
    background-color: var(--muted);
    padding: 20px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    margin-top: 75px;
}

.result-box__title {
    font-size: 1rem;
    color: var(--foreground);
    margin-bottom: 10px;
    padding-bottom: 5px;
}

.result-box__content {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--muted-foreground);
}

.result-box__content ul {
    margin-left: 20px;
}

/* Autocomplete */
.autocomplete-items {
    position: absolute;
    border: 1px solid var(--border);
    background-color: #fff;
    z-index: 99;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 150px;
    overflow-y: auto;
    border-top: none;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.autocomplete-items div {
    padding: 12px;
    cursor: pointer;
    border-bottom: 1px solid var(--border-color);
    transition: background-color 0.2s ease;
    color: var(--text-color);
}

.autocomplete-items div:last-child {
    border-bottom: none;
}

.autocomplete-items div:hover,
.autocomplete-active {
    background-color: #f1f1f1;
}

.autocomplete-active {
    background-color: var(--primary-color) !important;
    color: white !important;
}

@media (max-width: 480px) {
    .main-container {
        width: 100%;
        margin: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .header,
    .tab-content {
        padding: 15px;
    }
}

/* Estilização do selecionar_pacientes.php */

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 25px;
    background: var(--card);
    border-radius: 12px;
    border: 1px solid var(--border);
    width: 100%;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 1px 3px 0px, rgba(0, 0, 0, 0.06) 0px 1px 2px 0px;
}

.info-header {
    background-color: var(--muted);
    padding: 15px;
    border-radius: 5px;
    margin: 20px 0;
}

.info-header p {
    margin: 5px 0;
    font-size: 16px;
    color: var(--chart-5);
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    border-radius: var(--border-radius);
}

th, td {
    border: 1px solid var(--border);
    padding: 8px;
    text-align: left;
    color: var(--muted-foreground);
}

th {
    background-color: color-mix(in oklab,var(--muted)40%,transparent);
}

.actions {
    margin-top: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.actions button {
    padding: 10px 15px;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--background);
    cursor: pointer;
    transition: all .3s;
}

.btn-voltar {
    padding: 10px 15px;
    color: var(--muted-foreground);
    background-color: transparent;
    border: 1px solid var(--border);
    border-radius: 12px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    margin-bottom: 10px;
    transition: all .3s;
}

.btn-voltar:hover {
    background-color:
        color-mix(in oklab, var(--secondary) 50%, transparent);
}

#selecionarTodos {
    background-color: #007bff;
}
#selecionarTodos:hover {
    background-color: #1385ff;
}

#confirmarEnvio {
    background-color: #28a745;
}
#confirmarEnvio:hover {
    background-color: #39ac54;
}

#cancelarEnvio {
    background-color: #dc3545;
}
#cancelarEnvio:hover {
    background-color: #e64857;
}

#remarcarEnvio {
    background-color: #daa509;
}
#remarcarEnvio:hover {
    background-color: #e3b429;
}

.button-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.span-paciente {
    color: var(--primary);
}