[hidden] {
  display: none !important;
}

html {
  scroll-padding-top: 6rem;
}

body {
  overflow-x: hidden;
}

body.reborn-menu-open {
  overflow: hidden;
}

:focus-visible {
  outline: 3px solid hsl(var(--accent));
  outline-offset: 3px;
}

.reborn-skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  box-shadow: var(--shadow-medium);
  transform: translateY(-160%);
  transition: transform 180ms ease;
}

.reborn-skip-link:focus {
  transform: translateY(0);
}

.reborn-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  padding-block: 1.5rem;
  transition: padding 300ms ease, background-color 300ms ease, box-shadow 300ms ease;
}

.reborn-header.is-scrolled,
.reborn-header.is-menu-open {
  padding-block: 0.75rem;
  background: hsl(var(--background) / 0.95);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(12px);
}

.reborn-brand-logo {
  display: block;
  width: auto;
  height: 2.5rem;
  object-fit: contain;
}

.reborn-nav-link {
  color: hsl(var(--primary-foreground) / 0.8);
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 180ms ease, opacity 180ms ease;
}

.reborn-nav-link:hover,
.reborn-nav-link.is-active {
  color: hsl(var(--primary-foreground));
}

.reborn-header.is-scrolled .reborn-nav-link,
.reborn-header.is-menu-open .reborn-nav-link {
  color: hsl(var(--foreground) / 0.72);
}

.reborn-header.is-scrolled .reborn-nav-link:hover,
.reborn-header.is-scrolled .reborn-nav-link.is-active,
.reborn-header.is-menu-open .reborn-nav-link:hover,
.reborn-header.is-menu-open .reborn-nav-link.is-active {
  color: hsl(var(--primary));
}

.reborn-language-switcher {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem;
  border: 1px solid hsl(var(--background) / 0.3);
  border-radius: 999px;
  color: hsl(var(--background) / 0.9);
  font-size: 0.75rem;
  font-weight: 500;
}

.reborn-language-switcher svg {
  width: 0.875rem;
  height: 0.875rem;
  margin-left: 0.375rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  opacity: 0.7;
}

.reborn-language-switcher a {
  padding: 0.125rem 0.5rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.7;
  transition: opacity 180ms ease, color 180ms ease, background-color 180ms ease;
}

.reborn-language-switcher a:hover {
  opacity: 1;
}

.reborn-language-switcher a.is-active {
  background: hsl(var(--background));
  color: hsl(var(--primary));
  opacity: 1;
}

.reborn-header.is-scrolled .reborn-language-switcher,
.reborn-header.is-menu-open .reborn-language-switcher {
  border-color: hsl(var(--border));
  color: hsl(var(--foreground) / 0.72);
}

.reborn-header.is-scrolled .reborn-language-switcher a.is-active,
.reborn-header.is-menu-open .reborn-language-switcher a.is-active {
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
}

.reborn-nav-cta,
.reborn-mobile-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.25rem;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  background: hsl(var(--background));
  color: hsl(var(--primary));
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: 0 1px 2px hsl(var(--foreground) / 0.08);
  transition: color 180ms ease, background-color 180ms ease, box-shadow 180ms ease;
}

.reborn-nav-cta:hover {
  background: hsl(var(--background) / 0.9);
  box-shadow: var(--shadow-soft);
}

.reborn-header.is-scrolled .reborn-nav-cta,
.reborn-header.is-menu-open .reborn-nav-cta,
.reborn-mobile-cta {
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
}

