:root {
  --bg: #f2ede4;
  --bg-soft: #fffaf0;
  --ink: #111115;
  --muted: #696762;
  --line: #ded4c5;
  --lime: #e6ff3f;
  --violet: #8753ff;
  --sand: #e9dfce;
  --card: #fbf7ee;
  --dark: #0f0f16;
  --radius-xl: 34px;
  --radius-lg: 24px;
  --shadow: 0 30px 90px rgba(17, 17, 21, .10);
  --max: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 72% 12%, rgba(135, 83, 255, .10), transparent 32%),
    radial-gradient(circle at 8% 38%, rgba(230, 255, 63, .16), transparent 34%),
    var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.45;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
p, h1, h2, h3 { margin-top: 0; }

.page { overflow: hidden; }
.container { width: min(var(--max), calc(100% - 48px)); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(18px);
  background: rgba(242, 237, 228, .78);
  border-bottom: 1px solid rgba(222, 212, 197, .55);
}

.nav {
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--dark);
  color: #fff;
  font-weight: 900;
  letter-spacing: -.04em;
  box-shadow: 0 12px 34px rgba(17, 17, 21, .16);
  flex: 0 0 auto;
}

.brand strong {
  display: block;
  font-size: 1.05rem;
  letter-spacing: -.03em;
}

.brand span span {
  display: block;
  color: var(--muted);
  font-size: .93rem;
  margin-top: 1px;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.8vw, 34px);
  font-weight: 850;
  letter-spacing: -.03em;
}

.nav-links a {
  position: relative;
  padding: 9px 0;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .24s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  transform: scaleX(1);
  transform-origin: left;
}

.hero { padding: clamp(76px, 9vw, 132px) 0 70px; }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, .95fr);
  gap: clamp(38px, 6vw, 86px);
  align-items: center;
}

.hero-copy { min-width: 0; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 15px;
  background: var(--lime);
  border: 1px solid rgba(17, 17, 21, .24);
  border-radius: 999px;
  font-size: .88rem;
  font-weight: 900;
  letter-spacing: -.02em;
  box-shadow: 0 8px 22px rgba(230, 255, 63, .18);
}

.eyebrow::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--ink);
}

.hero h1,
.page-title h1,
.section h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 900;
  letter-spacing: -.085em;
  line-height: .88;
}

.hero h1 {
  margin: 42px 0 24px;
  font-size: clamp(4.2rem, 8.4vw, 7.65rem);
  max-width: 720px;
  overflow-wrap: normal;
}

.lead {
  color: var(--muted);
  font-size: clamp(1.1rem, 2vw, 1.45rem);
  line-height: 1.58;
  max-width: 700px;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 24px;
  border-radius: 999px;
  border: 1px solid rgba(17, 17, 21, .16);
  font-weight: 900;
  letter-spacing: -.025em;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 30px rgba(17, 17, 21, .12);
}

.btn-primary { background: var(--dark); color: #fff; border-color: var(--dark); }
.btn-secondary { background: rgba(255, 255, 255, .46); }

.hero-visual { display: block; min-width: 0; }

.image-carousel {
  position: relative;
  overflow: hidden;
  min-height: clamp(360px, 42vw, 520px);
  border-radius: var(--radius-xl);
  border: 2px solid var(--violet);
  background: var(--dark);
  color: #fff;
  box-shadow: var(--shadow);
}

.carousel-radio {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.carousel-viewport {
  height: 100%;
  min-height: inherit;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  height: 100%;
  min-height: inherit;
  transition: transform .55s cubic-bezier(.2,.8,.2,1);
}

.carousel-slide {
  position: relative;
  min-width: 100%;
  min-height: inherit;
  margin: 0;
  background: #111115;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  min-height: inherit;
  object-fit: cover;
  filter: saturate(.95) contrast(1.02);
}

.carousel-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(15,15,22,.06), rgba(15,15,22,.78)),
    linear-gradient(90deg, rgba(15,15,22,.52), transparent 58%);
  pointer-events: none;
}

.carousel-slide figcaption {
  position: absolute;
  left: clamp(26px, 4vw, 40px);
  right: clamp(26px, 4vw, 40px);
  bottom: clamp(26px, 4vw, 38px);
  z-index: 2;
}

