/* Australbyte — design system & modern UI */

:root {
  --cyan-light: #8ecae6;
  --cyan: #219ebc;
  --navy: #023047;
  --orange: #fb8500;
  --gold: #ffb703;
  --cream: #eff6e0;
  --glass: rgba(2, 48, 71, 0.72);
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 8px 32px rgba(0, 0, 20, 0.35);
  --shadow-hover: 0 16px 48px rgba(0, 0, 20, 0.45);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
  --header-h: 4rem;
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --motion-ok: 0;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Glass header */
header {
  background: var(--glass) !important;
  background-image: none !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(142, 202, 230, 0.15);
  height: var(--header-h);
  transition: height 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}

header.header--scrolled {
  height: 3.25rem;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25);
}

header.header--scrolled .logo img {
  max-height: 2.4em;
}

.menu {
  background: var(--glass) !important;
  background-image: none !important;
  backdrop-filter: blur(14px);
  border-bottom-left-radius: var(--radius);
  border: 1px solid rgba(142, 202, 230, 0.12);
  border-top: none;
}

#titulo, .titulo {
  transition: color 0.2s ease;
}

#titulo:hover, .titulo:hover {
  color: var(--gold) !important;
}

.active1, .active {
  background: rgba(33, 158, 188, 0.35) !important;
  border-color: rgba(255, 183, 3, 0.5) !important;
}

/* Hero orbit */
.parallax-container {
  isolation: isolate;
}

.parallax-container::before,
.parallax-container::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  z-index: 2;
  pointer-events: none;
  opacity: 0.55;
}

.parallax-container::before {
  width: min(420px, 55vw);
  height: min(420px, 55vw);
  background: var(--cyan);
  top: 15%;
  left: -8%;
  animation: orbit-float-a 28s ease-in-out infinite;
}

.parallax-container::after {
  width: min(360px, 45vw);
  height: min(360px, 45vw);
  background: var(--orange);
  bottom: 10%;
  right: -5%;
  animation: orbit-float-b 32s ease-in-out infinite;
}

.hero-grid {
  position: absolute;
  inset: 0;
  z-index: 2;
  background-image:
    radial-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(180deg, black 20%, transparent 95%);
  pointer-events: none;
}

.parallax::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 48, 71, 0.35) 0%,
    rgba(2, 48, 71, 0.65) 70%,
    rgba(2, 48, 71, 0.85) 100%
  );
  z-index: 1;
}

.banner-text {
  z-index: 4;
  width: min(92%, 720px);
}

/* Trust strip — barra inferior del hero */
.trust-strip {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0 2.5rem;
  padding: 1.1rem 1.5rem;
  background: rgba(2, 48, 71, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid rgba(142, 202, 230, 0.3);
}

.trust-item {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  color: var(--cream);
  white-space: nowrap;
}

.trust-item strong {
  font-size: 1.25rem;
  color: var(--gold);
}

.trust-item span {
  font-size: 0.85rem;
  opacity: 0.95;
}

@media (min-width: 640px) {
  .trust-item:not(:last-child) {
    padding-right: 2.5rem;
    border-right: 1px solid rgba(142, 202, 230, 0.25);
  }
}

/* Section titles */
.banner-text h1 {
  font-size: 3em;
  font-weight: bolder;
  background: linear-gradient(135deg, #fff 0%, var(--cyan-light) 40%, var(--gold) 75%, var(--orange) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  opacity: 0;
  animation: hero-fade-in-down 3s var(--ease-smooth) both;
}

.banner-text .hero-tagline {
  font-size: 1.5em;
  background: linear-gradient(135deg, #fff 0%, var(--cyan-light) 45%, var(--gold) 80%, var(--orange) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  opacity: 0;
  animation: hero-fade-in-down 4s var(--ease-smooth) 0.5s both;
}

.hero-cta-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  margin-top: 1.75rem;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0;
  padding: 0.75rem 1.5rem;
  background: var(--orange);
  color: #fff;
  font-size: 0.85rem;
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 0 4px 20px rgba(251, 133, 0, 0.4);
  transition: transform 0.45s var(--ease-smooth), box-shadow 0.45s var(--ease-smooth), background 0.45s var(--ease-smooth), border-color 0.45s var(--ease-smooth);
  opacity: 0;
  animation: hero-fade-in-place 4s var(--ease-smooth) 1.2s both;
}

.hero-cta--contact {
  background: transparent;
  border: 2px solid rgba(142, 202, 230, 0.75);
  box-shadow: none;
  color: #eff6e0;
  animation-delay: 1.85s;
}

.hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(251, 133, 0, 0.5);
  color: #fff;
}

.hero-cta--contact:hover {
  background: rgba(33, 158, 188, 0.4);
  border-color: var(--gold);
  box-shadow: 0 6px 24px rgba(33, 158, 188, 0.25);
  color: #fff;
}

.hero-cta i {
  transition: transform 0.45s var(--ease-smooth);
}

.hero-cta:hover i {
  transform: translateX(4px);
}

@keyframes orbit-float-a {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(40px, 30px); }
}