.reborn-nav-cta svg,
.reborn-mobile-cta svg {
  width: 1rem;
  height: 1rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.reborn-menu-toggle {
  position: relative;
  z-index: 60;
  display: grid;
  width: 2.75rem;
  height: 2.75rem;
  place-items: center;
  color: hsl(var(--background));
}

.reborn-header.is-scrolled .reborn-menu-toggle,
.reborn-header.is-menu-open .reborn-menu-toggle {
  color: hsl(var(--primary));
}

.reborn-menu-toggle svg {
  position: absolute;
  width: 1.5rem;
  height: 1.5rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  transition: opacity 180ms ease, transform 180ms ease;
}

.reborn-menu-close-icon,
.reborn-header.is-menu-open .reborn-menu-open-icon {
  opacity: 0;
  transform: rotate(-45deg);
}

.reborn-header.is-menu-open .reborn-menu-close-icon {
  opacity: 1;
  transform: rotate(0);
}

.reborn-mobile-navigation {
  position: absolute;
  inset: 0 0 auto;
  z-index: 55;
  min-height: 100dvh;
  background: hsl(var(--background));
}

.reborn-mobile-navigation nav {
  display: flex;
  min-height: 100dvh;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 1.75rem;
  padding: 6rem 1.5rem 2rem;
}

.reborn-mobile-navigation nav > a:not(.reborn-mobile-cta) {
  color: hsl(var(--foreground) / 0.8);
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(1.75rem, 8vw, 2.25rem);
  line-height: 1.1;
  transition: color 180ms ease;
}

.reborn-mobile-navigation nav > a:hover,
.reborn-mobile-navigation nav > a.is-active {
  color: hsl(var(--primary));
}

.reborn-mobile-cta {
  min-height: 3rem;
  margin-top: 0.5rem;
  padding-inline: 2rem;
  font-size: 1rem;
}

.reborn-footer-contact {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  color: hsl(var(--primary-foreground) / 0.8);
  font-size: 0.875rem;
  line-height: 1.45;
  transition: color 180ms ease;
}

a.reborn-footer-contact:hover {
  color: hsl(var(--primary-foreground));
}

.reborn-footer-contact svg {
  width: 1rem;
  height: 1rem;
  flex: 0 0 auto;
  margin-top: 0.1rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.reborn-whatsapp {
  position: fixed;
  right: 1.5rem;
  bottom: 1.5rem;
  z-index: 50;
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  gap: 0.75rem;
}

.reborn-whatsapp-popup {
  width: min(18rem, calc(100vw - 3rem));
  overflow: hidden;
  border: 1px solid hsl(var(--border));
  border-radius: 1rem;
  background: hsl(var(--card));
  box-shadow: 0 20px 48px hsl(var(--foreground) / 0.22);
  animation: reborn-popup-in 200ms ease-out both;
}

.reborn-whatsapp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: #25d366;
  color: white;
}

.reborn-whatsapp-head span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

.reborn-whatsapp-head svg,
.reborn-whatsapp-toggle svg {
  width: 1.5rem;
  height: 1.5rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.reborn-whatsapp-head button {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border-radius: 999px;
  color: white;
  font-size: 1.25rem;
}

.reborn-whatsapp-head button:hover {
  background: rgb(255 255 255 / 0.14);
}

.reborn-whatsapp-body {
  padding: 1rem;
}

.reborn-whatsapp-body h2 {
  margin-bottom: 0.25rem;
  color: hsl(var(--foreground));
  font-size: 1.125rem;
}

.reborn-whatsapp-body p {
  margin-bottom: 0.875rem;
  color: hsl(var(--muted-foreground));
  font-size: 0.875rem;
}

.reborn-whatsapp-body a {
  display: block;
  width: 100%;
  padding: 0.625rem 1rem;
  border-radius: 0.5rem;
  background: #25d366;
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  text-align: center;
  transition: background-color 180ms ease;
}

.reborn-whatsapp-body a:hover,
.reborn-whatsapp-toggle:hover {
  background: #1ebe57;
}

.reborn-whatsapp-toggle {
  position: relative;
  display: grid;
  width: 3.5rem;
  height: 3.5rem;
  place-items: center;
  border-radius: 999px;
  background: #25d366;
  color: white;
  box-shadow: 0 14px 30px hsl(var(--foreground) / 0.24);
  transition: background-color 180ms ease, transform 180ms ease;
}

.reborn-whatsapp-toggle:hover {
  transform: scale(1.05);
}

.reborn-whatsapp-toggle svg {
  position: absolute;
  transition: opacity 180ms ease, transform 180ms ease;
}

.reborn-whatsapp-close-icon,
.reborn-whatsapp.is-open .reborn-whatsapp-open-icon {
  opacity: 0;
  transform: rotate(-45deg);
}

.reborn-whatsapp.is-open .reborn-whatsapp-close-icon {
  opacity: 1;
  transform: rotate(0);
}

[data-reveal] {
  opacity: 0;
  transform: translateY(1.875rem);
  transition: opacity 600ms ease-out var(--reveal-delay, 0ms), transform 600ms ease-out var(--reveal-delay, 0ms);
}

[data-reveal="left"] {
  transform: translateX(-1.875rem);
}

[data-reveal="right"] {
  transform: translateX(1.875rem);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

.reborn-form-error {
  display: block;
  margin-top: 0.4rem;
  color: hsl(var(--destructive));
  font-size: 0.8rem;
}

.reborn-error-summary {
  margin-bottom: 1.5rem;
  padding: 0.875rem 1rem;
  border: 1px solid hsl(var(--destructive) / 0.25);
  border-radius: 0.5rem;
  background: hsl(var(--destructive) / 0.06);
  color: hsl(var(--destructive));
  font-size: 0.875rem;
}

.reborn-article-prose {
  max-width: 48rem;
  margin-inline: auto;
  color: hsl(var(--muted-foreground));
  line-height: 1.8;
}

.reborn-article-prose h2,
.reborn-article-prose h3 {
  margin: 2rem 0 0.75rem;
  color: hsl(var(--foreground));
}

.reborn-article-prose h2 {
  font-size: 1.75rem;
}

.reborn-article-prose p,
.reborn-article-prose ul,
.reborn-article-prose ol {
  margin-bottom: 1.25rem;
}

.reborn-article-prose ul,
.reborn-article-prose ol {
  padding-left: 1.5rem;
}

.reborn-article-prose ul {
  list-style: disc;
}

.reborn-article-prose ol {
  list-style: decimal;
}

@keyframes reborn-popup-in {
  from { opacity: 0; transform: translateY(0.75rem) scale(0.96); }
  to { opacity: 1; transform: none; }
}

@media (min-width: 768px) {
  .reborn-brand-logo {
    height: 3rem;
  }
}

@media (max-width: 767px) {
  [data-reveal] {
    transform: none !important;
  }

  .reborn-language-switcher.is-mobile {
    position: relative;
    z-index: 60;
  }

  .reborn-language-switcher.is-mobile svg {
    display: none;
  }

  .reborn-whatsapp {
    right: 1rem;
    bottom: max(1rem, env(safe-area-inset-bottom));
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
