/* Sun City Health — estilos principales
 * Marca: azul #294B77, amarillo #F7B801, gris #EFF1F3, blanco; naranja #FEA532 y melocotón #FEC57B.
 * Breakpoints: sm 640px · md 768px · lg 1024px
 */

/* ---------- Tokens ---------- */
:root {
    --radius: 0.5rem;
    --radius-md: calc(var(--radius) - 2px);

    --background: oklch(1 0 0);
    --foreground: oklch(0.40936435 0.08435103 255.60480785);
    --primary: oklch(0.40936435 0.08435103 255.60480785);
    --primary-foreground: oklch(1 0 0);
    --primary-dark: oklch(0.33 0.07 255.60480785);
    --sun: oklch(0.81853462 0.16799305 83.58595313);
    --brand-orange: oklch(0.79309081 0.15917845 67.44094591);
    --brand-peach: oklch(0.85910481 0.11233486 72.63023267);
    --secondary: oklch(0.95718882 0.00343646 247.8588463);
    --muted-foreground: oklch(0.45 0.035 252);
    --accent: oklch(0.95 0.015 245);
    --destructive: oklch(0.53 0.2 27);
    --success: oklch(0.5 0.12 155);
    --border: oklch(0.91 0.012 240);

    --font-sans: "Lucida Grande", "Lucida Sans Unicode", "Lucida Sans", Arial, sans-serif;
    --font-display: Georgia, "Times New Roman", serif;
    --font-tertiary: Helvetica, Arial, sans-serif;

    --container: 1200px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; border: 0 solid var(--border); }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background-color: var(--background);
    color: var(--muted-foreground);
    font-family: var(--font-sans);
    font-size: 1.0625rem;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    margin: 0;
    color: var(--primary);
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0;
}

p, ul, ol, figure { margin: 0; }
ul, ol { list-style: none; padding: 0; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; }

small, .text-sm { font-family: var(--font-tertiary); }

:focus-visible { outline: 3px solid var(--sun); outline-offset: 2px; border-radius: 4px; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* ---------- Utilidades ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 1.25rem; }
.container--narrow { max-width: 48rem; }

.section { padding-block: 4.5rem; }
@media (min-width: 768px) { .section { padding-block: 6rem; } }

.bg-secondary { background-color: var(--secondary); }
.text-primary { color: var(--primary); }
.text-center { text-align: center; }
.text-sm { font-size: 0.875rem; line-height: 1.4286; }
.text-lg { font-size: 1.125rem; line-height: 1.5556; }

.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-5 { margin-top: 1.25rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-10 { margin-top: 2.5rem; }
.pt-4 { padding-top: 1rem; }

.stack-6 > * + * { margin-top: 1.5rem; }
.stack-10 > * + * { margin-top: 2.5rem; }

.eyebrow {
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0;
    color: var(--primary);
    text-transform: uppercase;
}

.sun-rule { display: block; width: 3.5rem; height: 4px; border-radius: 2px; background: var(--sun); }

.icon { width: 1.5rem; height: 1.5rem; flex-shrink: 0; }
.icon--sm { width: 1rem; height: 1rem; }
.icon--md { width: 1.25rem; height: 1.25rem; }
.icon--lg { width: 1.5rem; height: 1.5rem; }
.icon--xl { width: 2rem; height: 2rem; }
.icon--center { margin-inline: auto; }

.screen-reader-text {
    position: absolute !important;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}
.skip-link:focus {
    position: absolute !important;
    left: 1rem; top: 1rem;
    width: auto; height: auto;
    margin: 0; padding: 0.5rem;
    clip: auto;
    z-index: 100;
    background: var(--background);
}

/* ---------- Botones ---------- */
.btn {
    display: inline-flex;
    min-height: 3rem;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border-radius: var(--radius-md);
    padding-inline: 1.5rem;
    font-size: 1rem;
    line-height: 1.5;
    font-weight: 600;
    transition: color .15s, background-color .15s, border-color .15s;
}
.btn--primary { background: var(--primary); color: var(--primary-foreground); }
.btn--primary:hover { background: var(--primary-dark); }
.btn--secondary { border: 2px solid var(--primary); background: var(--background); color: var(--primary); }
.btn--secondary:hover { background: var(--accent); }
.btn--on-dark { background: var(--background); color: var(--primary); }
.btn--on-dark:hover { background: var(--accent); }
.btn--outline-dark { border: 2px solid oklch(1 0 0 / 0.7); color: var(--primary-foreground); }
.btn--outline-dark:hover { background: oklch(1 0 0 / 0.1); }
.btn--block { width: 100%; }
.btn:disabled { opacity: 0.7; cursor: default; }

.btn-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }
.btn-row--center { justify-content: center; }