@keyframes orbit-float-b {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(-35px, -25px); }
}

/* Hero: igual que otras vistas — texto de arriba hacia abajo; botón en su lugar */
@keyframes hero-fade-in-down {
  from {
    opacity: 0;
    transform: translate3d(0, -2.75rem, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes hero-fade-in-place {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .banner-text h1,
  .banner-text .hero-tagline,
  .hero-cta,
  .hero-cta--contact {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

/* Scroll reveal */
[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 1s var(--ease-smooth),
    transform 1s var(--ease-smooth);
  will-change: opacity, transform;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
  will-change: auto;
}

.tituloBody[data-reveal] {
  transform: translateY(10px);
  transition:
    opacity 1.1s var(--ease-smooth),
    transform 1.1s var(--ease-smooth);
}

/* Section titles */
.bento-section .tituloBody {
  margin-top: 1em !important;
  margin-bottom: 1em !important;
}

.section-sub {
  text-align: center;
  color: #fff;
  font-size: 1em;
  max-width: 36rem;
  margin: 0 auto 2em;
  padding: 0 1rem;
}

/* Bento featured services */
#servicios {
  scroll-margin-top: 6rem;
}

/* Indicador scroll — arriba de "TODOS LOS SERVICIOS" */
.services-all-section {
  padding-top: 0.5rem;
}

.scroll-hint {
  display: flex;
  justify-content: center;
  margin: 1.5rem auto 0.25rem;
}

.scroll-hint__mouse {
  display: block;
  width: 26px;
  height: 42px;
  border: 2px solid rgba(142, 202, 230, 0.75);
  border-radius: 14px;
  position: relative;
  box-shadow: 0 0 12px rgba(142, 202, 230, 0.15);
}

.scroll-hint__wheel {
  position: absolute;
  left: 50%;
  top: 9px;
  width: 4px;
  height: 8px;
  margin-left: -2px;
  background: var(--gold);
  border-radius: 2px;
  animation: scroll-hint-wheel 2.2s var(--ease-smooth) infinite;
}

@keyframes scroll-hint-wheel {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  65% {
    opacity: 0.15;
    transform: translateY(14px);
  }
  100% {
    opacity: 0;
    transform: translateY(14px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-hint__wheel {
    animation: none;
    opacity: 0.7;
  }
}

.bento-section {
  padding: 0 1.5rem 3rem;
  max-width: 72rem;
  margin: 0 auto;
}

.bento-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  grid-template-rows: auto auto;
  gap: 1.25rem;
}

.bento-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: rgba(33, 158, 188, 0.25);
  border: 1px solid rgba(142, 202, 230, 0.25);
  min-height: 220px;
  transition:
    transform 0.55s var(--ease-smooth),
    box-shadow 0.55s var(--ease-smooth),
    border-color 0.55s var(--ease-smooth);
}

.bento-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.bento-card--large {
  grid-row: span 2;
  min-height: 460px;
}

.bento-card__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.8s var(--ease-smooth);
}

.bento-card:hover .bento-card__bg {
  transform: scale(1.03);
}

.bento-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    0deg,
    rgba(2, 48, 71, 0.96) 0%,
    rgba(2, 48, 71, 0.82) 40%,
    rgba(2, 48, 71, 0.35) 70%,
    rgba(2, 48, 71, 0.12) 100%
  );
}

/* Cards pequeñas: más oscuro donde va el texto */
.bento-card:not(.bento-card--large) .bento-card__overlay {
  background: linear-gradient(
    0deg,
    rgba(2, 48, 71, 0.98) 0%,
    rgba(2, 48, 71, 0.94) 50%,
    rgba(2, 48, 71, 0.55) 78%,
    rgba(2, 48, 71, 0.2) 100%
  );
}

.bento-card__content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  color: #fff;
}

.bento-card__content h3 {
  font-size: 1.25rem;
  letter-spacing: 0.06em;
  margin-bottom: 0.5rem;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.65);
}

