/* Custom CSS for Aqua Kaliana Website */

/* ===================================
   HEADER & FOOTER
   =================================== */

/* Ensure header and footer are always on top */
.site-header {
  position: relative;
  z-index: 1000 !important;
  background-color: #2590ce !important;
  min-height: 60px !important;
  height: auto !important;
  overflow: visible !important;
}

.site-header .wrapper {
  max-width: 1200px !important;
  width: 100% !important;
  margin: 0 auto !important;
  padding: 0 2rem !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  min-height: 60px !important;
  box-sizing: border-box !important;
}
.scroll-to-top {display: none;}
/* Logo sizing */
.site-title {
  display: flex !important;
  align-items: center !important;
  float: none !important;
  line-height: normal !important;
}

.site-title img,
.site-title .header-logo,
img.header-logo {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  height: 45px !important;
  max-height: 45px !important;
  min-height: 45px !important;
  width: auto !important;
  min-width: 100px !important;
  padding: 8px !important;
}

.site-header .wrapper::after {
  display: none !important;
}

/* Navigation styling */
.site-nav {
  display: flex !important;
  align-items: center !important;
}

.site-nav .trigger {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

/* Navigation links styling */
.site-nav .page-link {
  color: white !important;
  font-size: 1.2rem !important;
  font-weight: 500 !important;
  line-height: 1 !important;
}

.site-nav .page-link:hover {
  color: rgba(255, 255, 255, 0.8) !important;
}

/* Order Now button in header */
.btn-order-now {
  background-color: #000000 !important;
  color: white !important;
  padding: 10px 20px !important;
  border-radius: 6px !important;
  font-weight: 600 !important;
  font-size: 1.05rem !important;
  transition: all 0.3s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  text-decoration: none !important;
  margin-left: 10px !important;
  line-height: 1.2 !important;
}

.btn-order-now:hover {
  background-color: #333333 !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.btn-order-now svg {
  transition: transform 0.3s ease;
}

.btn-order-now:hover svg {
  transform: translateX(3px);
}

/* Mobile Navigation */
.site-nav .nav-trigger {
  display: none;
}

.site-nav .menu-icon {
  display: none;
}

/* Override minima's 600px breakpoint styling */
@media screen and (max-width: 600px) {
  .site-header {
    background-color: #2590ce !important;
    min-height: 55px !important;
    border: none !important;
    position: relative !important;
    z-index: 1000 !important;
  }

  .site-header .wrapper {
    background-color: transparent !important;
    padding: 0.25rem 1rem !important;
  }

  .site-title {
    margin: 0 !important;
    padding: 0 !important;
  }

  .site-title img,
  .site-title .header-logo,
  img.header-logo {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: 35px !important;
    max-height: 35px !important;
  }

  .site-nav {
    background-color: transparent !important;
    border: none !important;
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    left: auto !important;
    height: 55px !important;
  }

  .site-nav label[for="nav-trigger"] {
    display: block !important;
    background-color: transparent !important;
    cursor: pointer !important;
  }

  .site-nav .menu-icon {
    display: block !important;
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    right: 1rem !important;
  }

  .site-nav .menu-icon > svg {
    fill: white !important;
  }

  .site-nav .trigger {
    background-color: #2590ce !important;
    border: none !important;
    position: absolute !important;
    top: 55px !important;
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
    flex-direction: column !important;
    padding: 1rem 0 !important;
    box-shadow: 0 8px 12px -4px rgba(0,0,0,0.15) !important;
  }

  .site-nav input ~ .trigger {
    display: none !important;
  }

  .site-nav input:checked ~ .trigger {
    display: flex !important;
    background-color: #2590ce !important;
  }

  .site-nav .page-link {
    color: white !important;
    padding: 0.75rem 1rem !important;
    display: block !important;
    margin: 0 !important;
  }

  /* Ensure page content doesn't overlap header */
  .page-content {
    position: relative !important;
    z-index: 1 !important;
  }
}

/* Medium screens - reduce nav font size and gap */
@media (max-width: 1100px) {
  .site-nav .page-link {
    font-size: 1rem !important;
  }
  .site-nav .trigger {
    gap: 1rem;
  }
  .btn-order-now {
    padding: 8px 16px !important;
    font-size: 0.95rem !important;
  }
}

/* Smaller screens - further reduce nav spacing */
@media (max-width: 950px) {
  .site-nav .page-link {
    font-size: 0.95rem !important;
  }
  .site-nav .trigger {
    gap: 0.5rem;
  }
  .site-nav .page-link:not(:last-child) {
    margin-right: 9px !important;
  }
  .btn-order-now {
    padding: 6px 12px !important;
    font-size: 0.9rem !important;
    margin-left: 5px !important;
  }
}

/* Even smaller screens - minimal spacing */
@media (max-width: 900px) {
  .site-nav .page-link:not(:last-child) {
    margin-right: 2px !important;
  }
  .site-nav .trigger {
    gap: 0.25rem;
  }
}

@media (max-width: 768px) {
  .site-header {
    min-height: 55px !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
    z-index: 1000 !important;
  }

  .site-header .wrapper {
    position: relative;
    flex-direction: row;
    justify-content: center;
    padding: 0.25rem 1rem !important;
    min-height: 55px !important;
  }

  .site-title {
    margin: 0 !important;
    display: flex;
    align-items: center;
    height: 55px;
  }

  .site-title img {
    display: block !important;
    visibility: visible !important;
    height: 30px !important;
    max-height: 30px !important;
    min-height: 30px !important;
    padding: 0 !important;
  }

  .site-nav {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 55px;
    pointer-events: none;
    display: flex;
    align-items: center;
  }

  .site-nav .menu-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    right: 1rem;
    width: 32px;
    height: 32px;
    cursor: pointer;
    z-index: 100;
    pointer-events: auto;
  }

  .site-nav .menu-icon > svg {
    fill: white;
    width: 24px;
    height: 24px;
  }

  .site-nav .trigger {
    display: none;
    position: fixed !important;
    top: 60px !important;
    left: 0 !important;
    right: 0 !important;
    flex-direction: column;
    align-items: stretch !important;
    width: 100vw !important;
    background-color: #2590ce;
    padding: 1rem 0;
    gap: 0 !important;
    z-index: 999 !important;
    pointer-events: auto;
    box-shadow: 0 8px 12px -4px rgba(0,0,0,0.15);
  }

  .site-nav input:checked ~ .trigger {
    display: flex;
  }

  .site-nav .page-link {
    padding: 0.75rem 1rem !important;
    width: 100%;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 1rem !important;
  }

  .site-nav .page-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
  }

  .btn-order-now {
    margin: 0.5rem 1rem !important;
    justify-content: center !important;
    border-bottom: none !important;
  }

  /* Add padding to page content to account for fixed header */
  .page-content {
    padding-top: 55px !important;
  }
}

