:root {
  color-scheme: light;
  --paper: #f8f4ee;
  --paper-light: #fffdfa;
  --ink: #11171c;
  --muted: #34383b;
  --gold: #a77b4e;
  --gold-dark: #8a6039;
  --line: #dfd6cb;
  --content: 1440px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 70px; }
body { min-height: 100vh; margin: 0; display: flex; flex-direction: column; background: var(--paper); color: var(--ink); font: 14px/1.5 'DM Sans', Arial, sans-serif; }
main { flex: 1 0 auto; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { font-family: 'Playfair Display', Georgia, serif; font-weight: 500; line-height: 1.08; }
h1 { font-size: 40px; margin-bottom: 0; }
h2 { font-size: 24px; margin-bottom: 8px; }
h3 { font-size: 17px; margin-bottom: 7px; }
p { margin-bottom: 12px; font-family: 'DM Sans', Arial, sans-serif; line-height: 1.5; }
.site-header { position: relative; z-index: 10; height: 58px; padding: 0 max(30px, calc((100vw - var(--content)) / 2)); display: flex; align-items: center; justify-content: space-between; background: rgba(255,253,250,.96); border-bottom: 1px solid #e6ded4; }
.brand, .footer-logo { align-self: stretch; display: flex; align-items: center; }
.brand img { width: 120px; height: 58px; object-fit: contain; }
.nav { display: flex; align-items: center; gap: 34px; height: 100%; }
.nav a { position: relative; font-size: 12px; white-space: nowrap; }
.nav a[data-page][aria-current="page"]::after, .nav-dropdown summary[aria-current="page"]::after { position: absolute; content: ''; left: 0; right: 0; bottom: -10px; height: 1px; background: var(--gold); }
.nav a:hover, .footer-nav a:hover { color: var(--gold-dark); }
.nav-dropdown { position: relative; height: 100%; display: flex; align-items: center; }
.nav-dropdown summary { position: relative; cursor: pointer; list-style: none; font-size: 12px; white-space: nowrap; }
.nav-dropdown summary::-webkit-details-marker { display: none; }
.nav-dropdown summary::after { content: '⌄'; display: inline-block; margin-left: 6px; color: var(--gold-dark); }
.nav-dropdown[open] summary::after { content: '⌃'; }
.nav-dropdown-menu { position: absolute; top: calc(100% - 1px); left: -14px; z-index: 30; display: grid; min-width: 220px; padding: 7px 0; border: 1px solid var(--line); background: var(--paper-light); box-shadow: 0 8px 18px rgba(20,16,12,.12); }
.nav-dropdown-menu a { padding: 9px 14px; }
.nav-dropdown-menu a:hover { background: #eee7de; color: var(--gold-dark); }
.nav-dropdown-menu a[aria-current="page"] { color: var(--gold-dark); font-weight: 700; }
.nav-dropdown summary:hover { color: var(--gold-dark); }
.button-gold:hover { background: var(--gold-dark); color: #fff; }
.menu-btn { display: none; width: 40px; height: 40px; border: 0; background: transparent; padding: 8px; cursor: pointer; }
.menu-btn span { display: block; height: 2px; margin: 5px 0; background: var(--ink); }
.eyebrow { margin: 0 0 7px; color: var(--gold-dark); font-size: 10px; line-height: 1.4; letter-spacing: 3px; font-weight: 600; }
.rule { display: block; width: 52px; height: 1px; background: var(--gold-dark); margin: 12px 0; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 36px; border: 0; border-radius: 4px; padding: 9px 17px; font: 600 12px/1.2 'DM Sans', Arial, sans-serif; cursor: pointer; transition: background .18s ease; }
.button-gold { background: var(--gold); color: white; }
.button-dark { width: 100%; background: #111; color: white; }
.button-dark:hover { background: #353535; }

.home-hero { position: relative; min-height: 286px; display: grid; grid-template-columns: 1fr 1fr; overflow: hidden; background: var(--paper); }
.home-main, .contact-main { flex: 1 0 auto; }
.home-main { display: flex; }
.home-main .home-hero { flex: 1; }
.home-hero-copy { position: relative; z-index: 1; align-self: center; max-width: 690px; padding: 32px 34px 32px max(48px, calc((100vw - var(--content)) / 2)); }
.home-hero-copy h1 { max-width: 510px; font-size: 44px; }
.home-hero-copy p:not(.eyebrow) { max-width: 520px; margin: 0 0 16px; font-size: 16px; line-height: 1.55; }
.home-hero-image { position: absolute; inset: 0 0 0 41%; background: linear-gradient(90deg, var(--paper) 0%, rgba(248,244,238,.92) 8%, rgba(248,244,238,.15) 42%, rgba(248,244,238,0) 65%), url('assets/01_Oficina_con_computadora.jpg') center 53% / cover no-repeat; }
.text-link { display: inline-flex; align-items: center; gap: 9px; color: var(--gold-dark); border-bottom: 1px solid var(--gold); padding-bottom: 2px; font-size: 13px; }
.text-link:hover { color: var(--ink); }

.page-hero { position: relative; min-height: 220px; display: grid; grid-template-columns: 1fr 1fr; overflow: hidden; background: var(--paper); }
.page-hero-copy { position: relative; z-index: 1; align-self: center; max-width: 760px; padding: 28px 28px 28px max(48px, calc((100vw - var(--content)) / 2)); }
.page-hero-copy h1 { font-size: 39px; }
.page-hero-copy p:not(.eyebrow) { max-width: 600px; margin-bottom: 0; color: var(--muted); font-size: 15px; line-height: 1.55; }
.page-hero-image { position: absolute; inset: 0 0 0 47%; background-position: center; background-size: cover; }
.consumer-image { background-image: linear-gradient(90deg, var(--paper) 0%, rgba(248,244,238,.87) 12%, rgba(248,244,238,.06) 54%), url('assets/12_Escribiendo_en_escritorio.jpg'); background-position: center 55%; }
.ip-image { background-image: linear-gradient(90deg, var(--paper) 0%, rgba(248,244,238,.86) 10%, rgba(248,244,238,.04) 55%), url('assets/03_Libros_y_computadora.jpg'); background-position: 62% 54%; }
.consumer-services, .ip-services-section { max-width: var(--content); margin: 0 auto; padding: 28px 44px; display: flex; flex-direction: column; justify-content: flex-start; }
.section-title { display: flex; align-items: center; gap: 16px; margin-bottom: 10px; }
.section-title h2 { margin: 0; font-size: 24px; white-space: nowrap; }
.section-title .rule { width: 74px; margin: 0; }
.consumer-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.consumer-card { min-width: 0; }
.consumer-card img { width: 100%; height: 120px; object-fit: cover; object-position: center 58%; border-radius: 3px; }
.consumer-card:nth-child(2) img, .consumer-card:nth-child(4) img { object-position: 70% 55%; }
.consumer-card h3, .ip-service h3 { margin: 7px 0 6px; font-family: 'Playfair Display', Georgia, serif; font-size: 18px; font-weight: 500; line-height: 1.2; }
.consumer-card p, .ip-service p { margin: 0 0 7px; color: var(--muted); font-family: 'DM Sans', Arial, sans-serif; font-size: 14px; line-height: 1.5; }
.contact-strip { min-height: 58px; padding: 8px max(40px, calc((100vw - var(--content)) / 2)); display: flex; align-items: center; justify-content: center; gap: 28px; background: #eee7de; }
.contact-strip p { margin: 0; font-size: 12px; }
.contact-strip .button { margin-left: auto; min-width: 145px; }
.secondary-link { color: var(--gold-dark); font-size: 11px; }

.ip-services-section { padding-top: 28px; padding-bottom: 36px; }
.ip-service-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.ip-service { min-width: 0; overflow: hidden; border: 1px solid #e3dbd1; border-radius: 2px; background: var(--paper-light); }
.ip-service-image { height: 205px; overflow: hidden; background: #e7ded3; }
.ip-service-image img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.08); }
.ip-service:nth-child(1) .ip-service-image img { object-position: center 48%; }
.ip-service:nth-child(2) .ip-service-image img { object-position: center 55%; }
.ip-service-content { padding: 21px 24px 23px; }
.ip-service h3 { margin: 0 0 8px; font-size: 20px; }
.ip-service p { min-height: 42px; margin: 0 0 12px; color: var(--muted); font-size: 14px; }
.ip-service ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 18px; list-style: none; margin: 0; padding: 0; }
.ip-service li { padding: 9px 0; border-top: 1px solid #e8dfd5; color: #292c2d; font-size: 13px; line-height: 1.4; }

.contact-layout { position: relative; min-height: 420px; display: grid; grid-template-columns: minmax(0, .82fr) minmax(0, 1fr); align-items: center; gap: 28px; overflow: hidden; background: linear-gradient(90deg, rgba(248,244,238,.97) 0%, rgba(248,244,238,.94) 45%, rgba(248,244,238,.72) 100%), url('assets/20_Planta_en_escritorio.jpg') center 55% / cover no-repeat; }
.contact-main { display: flex; }
.contact-main .contact-layout { flex: 1; }
.contact-copy { width: 100%; max-width: 700px; padding: 26px 16px 26px max(48px, calc((100vw - var(--content)) / 2)); }
.contact-copy h1 { font-size: 40px; }
.contact-copy > p:not(.eyebrow) { max-width: 480px; margin-bottom: 16px; color: var(--muted); font-size: 14px; line-height: 1.6; }
.contact-methods { display: grid; gap: 9px; }
.contact-methods > div { display: flex; align-items: center; gap: 12px; }
.contact-icon { flex: 0 0 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; background: var(--gold); color: white; font-size: 19px; }
.contact-methods p { display: grid; margin: 0; font-size: 13px; line-height: 1.4; }
.contact-methods strong { font-size: 13px; font-weight: 600; }
.contact-form-wrap { position: relative; z-index: 1; width: min(100%, 620px); justify-self: start; }
.form-card { padding: 24px 26px 20px; background: rgba(255,253,250,.96); border: 1px solid rgba(255,255,255,.9); border-radius: 5px; box-shadow: 0 12px 34px rgba(50,38,25,.11); }
.field { min-width: 0; margin-bottom: 11px; }
.field label { display: block; margin: 0 0 5px; font-size: 12px; line-height: 1.35; }
.field label span { color: #9d3c2c; }
input, select, textarea { display: block; width: 100%; min-width: 0; min-height: 42px; padding: 8px 10px; border: 1px solid #ccc6bf; border-radius: 3px; background: #fff; color: var(--ink); font: 14px 'DM Sans', Arial, sans-serif; }
input:focus, select:focus, textarea:focus { outline: 2px solid #b48b62; outline-offset: 1px; }
textarea { min-height: 104px; resize: vertical; }
.consent { display: flex; align-items: flex-start; gap: 7px; margin: 8px 0; }
.consent input { flex: 0 0 14px; width: 14px; min-height: 14px; height: 14px; margin: 1px 0 0; padding: 0; accent-color: var(--gold-dark); }
.consent label { margin: 0; font-size: 12px; line-height: 1.45; }
.consent a { text-decoration: underline; text-underline-offset: 2px; }
.form-card .button { min-height: 42px; padding: 10px 16px; font-size: 13px; }
.form-note { margin: 9px 0 0; color: #5f5a54; font-size: 10px; line-height: 1.4; }
.success, .error { margin: 0 0 8px; padding: 9px 11px; border-left: 3px solid #46734d; background: #e8eee5; font-size: 12px; overflow-wrap: anywhere; }
.error { border-color: #a13e30; background: #f4e6e1; }

.site-footer { min-height: 125px; padding: 17px max(44px, calc((100vw - var(--content)) / 2)); display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); grid-template-rows: auto auto auto; align-items: center; column-gap: 24px; row-gap: 10px; background: #111; color: white; }
.footer-logo { width: auto; height: auto; font: 400 11px 'DM Sans', Arial, sans-serif; white-space: nowrap; }
.footer-nav { grid-column: 2; grid-row: 1; display: flex; align-items: center; justify-content: center; gap: 12px; font-size: 11px; }
.footer-nav a + a::before { content: '|'; margin-right: 12px; color: #9c938a; }
.footer-socials { grid-column: 1 / -1; grid-row: 2; display: flex; align-items: center; justify-content: center; gap: 18px; }
.footer-socials a { display: inline-flex; flex-direction: column; align-items: center; gap: 3px; min-width: 44px; white-space: nowrap; font-size: 8px; line-height: 1.1; }
.footer-socials a:hover { color: #e2c8a9; }
.social-mark { width: 23px; height: 23px; display: grid; flex: 0 0 23px; place-items: center; border: 2px solid white; border-radius: 50%; font-size: 13px; font-weight: 700; }
.copyright { grid-column: 1 / -1; grid-row: 3; justify-self: center; margin: 0; color: #ddd; font-size: 9px; text-align: center; }
.copyright span { margin: 0 5px; }
.copyright a { text-decoration: underline; text-underline-offset: 2px; }
.footer-wordmark { display: flex; align-items: center; color: white; font: 400 11px 'DM Sans', Arial, sans-serif; white-space: nowrap; }
.whatsapp-float { position: fixed !important; z-index: 40; right: max(20px, env(safe-area-inset-right)); bottom: max(18px, env(safe-area-inset-bottom)); display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border: 1px solid rgba(255,255,255,.35); border-radius: 24px; background: var(--gold); color: white; box-shadow: 0 5px 18px rgba(20,16,12,.22); font-size: 12px; font-weight: 600; }
.whatsapp-float:hover { background: var(--gold-dark); }
.whatsapp-float > span:first-child { width: 22px; height: 22px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.85); border-radius: 50%; font-size: 12px; }
.whatsapp-float:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.legal-page { width: min(100% - 40px, 900px); margin: 0 auto; padding: 54px 0 70px; }
.legal-page h1 { margin: 0 0 22px; }
.legal-page h2 { margin: 25px 0 7px; font-size: 22px; }
.legal-page p { color: var(--muted); }
.legal-page .text-link { margin-top: 14px; }
.home-hero-copy > p:not(.eyebrow), .page-hero-copy > p:not(.eyebrow), .contact-copy > p:not(.eyebrow), .legal-page p { text-align: justify; text-justify: inter-word; text-align-last: left; hyphens: none; }
.consumer-card p, .ip-service p, .form-note { text-align: left; hyphens: none; }
.contact-strip p { text-align: center; }

@media (max-width: 900px) {
  .site-header { padding-inline: 22px; }
  .nav { gap: 20px; }
  .nav-dropdown-menu { left: -10px; }
  .home-hero-copy, .page-hero-copy, .contact-copy { padding-left: 28px; }
  .consumer-services, .ip-services-section { padding-inline: 24px; }
  .consumer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
  .consumer-card img { height: 140px; }
  .contact-layout { gap: 20px; }
  .site-footer { padding-inline: 24px; }
}

@media (min-width: 681px) and (max-width: 900px) {
  .contact-layout { grid-template-columns: 1fr; align-content: center; gap: 8px; padding: 24px 0 32px; }
  .contact-copy { padding-block: 20px; }
  .contact-form-wrap { width: min(100% - 56px, 620px); justify-self: center; }
  .ip-service ul { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  html { scroll-padding-top: 72px; }
  h1 { font-size: 34px; }
  .site-header { height: 64px; padding-inline: 16px; }
  .brand img { width: 110px; height: 56px; }
  .menu-btn { display: block; }
  .nav { display: none; position: absolute; top: 64px; right: 0; left: 0; height: auto; padding: 16px 20px 20px; align-items: stretch; flex-direction: column; gap: 15px; border-bottom: 1px solid var(--line); background: var(--paper-light); box-shadow: 0 8px 16px #1112; }
  .nav.open { display: flex; }
  .nav a { width: fit-content; padding: 4px 0; }
  .nav-dropdown { display: block; height: auto; width: 100%; }
  .nav-dropdown summary { width: fit-content; padding: 4px 0; }
  .nav a[data-page][aria-current="page"]::after, .nav-dropdown summary[aria-current="page"]::after { bottom: -2px; }
  .nav-dropdown-menu { position: static; min-width: 0; margin: 6px 0 0 8px; padding: 4px 0; border: 0; border-left: 1px solid var(--line); background: transparent; box-shadow: none; }
  .nav-dropdown-menu a { display: block; width: fit-content; padding: 7px 12px; white-space: normal; }
  .home-hero { display: block; min-height: 390px; }
  .home-hero-image { inset: 0; background-image: linear-gradient(90deg, rgba(248,244,238,.96) 0%, rgba(248,244,238,.88) 58%, rgba(248,244,238,.28) 100%), url('assets/01_Oficina_con_computadora.jpg'); background-position: center; }
  .home-hero-copy { max-width: 580px; padding: 50px 24px 42px; }
  .home-hero-copy h1 { max-width: 450px; font-size: 36px; }
  .home-hero-copy p:not(.eyebrow) { font-size: 16px; line-height: 1.55; }
  .page-hero { min-height: 270px; display: block; }
  .page-hero-copy { max-width: 580px; padding: 44px 22px 38px; }
  .page-hero-copy h1 { font-size: 34px; }
  .page-hero-copy p:not(.eyebrow) { max-width: 500px; font-size: 14px; }
  .page-hero-image { inset: 0; }
  .consumer-image { background-image: linear-gradient(90deg, rgba(248,244,238,.96) 0%, rgba(248,244,238,.88) 58%, rgba(248,244,238,.38) 100%), url('assets/12_Escribiendo_en_escritorio.jpg'); }
  .ip-image { background-image: linear-gradient(90deg, rgba(248,244,238,.96) 0%, rgba(248,244,238,.88) 58%, rgba(248,244,238,.38) 100%), url('assets/03_Libros_y_computadora.jpg'); }
  .consumer-services, .ip-services-section { padding: 18px 20px 24px; }
  .consumer-services, .ip-services-section { min-height: 0; display: block; }
  .section-title h2 { font-size: 23px; }
  .consumer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px 14px; }
  .consumer-card img { height: 110px; }
  .consumer-card h3, .ip-service h3 { font-size: 17px; }
  .consumer-card p, .ip-service p, .ip-service li { font-size: 13px; }
  .contact-strip { min-height: 0; padding: 12px 18px; flex-wrap: wrap; justify-content: space-between; gap: 9px 16px; }
  .contact-strip p { flex: 1 1 100%; }
  .contact-strip .button { margin-left: 0; }
  .secondary-link { margin-left: auto; }
  .ip-service-grid { grid-template-columns: 1fr; gap: 20px; }
  .ip-service-image { height: 190px; }
  .ip-service-content { padding: 18px 20px 20px; }
  .ip-service p { min-height: 0; }
  .ip-service ul { gap: 0 12px; }
  .contact-layout { grid-template-columns: 1fr; align-content: center; gap: 0; padding: 8px 0 22px; background-image: linear-gradient(rgba(248,244,238,.93), rgba(248,244,238,.9)), url('assets/20_Planta_en_escritorio.jpg'); }
  .contact-copy { padding: 38px 22px 18px; }
  .contact-copy h1 { font-size: 36px; }
  .contact-copy > p:not(.eyebrow) { max-width: 520px; font-size: 13px; }
  .contact-methods { grid-template-columns: 1fr; gap: 8px; }
  .contact-icon { width: 32px; height: 32px; flex-basis: 32px; }
  .contact-form-wrap { width: min(100% - 32px, 560px); }
  .form-card { padding: 18px; }
  .field { margin-bottom: 10px; }
  .field label { font-size: 12px; margin-bottom: 4px; }
  input, select, textarea { min-height: 44px; font-size: 16px; }
  textarea { min-height: 100px; }
  .field label, .consent label { font-size: 13px; }
  .form-note { font-size: 11px; }
  .site-footer { min-height: 0; grid-template-columns: 1fr; grid-template-rows: auto; gap: 12px; padding: 16px 18px 18px; }
  .footer-logo { grid-column: 1 / -1; grid-row: auto; }
  .footer-nav { grid-column: 1 / -1; grid-row: auto; justify-content: center; flex-wrap: wrap; gap: 7px 11px; }
  .footer-nav a { font-size: 10px; }
  .footer-nav a + a::before { margin-right: 10px; }
  .footer-socials { grid-column: 1 / -1; grid-row: auto; justify-content: center; gap: 16px; }
  .whatsapp-float > span:last-child { display: none; }
  .whatsapp-float { width: 46px; min-height: 46px; justify-content: center; padding: 0; }
  .copyright { grid-column: 1 / -1; grid-row: auto; justify-self: start; max-width: calc(100% - 72px); margin: 0; line-height: 1.5; text-align: left; }
  .legal-page { width: min(100% - 36px, 900px); padding: 40px 0 54px; }
  .legal-page h1 { font-size: 33px; }
  .legal-page h2 { font-size: 20px; }
}

@media (max-width: 380px) {
  .home-hero-copy h1 { font-size: 32px; }
  .consumer-grid { grid-template-columns: 1fr; }
  .consumer-card img { height: 135px; }
  .ip-service ul { grid-template-columns: 1fr; }
}

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