.bento-card__content p {
  font-size: 0.9rem;
  line-height: 1.5;
  opacity: 1;
  margin-bottom: 1rem;
  color: rgba(239, 246, 224, 0.95);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

.bento-card:not(.bento-card--large) .bento-card__content {
  background: linear-gradient(
    0deg,
    rgba(2, 48, 71, 0.55) 0%,
    transparent 55%
  );
}

.bento-card .btn-like {
  align-self: flex-start;
  margin-top: 0;
}

/* Cards grid (home + enhanced) */
.card-container--grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.75rem;
  max-width: 72rem;
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
}

.card {
  position: relative;
  border-radius: var(--radius-lg) !important;
  background: linear-gradient(145deg, rgba(33, 158, 188, 0.95), rgba(2, 48, 71, 0.85)) !important;
  border: 1px solid rgba(142, 202, 230, 0.2);
  transition:
    transform 0.55s var(--ease-smooth),
    box-shadow 0.55s var(--ease-smooth),
    border-color 0.55s var(--ease-smooth);
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(251, 133, 0, 0.45);
}

.card-image {
  transition: transform 0.75s var(--ease-smooth);
}

.card:hover .card-image {
  transform: scale(1.02);
}

.h3Card {
  line-height: 1.35;
  padding-bottom: 10px;
}

.card-content h3 {
  height: auto;
  min-height: 0;
}

.pCard {
  line-height: 1.6;
}

.btn-like {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px !important;
  font-size: 0.8rem !important;
  transition: background 0.45s var(--ease-smooth), color 0.45s var(--ease-smooth), transform 0.45s var(--ease-smooth) !important;
}

.btn-like::after {
  content: "→";
  transition: transform 0.45s var(--ease-smooth);
}

.btn-like:hover::after {
  transform: translateX(4px);
}

.btn-like:hover {
  transform: translateY(-1px);
}

/* Footer */
footer {
  position: relative !important;
  margin-top: 4rem;
}

footer::before {
  background: linear-gradient(180deg, rgba(2, 48, 71, 0.3), rgba(0, 0, 0, 0.65)) !important;
}

/* Floating actions */
.open {
  bottom: 0 !important;
  width: auto !important;
  background: transparent !important;
  padding-bottom: 0 !important;
  overflow: visible !important;
}

#open-button {
  position: relative !important;
  bottom: auto !important;
  right: auto !important;
  width: 50px;
  height: 50px;
  margin-bottom: 8px !important;
  padding: 0 !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  border-radius: 50% !important;
  box-shadow: 0 4px 20px rgba(251, 133, 0, 0.45) !important;
  transition: transform 1.15s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s ease !important;
}

#open-button i {
  display: block;
  line-height: 1;
  margin-top: -2px;
}

.whatsapp {
  position: relative !important;
  bottom: auto !important;
  right: auto !important;
  transition: transform 0.45s var(--ease-smooth);
}

.whatsapp:hover {
  transform: scale(1.08);
}

.whatsapp:hover {
  transform: scale(1.08);
}

#goTopBtn {
  color: var(--gold) !important;
}

/* IA page accent */
body.page-ia .parallax-container::before {
  background: linear-gradient(135deg, var(--cyan), #7b2cbf);
  opacity: 0.45;
}

@media (max-width: 900px) {
  .bento-grid {
    grid-template-columns: 1fr;
  }

  .bento-card--large {
    grid-row: span 1;
    min-height: 280px;
  }
}

@media (max-width: 768px) {
  .banner-text h1 {
    font-size: 2em;
  }

  .banner-text .hero-tagline {
    font-size: 1em;
  }

  .trust-strip {
    gap: 0.75rem 1.25rem;
    padding: 0.9rem 1rem;
  }

  .trust-item {
    white-space: normal;
    flex: 1 1 auto;
    min-width: 140px;
    justify-content: center;
  }

  .trust-item:not(:last-child) {
    padding-right: 0;
    border-right: none;
  }

  .trust-item strong {
    font-size: 1.1rem;
  }

  .trust-item span {
    font-size: 0.75rem;
  }

  .card-container--grid {
    grid-template-columns: 1fr;
  }
}

/* Override legacy row-layout cards on home grid */
.card-container--grid .card {
  display: flex !important;
  flex-direction: column !important;
  width: 100% !important;
  max-width: none !important;
  height: auto !important;
  margin: 0 !important;
}

.card-container--grid .card-image {
  width: 100% !important;
  margin: 0 !important;
  border-radius: 0;
}

@media only screen and (min-width: 1045px) {
  .card-container--grid {
    display: grid !important;
    flex-wrap: unset !important;
  }
}