/* Small mobile devices - Galaxy S23 and similar */
@media (max-width: 420px) {
  .site-header {
    min-height: 50px !important;
  }

  .site-header .wrapper {
    min-height: 50px !important;
    padding: 0.25rem 0.75rem !important;
  }

  .site-title img {
    display: block !important;
    visibility: visible !important;
    height: 32px !important;
    max-height: 32px !important;
    min-height: 32px !important;
    padding: 4px !important;
  }

  .site-nav {
    height: 50px;
  }

  .site-nav .menu-icon {
    width: 32px;
    height: 32px;
    right: 0.75rem;
  }

  .site-nav .trigger {
    top: 50px;
  }

  .site-nav .page-link {
    font-size: 0.95rem !important;
    padding: 0.65rem 1rem !important;
  }
}

/* Very small screens */
@media (max-width: 360px) {
  .site-title img {
    display: block !important;
    visibility: visible !important;
    height: 28px !important;
    max-height: 28px !important;
    min-height: 28px !important;
    padding: 3px !important;
  }
}

.site-footer {
  position: relative;
  z-index: 1000 !important;
  border-top: none !important;
  padding: 0.75rem 0 !important;
  background: #f8f8f8;
}

/* Lock homepage scroll on mobile */
@media (max-width: 768px) {
  .home-page {
    overflow: hidden !important;
    height: 100vh !important;
    height: 100dvh !important; /* Dynamic viewport height - accounts for browser UI */
    position: fixed !important;
    width: 100% !important;
  }

  /* Ensure header stays on screen when body is fixed */
  .home-page .site-header {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
  }

  /* Fix mobile menu positioning when body is fixed */
  .home-page .site-nav .trigger {
    position: fixed !important;
    top: 60px !important;
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
    z-index: 999 !important;
  }

  /* Ensure header stays above menu */
  .home-page .site-header {
    z-index: 1000 !important;
  }
}

