/* ═══════════════════════════════════════════════════════
   Jasmine Gonzales, Realtor — Custom Styles
   Palette: Teal + Slate Grey | Geometric Modern
   ═══════════════════════════════════════════════════════ */

/* ── Base & Typography ── */
html {
  scroll-behavior: smooth;
}

body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background-color: #14b8a6;
  color: white;
}

/* ── Navbar ── */
.navbar-scrolled #navbar {
  background-color: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

.navbar-scrolled .nav-link {
  color: #1e293b;
}

.navbar-scrolled .nav-text-white {
  color: #1e293b;
}

.navbar-scrolled .nav-icon-white {
  color: #1e293b;
}

.nav-link {
  color: rgba(255, 255, 255, 0.85);
}

/* ── Mobile Menu ── */
#mobileMenu {
  transition: transform 0.3s ease;
}

#mobileMenu.open {
  transform: translateX(0);
}

#mobileMenu.closed {
  transform: translateX(100%);
}

/* ── Geometric Shapes ── */
.geo-circle {
  position: absolute;
  border-radius: 50%;
  opacity: 0.08;
}

.geo-circle-1 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, #5eead4, transparent 70%);
  top: -100px;
  right: -100px;
  animation: float-slow 20s ease-in-out infinite;
}

.geo-circle-2 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, #2dd4bf, transparent 70%);
  bottom: 10%;
  left: -50px;
  animation: float-slow 15s ease-in-out infinite reverse;
}

.geo-circle-3 {
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, #99f6e4, transparent 70%);
  top: 40%;
  right: 10%;
  animation: float-slow 12s ease-in-out infinite;
}

.geo-square {
  position: absolute;
  opacity: 0.06;
  background: white;
}

.geo-square-1 {
  width: 120px;
  height: 120px;
  top: 20%;
  left: 8%;
  transform: rotate(45deg);
  animation: spin-slow 25s linear infinite;
}

.geo-square-2 {
  width: 80px;
  height: 80px;
  bottom: 25%;
  right: 5%;
  transform: rotate(20deg);
  animation: spin-slow 20s linear infinite reverse;
}

.geo-triangle {
  position: absolute;
  opacity: 0.05;
  background: white;
  clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
}

.geo-triangle-1 {
  width: 150px;
  height: 150px;
  top: 60%;
  left: 15%;
  animation: float-slow 18s ease-in-out infinite;
}

.geo-triangle-2 {
  width: 100px;
  height: 100px;
  top: 10%;
  right: 20%;
  animation: float-slow 14s ease-in-out infinite reverse;
}

@keyframes float-slow {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-30px) rotate(5deg); }
}

@keyframes spin-slow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* ── Scroll Reveal Animations ── */
/* Default state: visible (progressive enhancement) */
.reveal-up,
.reveal-left,
.reveal-right {
  opacity: 1;
  transform: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
}

/* Only apply hidden state when JS is enabled and user prefers motion */
@media (prefers-reduced-motion: no-preference) {
  .js-enabled .reveal-up,
  .js-enabled .reveal-left,
  .js-enabled .reveal-right {
    opacity: 0;
  }

  .js-enabled .reveal-up {
    transform: translateY(40px);
  }

  .js-enabled .reveal-left {
    transform: translateX(-40px);
  }

  .js-enabled .reveal-right {
    transform: translateX(40px);
  }

  .js-enabled .reveal-up.revealed,
  .js-enabled .reveal-left.revealed,
  .js-enabled .reveal-right.revealed {
    opacity: 1;
    transform: none;
  }
}

/* ── Form Styles ── */
input:focus,
select:focus,
textarea:focus {
  outline: none;
}

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

/* ── Smooth anchor offset for fixed nav ── */
section[id], header[id] {
  scroll-margin-top: 80px;
}

/* ── Custom scrollbar ── */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
  background: #94a3b8;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #64748b;
}

/* ── Mobile link transitions ── */
.mobile-link {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.3s ease, transform 0.3s ease, color 0.2s ease;
}

#mobileMenu.open .mobile-link {
  opacity: 1;
  transform: translateY(0);
}

#mobileMenu:not(.open) .mobile-link {
  opacity: 0;
  transform: translateY(10px);
}
