/* ===== Aura Civillab – animations & interaction effects =====
   Everything here is additive. Delete the <link> to this file (and js/effects.js)
   to go back to a static site. */

:root{ --ease:cubic-bezier(.22,.8,.3,1); }

/* ---------- Page fade in / out ---------- */
body{ animation:pageIn .5s var(--ease) backwards; }
body.leaving{ opacity:0; transition:opacity .28s ease; }
@keyframes pageIn{ from{opacity:0} }

/* ---------- Scroll progress bar ---------- */
.scroll-progress{ position:fixed; top:0; left:0; right:0; height:3px; z-index:200; pointer-events:none;
  background:linear-gradient(90deg,var(--red),#ff6a6f); transform-origin:0 50%; transform:scaleX(0); }

/* ---------- Header ---------- */
.site-header{ transition:box-shadow .3s, background-color .3s; }
.site-header.scrolled{ box-shadow:0 6px 24px rgba(183,28,33,.12); background:rgba(255,255,255,.92);
  -webkit-backdrop-filter:blur(10px); backdrop-filter:blur(10px); }
.brand img{ transition:height .3s var(--ease), transform .3s var(--ease); }
.site-header.scrolled .brand img{ height:40px; }
@media (hover:hover){.brand:hover img{ transform:scale(1.05); }}

/* nav underline + scrollspy */
.nav-links a{ position:relative; }
.nav-links a::after{ content:""; position:absolute; left:4px; right:4px; bottom:6px; height:2px; background:var(--red);
  transform:scaleX(0); transform-origin:left; transition:transform .3s var(--ease); }
.nav-links a.active::after{ transform:scaleX(1); } @media (hover:hover){.nav-links a:hover::after{ transform:scaleX(1); }}
.nav-links a.active{ color:var(--red); }

/* hamburger / mobile menu */
.menu-toggle i{ display:inline-block; transition:transform .3s var(--ease); }
.menu-toggle.is-open i{ transform:rotate(180deg); }
.nav-links.open{ animation:menuDrop .3s var(--ease); }
@keyframes menuDrop{ from{ opacity:0; transform:translateY(-10px); } }
.icon-btn{ transition:transform .25s var(--ease), background .2s, box-shadow .25s; }
@media (hover:hover){.icon-btn:hover{ transform:rotate(-8deg) scale(1.1); box-shadow:0 6px 16px rgba(236,50,55,.4); }}

/* ---------- Hero entrance ---------- */
.hero .eyebrow, .hero h1, .hero .lead, .hero-actions, .hero-points{ animation:heroUp .8s var(--ease) backwards; }
.hero .eyebrow{ animation-delay:.1s } .hero h1{ animation-delay:.2s } .hero .lead{ animation-delay:.32s }
.hero-actions{ animation-delay:.44s } .hero-points{ animation-delay:.56s }
@keyframes heroUp{ from{ opacity:0; transform:translateY(28px); } }
.hero-img{ animation:heroImg 1s var(--ease) .25s backwards; will-change:transform; }
@keyframes heroImg{ from{ opacity:0; transform:translateX(50px) scale(.94); } }
.hero-img img{ animation:floaty 6s ease-in-out 1.3s infinite; }
@keyframes floaty{ 50%{ transform:translateY(-10px); } }
.hero h1 span{ background:linear-gradient(90deg,var(--red),#ff7a7e,var(--red)); background-size:200% 100%;
  -webkit-background-clip:text; background-clip:text; color:transparent; animation:shine 4s linear infinite; }
@keyframes shine{ to{ background-position:200% 0; } }

/* ---------- Scroll reveal ---------- */
.js .reveal:not(.in){ opacity:0; }
.reveal.in{ animation:revealUp .75s var(--ease) var(--d,0s) backwards; }
.reveal[data-reveal="left"].in{ animation-name:revealLeft; }
.reveal[data-reveal="right"].in{ animation-name:revealRight; }
.reveal[data-reveal="zoom"].in{ animation-name:revealZoom; }
@keyframes revealUp{ from{ opacity:0; transform:translateY(40px); } }
@keyframes revealLeft{ from{ opacity:0; transform:translateX(-50px); } }
@keyframes revealRight{ from{ opacity:0; transform:translateX(50px); } }
@keyframes revealZoom{ from{ opacity:0; transform:scale(.88); } }

/* section headings get an animated red underline when revealed */
.section-head h2{ position:relative; display:inline-block; }
.section-head h2::after{ content:""; display:block; height:3px; width:0; margin:8px auto 0; border-radius:3px; background:var(--red);
  transition:width .7s var(--ease) .3s; }
.section-head.in h2::after{ width:56px; }

/* ---------- Cards: hover + press ---------- */
.cat-card:active, .pcard:active{ transform:scale(.98); transition-duration:.1s; }
.cat-icon{ transition:transform .35s var(--ease), background .25s, color .25s; }
@media (hover:hover){.cat-card:hover .cat-icon{ transform:rotate(-8deg) scale(1.12); background:var(--red); color:#fff; }}
.cat-num{ transition:transform .4s var(--ease), color .3s; }
@media (hover:hover){.cat-card:hover .cat-num{ transform:translateX(-6px) scale(1.1); color:#f3c4c6; }}
.pimg img{ transition:transform .5s var(--ease); }
@media (hover:hover){.pcard:hover .pimg img{ transform:scale(1.07); }}
.pcard::before{ content:""; position:absolute; left:0; top:0; height:3px; width:100%; background:var(--red);
  transform:scaleX(0); transform-origin:left; transition:transform .4s var(--ease); z-index:2; }
.pcard{ position:relative; }
@media (hover:hover){.pcard:hover::before{ transform:scaleX(1); }}
.link-btn i{ transition:transform .2s; } @media (hover:hover){.link-btn:hover i{ transform:translateX(4px); }}
.branch{ transition:transform .25s var(--ease), box-shadow .25s, border-color .25s; }
@media (hover:hover){.branch:hover{ transform:translateX(6px); box-shadow:var(--shadow); border-color:#e9b3b5; }}
.chip{ transition:transform .2s var(--ease), background .2s, color .2s, border-color .2s; }
@media (hover:hover){.chip:hover{ transform:translateY(-2px); }} .chip:active{ transform:scale(.95); }
.insta{ transition:transform .3s var(--ease), box-shadow .3s; }
@media (hover:hover){.insta:hover{ transform:translateY(-4px); box-shadow:0 18px 36px rgba(183,28,33,.3); }}
.insta>i{ display:inline-block; animation:pulse 2.4s ease-in-out infinite; }
@keyframes pulse{ 50%{ transform:scale(1.15); } }
.contact-list li{ transition:transform .2s var(--ease); } @media (hover:hover){.contact-list li:hover{ transform:translateX(5px); }}
.about article{ transition:transform .3s var(--ease); } @media (hover:hover){.about article:hover{ transform:translateY(-4px); }}
.search input{ transition:box-shadow .25s, border-color .25s; }
.search input:focus{ box-shadow:0 0 0 4px rgba(236,50,55,.15); }

/* ---------- Buttons: lift, press, ripple ---------- */
.btn, .chip, .link-btn, .icon-btn, .modal-close, .to-top{ position:relative; overflow:hidden; -webkit-tap-highlight-color:transparent; }
.btn{ transition:transform .2s var(--ease), box-shadow .25s, background .2s, color .2s; }
@media (hover:hover){.btn:hover{ transform:translateY(-2px); box-shadow:0 8px 20px rgba(236,50,55,.28); }}
.btn:active{ transform:translateY(0) scale(.96); box-shadow:none; }
.btn i{ transition:transform .25s var(--ease); } @media (hover:hover){.btn:hover i{ transform:translateY(2px); }}
.ripple{ position:absolute; border-radius:50%; pointer-events:none; background:currentColor; opacity:.28;
  transform:scale(0); animation:ripple .65s ease-out forwards; }
.btn-primary .ripple, .icon-btn .ripple, .chip.active .ripple{ background:#fff; opacity:.4; }
@keyframes ripple{ to{ transform:scale(1); opacity:0; } }

/* ---------- Modal ---------- */
.modal:not([hidden]){ animation:fadeIn .25s ease; }
.modal:not([hidden]) .modal-box{ animation:popIn .4s var(--ease); }
.modal:not([hidden]) .modal-box > *{ animation:fadeUp .45s var(--ease) backwards; }
.modal-box > :nth-child(3){ animation-delay:.06s!important } .modal-box > :nth-child(4){ animation-delay:.1s!important }
.modal-box > :nth-child(5){ animation-delay:.14s!important } .modal-box > :nth-child(6){ animation-delay:.18s!important }
.modal-box > :nth-child(7){ animation-delay:.22s!important } .modal-box > :nth-child(8){ animation-delay:.26s!important }
.modal.closing{ animation:fadeOut .22s ease forwards!important; }
.modal.closing .modal-box{ animation:popOut .22s ease forwards!important; }
.modal-close{ transition:transform .3s var(--ease), background .2s, color .2s; }
@media (hover:hover){.modal-close:hover{ transform:rotate(90deg); background:var(--red); color:#fff; }}
@keyframes fadeIn{ from{ opacity:0 } } @keyframes fadeOut{ to{ opacity:0 } }
@keyframes popIn{ from{ opacity:0; transform:translateY(30px) scale(.9); } }
@keyframes popOut{ to{ opacity:0; transform:translateY(20px) scale(.94); } }
@keyframes fadeUp{ from{ opacity:0; transform:translateY(14px); } }

/* ---------- Back to top ---------- */
.to-top{ position:fixed; right:20px; bottom:20px; z-index:60; width:46px; height:46px; border-radius:50%; border:0; cursor:pointer;
  background:var(--red); color:#fff; font-size:1.1rem; display:grid; place-items:center;
  box-shadow:0 8px 20px rgba(236,50,55,.4); opacity:0; transform:translateY(20px) scale(.8); pointer-events:none;
  transition:opacity .3s, transform .3s var(--ease), background .2s; }
.to-top.show{ opacity:1; transform:none; pointer-events:auto; }
@media (hover:hover){.to-top:hover{ background:var(--red-dark); transform:translateY(-4px); }}
.to-top:active{ transform:scale(.9); }

/* ---------- Anchor target flash ---------- */
.flash{ animation:flash 1.2s ease; }
@keyframes flash{ 0%,100%{ background-color:transparent } 30%{ background-color:rgba(236,50,55,.12) } }

/* ---------- Respect reduced-motion settings ---------- */
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{ animation:none!important; transition:none!important; scroll-behavior:auto!important; }
  .js .reveal:not(.in){ opacity:1; }
  .scroll-progress{ display:none; }
}