/* Transparent footer on home page - so it doesn't cover the bottle */
.home-page .site-footer {
  background: transparent !important;
  position: fixed !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 1000 !important;
  padding: 0.5rem 0 !important;
}

.home-page .site-footer .wrapper,
.home-page .footer-content {
  background: transparent !important;
}

.home-page .footer-content {
  flex-direction: row !important;
  flex-wrap: wrap !important;
  justify-content: center !important;
  gap: 0.5rem !important;
  font-size: 0.75rem !important;
}

.home-page .footer-content .copyright {
  font-size: 0.7rem !important;
}

.home-page .footer-content .footer-links {
  flex-direction: row !important;
  gap: 0.25rem !important;
  font-size: 0.7rem !important;
}

.home-page .footer-content .footer-links .separator {
  display: inline !important;
}

.home-page .footer-content .copyright,
.home-page .footer-content .footer-links a,
.home-page .footer-content .footer-links .separator {
  color: #2c3e50 !important;
  text-shadow: 0 1px 2px rgba(255,255,255,0.5) !important;
}

/* Adjust hero content for shorter screens */
@media (max-height: 800px) {
  .hero-content {
    padding: 0 1rem !important;
    margin-top: 0.5rem !important;
  }
}

/* Adjust hero content for medium-short screens (500-600px) */
@media (max-height: 600px) {
  .hero-content {
    padding: 0 0.5rem !important;
    margin-top: 0 !important;
  }

  .hero-description {
    font-size: 0.95rem !important;
    line-height: 1.3 !important;
    margin-bottom: 0.75rem !important;
  }

  .hero-logo-img {
    max-height: 35vh !important;
  }

  .btn-hero {
    padding: 6px 14px !important;
    font-size: 0.85rem !important;
  }

  .home-page .footer-content {
    font-size: 0.7rem !important;
  }
}

/* Adjust hero content for short/landscape screens */
@media (max-height: 500px) {
  .hero-content {
    padding: 0 !important;
    margin-top: 0 !important;
  }

  .hero-description {
    font-size: 0.85rem !important;
    line-height: 1.3 !important;
    margin-bottom: 1rem !important;
  }

  .btn-hero {
    padding: 6px 12px !important;
    font-size: 0.75rem !important;
  }

  .home-page .footer-content {
    font-size: 0.6rem !important;
  }

  .home-page .footer-content .copyright,
  .home-page .footer-content .footer-links {
    font-size: 0.6rem !important;
  }
}

/* Also remove page-content wrapper padding on home */
.home-page .page-content {
  padding: 0 !important;
}

.home-page .page-content > .wrapper {
  max-width: 100% !important;
  padding: 0 !important;
}

/* Allow footer wrapper to use full width */
.site-footer .wrapper {
  max-width: 100% !important;
  padding: 0 2rem !important;
}

/* Footer content styling */
.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  min-height: auto;
}

.footer-content .copyright {
  white-space: nowrap;
  font-size: 0.9rem;
}

.footer-content .footer-links {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 0.9rem;
}

.footer-content .footer-links a {
  text-decoration: none;
  color: inherit;
}