.link-arrow { display: inline-flex; align-items: center; gap: 0.25rem; font-weight: 600; color: var(--primary); }
.link-arrow:hover { color: var(--primary-dark); }

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

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    border-bottom-width: 1px;
    background: oklch(1 0 0 / 0.95);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .site-header { top: 0; } }

.site-header__inner {
    display: flex;
    height: 4.5rem;
    align-items: center;
    justify-content: space-between;
    padding-block: 0.75rem;
}

.site-logo { display: inline-flex; }
.site-logo__img { width: 13rem; max-width: 100%; height: auto; }
@media (min-width: 640px) { .site-logo__img { width: 15rem; } }
.site-logo--light { border-radius: var(--radius-md); background: var(--background); padding: 0.5rem; }

.main-navigation, .site-header__cta { display: none; }

.main-navigation__list { display: flex; gap: 1.75rem; }
.main-navigation__list a,
.mobile-navigation__list a { font-weight: 500; color: var(--foreground); }
.main-navigation__list a:hover { color: var(--primary-dark); }
.main-navigation__list .current-menu-item > a {
    color: var(--primary);
    text-decoration: underline;
    text-decoration-color: var(--sun);
    text-decoration-thickness: 4px;
    text-underline-offset: 8px;
}

.menu-toggle {
    display: inline-flex;
    width: 2.25rem;
    height: 2.25rem;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    color: var(--primary);
}
.menu-toggle:hover { background: var(--accent); }
.menu-toggle .icon--xl { width: 1.75rem; height: 1.75rem; }
.menu-toggle__close, .menu-toggle[aria-expanded="true"] .menu-toggle__open { display: none; }
.menu-toggle[aria-expanded="true"] .menu-toggle__close { display: block; }

.mobile-navigation { border-top-width: 1px; }
.mobile-navigation .container { padding-block: 0.75rem; }
.mobile-navigation__list a { display: block; padding-block: 0.75rem; font-size: 1.125rem; line-height: 1.5556; }
.mobile-navigation .btn { margin-block: 0.5rem; }

@media (min-width: 1024px) {
    .main-navigation, .site-header__cta { display: block; }
    .menu-toggle, .mobile-navigation { display: none !important; }
}

