/* =========================================================
   VITRALAR S.A. — Hoja de estilos
   Paleta tomada del logo de VITRALAR + neutros.
   El rojo de Claro no se usa en ningún lugar.
   ========================================================= */

:root {
    /* Colores de marca (tomados del logo de VITRALAR, valores exactos) */
    --brand-orange: #FF5D15;
    --brand-green:  #61C225;
    --brand-teal:   #01C8B5;
    --brand-cyan:   #00C3E9;
    --brand-amber:  #FEB300;

    /* Colores de uso. Los tonos del logo son claros: sobre blanco no alcanzan
       el contraste mínimo para texto, así que texto y botones usan una
       versión profunda del turquesa del logo. */
    --color-primary: #00766C;      /* turquesa profundo — botones y enlaces */
    --color-secondary: #FEB300;    /* ámbar de la "V" — acentos */
    --color-ink: #1E2A30;          /* texto y títulos */
    --color-muted: #52606A;        /* texto secundario */
    --color-surface: #F3F6F7;      /* fondos alternos */
    --color-line: #DCE3E6;         /* bordes */
    --color-white: #FFFFFF;
    --color-focus: #007FA0;

    --font-base: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --container: 1120px;
    --gutter: 1.25rem;
    --radius: 4px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
    margin: 0;
    font-family: var(--font-base);
    font-size: 1rem;
    line-height: 1.65;
    color: var(--color-ink);
    background: var(--color-white);
}

img, svg, iframe { max-width: 100%; display: block; }

h1, h2, h3 { line-height: 1.2; color: var(--color-ink); margin: 0 0 .75rem; }
h1 { font-size: clamp(1.75rem, 1.2rem + 2.6vw, 2.75rem); font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: clamp(1.5rem, 1.25rem + 1.2vw, 2rem); font-weight: 700; }
h3 { font-size: 1.0625rem; font-weight: 600; }
p  { margin: 0 0 1rem; }

a { color: var(--color-primary); text-underline-offset: 3px; }
a:hover { color: var(--color-focus); }
:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 3px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 760px; }

/* Accesibilidad */
.skip-link {
    position: absolute; left: -9999px; top: 0; z-index: 100;
    background: var(--color-primary); color: var(--color-white); padding: .75rem 1rem;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* Aviso de configuración pendiente (desaparece al completar config.php) */
.config-notice {
    background: #FFF4D6; color: #5A4300; border-bottom: 1px solid #E8CF8A;
    padding: .6rem var(--gutter); font-size: .875rem; text-align: center;
}

/* ---------- Encabezado ---------- */
.site-header {
    background: var(--color-white);
    border-bottom: 1px solid var(--color-line);
    position: sticky; top: 0; z-index: 10;
}
.header-inner {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
    gap: .5rem 1.5rem; padding-top: .9rem; padding-bottom: .9rem;
}
.brand img { height: 36px; width: auto; }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; }
.site-nav a {
    text-decoration: none; font-weight: 500; font-size: .9375rem; color: var(--color-ink);
    padding: .25rem 0; border-bottom: 2px solid transparent;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] { border-bottom-color: var(--brand-amber); color: var(--color-ink); }