.footer-content .footer-links a:hover {
  text-decoration: underline;
}

.footer-content .footer-links .separator {
  color: #828282;
}

@media (max-width: 900px) {
  .footer-content {
    flex-direction: column;
    text-align: center;
    gap: 0.75rem;
  }

  .footer-content .footer-links {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .site-footer {
    padding: 0.5rem 0 !important;
  }

  .site-footer .wrapper {
    padding: 0 1rem !important;
  }

  .footer-content {
    gap: 0.5rem;
    font-size: 0.85rem;
  }

  .footer-content .copyright {
    font-size: 0.8rem;
  }

  .footer-content .footer-links {
    gap: 0.25rem;
    font-size: 0.75rem;
  }

  .footer-content .footer-links .separator {
    margin: 0 0.15rem;
  }
}

@media (max-width: 420px) {
  .footer-content .footer-links {
    flex-direction: column;
    gap: 0.25rem;
  }

  .footer-content .footer-links .separator {
    display: none;
  }
}

/* ===================================
   LANGUAGE SWITCHER
   =================================== */

/* Hide mobile language link on desktop */
.mobile-lang-link {
  display: none !important;
}

.language-switcher {
  position: fixed;
  bottom: 20px;
  right: 2rem;
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(255, 255, 255, 0.95);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* On mobile: hide floating switcher, show menu link */
@media (max-width: 768px) {
  .language-switcher {
    display: none !important;
  }

  .mobile-lang-link {
    display: block !important;
    border-top: 1px solid rgba(255, 255, 255, 0.2) !important;
    margin-top: 0.5rem !important;
    padding-top: 1rem !important;
  }
}

.language-switcher .lang-link {
  color: #2590ce;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 0.3s ease;
}

.language-switcher .lang-link:hover {
  color: #1a6fa3;
  text-decoration: underline;
}

.language-switcher .lang-link.active {
  font-weight: 700;
  color: #1a6fa3;
}

.language-switcher .lang-separator {
  color: #828282;
  margin: 0 0.25rem;
}

@media (max-width: 768px) {
  .language-switcher {
    bottom: 15px;
    right: 1rem;
    padding: 0.4rem 0.8rem;
  }

  .language-switcher .lang-link {
    font-size: 0.85rem;
  }
}

/* Short screens - landscape mobile or Windows with short displays */
@media (max-height: 700px) {
  .language-switcher {
    bottom: 10px;
    right: 1rem;
    padding: 0.35rem 0.7rem;
  }

  .language-switcher .lang-link {
    font-size: 0.8rem;
  }
}

@media (max-height: 500px) {
  .language-switcher {
    bottom: 5px;
    right: 0.5rem;
    padding: 0.25rem 0.5rem;
  }
}

/* ===================================
   HOME PAGE HERO CONTENT
   =================================== */

/* Ensure parent containers don't hide content */
.page-content {
  overflow: visible !important;
}

.page-content .wrapper {
  overflow: visible !important;
}

.home {
  overflow: visible !important;
}

/* Hide the page heading on home page */
.home .page-heading {
  display: none !important;
}

.hero-logo-content-wrapper {
  position: absolute;
  width: 50%;
  display: flex;
  flex-direction: column;
  z-index: 100;
  right: 9%;
  top: 17%;
  align-items: center;
}

.hero-logo-img {
  max-width: 100%;
  height: auto;
  max-height: 50vh;
  object-fit: contain;
  object-position: top center;
  pointer-events: none;
}

.hero-content {
  width: 100%;
  margin-top: 2rem;
  padding: 0rem 3rem;
  text-align: center;
  pointer-events: none;
  background-color: transparent;
  border-radius: 12px;
  box-sizing: border-box;
  display: block !important;
  visibility: visible !important;
}

.hero-content p,
.hero-content .hero-buttons {
  pointer-events: auto;
}

.hero-description {
  font-size: 1.3rem;
  line-height: 1.8;
  color: #2c3e50;
  margin-bottom: 2rem;
  font-weight: 400;
}

.hero-buttons {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  position: relative;
  z-index: 103;
}

.btn-hero {
  background-color: #2590ce !important;
  color: white !important;
  padding: 14px 32px !important;
  border-radius: 6px !important;
  font-weight: 600 !important;
  font-size: 1.1rem !important;
  transition: all 0.3s ease !important;
  display: inline-block !important;
  text-decoration: none !important;
  border: none !important;
  cursor: pointer !important;
}

.btn-hero:hover {
  background-color: #1a6fa3 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 144, 206, 0.4);
}

/* Short/landscape screens - override btn-hero */
@media (max-height: 500px) {
  .btn-hero {
    padding: 8px 16px !important;
    font-size: 0.9rem !important;
  }

  .hero-logo-img {
    max-height: 40vh !important;
  }
}

@media (max-width: 768px) {
  .hero-logo-content-wrapper {
    width: 85%;
    right: auto;
    left: 50%;
    transform: translateX(-50%);
    top: 8%;
    gap: 0;
  }

  .hero-logo-img {
    max-height: 22vh;
    max-width: 65vw;
    margin-top: 15px;
  }

  .hero-content {
    margin-top: 0;
    padding: 0 12px;
  }

  .hero-description {
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 1.5rem;
  }

  .hero-buttons {
    gap: 0.75rem;
  }

  .btn-hero {
    padding: 10px 20px !important;
    font-size: 0.95rem !important;
  }
}

/* Small mobile devices - Galaxy S23 and similar */
@media (max-width: 420px) {
  .hero-logo-content-wrapper {
    width: 90%;
    top: 10%;
  }

  .hero-logo-img {
    max-height: 18vh;
    max-width: 60vw;
    margin-top: 10px;
  }

  .hero-description {
    font-size: 0.9rem;
    line-height: 1.4;
    margin-bottom: 1rem;
  }

  .btn-hero {
    padding: 8px 16px !important;
    font-size: 0.85rem !important;
  }
}


/* ===================================
   ANIMATIONS
   =================================== */

/* Fade in animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Water drop animation */
@keyframes waterDrop {
  0% {
    transform: translateY(-100px);
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Ripple effect animation */
@keyframes ripple {
  0% {
    transform: scale(0.8);
    opacity: 1;
  }
  100% {
    transform: scale(2.4);
    opacity: 0;
  }
}

/* Floating animation for bottles */
@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Wave animation */
@keyframes wave {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Water flow animation - slow drifting movement */
@keyframes waterFlow {
  0%, 100% {
    transform: translate(0, 0) scale(1);
  }
  25% {
    transform: translate(2%, 3%) scale(1.02);
  }
  50% {
    transform: translate(-1%, 2%) scale(1.01);
  }
  75% {
    transform: translate(3%, -2%) scale(1.02);
  }
}

/* Caustics light pattern animation */
@keyframes caustics {
  0% {
    opacity: 0.6;
    transform: translate(0, 0) scale(1);
  }
  25% {
    opacity: 0.8;
    transform: translate(8%, 5%) scale(1.05);
  }
  50% {
    opacity: 0.7;
    transform: translate(-5%, 8%) scale(1.03);
  }
  75% {
    opacity: 0.85;
    transform: translate(6%, -4%) scale(1.04);
  }
  100% {
    opacity: 0.6;
    transform: translate(0, 0) scale(1);
  }
}

/* Shimmer effect - subtle light rays through water */
@keyframes shimmer {
  0% {
    opacity: 0.15;
    background-position: -100% center;
  }
  50% {
    opacity: 0.25;
    background-position: 100% center;
  }
  100% {
    opacity: 0.15;
    background-position: -100% center;
  }
}

/* Gentle water movement - organic flowing motion */
@keyframes gentleWave {
  0% {
    transform: translate(0, 0) scale(1);
  }
  25% {
    transform: translate(15px, -10px) scale(1.02);
  }
  50% {
    transform: translate(-10px, 5px) scale(1.01);
  }
  75% {
    transform: translate(10px, 10px) scale(1.02);
  }
  100% {
    transform: translate(0, 0) scale(1);
  }
}

/* Subtle opacity variation for depth */
@keyframes depthPulse {
  0%, 100% {
    opacity: 0.4;
  }
  50% {
    opacity: 0.6;
  }
}

/* Expanding ripples animation */
@keyframes expandRipples {
  0% {
    background-size: 100% 100%;
  }
  50% {
    background-size: 120% 120%;
  }
  100% {
    background-size: 100% 100%;
  }
}

/* ===================================
   UTILITY CLASSES
   =================================== */

.fade-in {
  animation: fadeIn 1s ease-in;
}

.water-drop {
  animation: waterDrop 1.5s ease-out;
}

.float {
  animation: float 3s ease-in-out infinite;
}

/* ===================================
   VIDEO CONTAINER
   =================================== */

.video-container {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  height: 0;
  overflow: hidden;
  max-width: 100%;
  margin: 2rem 0;
}

.video-container iframe,
.video-container video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

/* Responsive video */
.responsive-video {
  width: 100%;
  height: auto;
  display: block;
  margin: 2rem auto;
}

/* ===================================
   CUSTOM WATER THEME
   =================================== */

/* Water gradient background */
.water-gradient {
  background: linear-gradient(180deg,
    rgba(135, 206, 235, 0.1) 0%,
    rgba(70, 130, 180, 0.1) 100%);
}

/* Ripple effect container */
.ripple-container {
  position: relative;
  display: inline-block;
  cursor: pointer;
}

.ripple-container::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid rgba(135, 206, 235, 0.6);
  transform: translate(-50%, -50%);
  animation: ripple 2s ease-out infinite;
}

/* ===================================
   BUTTONS & INTERACTIVE ELEMENTS
   =================================== */

.btn-water {
  background-color: #2590ce;
  color: white;
  padding: 14px 32px;
  border: none;
  border-radius: 6px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

.btn-water:hover {
  background-color: #1a6fa3;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 144, 206, 0.4);
  color: white;
}

.btn-water:active {
  transform: translateY(0);
}

/* ===================================
   HERO SECTION WITH WATER ANIMATION
   =================================== */

/* Body background for home page - canvas shows on top of this */
.home-page,
.home-page body {
  background-color: #9a9a9a !important;
}

/* WebGL canvas inside hero - below content layers */
#water-canvas,
.hero-canvas {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 10;
  pointer-events: none;
}

.hero {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh; /* Dynamic viewport height - accounts for mobile browser UI */
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: linear-gradient(180deg, #87ceeb 0%, #b0e0e6 50%, #e0f4f8 100%);
  z-index: 100;
  padding-bottom: env(safe-area-inset-bottom, 0); /* iOS safe area */
  isolation: isolate; /* Prevent WebGL compositing from affecting elements outside hero */
}

/* When WebGL is active, hide all CSS effect layers - WebGL provides the effect */
/* Keep only .hero-background (grey base) visible */
.hero.webgl-active .hero-shimmer,
.hero.webgl-active .hero-water-layer,
.hero.webgl-active .hero-background-content {
  display: none;
}

/* On mobile, same rules */
@media (max-width: 768px) {
  .hero.webgl-active .hero-shimmer,
  .hero.webgl-active .hero-water-layer,
  .hero.webgl-active .hero-background-content,
  .hero.mobile-webgl .hero-shimmer,
  .hero.mobile-webgl .hero-water-layer,
  .hero.mobile-webgl .hero-background-content {
    display: none !important;
  }

  /* Ensure hero has proper background on mobile - override any inline transparent backgrounds */
  .hero.webgl-active,
  .hero.mobile-webgl {
    background: linear-gradient(180deg, #87ceeb 0%, #b0e0e6 50%, #e0f4f8 100%) !important;
  }
}

/* Base background layer - testing with no background */
.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: transparent;
  z-index: 1;
}

/* Content layer that will be distorted by water */
.hero-background-content {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  background:
    radial-gradient(ellipse 450px 320px at 22% 38%, rgba(135, 206, 235, 0.35) 0%, transparent 65%),
    radial-gradient(ellipse 380px 300px at 35% 62%, rgba(100, 180, 220, 0.30) 0%, transparent 70%),
    radial-gradient(ellipse 320px 280px at 48% 75%, rgba(176, 224, 230, 0.28) 0%, transparent 68%);
  filter: blur(50px);
  animation: gentleWave 22s ease-in-out infinite;
  will-change: transform;
}

/* Water surface layer with distortion */
.hero-water-layer {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  background:
    radial-gradient(circle at 33% 48%, rgba(255, 255, 255, 0.12) 0%, transparent 45%),
    radial-gradient(circle at 68% 52%, rgba(135, 206, 235, 0.10) 0%, transparent 48%),
    radial-gradient(circle at 52% 72%, rgba(176, 224, 230, 0.10) 0%, transparent 52%);
  backdrop-filter: blur(2px);
  filter: blur(35px);
  animation: waterFlow 16s ease-in-out infinite, depthPulse 11s ease-in-out infinite;
  mix-blend-mode: overlay;
  will-change: transform;
}

/* Water ripples - caustics light patterns - hidden when WebGL works, shown as fallback */
.hero-caustics {
  display: none;
}

/* WebGL canvas - stays below hero content, force own compositing layer */
/* NOTE: Do NOT set width/height via CSS - breaks mobile WebGL. Size via JS canvas.width/height only */
.hero-canvas {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1; /* Below hero content (z-index 100+) */
  pointer-events: none;
  mix-blend-mode: normal;
  will-change: transform; /* Force own compositing layer */
  contain: strict; /* Isolate rendering to prevent affecting other elements */
}

/* CSS fallback when WebGL is not available */
.hero.no-webgl .hero-caustics {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 4;
  background:
    radial-gradient(ellipse 200px 150px at 20% 30%, rgba(255, 255, 255, 0.3) 0%, transparent 70%),
    radial-gradient(ellipse 180px 120px at 60% 50%, rgba(255, 255, 255, 0.25) 0%, transparent 65%),
    radial-gradient(ellipse 150px 100px at 40% 70%, rgba(255, 255, 255, 0.2) 0%, transparent 60%),
    radial-gradient(ellipse 120px 80px at 80% 25%, rgba(255, 255, 255, 0.2) 0%, transparent 55%);
  animation: causticsFallback 8s ease-in-out infinite;
  pointer-events: none;
}

@keyframes causticsFallback {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.8;
  }
  25% {
    transform: translate(10px, -5px) scale(1.02);
    opacity: 1;
  }
  50% {
    transform: translate(-5px, 10px) scale(0.98);
    opacity: 0.9;
  }
  75% {
    transform: translate(-10px, -10px) scale(1.01);
    opacity: 1;
  }
}

/* Shimmer overlay - very subtle light rays */
.hero-shimmer {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 5;
  background:
    linear-gradient(
      115deg,
      transparent 0%,
      transparent 40%,
      rgba(255, 255, 255, 0.06) 45%,
      rgba(255, 255, 255, 0.12) 48%,
      rgba(255, 255, 255, 0.15) 50%,
      rgba(255, 255, 255, 0.12) 52%,
      rgba(255, 255, 255, 0.06) 55%,
      transparent 60%,
      transparent 100%
    );
  background-size: 300% 100%;
  background-position: -100% center;
  animation: shimmer 25s ease-in-out infinite;
  pointer-events: none;
}

/* Aqua Kaliana logo - hidden, now using img tag in content */
.hero-logo {
  display: none;
}

/* Mockup image - positioned at bottom left */
.hero-mockup {
position: absolute;
  bottom: 0;
  left: 0;
  width: 50%;
  height: 85%;
  z-index: 101;
  background: url('/assets/images/mockup.png') bottom center no-repeat;
    background-size: auto;
  background-size: contain;
  pointer-events: none;
  align-content: center;
}

/* Greek mockup image */
.hero-mockup-el {
  background: url('/assets/images/mockup-el.png') bottom center no-repeat;
  background-size: contain;
}

/* Hero content - always on top */
.hero-content {
  position: relative;
  z-index: 102;
  text-align: center;
  padding: 3rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.hero-content h1 {
  font-size: 3.5rem;
  font-weight: 700;
  color: #2c3e50;
  margin-bottom: 1.5rem;
  text-shadow: 0 2px 4px rgba(255, 255, 255, 0.5);
}

.hero-content p {
  font-size: 1.25rem;
  color: #34495e;
  margin-bottom: 2rem;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.3);
  line-height: 1.25;
}

.hero-content .tagline {
  font-size: 1.8rem;
  font-weight: 600;
  color: #4682B4;
  font-style: italic;
  margin-bottom: 2.5rem;
}

/* ===================================
   RESPONSIVE DESIGN
   =================================== */

@media (max-width: 768px) {
  .btn-water {
    padding: 10px 20px;
    font-size: 14px;
  }

  .hero {
    min-height: 400px;
    width: 400vw; /* 4x screen width */
    left: -150vw; /* Center the 4x wide area */
  }

  /* Reposition all child elements to be in the visible area */
  .hero-background,
  .hero-background-content,
  .hero-water-layer,
  .hero-caustics,
  .hero-shimmer,
  .hero-logo,
  .hero-mockup {
    left: 150vw; /* Offset back to visible area */
    width: 100vw; /* Take up full viewport width */
  }

  /* Canvas inside hero - offset back to visible area like other hero children */
  .hero-canvas,
  #water-canvas {
    left: 150vw !important;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
  }

  /* Mockup - centered on mobile */
  .hero-mockup {
    left: 150vw !important; /* Offset back to visible area */
    width: 100vw !important;
    height: 50%;
    background-position: bottom center !important;
  }

  .hero-content {
    position: relative;
    left: 0; /* Offset back to visible area */
    width: 90vw; /* Take up full viewport width */
    padding: 0 12px !important;
  }

  .hero-content h1 {
    font-size: 2rem;
  }

  .hero-content p {
    font-size: 1rem;
  }

  .hero-content .tagline {
    font-size: 1.2rem;
  }

  /* Logo - 100% width, centered on mobile */
  .hero-logo {
    background-position: center center;
  }

  /* Reduce animation intensity on mobile for performance */
  .hero-water-layer,
  .hero-caustics {
    animation-duration: 60s;
  }
}

/* Below 525px - can increase bottle size again */
@media (max-width: 525px) {
  .hero-mockup {
    height: 55%;
  }
}

@media (max-width: 480px) {
  .hero {
    min-height: 350px;
  }

  .hero-mockup {
    height: 52%;
  }

  .hero-content h1 {
    font-size: 1.75rem;
  }

  .hero-content p {
    font-size: 0.9rem;
  }

  .hero-content .tagline {
    font-size: 1.1rem;
  }
}

/* Small mobile devices - Galaxy S23 and similar */
@media (max-width: 420px) {
  .hero {
    min-height: 300px;
  }

  .hero-mockup {
    height: 50%;
  }

  .hero-content h1 {
    font-size: 1.5rem;
  }

  .hero-content p {
    font-size: 0.85rem;
  }

  .hero-content .tagline {
    font-size: 1rem;
  }
}


/* ===================================
   ACCESSIBILITY
   =================================== */

/* Focus states for keyboard navigation */
button:focus,
a:focus {
  outline: 3px solid rgba(135, 206, 235, 0.8);
  outline-offset: 2px;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  /* Disable water effects for reduced motion */
  .hero-water-layer,
  .hero-caustics,
  .hero-shimmer,
  .hero-background-content {
    animation: none !important;
    filter: none !important;
  }
}
