/* Edgar Garrido — editorial direction. Loaded after the existing home styles. */
:root {
  --eg-paper: #f5f3ec;
  --eg-white: #fff;
  --eg-ink: #111214;
  --eg-muted: #4f565a;
  --eg-line: #d8dad3;
  --eg-green: #a9c447;
  --eg-green-ink: #52670f;
}

body.eg-home { background: var(--eg-paper); color: var(--eg-ink); }
body.eg-home .container { width: min(1240px, calc(100% - 56px)); }
body.eg-home .site-header {
  position: fixed !important;
  inset: 0 0 auto !important;
  height: 76px !important;
  padding-inline: max(28px, calc((100vw - 1240px) / 2));
  background: rgba(245,243,236,.97) !important;
  border-bottom-color: var(--eg-line);
  backdrop-filter: blur(10px);
}
body.eg-home .site-header .brand img { width: clamp(190px, 17vw, 235px); }
body.eg-home .nav a,
body.eg-home .header-link { color: var(--eg-ink); }
body.eg-home .nav .nav-cta { display: none; }
body.eg-home .nav a:hover,
body.eg-home .header-link:hover { color: var(--eg-green-ink); }
body.eg-home .section { padding-block: clamp(76px, 8vw, 112px); }
body.eg-home .section-head { max-width: 920px; }
body.eg-home .section-head h2,
body.eg-home .contact h2 {
  font-size: clamp(2.75rem, 5vw, 5rem);
  line-height: 1.04;
  letter-spacing: -.055em;
  text-wrap: balance;
}
body.eg-home .section-head > p:last-child { max-width: 720px; color: var(--eg-muted); }
body.eg-home .eyebrow { margin-bottom: 18px; color: var(--eg-green-ink); }
body.eg-home .btn { border-radius: 4px; }
body.eg-home .btn:focus-visible,
body.eg-home .text-link:focus-visible,
body.eg-home a:focus-visible,
body.eg-home button:focus-visible { outline: 3px solid var(--eg-green-ink); outline-offset: 4px; }

