/* ==========================================================================
   KAMILA ALVES - BIOLINK DESIGN SYSTEM & ANIMATIONS
   Desktop: Centered Mobile App Block Frame ("Blocadinho" no Desktop)
   Mobile: Fullscreen Edge-to-Edge Expansion (Sem bloco no Celular)
   ========================================================================== */

:root {
  --card-bg: rgba(253, 251, 248, 0.96);
  --card-border: #ECE4D8;
  --card-hover-border: #D9A0B0;
  
  --primary-berry: #B53C5C;
  --primary-rose: #B87289;
  --primary-light-pink: #FAF0F3;
  --primary-soft-blush: #F5E6EA;
  
  --text-main: #3C3134;
  --text-sub: #786169;
  --text-title: #B53C5C;
  
  --shadow-card: 0 8px 24px -4px rgba(181, 60, 92, 0.07), 0 3px 8px rgba(0, 0, 0, 0.02);
  --shadow-hover: 0 14px 36px -4px rgba(181, 60, 92, 0.18), 0 6px 16px rgba(0, 0, 0, 0.04);
  --shadow-btn: 0 6px 18px rgba(181, 60, 92, 0.28);

  --font-heading: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;

  --radius-card: 22px;
  --radius-pill: 50px;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  width: 100%;
  min-height: 100vh;
  background: #EFE4EA;
  scroll-behavior: smooth; /* Efeito de scroll suave */
}

