/* Complete redesign to match Swire Properties style */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

/* Decorative geometric shapes similar to reference */
.decorative-shapes {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}

.shape {
  position: absolute;
  opacity: 0.6;
  animation: float 20s infinite ease-in-out;
}

/* Shape 1 - Gold curved line top left */
.shape-1 {
  width: 200px;
  height: 200px;
  top: 10%;
  left: 5%;
  border: 3px solid #fbbf24;
  border-radius: 50% 0 50% 50%;
  border-right: none;
  border-top: none;
  animation-delay: 0s;
}

/* Shape 2 - Red circle top center */
.shape-2 {
  width: 80px;
  height: 80px;
  top: 15%;
  left: 45%;
  background: #ef4444;
  border-radius: 50%;
  animation-delay: 2s;
}

/* Shape 3 - Green semi-circle top right */
.shape-3 {
  width: 150px;
  height: 150px;
  top: 8%;
  right: 3%;
  background: #16a34a;
  border-radius: 0 0 0 100%;
  animation-delay: 4s;
}

/* Shape 4 - Blue quarter circle bottom left */
.shape-4 {
  width: 120px;
  height: 120px;
  bottom: 25%;
  left: 2%;
  background: #3b82f6;
  border-radius: 0 100% 0 0;
  animation-delay: 6s;
}

/* Shape 5 - Teal circle bottom right */
.shape-5 {
  width: 100px;
  height: 100px;
  bottom: 20%;
  right: 8%;
  border: 4px solid #14b8a6;
  border-radius: 50%;
  animation-delay: 8s;
}

/* Shape 6 - Yellow curved path bottom center */
.shape-6 {
  width: 180px;
  height: 180px;
  bottom: 15%;
  left: 40%;
  border: 3px solid #fbbf24;
  border-radius: 50%;
  border-top: none;
  border-right: none;
  animation-delay: 10s;
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
  25% {
    transform: translate(10px, -10px) rotate(5deg);
  }
  50% {
    transform: translate(-5px, 10px) rotate(-5deg);
  }
  75% {
    transform: translate(15px, 5px) rotate(3deg);
  }
}

/* Image fade-in animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.8s ease-in-out;
}

/* Service card flip effect */
.service-card {
  position: relative;
  min-height: 320px;
  transition: all 0.4s ease;
}

.service-card-front,
.service-card-back {
  transition: opacity 0.3s ease;
}

.card-flipped {
  background: linear-gradient(135deg, #f9fafb 0%, #e5e7eb 100%) !important;
}

/* Case card effects */
.case-card {
  transition: transform 0.3s ease;
}

/* Cookie popup animation */
#cookiePopup {
  animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Mobile menu transition */
#mobileMenu {
  transition: max-height 0.3s ease-in-out;
}

/* Form focus states matching design */
input:focus,
textarea:focus {
  outline: none;
  border-color: #15803d !important;
  box-shadow: 0 0 0 3px rgba(21, 128, 61, 0.1) !important;
}

/* Custom scrollbar matching green theme */
::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: #f3f4f6;
}

::-webkit-scrollbar-thumb {
  background: #15803d;
  border-radius: 6px;
}

::-webkit-scrollbar-thumb:hover {
  background: #166534;
}

/* Button hover animations */
button,
a {
  transition: all 0.3s ease;
}

img {
  max-width: 100%;
  height: auto;
}

section {
  position: relative;
  z-index: 2;
}

iframe {
  display: block;
  width: 100%;
}

@media print {
  header,
  footer,
  #cookiePopup,
  .decorative-shapes {
    display: none;
  }
}

/* Animation for scroll elements */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.animated {
  opacity: 1;
  transform: translateY(0);
}

/* Focus visible for accessibility */
*:focus-visible {
  outline: 2px solid #fbbf24;
  outline-offset: 2px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .decorative-shapes {
    display: none;
  }

  .shape {
    transform: scale(0.6);
  }
}

/* Additional hover effects for links */
a {
  position: relative;
}

nav a::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: #15803d;
  transition: width 0.3s ease;
}

nav a:hover::after {
  width: 100%;
}