.carousel-slide figcaption span {
  display: block;
  margin-bottom: 14px;
  color: rgba(255,255,255,.72);
  font-size: .85rem;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.carousel-slide figcaption strong {
  display: block;
  max-width: 560px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.8rem, 6vw, 5rem);
  line-height: .9;
  letter-spacing: -.08em;
}

.carousel-dots {
  position: absolute;
  right: 28px;
  bottom: 28px;
  z-index: 3;
  display: flex;
  gap: 9px;
  align-items: center;
}

.carousel-dots label {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.48);
  cursor: pointer;
  transition: width .25s ease, background .25s ease;
}

.carousel-dots label span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

#slide-1:checked ~ .carousel-viewport .carousel-track { transform: translateX(0); }
#slide-2:checked ~ .carousel-viewport .carousel-track { transform: translateX(-100%); }
#slide-3:checked ~ .carousel-viewport .carousel-track { transform: translateX(-200%); }
#slide-1:checked ~ .carousel-dots label[for="slide-1"],
#slide-2:checked ~ .carousel-dots label[for="slide-2"],
#slide-3:checked ~ .carousel-dots label[for="slide-3"] {
  width: 34px;
  background: var(--lime);
}


.feature-card {
  min-height: 430px;
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  border: 2px solid var(--violet);
  background:
    linear-gradient(180deg, rgba(15, 15, 22, .18), rgba(15, 15, 22, .78)),
    radial-gradient(circle at 74% 24%, rgba(135, 83, 255, .72), transparent 28%),
    linear-gradient(125deg, #08080d 0%, #14131d 45%, #1e2434 100%);
  color: #fff;
  box-shadow: var(--shadow);
}

.feature-card::before,
.feature-card::after {
  content: "";
  position: absolute;
  top: -10px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--violet);
  z-index: 2;
}
.feature-card::before { left: -10px; }
.feature-card::after { right: -10px; }

.feature-top {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 30px;
  color: rgba(255,255,255,.72);
  font-size: .88rem;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.spark { color: var(--lime); font-size: 2.15rem; line-height: 1; }
.stage-lines {
  position: absolute;
  inset: 0;
  opacity: .58;
  background-image: repeating-linear-gradient(90deg, rgba(255, 255, 255, .08) 0 2px, transparent 2px 42px);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

.cue-box { position: absolute; left: 38px; right: 38px; bottom: 34px; z-index: 2; }
.cue-box h2 {
  margin: 0 0 6px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.6rem, 6vw, 4.7rem);
  letter-spacing: -.07em;
  line-height: .9;
}
.cue-box p { margin: 0; color: rgba(255,255,255,.76); font-size: 1.05rem; }

.mini-grid { display: grid; grid-template-columns: .95fr .95fr; gap: 18px; }
.mini-card {
  min-height: 170px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 250, 240, .75);
  padding: 25px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.mini-card.alt { background: var(--sand); }
.fake-lines span {
  display: block;
  height: 10px;
  border-radius: 999px;
  background: rgba(17, 17, 21, .18);
  margin-bottom: 10px;
}
.fake-lines span:first-child { width: 92%; background: var(--ink); }
.fake-lines span:nth-child(2) { width: 68%; }
.fake-lines span:nth-child(3) { width: 46%; }
.mini-card h3 { margin: 0; font-size: 1.42rem; line-height: 1.02; letter-spacing: -.06em; }

.tools { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 14px; }
.tool {
  display: grid;
  place-items: center;
  min-width: 34px;
  height: 31px;
  padding: 0 8px;
  border-radius: 8px;
  background: rgba(17, 17, 21, .72);
  color: #fff;
  font-weight: 900;
  font-size: .9rem;
}

.page-title { padding: clamp(72px, 9vw, 128px) 0 clamp(40px, 6vw, 72px); }
.page-title h1 { margin: 24px 0 22px; font-size: clamp(4.2rem, 10vw, 8rem); max-width: 980px; }

.section {
  padding: clamp(72px, 8vw, 110px) 0;
  border-top: 1px solid rgba(222, 212, 197, .7);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, .78fr) minmax(260px, .6fr);
  gap: 32px;
  align-items: end;
  margin-bottom: 42px;
}

