/* ACREVIA — Coverflow 3D (Projects, home) */

.coverflow-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
  isolation: isolate;
}

.coverflow-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: var(--cf-grad, var(--grad-purple));
  transition: background 700ms ease;
}
.coverflow-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 40%, rgba(12,12,18,.05) 0%, rgba(12,12,18,.75) 100%);
}

/* Difuminado hacia el fondo de la página, sin corte duro — pseudo-elementos
   en vez de mask-image (mask tiene soporte poco confiable en Safari/iOS). */
.coverflow-wrap::before,
.coverflow-wrap::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  height: 110px;
  z-index: 1;
  pointer-events: none;
}
.coverflow-wrap::before { top: 0; background: linear-gradient(to bottom, var(--bg) 0%, rgba(247,245,239,0) 100%); }
.coverflow-wrap::after { bottom: 0; background: linear-gradient(to top, var(--bg) 0%, rgba(247,245,239,0) 100%); }

@media (max-width: 720px) {
  .coverflow-wrap::before,
  .coverflow-wrap::after { height: 64px; }
}

.coverflow {
  position: relative;
  z-index: 2;
  padding: 56px 0 40px;
  touch-action: pan-y;
}

.coverflow-stage {
  position: relative;
  width: 100%;
  height: 460px;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1400px;
}

.cf-slide {
  position: absolute;
  width: 280px;
  height: 400px;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: #0C0C12;
  border: 1px solid rgba(255,255,255,.14);
  transform-origin: center center;
  transition: transform 700ms cubic-bezier(.25,1,.5,1), opacity 700ms cubic-bezier(.25,1,.5,1), filter 700ms ease;
  cursor: pointer;
}
.cf-slide.is-active { cursor: default; box-shadow: 0 25px 60px rgba(0,0,0,.45), 0 0 0 1px rgba(255,255,255,.08); }

.cf-slide-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cf-slide-initials {
  font-family: var(--font-display);
  font-size: 46px;
  font-weight: 800;
  color: rgba(255,255,255,.92);
  letter-spacing: -.01em;
}

.cf-slide-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.25) 0%, rgba(0,0,0,.05) 30%, rgba(0,0,0,.65) 62%, rgba(0,0,0,.94) 100%);
  pointer-events: none;
}

.cf-slide-content {
  position: relative;
  height: 100%;
  padding: 18px 18px 22px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  text-align: center;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 400ms ease, transform 400ms ease;
  pointer-events: none;
}
.cf-slide.is-active .cf-slide-content { opacity: 1; transform: translateY(0); pointer-events: auto; }

.cf-slide-tag {
  align-self: flex-end;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  color: rgba(255,255,255,.85);
  text-shadow: 0 2px 6px rgba(0,0,0,.7);
  margin-bottom: auto;
}

.cf-slide-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  line-height: 1.15;
  text-shadow: 0 3px 12px rgba(0,0,0,.85);
}

.cf-slide-line {
  width: 30px;
  height: 2px;
  background: var(--gold-vivid);
  border-radius: 2px;
  margin: 8px auto 8px;
}

.cf-slide-desc {
  font-family: var(--font-body);
  font-size: 13px;
  color: rgba(255,255,255,.88);
  line-height: 1.4;
  margin: 0 0 14px;
  text-shadow: 0 2px 8px rgba(0,0,0,.85);
}

.cf-slide-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  align-self: center;
  padding: 9px 20px;
  border-radius: 100px;
  background: #fff;
  color: var(--text);
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .03em;
  text-decoration: none;
  transition: transform .2s;
}
.cf-slide-cta:hover { transform: translateY(-2px); }

.coverflow-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-top: 8px;
}

.cf-arrow {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.25);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .2s, transform .2s;
  flex-shrink: 0;
}
.cf-arrow:hover { background: rgba(255,255,255,.22); transform: translateY(-1px); }

.cf-dots { display: flex; align-items: center; gap: 7px; }
.cf-dot {
  height: 7px;
  width: 7px;
  border-radius: 100px;
  background: rgba(255,255,255,.35);
  border: none;
  cursor: pointer;
  transition: width .3s, background .3s;
  padding: 0;
}
.cf-dot.is-active { width: 22px; background: #fff; }

@media (max-width: 720px) {
  .coverflow-stage { height: 400px; }
  .cf-slide { width: 230px; height: 340px; }
  .cf-slide-title { font-size: 18px; }
}
