/* =========================================================
   FEDEPAPA - FORMULARIO DE TELEMEDICINA FAMILIAR
   ========================================================= */

:root {
    --blue: #0758b8;
    --blue-dark: #002b59;
    --blue-light: #eef6ff;
    --green: #0a8f43;
    --green-light: #e8f7ee;
    --text: #102d52;
    --muted: #53647a;
    --border: #e7edf5;
    --white: #ffffff;
    --bg: #f5f9fd;
    --shadow: 0 5px 20px rgba(20, 48, 86, .06);
    --radius: 12px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- HEADER Y NAVEGACIÓN --- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 2000;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}

.nav-wrapper {
    min-height: 74px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.brand {
    display: flex;
    align-items: center;
}

.brand img,
.brand-logo {
    width: 145px !important;
    max-width: 145px !important;
    height: 42px !important;
    max-height: 42px !important;
    object-fit: contain !important;
    display: block !important;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 18px;
}

.main-nav a {
    font-size: 13px;
    font-weight: 500;
    color: var(--text);
    padding: 8px 0;
    position: relative;
    white-space: nowrap;
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--blue);
}

.main-nav a.active::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--blue);
    border-radius: 2px;
}

/* BOTONES */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 13px;
    font-weight: 700;
    border-radius: 6px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all .2s ease;
    white-space: nowrap;
}

.btn-header {
    padding: 9px 16px;
    font-size: 12px;
    flex: none;
}

.btn-whatsapp {
    background: var(--green);
    color: var(--white);
}

.btn-primary {
    background: var(--blue);
    color: var(--white);
}

/* ESTRUCTURA Y FORMULARIO */
.page-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 24px;
    padding: 30px 20px;
}

.card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: var(--shadow);
}

.section-heading {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 20px;
}

.heading-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: var(--blue-light);
    color: var(--blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex: none;
}

.section-heading h3 {
    font-size: 16px;
    color: var(--blue-dark);
}

.section-heading p {
    font-size: 12px;
    color: var(--muted);
}

.form-grid {
    display: grid;
    gap: 16px;
}

.form-grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.field label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--blue-dark);
}

.field em {
    color: #e22;
    font-style: normal;
}

input, select {
    width: 100%;
    height: 42px;
    border: 1px solid #cdd9e6;
    border-radius: 6px;
    padding: 0 12px;
    font-size: 13px;
    outline: none;
    background: var(--white);
}

.is-hidden {
    display: none !important;
}

/* --- FOOTER IDENTICO AL INDEX --- */
.site-footer {
    background: var(--white);
    border-top: 1px solid var(--border);
    padding: 40px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.footer-brand p {
    font-size: 12px;
    color: var(--muted);
    margin-top: 10px;
    line-height: 1.5;
}

.site-footer h3 {
    font-size: 13px;
    color: var(--blue-dark);
    margin-bottom: 12px;
    font-weight: 700;
}

.site-footer div > a {
    display: block;
    font-size: 12px;
    color: var(--muted);
    margin-bottom: 8px;
}

.socials {
    display: flex !important;
    flex-direction: row !important;
    gap: 10px !important;
}

.socials a {
    display: flex !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    background: var(--blue-light) !important;
    color: var(--blue) !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 13px !important;
    margin-bottom: 0 !important;
}

.copyright {
    text-align: center;
    font-size: 11px;
    color: var(--muted);
    border-top: 1px solid var(--border);
    padding-top: 20px;
}

@media (max-width: 900px) {
    .page-shell { grid-template-columns: 1fr; }
    .sidebar { display: none; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 750px) {
    .form-grid.three { grid-template-columns: 1fr; }
}