.kicker {
  display: inline-block;
  margin-bottom: 16px;
  font-size: .83rem;
  text-transform: uppercase;
  letter-spacing: .14em;
  font-weight: 900;
  color: var(--muted);
}

.section h2 { font-size: clamp(3rem, 7vw, 6.25rem); margin-bottom: 0; }
.section-intro { color: var(--muted); font-size: 1.1rem; line-height: 1.65; max-width: 600px; }

.about-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 24px; align-items: stretch; }
.profile-card {
  background: var(--dark);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: clamp(28px, 4vw, 44px);
  position: relative;
  overflow: hidden;
  min-height: 360px;
}
.profile-card::after {
  content: "GM";
  position: absolute;
  right: -26px;
  bottom: -42px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 12rem;
  line-height: 1;
  letter-spacing: -.16em;
  color: rgba(255,255,255,.06);
  font-weight: 900;
}
.profile-card h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 3.4rem;
  line-height: .92;
  letter-spacing: -.08em;
  margin-bottom: 22px;
  position: relative;
  z-index: 1;
}
.profile-card p { color: rgba(255,255,255,.72); font-size: 1.05rem; line-height: 1.68; position: relative; z-index: 1; }

.detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.info-card,
.project-card,
.timeline-card,
.contact-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 250, 240, .66);
  padding: 28px;
  box-shadow: 0 16px 50px rgba(17, 17, 21, .045);
}
.info-card h3,
.project-card h3,
.timeline-card h3,
.contact-card h3 { margin-bottom: 10px; font-size: 1.45rem; line-height: 1.08; letter-spacing: -.055em; }
.info-card p,
.project-card p,
.timeline-card p,
.contact-card p { color: var(--muted); margin-bottom: 0; line-height: 1.65; }

.project-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.project-card {
  min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform .22s ease, box-shadow .22s ease;
}
.project-card:hover { transform: translateY(-5px); box-shadow: 0 28px 70px rgba(17, 17, 21, .10); }
.project-card.featured {
  grid-column: span 2;
  background:
    linear-gradient(180deg, rgba(15, 15, 22, .08), rgba(15, 15, 22, .72)),
    radial-gradient(circle at 68% 26%, rgba(230, 255, 63, .28), transparent 26%),
    var(--dark);
  color: #fff;
  border-color: rgba(255,255,255,.12);
}
.project-card.featured p,
.project-card.featured .meta { color: rgba(255,255,255,.7); }
.project-card h3 {
  font-size: clamp(1.65rem, 3vw, 3.1rem);
  font-family: Georgia, "Times New Roman", serif;
  letter-spacing: -.08em;
  line-height: .95;
}
.meta {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 7px 12px;
  border: 1px solid currentColor;
  border-radius: 999px;
  color: var(--muted);
  font-size: .76rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 18px;
}

.cv-layout { display: grid; grid-template-columns: minmax(0, .86fr) minmax(0, 1.14fr); gap: 24px; align-items: start; }
.timeline-card { padding: clamp(28px, 4vw, 38px); }
.timeline-group + .timeline-group { margin-top: 36px; padding-top: 30px; border-top: 1px solid var(--line); }
.timeline-group h3 { margin-bottom: 18px; }
.timeline-item {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 22px;
  padding: 18px 0;
  border-top: 1px solid rgba(222, 212, 197, .7);
}
.timeline-item:first-of-type { border-top: 0; padding-top: 0; }
.year { color: var(--muted); font-size: .9rem; font-weight: 900; letter-spacing: -.02em; }
.timeline-item strong { display: block; font-size: 1.05rem; letter-spacing: -.035em; margin-bottom: 5px; }
.timeline-item span { display: block; color: var(--muted); line-height: 1.55; }
.skills-card { background: var(--sand); }
.tag-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.tag {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid rgba(17, 17, 21, .13);
  background: rgba(255,255,255,.42);
  font-size: .88rem;
  font-weight: 800;
  color: #33312d;
}

