/* =============================================
   HAPPY HIVE KIDS — Main Stylesheet
   ============================================= */

/* --- CSS Variables --- */
:root {
  --primary-color: #F3A82E;
  --accent-color: #4C2C1A;
  --text-dark: #4C2C1A;
  --text-light: #FFFFFF;
  --glass-bg: rgba(248, 239, 223, 0.7);
  --glass-border: rgba(76, 44, 26, 0.2);
}

/* --- Reset --- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* --- Base --- */
body {
  font-family: 'Nunito', sans-serif;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #F8EFDF url('background.jpeg') no-repeat center center;
  background-size: cover;
  position: relative;
  color: var(--text-dark);
}

/* --- Header --- */
header {
  height: 100px;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0 40px;
  position: relative;
  z-index: 2000;
}

#navbar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 1600px;
}

.nav-left,
.nav-right {
  display: flex;
  align-items: center;
  flex: 1;
}

.nav-left {
  justify-content: flex-end;
  gap: 3vw;
}

.nav-right {
  justify-content: flex-start;
  gap: 3vw;
}

.logo-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0 40px;
}

/* Mobile-only header logo (hidden on desktop) */
.header-logo-container {
  display: none;
}

#logo-img,
#header-logo-img {
  height: 75px;
  object-fit: contain;
  transition: transform 0.3s;
}

#logo-img:hover,
#header-logo-img:hover {
  transform: scale(1.05);
}

/* --- Nav Links --- */
.header-link {
  text-decoration: none;
  color: var(--text-dark);
  font-family: 'Cabin', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: color 0.3s ease;
  position: relative;
}

.header-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--primary-color);
  transition: width 0.3s ease;
}

.header-link:hover::after { width: 100%; }
.header-link:hover { color: var(--primary-color); }

/* --- Search Box --- */
.search-box {
  display: flex;
  align-items: center;
  background: rgba(76, 44, 26, 0.05);
  border: 1px solid var(--accent-color);
  border-radius: 30px;
  padding: 5px 15px;
  backdrop-filter: blur(5px);
  transition: background 0.3s;
}

.search-box:focus-within {
  background: rgba(255, 255, 255, 0.9);
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-dark);
  font-family: 'Nunito', sans-serif;
  font-size: 1rem;
  width: 120px;
  transition: width 0.3s;
}

.search-box:focus-within input {
  width: 180px;
}

.search-box input::placeholder { color: rgba(76, 44, 26, 0.6); }
.search-box:focus-within input::placeholder { color: #888; }

.search-box button {
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text-dark);
  display: flex;
  align-items: center;
  justify-content: center;
}

.search-box svg {
  width: 20px;
  height: 20px;
}

/* --- Hamburger (Mobile) --- */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  gap: 6px;
  z-index: 5000;
  position: relative;
  width: 40px;
  height: 40px;
}

.hamburger span {
  width: 28px;
  height: 3px;
  background-color: var(--accent-color);
  transition: all 0.3s ease;
  border-radius: 2px;
}

.hamburger.active span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; transform: translateX(10px); }
.hamburger.active span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* --- Mobile Hero Image (hidden on desktop) --- */
.mobile-hero-image {
  display: none;
  width: 100%;
  max-width: 320px;
  height: auto;
  margin: 0 auto 10px auto;
  object-fit: contain;
}

/* --- Main Content --- */
main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 0 8vw;
  z-index: 1;
  position: relative;
}