/* DESKTOP VIEW */
body {
  width: 100%;
  min-height: 100vh;
  margin: 0;
  padding: 24px 0;
  background: #EFE4EA;
  font-family: var(--font-body);
  color: var(--text-main);
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.app-container {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 440px;
  min-height: calc(100vh - 48px);
  padding: 0 16px 40px 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 0 auto;
  
  background-color: #FAF0F3;
  background-image: url('assets/bg.png');
  background-position: top center;
  background-size: 100% auto;
  background-repeat: no-repeat;
  background-attachment: scroll;
  
  border-radius: 32px;
  border: 1px solid rgba(181, 60, 92, 0.14);
  box-shadow: 0 16px 50px rgba(60, 49, 52, 0.14);
  overflow: hidden;
}

/* MOBILE VIEW */
@media (max-width: 480px) {
  html, body {
    padding: 0;
    margin: 0;
    background: #FAF0F3;
    width: 100vw;
    overflow-x: hidden;
  }

  .app-container {
    max-width: 100vw;
    width: 100%;
    margin: 0;
    padding: 0 16px 40px 16px;
    border-radius: 0 !important;
    border: none !important;
    box-shadow: none !important;
    min-height: 100vh;
    background-size: 100% auto;
    background-color: #FAF0F3;
  }

  .top-logo-header {
    margin-top: calc(55vw + 100px);
  }
}

/* ==========================================================================
   ENTRANCE ANIMATIONS & KEYFRAMES
   ========================================================================== */

/* Logo Entrance Keyframe Animation */
@keyframes logoFadeIn {
  0% {
    opacity: 0;
    transform: translateY(-24px) scale(0.94);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Card Cascade Entrance Keyframe Animation (triggered by JS IntersectionObserver) */
@keyframes cardSlideUp {
  0% {
    opacity: 0;
    transform: translateY(36px) scale(0.97);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Icon micro-animation keyframes */
@keyframes iconBounce {
  0%   { transform: scale(1) rotate(0deg); }
  30%  { transform: scale(1.22) rotate(-8deg); }
  60%  { transform: scale(0.92) rotate(5deg); }
  100% { transform: scale(1) rotate(0deg); }
}

@keyframes iconSpin {
  0%   { transform: rotate(0deg) scale(1); }
  50%  { transform: rotate(20deg) scale(1.15); }
  100% { transform: rotate(0deg) scale(1); }
}

/* Footer Fade In */
@keyframes footerFadeIn {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Scroll reveal states (JS-controlled via IntersectionObserver) */
.reveal-hidden {
  opacity: 0;
  transform: translateY(36px) scale(0.97);
  transition: none;
}

.reveal-visible {
  animation: cardSlideUp 0.75s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* TOP HEADER LOGO WITH ENTRANCE ANIMATION */
.top-logo-header {
  width: 100%;
  margin-top: 335px;
  margin-bottom: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  animation: logoFadeIn 0.95s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.logo-box-svg {
  width: 100%;
  max-width: 385px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-logo-img {
  width: 100%;
  max-height: 165px;
  object-fit: contain;
  filter: none !important;
  -webkit-filter: none !important;
  box-shadow: none !important;
  text-shadow: none !important;
  drop-shadow: none !important;
  transition: transform 0.3s ease;
}

.top-logo-header:hover .hero-logo-img {
  transform: scale(1.02);
}

/* ==========================================================================
   LINK CARDS WITH STAGGERED CASCADE ENTRANCE & GLOW HOVER
   ========================================================================== */
.links-section {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.link-card {
  width: 100%;
  min-height: 84px;
  display: flex;
  align-items: center;
  background: var(--card-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-card);
  padding: 14px 18px;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow-card);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.28s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.28s ease,
              background 0.28s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  text-align: left;
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
}

/* Shimmer overlay effect on hover */
.link-card::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    60deg,
    transparent 30%,
    rgba(255, 255, 255, 0.4) 50%,
    transparent 70%
  );
  transform: rotate(25deg) translateY(-100%);
  transition: transform 0.65s ease;
  pointer-events: none;
}

.link-card:hover::after {
  transform: rotate(25deg) translateY(100%);
}

.link-card:hover {
  transform: translateY(-4px) scale(1.01);
  border-color: var(--card-hover-border);
  box-shadow: var(--shadow-hover);
  background: rgba(255, 255, 255, 0.99);
}

.link-card:active {
  transform: translateY(0) scale(0.98);
}

/* Left Icon Wrapper */
.card-icon-wrapper {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--primary-soft-blush);
  background: var(--primary-light-pink);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-right: 14px;
  transition: transform 0.25s ease, background 0.25s ease;
}

.card-icon-wrapper i {
  width: 20px;
  height: 20px;
  color: var(--primary-berry);
  stroke-width: 1.8px;
}

.card-svg-icon {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.link-card:hover .card-icon-wrapper {
  transform: scale(1.12) rotate(6deg);
  background: var(--primary-soft-blush);
}

/* Icon animation on hover - bounce effect */
.link-card:hover .card-icon-wrapper i {
  animation: iconBounce 0.5s ease forwards;
}

.link-card:hover .card-icon-wrapper .card-svg-icon {
  animation: iconSpin 0.5s ease forwards;
}

/* Card Content */
.card-content {
  flex: 1;
  position: relative;
  z-index: 1;
  padding-right: 8px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.card-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text-title);
  line-height: 1.2;
  margin-bottom: 3px;
}

.card-description {
  font-size: 0.74rem;
  line-height: 1.32;
  color: var(--text-sub);
  margin: 0;
  word-break: break-word;
}

/* Right Chevron Arrow */
.card-chevron {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--primary-soft-blush);
  background: var(--primary-light-pink);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.25s ease;
}

.card-chevron i {
  width: 16px;
  height: 16px;
  color: var(--primary-berry);
  stroke-width: 2px;
}

.link-card:hover .card-chevron {
  background: var(--primary-berry);
  border-color: var(--primary-berry);
  transform: translateX(4px);
}

.link-card:hover .card-chevron i {
  color: #FFF;
}

.link-card-a {
  box-sizing: border-box;
}

/* ==========================================================================
   FOOTER SECTION
   ========================================================================== */
.app-footer {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  opacity: 0;
  animation: footerFadeIn 0.8s ease forwards;
  animation-delay: 0.9s;
}

.footer-heading-box {
  margin-bottom: 4px;
}

.footer-heading {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  letter-spacing: 0.22em;
  color: var(--primary-berry);
  text-transform: uppercase;
  font-weight: 600;
}

.footer-star {
  font-size: 0.65rem;
  color: var(--primary-rose);
  margin-bottom: 14px;
}

.footer-social-icons {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
}

.footer-social-icons a,
.footer-social-icons button {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--card-border);
  background: var(--card-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-berry);
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.footer-social-icons i {
  width: 20px;
  height: 20px;
  stroke-width: 1.8px;
}

.footer-svg-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.footer-social-icons a:hover,
.footer-social-icons button:hover {
  background: var(--primary-berry);
  border-color: var(--primary-berry);
  color: #FFF;
  transform: translateY(-3px) scale(1.08);
}

.footer-social-icons a:hover .footer-svg-icon {
  filter: brightness(0) invert(1);
}

.copyright-text {
  font-size: 0.72rem;
  color: var(--text-sub);
  opacity: 0.85;
}

/* ==========================================================================
   MODAL BOTTOM SHEETS & PHOTO GALLERY
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(60, 49, 52, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.modal-sheet {
  width: 100%;
  max-width: 450px;
  max-height: 88vh;
  background: #FDFBF8;
  border-top-left-radius: 28px;
  border-top-right-radius: 28px;
  border: 1px solid var(--card-border);
  border-bottom: none;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.12);
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.modal-backdrop.active .modal-sheet {
  transform: translateY(0);
}

.sheet-header {
  position: relative;
  padding: 14px 20px 4px 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
}

.sheet-drag-handle {
  width: 42px;
  height: 4px;
  border-radius: 2px;
  background: #E8D9DE;
}

.sheet-close-btn {
  position: absolute;
  right: 16px;
  top: 12px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: var(--primary-light-pink);
  color: var(--primary-berry);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.sheet-close-btn i {
  width: 18px;
  height: 18px;
}

.sheet-body {
  padding: 12px 16px 28px 16px;
  overflow-y: auto;
  flex: 1;
}

.modal-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--primary-berry);
  background: var(--primary-light-pink);
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  margin-bottom: 8px;
  text-transform: uppercase;
}

.modal-badge i {
  width: 13px;
  height: 13px;
}

.modal-heading {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-title);
  margin-bottom: 4px;
}

.modal-subtext {
  font-size: 0.8rem;
  color: var(--text-sub);
  margin-bottom: 14px;
  line-height: 1.4;
}

/* GALLERY CATEGORY FILTER TAGS */
.gallery-filters-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 6px 8px;
  margin-bottom: 16px;
  width: 100%;
}

.gallery-filter-pill {
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid var(--card-border);
  background: #FAF5F7;
  color: var(--text-sub);
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.gallery-filter-pill:hover,
.gallery-filter-pill.active {
  background: var(--primary-berry);
  border-color: var(--primary-berry);
  color: #FFF;
  box-shadow: 0 4px 12px rgba(181, 60, 92, 0.2);
}

/* GALLERY PHOTO GRID */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.gallery-item-card {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: #FFF;
  border: 1px solid var(--card-border);
  aspect-ratio: 1;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(181, 60, 92, 0.06);
  transition: all 0.25s ease;
}

.gallery-item-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.gallery-item-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.gallery-item-card:hover img {
  transform: scale(1.06);
}

.item-tag {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(60, 49, 52, 0.8) 0%, transparent 100%);
  color: #FFF;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 14px 8px 6px 8px;
  text-align: center;
}

/* LIGHTBOX FULLSCREEN PREVIEW */
.lightbox-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(30, 22, 24, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.lightbox-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 75vh;
  border-radius: 16px;
  object-fit: contain;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.lightbox-caption {
  color: #FFF;
  font-size: 0.88rem;
  font-weight: 600;
  margin-top: 12px;
  text-align: center;
}

.lightbox-close-btn {
  position: absolute;
  top: -44px;
  right: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #FFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.lightbox-close-btn i {
  width: 20px;
  height: 20px;
}

/* Procedure Cards & Location */
.procedures-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.procedure-card {
  background: #FAF5F7;
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 16px;
}

.proc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.proc-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-berry);
}

.proc-price {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--primary-berry);
  background: #FFF;
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid var(--primary-soft-blush);
}

.proc-desc {
  font-size: 0.8rem;
  color: var(--text-sub);
  line-height: 1.45;
  margin-bottom: 12px;
}

.proc-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.proc-detail {
  font-size: 0.74rem;
  color: var(--primary-rose);
  display: flex;
  align-items: center;
  gap: 4px;
}

.proc-detail i {
  width: 14px;
  height: 14px;
}

.proc-btn {
  padding: 6px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--primary-berry);
  background: #FFF;
  color: var(--primary-berry);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.proc-btn:hover {
  background: var(--primary-berry);
  color: #FFF;
}

.location-info-card {
  background: #FAF5F7;
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 20px;
}

.loc-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.loc-icon {
  width: 20px;
  height: 20px;
  color: var(--primary-berry);
  flex-shrink: 0;
  margin-top: 2px;
}

.loc-svg-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
  margin-top: 2px;
}

.loc-item strong {
  font-size: 0.82rem;
  color: var(--text-main);
  display: block;
}

.loc-item p {
  font-size: 0.78rem;
  color: var(--text-sub);
  margin-top: 2px;
}

/* ==========================================================================
   LOCATION INLINE CARD (Endereço + Botões Waze & Maps)
   ========================================================================== */
.location-inline-card {
  display: block; /* Override flex from .link-card */
  height: auto;
  min-height: unset;
  padding: 18px;
  cursor: default;
}

.location-inline-card:hover {
  transform: none;
  box-shadow: var(--shadow-card);
}

.location-inline-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.location-inline-header {
  display: flex;
  align-items: center;
  gap: 0;
}

.location-inline-header .card-icon-wrapper {
  flex-shrink: 0;
}

.location-inline-header .card-content {
  padding-right: 0;
}

.location-address-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: var(--primary-light-pink);
  border-radius: 12px;
  padding: 10px 12px;
}