.contact-section { padding-bottom: clamp(80px, 10vw, 140px); }
.contact-card {
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(360px, .85fr);
  align-items: center;
  gap: clamp(26px, 5vw, 64px);
  padding: clamp(32px, 5vw, 56px);
  background: var(--dark);
  color: #fff;
  border-color: rgba(255,255,255,.12);
  border-radius: var(--radius-xl);
  overflow: hidden;
  position: relative;
}
.contact-card::before {
  content: "";
  position: absolute;
  inset: auto -80px -160px auto;
  width: 440px;
  height: 440px;
  border-radius: 50%;
  background: rgba(135, 83, 255, .42);
  filter: blur(26px);
}
.contact-copy,
.contact-form,
.contact-action-panel { position: relative; z-index: 1; min-width: 0; }
.contact-card h1,
.contact-card h2 { color: #fff; margin-bottom: 20px; }
.contact-card p { color: rgba(255,255,255,.7); max-width: 640px; }
.contact-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 34px;
}
.contact-quick a,
.contact-quick span {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 15px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.07);
  color: rgba(255,255,255,.88);
  font-weight: 850;
  letter-spacing: -.025em;
}
.contact-quick a:hover { background: rgba(255,255,255,.12); }
.contact-form {
  display: grid;
  gap: 16px;
  padding: clamp(22px, 3vw, 30px);
  border-radius: 28px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.07);
  box-shadow: 0 24px 80px rgba(0,0,0,.18);
  backdrop-filter: blur(18px);
}
.form-row {
  display: grid;
  gap: 8px;
}
.form-row.two-columns {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.contact-form label {
  color: rgba(255,255,255,.72);
  font-size: .82rem;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 18px;
  background: rgba(255,255,255,.08);
  color: #fff;
  font: inherit;
  font-weight: 750;
  letter-spacing: -.025em;
  outline: none;
  transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}
.contact-form input {
  height: 54px;
  padding: 0 16px;
}
.contact-form textarea {
  min-height: 150px;
  resize: vertical;
  padding: 15px 16px;
  line-height: 1.55;
}
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: rgba(255,255,255,.38); }
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: rgba(230, 255, 63, .62);
  background: rgba(255,255,255,.11);
  box-shadow: 0 0 0 4px rgba(230, 255, 63, .08);
}
.form-button {
  width: fit-content;
  margin-top: 4px;
}
.form-note {
  margin: -2px 0 0;
  color: rgba(255,255,255,.52) !important;
  font-size: .88rem;
  line-height: 1.45 !important;
}

.footer { padding: 32px 0 46px; color: var(--muted); border-top: 1px solid var(--line); font-size: .93rem; }
.footer .container { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }

@media (max-width: 1020px) {
  .hero-grid,
  .section-heading,
  .about-grid,
  .cv-layout,
  .contact-card { grid-template-columns: 1fr; }
  .hero-visual { max-width: 720px; }
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project-card.featured { grid-column: span 2; }
}

@media (max-width: 720px) {
  .container { width: min(100% - 30px, var(--max)); }
  .nav { min-height: auto; padding: 15px 0; align-items: flex-start; flex-direction: column; gap: 14px; }
  .brand-mark { width: 45px; height: 45px; }
  .brand span span { font-size: .78rem; white-space: normal; }
  .nav-links { width: 100%; overflow-x: auto; gap: 18px; padding-bottom: 2px; }
  .nav-links a { flex: 0 0 auto; font-size: .95rem; }
  .hero { padding-top: 52px; }
  .hero h1, .page-title h1 { margin-top: 30px; font-size: clamp(3.6rem, 18vw, 5.3rem); }
  .feature-card { min-height: 350px; }
  .image-carousel { min-height: 350px; }
  .carousel-slide figcaption strong { font-size: clamp(2.55rem, 12vw, 3.6rem); }
  .mini-grid,
  .detail-grid,
  .project-grid { grid-template-columns: 1fr; }
  .project-card.featured { grid-column: span 1; }
  .timeline-item { grid-template-columns: 1fr; gap: 7px; }
  .section h2 { font-size: clamp(3.1rem, 16vw, 4.6rem); }
  .form-row.two-columns { grid-template-columns: 1fr; }
  .contact-card { border-radius: 28px; }
}