/* ---------- Layout ---------- */
.split { display: grid; align-items: center; gap: 3rem; }
.split--top { align-items: start; }
@media (min-width: 1024px) { .split { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.media-img { width: 100%; aspect-ratio: 6 / 5; border-radius: var(--radius); object-fit: cover; }

.grid { display: grid; gap: 1.5rem; margin-top: 3rem; }
@media (min-width: 640px) { .grid--4, .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) {
    .grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.grid--5 { gap: 1.25rem; }
@media (min-width: 640px) { .grid--5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .grid--5 { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (min-width: 768px) { .grid--steps { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- Section heading & heroes ---------- */
.section-heading { max-width: 42rem; }
.section-heading .sun-rule { margin-block: 1rem; }
.section-heading h2 { font-size: 1.875rem; line-height: 1.2; }
.section-heading__intro { margin-top: 1rem; font-size: 1.125rem; line-height: 1.5556; }
.section-heading--center { margin-inline: auto; text-align: center; }
.section-heading--center .sun-rule { margin-inline: auto; }
@media (min-width: 768px) { .section-heading h2 { font-size: 2.25rem; line-height: 1.1111; } }

.home-hero { background: var(--background); }
.home-hero__inner { padding-block: 3.5rem; }
@media (min-width: 768px) { .home-hero__inner { padding-block: 5rem; } }
.sun-rule--lg { margin-block: 1.25rem; }
.home-hero__title { font-size: 2.25rem; line-height: 1.1111; }
@media (min-width: 768px) { .home-hero__title { font-size: 3rem; line-height: 1; } }
@media (min-width: 1024px) { .home-hero__title { font-size: 3.4rem; } }
.home-hero__text { margin-top: 1.5rem; max-width: 36rem; font-size: 1.125rem; line-height: 1.5556; }
.home-hero__media { position: relative; }
.home-hero__corner {
    position: absolute;
    left: -0.75rem;
    top: -0.75rem;
    width: 6rem;
    height: 6rem;
    border-top: 4px solid var(--sun);
    border-left: 4px solid var(--sun);
    border-top-left-radius: var(--radius);
}
.home-hero__media .media-img { position: relative; }

.page-hero { border-bottom-width: 1px; background: var(--secondary); }
.page-hero__inner { padding-block: 4rem; }
@media (min-width: 768px) { .page-hero__inner { padding-block: 5rem; } }
.page-hero .sun-rule { margin-bottom: 1.25rem; }
.page-hero h1 { max-width: 48rem; font-size: 2.25rem; line-height: 1.1111; }
@media (min-width: 768px) { .page-hero h1 { font-size: 3rem; line-height: 1; } }
.page-hero__intro { margin-top: 1.25rem; max-width: 42rem; font-size: 1.125rem; line-height: 1.5556; }

/* ---------- Cards ---------- */
.card { border-width: 1px; border-radius: var(--radius); background: var(--background); padding: 1.5rem; }
.card--flex { display: flex; flex-direction: column; }
.card--step { padding: 1.75rem; }
.card__title { margin-top: 1.25rem; font-size: 1.25rem; line-height: 1.4; }
.card__title--tight { margin-top: 1rem; }
.card__text { margin-top: 0.5rem; }
.card__grow { flex: 1; }

.icon-badge {
    display: flex;
    width: 3rem;
    height: 3rem;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    background: var(--accent);
    color: var(--primary);
    flex-shrink: 0;
}
.icon-badge--lg { width: 4rem; height: 4rem; }
.icon-badge--sm { width: 2.75rem; height: 2.75rem; }

.step-number {
    display: flex;
    width: 2.75rem;
    height: 2.75rem;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    background: var(--primary);
    color: var(--primary-foreground);
    font-size: 1.125rem;
    font-weight: 700;
}

.value-label { margin-top: 0.75rem; font-weight: 600; color: var(--primary); }

/* ---------- Services ---------- */
.service-row { display: grid; gap: 1.5rem; padding: 1.75rem; scroll-margin-top: 7rem; }
@media (min-width: 768px) { .service-row { grid-template-columns: auto 1fr auto; align-items: center; } }
.service-row__title { font-size: 1.5rem; line-height: 1.3333; }

/* ---------- Insurance ---------- */
.insurance-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.insurer {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border-width: 1px;
    border-radius: var(--radius);
    background: var(--secondary);
    padding: 0.75rem;
    text-align: center;
    font-weight: 500;
}
/* Con logo: fondo blanco para que los logos se vean con sus colores */
.insurer--has-logo { background: var(--background); }
.insurer__logo { width: auto; max-width: 80%; height: 2.75rem; object-fit: contain; }
.insurer--has-logo .insurer__name { font-family: var(--font-tertiary); font-size: 0.8125rem; line-height: 1.3; }

.insurance-grid--home { align-self: center; }
.insurance-grid--home .insurer { min-height: 5rem; font-family: var(--font-tertiary); font-size: 0.875rem; line-height: 1.4286; }
.insurance-grid--page { margin-top: 2.5rem; }
.insurance-grid--page .insurer { min-height: 6rem; }
.insurance-grid--page .insurer--has-logo { min-height: 8rem; }
.insurance-grid--page .insurer--has-logo .insurer__logo { height: 3.5rem; }
@media (min-width: 768px) { .insurance-grid--page { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .insurance-grid--page { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* ---------- Final CTA ---------- */
.final-cta { background: var(--primary); text-align: center; }
.final-cta .sun-rule { margin: 0 auto 1.25rem; }
.final-cta h2 { color: var(--primary-foreground); font-size: 1.875rem; line-height: 1.2; }
@media (min-width: 768px) { .final-cta h2 { font-size: 2.25rem; line-height: 1.1111; } }
.final-cta__text {
    margin: 1rem auto 0;
    max-width: 42rem;
    font-size: 1.125rem;
    line-height: 1.5556;
    color: oklch(1 0 0 / 0.9);
}

/* ---------- Contact ---------- */
.contact-layout { display: grid; gap: 3rem; }
@media (min-width: 1024px) { .contact-layout { grid-template-columns: 2fr 3fr; } }

.contact-info__title { font-size: 1.5rem; line-height: 1.3333; }
.contact-info { margin-top: 1.5rem; }
.contact-info > li { display: flex; gap: 1rem; }
.contact-info > li + li { margin-top: 1.25rem; }
.contact-info__label { font-weight: 600; color: var(--primary); }

.contact-form { border-width: 1px; border-radius: var(--radius); background: var(--secondary); padding: 1.5rem; scroll-margin-top: 7rem; }
@media (min-width: 768px) { .contact-form { padding: 2rem; } }

.form-grid { display: grid; gap: 1.25rem; }
@media (min-width: 768px) { .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.form-field label { font-weight: 600; color: var(--primary); }
.form-field input,
.form-field select,
.form-field textarea {
    display: block;
    width: 100%;
    margin-top: 0.5rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--background);
    padding: 0.75rem 1rem;
    color: var(--foreground);
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus { border-color: var(--primary); }
.form-field__error { margin-top: 0.25rem; font-family: var(--font-tertiary); font-size: 0.875rem; line-height: 1.4286; color: var(--destructive); }

.contact-form__submit { margin-top: 1.5rem; width: 100%; }
@media (min-width: 768px) { .contact-form__submit { width: auto; } }

.form-notice { margin-top: 1.25rem; border: 1px solid; border-radius: var(--radius-md); background: var(--background); padding: 1rem; }
.form-notice--error { border-color: oklch(0.53 0.2 27 / 0.4); color: var(--destructive); }
.form-notice--success { border-color: oklch(0.5 0.12 155 / 0.4); color: var(--success); }

/* ---------- Footer ---------- */
.site-footer { background: var(--primary-dark); color: oklch(1 0 0 / 0.85); }
.site-footer__grid { display: grid; gap: 2.5rem; padding-block: 3.5rem; }
@media (min-width: 768px) { .site-footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .site-footer__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.site-footer__about { margin-top: 1rem; }
.site-footer__title { font-size: 1rem; line-height: 1.5; color: var(--primary-foreground); }
.site-footer__list { margin-top: 1rem; }
.site-footer__list > li + li { margin-top: 0.5rem; }
.site-footer a:hover { text-decoration: underline; }
.site-footer__contact { margin-top: 1rem; }
.site-footer__contact > li { display: flex; gap: 0.5rem; }
.site-footer__contact > li + li { margin-top: 0.75rem; }
.site-footer__contact .icon { margin-top: 0.25rem; color: var(--sun); }

.site-footer__bottom { border-top: 1px solid oklch(1 0 0 / 0.15); }
.site-footer__bottom-inner { display: flex; flex-direction: column; gap: 0.5rem; padding-block: 1.25rem; }
@media (min-width: 768px) { .site-footer__bottom-inner { flex-direction: row; justify-content: space-between; } }
.site-footer__legal { display: flex; gap: 1.25rem; }

/* ---------- Contenido genérico & 404 ---------- */
.entry-content > * + * { margin-top: 1rem; }
.entry-content h2 { margin-top: 2.5rem; font-size: 1.875rem; }
.entry-content h3 { margin-top: 2rem; font-size: 1.5rem; }
.entry-content ul { list-style: disc; padding-left: 1.5rem; }
.entry-content ol { list-style: decimal; padding-left: 1.5rem; }
.entry-content a { color: var(--primary); text-decoration: underline; }

.not-found { display: flex; min-height: 60vh; align-items: center; justify-content: center; padding: 4rem 1rem; }
.not-found__inner { max-width: 28rem; text-align: center; }
.not-found__code { font-family: var(--font-sans); font-size: 4.5rem; line-height: 1; color: var(--foreground); }
.not-found__title { margin-top: 1rem; font-family: var(--font-sans); font-size: 1.25rem; font-weight: 600; color: var(--foreground); }