/* The opening reads like a personal editorial cover, not a product dashboard. */
body.eg-home .hero {
  min-height: min(800px, 92svh);
  padding: calc(var(--header) + 78px) 0 88px;
  background: var(--eg-paper);
  color: var(--eg-ink);
}
body.eg-home .hero-grid {
  grid-template-columns: minmax(0, 1.65fr) minmax(330px, .8fr);
  gap: clamp(48px, 6vw, 86px);
  align-items: center;
}
body.eg-home .hero-copy { max-width: 850px; }
body.eg-home .hero .eyebrow { color: var(--eg-green-ink); }
body.eg-home .hero h1 {
  max-width: 900px;
  color: var(--eg-ink);
  font-size: clamp(3.8rem, 6.65vw, 7rem);
  font-weight: 650;
  line-height: .99;
  letter-spacing: -.067em;
  text-wrap: balance;
}
body.eg-home .hero h1 span { color: inherit; }
body.eg-home .hero-lead {
  max-width: 690px;
  margin-top: 30px;
  color: var(--eg-muted);
  font-size: clamp(1.03rem, 1.45vw, 1.22rem);
  line-height: 1.62;
}
body.eg-home .hero-actions { gap: 10px 14px; margin-top: 32px; }
body.eg-home .hero .btn {
  min-height: 50px;
  border-color: var(--eg-ink);
  background: var(--eg-ink);
  color: #fff;
}
body.eg-home .hero .btn:hover { border-color: #33383a; background: #33383a; }
body.eg-home .hero .btn-secondary {
  border-color: #8f9691;
  background: transparent;
  color: var(--eg-ink);
}
body.eg-home .hero .btn-secondary:hover { border-color: var(--eg-ink); background: #fff; }
body.eg-home .hero .text-link {
  margin-left: 0;
  border-bottom: 1px solid var(--eg-line);
  color: var(--eg-green-ink);
}
body.eg-home .hero-meta { margin-top: 29px; color: #666c68; }
body.eg-home .hero-proof {
  align-self: center;
  justify-content: center;
  padding: clamp(26px, 3vw, 42px);
  border: 1px solid var(--eg-line);
  background: #fff;
  box-shadow: 14px 14px 0 #e6e9d8, 28px 28px 0 #dce7ac;
}
body.eg-home .hero-proof-kicker { margin-bottom: 18px; color: var(--eg-green-ink); }
body.eg-home .hero-proof dl > div {
  display: block;
  padding: 16px 0;
  border-top-color: var(--eg-line);
}
body.eg-home .hero-proof dt { color: var(--eg-ink); font-size: 1.05rem; }
body.eg-home .hero-proof dd { margin-top: 4px; color: var(--eg-muted); font-size: .76rem; }
body.eg-home .hero-proof-note {
  margin: 0;
  padding-top: 21px;
  border-top: 2px solid var(--eg-green);
  color: var(--eg-ink);
  font-weight: 650;
}

/* A compact lead-in and editorial rows carry the existing content. */
body.eg-home .problem-scenarios { background: #fff; }
body.eg-home .problem-layout { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(42px, 5vw, 82px); }
body.eg-home .problem-layout .section-head h2 { font-size: clamp(3rem, 4.2vw, 4.6rem); line-height: 1.055; }
body.eg-home .problem-layout,
body.eg-home .contribution-grid { gap: clamp(38px, 6vw, 92px); }
body.eg-home .problem-list article,
body.eg-home .area-grid article,
body.eg-home .contribution-list p { border-color: var(--eg-line); }
body.eg-home .problem-list article { padding-block: 19px; }
body.eg-home .problem-list article::after { content: none; }
body.eg-home .profile { background: #f8f7f2; }
body.eg-home .profile .section-head { margin-bottom: 42px; }
body.eg-home .area-grid article { padding-block: 25px; }
body.eg-home .area-grid article { grid-template-columns: 108px minmax(0, .78fr) minmax(0, 1fr); }
body.eg-home .area-grid article > .k-number {
  margin: 0 !important;
  color: var(--eg-green-ink) !important;
  font-size: clamp(2.1rem, 2.75vw, 2.8rem) !important;
  font-weight: 650 !important;
  letter-spacing: -.055em !important;
}
body.eg-home .area-grid h3 { max-width: 380px; }
body.eg-home .contribution { background: #fff; }
body.eg-home .contribution-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr); }
body.eg-home .contribution-grid .section-head h2 { font-size: clamp(3rem, 4.15vw, 4.65rem); line-height: 1.055; }
body.eg-home .diagnostic-offer { background: #edece5; }
body.eg-home .diagnostic-item { grid-template-columns: 36px minmax(0, 1fr); }
body.eg-home .section-cta .btn,
body.eg-home .method-cta .btn,
body.eg-home .experience-case-cta {
  min-height: 42px;
  padding-inline: 15px;
  font-size: .75rem;
}
body.eg-home .experience { background: #fff; }
body.eg-home .experience-main { margin-top: 42px; }

/* Real work is displayed as a curated, asymmetrical editorial collection. */
body.eg-home #proyectos { background: var(--eg-paper); }
body.eg-home #proyectos .section-head { max-width: 900px; }
body.eg-home .case-feature {
  margin-top: 44px;
  padding: clamp(30px, 4.3vw, 58px);
  border: 0;
  border-top: 4px solid var(--eg-green);
  border-radius: 2px;
  background: var(--eg-ink);
}
body.eg-home .case-feature h3 { font-size: clamp(2.2rem, 4.3vw, 4.4rem); line-height: 1.04; }
body.eg-home .project-grid { gap: 14px; margin-top: 14px; }
body.eg-home .project-card {
  min-width: 0;
  min-height: 360px;
  border-color: var(--eg-line);
  border-radius: 2px;
  box-shadow: none;
}
body.eg-home .project-card img { height: 218px; background: #ecebe4; }
body.eg-home .project-card:nth-child(1) img,
body.eg-home .project-card:nth-child(2) img { height: 218px; }
body.eg-home .project-card > .tag { margin-top: 24px; }
body.eg-home .project-card .text-link { margin-bottom: 24px; }
body.eg-home .project-grid > .project-card--kivo-primary {
  grid-column: span 8 !important;
  min-height: 395px !important;
}
body.eg-home .project-grid > .project-card--kivo-primary img {
  height: 230px !important;
  object-fit: contain;
}
body.eg-home .project-grid > .project-card--cromv {
  grid-column: span 4 !important;
  min-height: 280px !important;
  align-self: start;
  border-radius: 2px;
}
body.eg-home .project-card--cromv .cromv-visual { min-height: 210px !important; }
body.eg-home .project-card--cromv .cromv-meta { padding: 16px 19px !important; }
body.eg-home .project-grid > .project-card:last-child { grid-column: span 5 !important; }
body.eg-home #insights { background: #fff; }
body.eg-home .featured-projects { gap: 14px; margin-top: 44px; }
body.eg-home #insights .project-feature {
  border-color: var(--eg-line);
  border-radius: 2px;
  background: var(--eg-paper);
}
body.eg-home #insights .project-feature img { height: 235px; }

/* A functional process map: the relationship exists without animation. */
body.eg-home .approach { background: #fff; }
body.eg-home .approach-grid { display: block; }
body.eg-home .approach .section-head { max-width: 790px; }
body.eg-home .approach-process { margin-top: 46px; }
body.eg-home .approach-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  border-bottom: 1px solid var(--eg-line);
}
body.eg-home .approach-steps li {
  display: block;
  min-width: 0;
  min-height: 218px;
  padding: 23px 20px 26px;
  border-bottom: 0;
  border-left: 1px solid var(--eg-line);
}
body.eg-home .approach-steps li:first-child { border-left: 0; padding-left: 0; }
body.eg-home .approach-steps .k-number { margin-bottom: 26px; }
body.eg-home .approach-steps h3 { font-size: 1.16rem; }
body.eg-home .approach-steps p { font-size: .8rem; }
body.eg-home .method-cta { justify-content: flex-start; }
body.eg-home .method-cta span { max-width: none; }

body.eg-home .skills { background: #f8f7f2; }
body.eg-home .education { background: var(--eg-paper); }
body.eg-home .contact { background: var(--eg-ink); }
body.eg-home .footer { background: #0b0c0e; }

@media (hover:hover) {
  body.eg-home .project-card:hover,
  body.eg-home #insights .project-feature:hover { transform: translateY(-2px); }
}
@media (max-width: 1100px) {
  body.eg-home .hero-grid { grid-template-columns: minmax(0, 1fr) minmax(280px, .58fr); gap: 34px; }
  body.eg-home .hero h1 { font-size: clamp(3.7rem, 6.8vw, 6.4rem); }
  body.eg-home .approach-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  body.eg-home .approach-steps li:nth-child(4) { border-left: 0; }
  body.eg-home .approach-steps li { min-height: 195px; border-top: 1px solid var(--eg-line); }
}
@media (max-width: 900px) {
  body.eg-home .hero { min-height: 0; padding-block: calc(var(--header) + 52px) 58px; }
  body.eg-home .hero-grid { grid-template-columns: 1fr; gap: 46px; }
  body.eg-home .hero-proof { width: calc(100% - 28px); padding: 25px; }
  body.eg-home .hero-proof dl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
  body.eg-home .hero-proof dl > div { border-top: 0; padding: 0; }
  body.eg-home .hero-proof-note { margin-top: 20px; }
  body.eg-home .project-grid > .project-card--kivo-primary { grid-column: 1 / -1 !important; }
  body.eg-home .project-grid > .project-card--cromv { grid-column: span 6 !important; }
  body.eg-home .project-grid > .project-card:last-child { grid-column: span 6 !important; }
}
@media (max-width: 680px) {
  body.eg-home .container { width: min(100% - 32px, 1240px); }
  body.eg-home .site-header { padding-inline: 14px; }
  body.eg-home .section { padding-block: 63px; }
  body.eg-home .section-head h2 { font-size: clamp(2.4rem, 10.4vw, 3.65rem); }
  body.eg-home .hero { padding: calc(var(--header) + 36px) 0 50px; }
  body.eg-home .hero h1 { font-size: clamp(3.05rem, 12.8vw, 4.5rem); line-height: 1.01; }
  body.eg-home .hero-lead { margin-top: 23px; font-size: 1rem; }
  body.eg-home .hero-actions .btn { width: 100%; }
  body.eg-home .hero .text-link { padding-block: 6px; }
  body.eg-home .hero-proof dl { grid-template-columns: 1fr; gap: 0; }
  body.eg-home .hero-proof { width: 100%; box-shadow: 8px 8px 0 #e6e9d8; }
  body.eg-home .hero-proof dl > div { display: grid; grid-template-columns: 105px 1fr; gap: 12px; padding: 13px 0; border-top: 1px solid var(--eg-line); }
  body.eg-home .hero-proof dd { margin: 0; }
  body.eg-home .problem-layout,
  body.eg-home .contribution-grid { grid-template-columns: 1fr; }
  body.eg-home .problem-layout .section-head h2,
  body.eg-home .contribution-grid .section-head h2 { font-size: clamp(2.65rem, 10.6vw, 3.75rem); }
  body.eg-home .area-grid article { grid-template-columns: 50px minmax(0, 1fr); gap: 14px; }
  body.eg-home .area-grid article > .k-number { font-size: 1.85rem !important; }
  body.eg-home .case-feature { margin-top: 35px; }
  body.eg-home .project-grid { grid-template-columns: 1fr; }
  body.eg-home .project-grid > .project-card--kivo-primary,
  body.eg-home .project-grid > .project-card--cromv,
  body.eg-home .project-grid > .project-card:last-child { grid-column: 1 / -1 !important; }
  body.eg-home .project-card--cromv .cromv-visual { min-height: 170px !important; }
  body.eg-home .diagnostic-item { grid-template-columns: 36px minmax(0, 1fr); }
  body.eg-home .featured-projects { grid-template-columns: 1fr; }
  body.eg-home .approach-steps { grid-template-columns: 1fr; }
  body.eg-home .approach-steps li,
  body.eg-home .approach-steps li:first-child {
    display: grid;
    grid-template-columns: 43px minmax(0, 1fr);
    gap: 13px;
    min-height: 0;
    padding: 18px 0;
    border-left: 0;
    border-top: 1px solid var(--eg-line);
  }
  body.eg-home .approach-steps .k-number { margin: 4px 0 0; }
  body.eg-home .approach-steps li > div { min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  body.eg-home .project-card,
  body.eg-home .project-feature { transition: none !important; transform: none !important; }
}