/* Contact action panel refinements */
.contact-action-panel {
  align-self: center;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: clamp(24px, 4vw, 34px);
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 30px;
  background: rgba(255,255,255,.06);
  box-shadow: 0 24px 80px rgba(0,0,0,.14);
  backdrop-filter: blur(18px);
}
.contact-action-panel .panel-label {
  color: rgba(255,255,255,.55);
  font-size: .82rem;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.contact-action-panel h3 {
  color: #fff;
  margin: 0;
  max-width: 520px;
  font-size: clamp(2.25rem, 4.2vw, 4.5rem);
  line-height: .92;
  letter-spacing: -.08em;
  font-family: Georgia, "Times New Roman", serif;
}
.contact-action-panel p {
  margin: 0;
  max-width: 520px;
}
.contact-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 10px;
}
.button-outline-light {
  background: rgba(255,255,255,.07);
  color: #fff;
  border: 1px solid rgba(255,255,255,.18);
}
.button-outline-light:hover { background: rgba(255,255,255,.12); }


/* Ajustes página Contacto */
.contact-title {
  margin-bottom: 22px !important;
  max-width: 100%;
}
.contact-title span,
.contact-title small {
  display: block;
  color: #fff;
}
.contact-title span {
  font-size: clamp(4rem, 5.1vw, 5.75rem);
  line-height: .84;
  max-width: 100%;
  letter-spacing: -.09em;
}
.contact-title small {
  margin-top: 8px;
  font: inherit;
  font-size: clamp(2.35rem, 3.35vw, 3.65rem);
  line-height: .88;
  letter-spacing: -.085em;
}
.contact-action-panel h3 {
  font-size: clamp(1.55rem, 2.8vw, 2.35rem);
  line-height: 1;
  max-width: 560px;
}
.contact-action-panel p { display: none; }
.contact-buttons { margin-top: 4px; }


@media (min-width: 1161px) {
  .contact-copy { overflow: hidden; }
  .contact-action-panel { justify-self: stretch; }
}

@media (max-width: 1160px) {
  .contact-card {
    grid-template-columns: 1fr;
  }
  .contact-action-panel {
    align-self: stretch;
  }
}

@media (max-width: 720px) {
  .contact-title span {
    font-size: clamp(3.8rem, 16vw, 5.2rem);
  }
  .contact-title small {
    font-size: clamp(2.25rem, 10vw, 3.3rem);
  }
}