.glass-box {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 30px 40px;
  width: 100%;
  max-width: 550px;
  box-shadow: 0 8px 32px 0 rgba(76, 44, 26, 0.1);
  animation: fadeIn 1s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

.subheading-top {
  font-family: 'Cabin', sans-serif;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

h1 {
  font-size: 2.8rem;
  font-family: 'Cabin', sans-serif;
  color: var(--primary-color);
  line-height: 1.1;
  margin-bottom: 25px;
  -webkit-text-stroke: 1.2px var(--accent-color);
  text-shadow: 2px 2px 0px rgba(76, 44, 26, 0.2);
  paint-order: stroke fill;
}

/* --- Email Form --- */
.email-form {
  display: flex;
  margin-bottom: 25px;
  gap: 10px;
}

.email-form input {
  flex: 1;
  padding: 12px 20px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 30px;
  font-family: 'Nunito', sans-serif;
  font-size: 1rem;
  outline: none;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
}

.email-form button {
  padding: 12px 25px;
  background: var(--primary-color);
  color: #fff;
  border: none;
  border-radius: 30px;
  font-family: 'Cabin', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.email-form button:hover {
  background: #E0960F;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* --- Content Block --- */
.content-block h3 {
  font-family: 'Cabin', sans-serif;
  font-size: 1.2rem;
  color: var(--text-dark);
  margin-bottom: 10px;
}

.content-block p {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-dark);
  text-align: justify;
}

/* --- Footer --- */
footer {
  height: 60px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(248, 239, 223, 0.8);
  border-top: 1px solid rgba(76, 44, 26, 0.1);
  z-index: 10;
  color: var(--text-dark);
  font-size: 0.9rem;
  position: relative;
}

footer a {
  color: var(--text-dark);
  text-decoration: none;
  transition: color 0.3s;
  font-weight: 600;
}

footer a:hover { color: var(--primary-color); }

.divider {
  margin: 0 15px;
  color: rgba(76, 44, 26, 0.2);
}

/* --- WhatsApp Floating Button --- */
.whatsapp-float {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 9999;
  width: 58px;
  height: 58px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-decoration: none;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.45);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  animation: wa-pulse 2.5s infinite;
}

.whatsapp-float svg {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 8px 28px rgba(37, 211, 102, 0.6);
  animation: none;
}

.whatsapp-tooltip {
  position: absolute;
  right: 68px;
  background: var(--accent-color);
  color: #fff;
  font-family: 'Nunito', sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 20px;
  pointer-events: none;
  opacity: 0;
  transform: translateX(8px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.whatsapp-tooltip::after {
  content: '';
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
  border-width: 5px 0 5px 6px;
  border-style: solid;
  border-color: transparent transparent transparent var(--accent-color);
}

.whatsapp-float:hover .whatsapp-tooltip {
  opacity: 1;
  transform: translateX(0);
}

@keyframes wa-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5); }
  70%  { box-shadow: 0 0 0 14px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* =============================================
   RESPONSIVE DESIGN
   ============================================= */

@media (max-width: 1200px) {
  .nav-left, .nav-right { gap: 2vw; }
  .header-link { font-size: 1rem; }
  h1 { font-size: 2.4rem; }
}

@media (max-width: 992px) {
  body {
    overflow-y: auto;
    height: auto;
    min-height: 100vh;
  }
  .glass-box { padding: 30px; max-width: 450px; }
  h1 { font-size: 2.2rem; }
  .nav-left, .nav-right { gap: 1.5vw; }
  .header-link { font-size: 0.9rem; }
  #logo-img { height: 70px; }
  .search-box input { width: 90px; }
  .search-box:focus-within input { width: 130px; }
}

@media (max-width: 768px) {
  body {
    overflow: hidden;
    height: 100vh;
    background: #F8EFDF;
  }

  header {
    justify-content: space-between;
    height: 70px;
    padding: 0 15px;
  }

  .hamburger { display: flex; }
  .logo-container { padding: 0; }

  /* Centered logo in mobile header */
  .header-logo-container {
    display: flex !important;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    justify-content: center;
    align-items: center;
  }

  #header-logo-img { height: 60px; }

  /* Mobile slide-in nav drawer */
  #navbar {
    position: fixed;
    top: 0;
    left: -100%;
    width: 250px;
    height: 100vh;
    background: #F8EFDF;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    transition: left 0.4s ease-in-out;
    padding: 40px 20px;
    z-index: 3000;
    box-shadow: 5px 0 25px rgba(76, 44, 26, 0.2);
  }

  #navbar.active { left: 0; }

  /* Logo inside nav drawer */
  #navbar .logo-container {
    display: flex !important;
    order: -1;
  }

  #navbar #logo-img { height: 40px; }

  .nav-left,
  .nav-right {
    flex-direction: column;
    width: 100%;
    gap: 15px;
    margin: 10px 0;
    text-align: center;
  }

  .nav-left { margin-top: auto; }

  .header-link { font-size: 1.1rem; }

  .search-box {
    background: rgba(76, 44, 26, 0.05);
    margin-top: 10px;
    margin-bottom: auto;
    width: 100%;
    justify-content: center;
  }

  /* Mobile hero image */
  .mobile-hero-image {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    margin: 0 auto 5px auto;
  }

  main {
    padding: 0;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
  }

  .glass-box {
    max-width: 92%;
    padding: 12px 20px;
    border-radius: 15px;
    margin: 0 auto;
  }

  .subheading-top {
    font-size: 0.85rem;
    margin-bottom: 3px;
    letter-spacing: 0.5px;
  }

  h1 {
    font-size: 1.25rem;
    margin-bottom: 8px;
    -webkit-text-stroke: 0.8px var(--accent-color);
  }

  .email-form { margin-bottom: 12px; gap: 8px; }
  .email-form input { padding: 8px 15px; font-size: 0.85rem; }
  .email-form button { padding: 8px 15px; font-size: 0.85rem; }

  .content-block h3 {
    font-size: 0.85rem;
    margin-bottom: 4px;
    font-weight: 700;
  }

  .content-block p {
    font-size: 0.72rem;
    line-height: 1.4;
    text-align: center;
  }

  footer {
    height: 40px;
    padding: 0 10px;
    gap: 10px;
    font-size: 0.65rem;
  }

  .divider { margin: 0 5px; }

  /* WhatsApp adjustments */
  .whatsapp-float {
    bottom: 18px;
    right: 18px;
    width: 52px;
    height: 52px;
  }

  .whatsapp-float svg {
    width: 26px;
    height: 26px;
  }

  .whatsapp-tooltip { display: none; }
}

@media (max-height: 700px) and (min-width: 769px) {
  h1 { font-size: 2rem; margin-bottom: 15px; }
  .glass-box { padding: 25px; }
  .content-block p { font-size: 0.9rem; line-height: 1.4; }
  header { height: 90px; }
  #logo-img { height: 70px; }
}