/* ---------- Botones ---------- */
.btn {
    display: inline-block; text-decoration: none; font-weight: 600; font-size: 1rem;
    padding: .8rem 1.35rem; border-radius: var(--radius); border: 2px solid var(--color-primary);
    text-align: center;
}
.btn-primary { background: var(--color-primary); color: var(--color-white); }
.btn-primary:hover { background: #005E56; color: var(--color-white); }
.btn-secondary { background: transparent; color: var(--color-primary); }
.btn-secondary:hover { background: var(--color-surface); color: var(--color-primary); }

/* ---------- Hero ---------- */
.hero { padding: 3rem 0 3.5rem; border-bottom: 1px solid var(--color-line); }
.hero-inner { display: grid; gap: 2rem; align-items: center; }
.hero h1 { max-width: 18ch; }
.hero-lead { font-size: 1.125rem; color: var(--color-muted); max-width: 52ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.hero-art { display: none; }   /* en móvil ya se ve el logo en el encabezado */
.partner-badge { margin-top: 1.5rem; height: 48px; width: auto; }

/* ---------- Secciones ---------- */
.section { padding: 3.5rem 0; }
.section-alt { background: var(--color-surface); }
.section-intro { color: var(--color-muted); max-width: 60ch; margin-bottom: 2rem; }

/* Servicios: lista con filete superior, sin sombras */
.services {
    list-style: none; margin: 0; padding: 0;
    display: grid; gap: 1.75rem 2rem;
}
.service {
    border-top: 4px solid var(--brand-teal);
    padding-top: 1rem;
}
/* Cada servicio toma un color del logo, en el mismo orden que el marco */
.service:nth-child(5n+1) { border-top-color: var(--brand-orange); }
.service:nth-child(5n+2) { border-top-color: var(--brand-green); }
.service:nth-child(5n+3) { border-top-color: var(--brand-teal); }
.service:nth-child(5n+4) { border-top-color: var(--brand-cyan); }
.service:nth-child(5n+5) { border-top-color: var(--brand-amber); }
.service p { color: var(--color-muted); margin: 0; font-size: .9375rem; }

/* ---------- Contacto ---------- */
.contact-grid { display: grid; gap: 2rem; }
.contact-list { margin: 1.25rem 0 0; }
.contact-list dt {
    font-size: .8125rem; font-weight: 600; color: var(--color-muted); margin-top: 1rem;
}
.contact-list dt:first-child { margin-top: 0; }
.contact-list dd { margin: .15rem 0 0; font-size: 1.0625rem; }
.map { border: 1px solid var(--color-line); border-radius: var(--radius); overflow: hidden; min-height: 300px; }
.map iframe { width: 100%; height: 100%; min-height: 300px; border: 0; }

/* ---------- Páginas legales ---------- */
.legal h1 { margin-bottom: .25rem; }
.legal h2 { font-size: 1.25rem; margin-top: 2rem; }
.legal-updated { color: var(--color-muted); font-size: .9375rem; margin-bottom: 2rem; }
.legal ul { padding-left: 1.25rem; margin: 0 0 1rem; }
.legal li { margin-bottom: .35rem; }

/* ---------- Pie ---------- */
.site-footer {
    background: var(--color-ink); color: #D5DDE1;
    border-top: 6px solid transparent;
    border-image: linear-gradient(90deg,
        var(--brand-orange) 0 25%, var(--brand-green) 25% 50%,
        var(--brand-teal) 50% 75%, var(--brand-cyan) 75% 100%) 1;
    font-size: .9375rem; padding-top: 2.5rem;
}
.site-footer a { color: var(--color-white); }
.site-footer a:hover { color: var(--brand-amber); }
.site-footer p { margin: 0 0 .4rem; }
.site-footer address { font-style: normal; }
.footer-grid { display: grid; gap: 1.5rem; padding-bottom: 2rem; }
.footer-legal-name { color: var(--color-white); font-weight: 700; font-size: 1.0625rem; }
.footer-links ul { list-style: none; margin: 0; padding: 0; }
.footer-links li { margin-bottom: .4rem; }
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .15);
    padding-top: 1.25rem; padding-bottom: 1.75rem; font-size: .875rem;
}
.footer-disclaimer { color: #AEBAC0; }

/* ---------- Pantallas medianas ---------- */
@media (min-width: 640px) {
    .services { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Pantallas grandes ---------- */
@media (min-width: 960px) {
    .hero { padding: 5rem 0 5.5rem; }
    .hero-inner { grid-template-columns: 1fr auto; gap: 4rem; }
    .hero-art { display: block; width: 260px; height: auto; justify-self: end; }
    .section { padding: 5rem 0; }
    .services { grid-template-columns: repeat(3, 1fr); }
    .contact-grid { grid-template-columns: 5fr 6fr; gap: 3rem; align-items: stretch; }
    .footer-grid { grid-template-columns: 1.2fr 2fr 1fr; }
}