.location-addr-icon {
  width: 16px;
  height: 16px;
  color: var(--primary-berry);
  flex-shrink: 0;
  margin-top: 1px;
}

.location-addr-text {
  font-size: 0.78rem;
  color: var(--text-sub);
  line-height: 1.45;
}

/* Map navigation buttons row */
.location-map-btns {
  display: flex;
  gap: 10px;
}

.map-btn {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 12px 12px;
  text-decoration: none;
  color: var(--text-main);
  box-shadow: var(--shadow-card);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  min-height: 62px;
}

.map-btn:hover {
  background: var(--primary-berry);
  border-color: var(--card-hover-border);
  color: #FFF;
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.map-btn:hover .map-btn-icon {
  filter: brightness(0) invert(1);
}

.map-btn:hover .map-btn-chevron {
  color: #FFF;
}

.map-btn-icon {
  width: 32px;
  height: 32px;
  object-fit: contain;
  flex-shrink: 0;
  transition: filter 0.25s ease;
}

.map-btn span {
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.35;
  flex: 1;
}

.map-btn-chevron {
  width: 16px;
  height: 16px;
  color: var(--primary-berry);
  flex-shrink: 0;
  transition: color 0.25s ease, transform 0.25s ease;
}

.map-btn:hover .map-btn-chevron {
  transform: translateX(2px);
}
