/* Cencerro · minimal: leche (crema), tierra (café) y overo colorado */
:root {
  --cream: #faf5ec; --paper: #fffdf8; --line: #e6dccd;
  --ink: #2b211b; --muted: #75685c; --red: #b5532f; --red-2: #9a4122; --peach: #f0b48f;
  --serif: "Fraunces", Georgia, serif; --sans: Inter, system-ui, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { background: var(--cream); color: var(--ink); font: 400 17px/1.65 var(--sans); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
:focus-visible { outline: 2.5px solid var(--red); outline-offset: 4px; border-radius: 6px; }
.wrap { width: min(1080px, 88%); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 1rem; background: var(--ink); color: #fff; padding: .6rem 1rem; border-radius: 8px; z-index: 50; }
.skip:focus { left: 1rem; }

/* Botones */
.btn { display: inline-flex; align-items: center; gap: .5rem; padding: .9rem 1.5rem; border-radius: 999px; font: 600 .95rem var(--sans); text-decoration: none; cursor: pointer; border: 0; transition: background .2s, transform .2s, gap .2s; }
.btn.primary { background: var(--red); color: #fff; }
.btn.primary:hover { background: var(--red-2); transform: translateY(-1px); }
.btn.link { padding-inline: .4rem; background: none; color: inherit; }
.btn.link:hover { gap: .8rem; }
.btn svg { width: 1.1em; height: 1.1em; }
.cta { display: flex; align-items: center; gap: .8rem 1.2rem; flex-wrap: wrap; }

/* Navegación */
.nav { position: fixed; inset: 0 0 auto; z-index: 20; transition: background .3s, box-shadow .3s, color .3s; color: #fff; background: linear-gradient(rgba(22,16,11,.55), rgba(22,16,11,0)); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; padding: 1.1rem 0; }
.nav.solid { background: color-mix(in srgb, var(--cream) 90%, transparent); backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--line); color: var(--ink); }
.brand { display: inline-flex; align-items: center; gap: .45rem; text-decoration: none; font: 600 1.45rem var(--serif); letter-spacing: -.02em; }
.brand img { width: 30px; height: 30px; }
.nav .logo-dark, .nav.solid .logo-light { display: none; }
.nav.solid .logo-dark { display: block; }
.nav nav { display: flex; align-items: center; gap: 1.8rem; font-size: .93rem; font-weight: 500; }
.nav nav a { text-decoration: none; opacity: .9; }
.nav nav a:hover { opacity: 1; }
.nav-cta { border: 1.5px solid currentColor; padding: .45rem 1rem; border-radius: 999px; }
.nav.solid .nav-cta { background: var(--ink); border-color: var(--ink); color: var(--cream); }

/* Inicio */
.hero { position: relative; isolation: isolate; background: #1d1611; min-height: 100svh; display: flex; align-items: flex-end; padding: 8rem 0 clamp(4rem, 12vh, 8rem); color: #fff; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background: url("/img/hero-cerro-castillo.webp") center 55% / cover no-repeat; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(22,16,11,.85) 0%, rgba(22,16,11,.45) 45%, rgba(22,16,11,.15) 75%, rgba(22,16,11,.35) 100%); }
.kicker { font: 500 .8rem var(--sans); letter-spacing: .2em; text-transform: uppercase; opacity: .9; margin-bottom: 1.2rem; text-shadow: 0 1px 10px rgba(0,0,0,.55); }
.hero h1, .lead { text-shadow: 0 2px 20px rgba(0,0,0,.3); }
.hero h1 { font: 500 clamp(2.5rem, 6vw, 4.6rem)/1.04 var(--serif); letter-spacing: -.025em; max-width: 14ch; margin-bottom: 1.2rem; }
.hero h1 em { color: var(--peach); }
.lead { font-size: 1.2rem; max-width: 30rem; opacity: .9; margin-bottom: 2rem; }
.credit { position: absolute; right: 1.2rem; bottom: 1rem; font-size: .7rem; opacity: .55; }

/* Secciones */
.block { padding: clamp(5rem, 12vh, 8rem) 0; }
.block.tight { padding-top: 0; }
.h2 { font: 500 clamp(2rem, 4vw, 2.9rem)/1.1 var(--serif); letter-spacing: -.02em; margin-bottom: 2.6rem; }
.h2 em { color: var(--red); }

/* Qué hacemos */
.services { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--ink); }
.services article { padding: 1.8rem 2rem 0 0; }
.services article + article { padding-left: 2rem; border-left: 1px solid var(--line); }
.n { font: 500 .8rem var(--sans); color: var(--red); letter-spacing: .1em; }
.services h3 { font: 600 1.45rem/1.2 var(--serif); margin: .5rem 0 .4rem; }
.services p { color: var(--muted); }
.promises { list-style: none; display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 3.2rem; }
.promises li { display: inline-flex; align-items: center; gap: .5rem; padding: .5rem 1rem; border: 1px solid var(--line); border-radius: 999px; font-size: .9rem; background: var(--paper); }
.promises li::before { content: ""; width: .45rem; height: .45rem; border-radius: 50%; background: var(--red); }

/* Trabajo */
.project { display: grid; grid-template-columns: 1.25fr 1fr; gap: 3rem; align-items: center; }
.project-img { display: block; border-radius: 16px; overflow: hidden; box-shadow: 0 30px 60px -20px rgba(43,33,27,.35); }
.project-img img { transition: transform .7s cubic-bezier(.2,.7,.2,1); }
.project:hover .project-img img { transform: scale(1.025); }
.project-type { font: 500 .8rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: .6rem; }
.project h3 { font: 600 2.2rem/1.1 var(--serif); letter-spacing: -.02em; margin-bottom: .8rem; }
.project p { color: var(--muted); margin-bottom: 1.4rem; }
.project .btn.link { padding-left: 0; color: var(--red); }

/* Contacto */
.contact { background: var(--ink); color: var(--cream); padding: clamp(5rem, 12vh, 7.5rem) 0; }
.contact-in { display: grid; grid-template-columns: 1.15fr .85fr; gap: 4rem; align-items: center; }
.contact .h2 { margin-bottom: 1.2rem; }
.contact .h2 em { color: var(--peach); }
.contact-text > p { color: #d6cabb; max-width: 32rem; margin-bottom: 2rem; }
.contact .btn.link { color: var(--cream); }
.meta { margin-top: 1.6rem; font-size: .9rem; color: #a8998a !important; }
.meta a { text-decoration: none; border-bottom: 1px solid #5a4b3f; }
.meta a:hover { border-color: var(--cream); color: var(--cream); }
.contact-photo img { border-radius: 16px; aspect-ratio: 4 / 5; object-fit: cover; object-position: 55% 50%; }

/* Pie */
.foot { padding: 1.6rem 0; font-size: .82rem; color: var(--muted); }
.foot-in { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.foot summary { cursor: pointer; }
.foot ul { list-style: none; margin-top: .5rem; font-size: .76rem; }

/* Aparición suave */
.reveal { opacity: 0; transform: translateY(10px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (max-width: 860px) {
  .services { grid-template-columns: 1fr; }
  .services article, .services article + article { padding: 1.4rem 0; border-left: 0; border-bottom: 1px solid var(--line); }
  .project, .contact-in { grid-template-columns: 1fr; gap: 2rem; }
  .contact-photo { order: -1; }
  .contact-photo img { aspect-ratio: 16 / 10; }
}
@media (max-width: 560px) {
  .nav nav a:not(.nav-cta) { display: none; }
  body { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- Cencerro interactivo ---------- */
.bell-wrap { position: absolute; top: 92px; right: clamp(1.5rem, 9vw, 9rem); width: 120px; height: clamp(210px, 34vh, 320px); pointer-events: none; z-index: 2; }
/* Clavo del que cuelga la cuerda */
.bell-wrap::before { content: ""; position: absolute; top: -5px; left: 50%; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: var(--cream); box-shadow: 0 2px 6px rgba(0,0,0,.45); }
.bell { position: absolute; left: 0; bottom: 0; width: 120px; height: 180px; background: none; border: 0; cursor: pointer; pointer-events: auto; -webkit-tap-highlight-color: transparent; }
.bell svg { width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 18px 22px rgba(0,0,0,.35)); }
.bell .rope { stroke: #e9dccb; stroke-width: 2.5; opacity: .85; }
.bell .strap { fill: none; stroke: var(--cream); stroke-width: 5; }
.bell .body { fill: var(--cream); stroke: var(--cream); stroke-width: 4; stroke-linejoin: round; }
.bell .shine { stroke: #fff; stroke-width: 4; stroke-linecap: round; opacity: .55; }
.bell .rim { stroke: #e3d3bd; stroke-width: 6; stroke-linecap: round; }
.bell .clapper-rod { stroke: var(--ink); stroke-width: 4; stroke-linecap: round; }
.bell .clapper { fill: var(--red); }
.bell:focus-visible { outline: none; }
.bell:focus-visible .body { stroke: var(--peach); stroke-width: 7; }
.waves { position: absolute; left: 50%; top: 58%; width: 0; height: 0; }
.waves i { position: absolute; left: -70px; top: -70px; width: 140px; height: 140px; border-radius: 50%; border: 2px solid rgba(250,245,236,.7); opacity: 0; }
.bell.ring .waves i { animation: wave .9s ease-out; }
.bell.ring .waves i + i { animation-delay: .18s; }
@keyframes wave { from { opacity: .8; transform: scale(.5); } to { opacity: 0; transform: scale(1.6); } }
.bell-tip { position: absolute; right: calc(100% + .4rem); bottom: 4.6rem; white-space: nowrap; font: 500 .78rem var(--sans); letter-spacing: .04em; color: #fff; opacity: .85; text-shadow: 0 1px 8px rgba(0,0,0,.6); transition: opacity .4s; }
.bell-tip::after { content: " ↷"; }
.bell-wrap.played .bell-tip { opacity: 0; }
.bell-bubble { position: absolute; right: calc(100% + .3rem); bottom: 6.5rem; white-space: nowrap; pointer-events: auto; background: var(--cream); color: var(--ink); text-decoration: none; font: 600 .9rem var(--sans); padding: .55rem .95rem; border-radius: 14px 14px 4px 14px; box-shadow: 0 12px 30px rgba(0,0,0,.3); opacity: 0; transform: translateY(6px) scale(.95); transform-origin: bottom right; transition: opacity .3s, transform .3s; visibility: hidden; }
.bell-bubble.show { opacity: 1; transform: none; visibility: visible; }
.bell-bubble:hover { background: #fff; }

/* Logo del menú: se mece al pasar el mouse */
.brand img { transform-origin: 50% 15%; }
.brand:hover img { animation: wobble .9s ease-in-out; }
@keyframes wobble { 20% { transform: rotate(14deg); } 45% { transform: rotate(-10deg); } 70% { transform: rotate(5deg); } 100% { transform: rotate(0); } }

@media (max-width: 860px) {
  .bell-wrap { top: 104px; width: 76px; height: 170px; right: 7%; }
  .bell { width: 76px; height: 114px; }
  .bell-tip { bottom: 2.6rem; font-size: .72rem; }
  .bell-bubble { bottom: 4rem; font-size: .82rem; }
}
@media (prefers-reduced-motion: reduce) {
  .brand:hover img { animation: none; }
}