/* === Página Proyectos interactiva === */
.button,
.form-launch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 900;
  letter-spacing: -.025em;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
}
.button:hover,
.form-launch:hover { transform: translateY(-2px); box-shadow: 0 16px 30px rgba(0,0,0,.15); }
.button-light { background: #fff; color: var(--dark); }

.projects-title h1 { max-width: 760px; }
.projects-section { padding-top: clamp(48px, 6vw, 84px); }
.project-board { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; align-items: stretch; }
.project-flip-card, .project-open-card { min-height: 360px; border: 0; background: transparent; padding: 0; text-align: left; color: inherit; font: inherit; }
.project-flip-card { perspective: 1600px; cursor: pointer; }
.project-featured { grid-column: span 2; min-height: 430px; }
.project-flip-inner { position: relative; min-height: inherit; height: 100%; transform-style: preserve-3d; transition: transform .72s cubic-bezier(.2,.8,.2,1); }
.project-flip-card.is-flipped .project-flip-inner { transform: rotateY(180deg); }
.project-face { position: absolute; inset: 0; min-height: inherit; backface-visibility: hidden; -webkit-backface-visibility: hidden; border-radius: var(--radius-lg); border: 1px solid var(--line); overflow: hidden; }
.project-front { display: flex; flex-direction: column; justify-content: space-between; padding: clamp(28px, 4vw, 42px); background: rgba(255,250,240,.7); box-shadow: 0 16px 50px rgba(17,17,21,.045); }
.project-face-dark { background: linear-gradient(180deg, rgba(15,15,22,.04), rgba(15,15,22,.72)), radial-gradient(circle at 72% 26%, rgba(230,255,63,.23), transparent 24%), var(--dark); color: #fff; border-color: rgba(255,255,255,.12); }
.project-face-dark .meta, .project-face-dark p { color: rgba(255,255,255,.72); }
.project-face h3, .open-card-title { display: block; font-family: Georgia, "Times New Roman", serif; font-size: clamp(2.25rem, 4vw, 4.65rem); line-height: .88; letter-spacing: -.085em; font-weight: 900; margin: 0; }
.project-front p, .open-card-text { color: var(--muted); font-size: 1.05rem; line-height: 1.6; max-width: 700px; display: block; margin-top: 22px; }
.card-hint { display: inline-flex; width: fit-content; margin-top: 18px; color: inherit; opacity: .72; font-size: .86rem; font-weight: 900; letter-spacing: .02em; }
.project-back { transform: rotateY(180deg); background: var(--dark); color: #fff; border-color: rgba(255,255,255,.12); }
.flip-close, .modal-close { position: absolute; z-index: 6; top: 18px; right: 18px; border: 1px solid rgba(255,255,255,.18); background: rgba(15,15,22,.72); color: #fff; border-radius: 999px; min-height: 40px; padding: 0 14px; font-weight: 900; cursor: pointer; backdrop-filter: blur(12px); }
.project-open-card { display: flex; flex-direction: column; justify-content: space-between; border: 1px solid var(--line); border-radius: var(--radius-lg); background: rgba(255,250,240,.7); padding: clamp(28px, 3.5vw, 36px); box-shadow: 0 16px 50px rgba(17,17,21,.045); cursor: pointer; transition: transform .22s ease, box-shadow .22s ease, background .22s ease; }
.project-open-card:hover, .project-open-card:focus-visible { transform: translateY(-5px); box-shadow: 0 28px 70px rgba(17,17,21,.10); outline: none; }
.project-open-card .open-card-title { font-size: clamp(2rem, 3.2vw, 3.65rem); }
.card-carousel { position: absolute; inset: 0; overflow: hidden; background: var(--dark); }
.card-carousel-window, .card-carousel-track, .card-carousel-slide { height: 100%; min-height: inherit; }
.card-carousel-window { overflow: hidden; }
.card-carousel-track { display: flex; transition: transform .48s cubic-bezier(.2,.8,.2,1); }
.card-carousel-slide { position: relative; min-width: 100%; margin: 0; }
.card-carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  background: var(--dark);
  cursor: zoom-in;
}
.card-carousel-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 35%, rgba(15,15,22,.78)); }
.card-carousel-slide figcaption { position: absolute; z-index: 2; left: clamp(22px, 4vw, 36px); bottom: clamp(22px, 4vw, 34px); right: 100px; color: #fff; font-family: Georgia, "Times New Roman", serif; font-size: clamp(2rem, 4vw, 4.2rem); line-height: .9; letter-spacing: -.08em; font-weight: 900; }
.carousel-arrow { position: absolute; z-index: 5; top: 50%; transform: translateY(-50%); width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(255,255,255,.18); background: rgba(15,15,22,.62); color: #fff; font-size: 2rem; line-height: 1; cursor: pointer; backdrop-filter: blur(12px); }
.carousel-prev { left: 18px; }
.carousel-next { right: 18px; }
.card-carousel-dots { position: absolute; z-index: 5; right: 26px; bottom: 26px; display: flex; gap: 8px; }
.card-carousel-dots button { width: 12px; height: 12px; border: 0; border-radius: 999px; background: rgba(255,255,255,.46); padding: 0; cursor: pointer; transition: width .22s ease, background .22s ease; }
.card-carousel-dots button.active { width: 34px; background: var(--lime); }
.project-modal[aria-hidden="true"] { display: none; }
.project-modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 24px; }
.project-modal-backdrop { position: absolute; inset: 0; background: rgba(15,15,22,.62); backdrop-filter: blur(14px); }
.project-modal-dialog { position: relative; z-index: 1; width: min(1080px, 100%); max-height: min(760px, calc(100vh - 48px)); min-height: min(680px, calc(100vh - 48px)); border-radius: var(--radius-xl); overflow: hidden; background: var(--dark); color: #fff; box-shadow: 0 38px 120px rgba(0,0,0,.36); display: grid; grid-template-columns: minmax(260px, .62fr) minmax(0, 1fr); }
.modal-copy { padding: clamp(30px, 4vw, 48px); background: radial-gradient(circle at 82% 72%, rgba(135,83,255,.22), transparent 42%), var(--dark); }
.modal-copy .meta { color: rgba(255,255,255,.7); }
.modal-copy h2 { font-family: Georgia, "Times New Roman", serif; font-size: clamp(3.2rem, 6vw, 5.8rem); line-height: .86; letter-spacing: -.09em; margin: 20px 0 22px; }
.modal-copy p { color: rgba(255,255,255,.7); line-height: 1.62; }
.modal-carousel { position: relative; min-height: 100%; }
body.modal-open { overflow: hidden; }

@media (max-width: 1020px) {
  .project-board { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project-featured, .project-alumbrado { grid-column: span 2; }
  .project-modal-dialog { grid-template-columns: 1fr; min-height: calc(100vh - 48px); }
  .modal-copy { padding-bottom: 18px; }
  .modal-carousel { min-height: 420px; }
}
@media (max-width: 720px) {
  .project-board { grid-template-columns: 1fr; }
  .project-featured, .project-alumbrado { grid-column: span 1; min-height: 430px; }
  .project-open-card { min-height: 300px; }
  .project-modal { padding: 14px; }
  .project-modal-dialog { min-height: calc(100vh - 28px); border-radius: 28px; }
  .modal-carousel { min-height: 360px; }
  .carousel-arrow { width: 42px; height: 42px; }
}

/* === Ajuste fino: página Proyectos === */
@media (min-width: 1021px) {
  .project-board {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-auto-rows: minmax(430px, auto);
    gap: 22px;
    align-items: stretch;
  }

  .project-conciertos {
    grid-column: 1 / span 2;
    grid-row: 1;
    min-height: 430px;
  }

  .project-ghost {
    grid-column: 3;
    grid-row: 1;
    min-height: 430px;
  }

  .project-cineman {
    grid-column: 4;
    grid-row: 1;
    min-height: 430px;
  }

  .project-alumbrado {
    grid-column: 1 / span 4;
    grid-row: 2;
    min-height: 430px;
  }

  .project-conciertos .project-face h3 {
    font-size: clamp(3rem, 4.4vw, 5.15rem);
    max-width: 760px;
  }

  .project-alumbrado .project-face h3 {
    font-size: clamp(2.45rem, 3.55vw, 4.35rem);
    max-width: 760px;
  }
}

.project-back .card-carousel-slide figcaption {
  left: clamp(24px, 3vw, 38px);
  right: 92px;
  bottom: clamp(22px, 3vw, 32px);
  font-size: clamp(1.65rem, 3vw, 3.35rem);
  line-height: .92;
}

.project-back .card-carousel-slide::after,
.modal-carousel .card-carousel-slide::after {
  background: linear-gradient(180deg, rgba(15,15,22,.08), rgba(15,15,22,.72));
}

.project-open-card .open-card-title {
  word-break: normal;
  overflow-wrap: normal;
}

@media (max-width: 1020px) {
  .project-conciertos,
  .project-alumbrado {
    min-height: 470px;
  }
}


/* Carrusel de inicio: limpio, sin textos encima de las fotos */
.image-carousel.clean-carousel .carousel-slide::after { background: none; }
.image-carousel.clean-carousel .carousel-slide img {
  object-position: center center;
  cursor: zoom-in;
}

/* Visor de imagen completa */
.full-image-viewer[aria-hidden="true"] { display: none; }
.full-image-viewer {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(15,15,22,.9);
  backdrop-filter: blur(14px);
}
.full-image-viewer img {
  max-width: calc(100vw - 56px);
  max-height: calc(100vh - 76px);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 18px;
  box-shadow: 0 32px 100px rgba(0,0,0,.48);
}
.full-image-close {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 301;
  border: 1px solid rgba(255,255,255,.2);
  background: rgba(15,15,22,.76);
  color: #fff;
  width: 46px;
  height: 46px;
  border-radius: 999px;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(12px);
}
