/* ==========================================================
   Dela Vega Healthcare Services - Doctean Integrated Theme Stylesheet
   ========================================================== */

/* ---------- Color Tokens & Variables ---------- */
:root {
  --primary-color: #0e9a83;
  --primary-hover: #0b7c69;
  --secondary-color: #14181d;
  --text-dark: #14181d;
  --text-muted: #64758d;
  --bg-light: #f6f8fb;
  --border-light: #e2e8f0;
  
  --font-heading: 'Sora', 'Plus Jakarta Sans', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
}

/* ---------- Typography & Global Resets ---------- */
body {
  font-family: var(--font-body);
  color: var(--text-dark);
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
}

/* Smooth Scrolling */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

/* ---------- Hero Banner & Dark Gradient Overlay for Readability ---------- */
.banner-slider,
.banner-swiper,
.banner-swiper .swiper-wrapper,
.banner-swiper .swiper-slide {
  position: relative;
  min-height: 620px;
  width: 100%;
}

.banner-swiper .swiper-slide {
  opacity: 1 !important;
  visibility: visible !important;
}

.slider-img {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  min-height: 620px;
  background-size: cover;
  background-position: right top;
  background-repeat: no-repeat;
  z-index: 1;
}

.slider-img::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(3, 27, 78, 0.7) 0%, rgba(3, 27, 78, 0.4) 60%, rgba(3, 27, 78, 0.1) 100%);
  z-index: 2;
}

.banner-content {
  position: relative;
  z-index: 10 !important;
  padding: 130px 0 100px;
}

.banner-text h6,
.banner-content h6 {
  background-color: #1344FE !important;
  color: #ffffff !important;
  padding: 8px 22px !important;
  border-radius: 100px !important;
  display: inline-block !important;
  font-size: 14px !important;
  line-height: 24px !important;
  font-weight: 600 !important;
  letter-spacing: 2px !important;
  text-transform: uppercase !important;
  margin-bottom: 20px !important;
  box-shadow: 0 4px 14px rgba(19, 68, 254, 0.4) !important;
}

.banner-text h1 {
  color: #ffffff !important;
  font-size: 4.5rem;
  line-height: 1.1;
  font-weight: 700;
  margin-bottom: 24px;
}

.banner-text p {
  color: rgba(255, 255, 255, 0.95) !important;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

/* ---------- Hero Banner Text Looping Animation ---------- */
.swiper-slide-active .splitting .char {
  animation-duration: 0.75s;
  animation-timing-function: cubic-bezier(0.5, 0, 0.5, 1);
  animation-fill-mode: both;
  animation-name: slide-in;
  animation-delay: calc(0.2s + (40ms * var(--char-index)));
}

.swiper-slide-active .banner-text h6 {
  animation: zoomIn 1s ease-out both, heroPillPulse 4s ease-in-out infinite 1.2s;
}

.swiper-slide-active .banner-text h1 {
  animation: heroFloatLoop 5s ease-in-out infinite 1.2s;
}

@keyframes heroPillPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 4px 14px rgba(19, 68, 254, 0.4); }
  50% { transform: scale(1.05); box-shadow: 0 6px 22px rgba(19, 68, 254, 0.7); }
}

@keyframes heroFloatLoop {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

/* ---------- Marquee Animation ---------- */
.marquee-wrap {
  overflow: hidden;
  white-space: nowrap;
  width: 100%;
  position: relative;
  padding: 12px 0;
}

.marquee-inner {
  display: inline-flex;
  align-items: center;
  gap: 3rem;
  animation: marquee-scroll 25s linear infinite;
  min-width: 200%;
}

.marquee-text {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-heading);
  font-weight: 700;
  white-space: nowrap;
}

@keyframes marquee-scroll {
  0% { transform: translateX(0%); }
  100% { transform: translateX(-50%); }
}

/* ---------- Explore More Button & Circular SVG Text ---------- */
.round-text {
  position: relative;
  width: 150px;
  height: 150px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.round-text svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: rotateCircle 16s linear infinite;
  fill: #ffffff;
}

.round-text svg text {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 2px;
  fill: #ffffff;
  text-transform: uppercase;
}

@keyframes rotateCircle {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.text-btn-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #1344FE;
  color: #ffffff !important;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  line-height: 1;
  text-decoration: none;
  z-index: 5;
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
  transform-origin: center center;
  box-shadow: 0 4px 14px rgba(19, 68, 254, 0.4);
}

.text-btn-icon i {
  pointer-events: none;
}

.text-btn-icon:hover {
  transform: translate(-50%, -50%) scale(1.12);
  background-color: #ffffff !important;
  color: #1344FE !important;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.25);
}

/* ---------- Department Service Cards (`style-3`) Equal Sizing ---------- */
.service-swiper .swiper-wrapper {
  align-items: stretch;
}

.service-swiper .swiper-slide {
  height: auto;
  display: flex;
}

.service-item.style-3 {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background: #ffffff;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.service-item.style-3:hover {
  transform: translateY(-6px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.service-desc {
  flex: 0 0 auto;
}

.service-image {
  position: relative;
  overflow: hidden;
  height: 220px;
  flex: 0 0 220px;
  background-color: var(--bg-light);
}

.service-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.5s ease;
}

.service-item.style-3:hover .service-image img {
  transform: scale(1.08);
}

.service-item.style-3 .service-body {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.arrow-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg-light);
  color: var(--primary-color);
  transition: all 0.3s ease;
  text-decoration: none;
  margin-top: 12px;
}

.arrow-button:hover {
  background: var(--primary-color);
  color: #ffffff;
}

.arrow-button svg line {
  stroke: currentColor;
  stroke-width: 2;
}

/* ---------- Health Toolkit & Calculators ---------- */
.toolkit {
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
}

.toolkit-tabs {
  background: var(--bg-light);
  border-bottom: 1px solid var(--border-light);
}

.toolkit-tab {
  background: transparent;
  border: none;
  padding: 16px 24px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.25s ease;
  border-bottom: 3px solid transparent;
}

.toolkit-tab:hover {
  color: var(--primary-color);
}

.toolkit-tab.is-active {
  color: var(--primary-color);
  background: #ffffff;
  border-bottom-color: var(--primary-color);
}

.toolkit-panel {
  display: none;
}

.toolkit-panel.is-active {
  display: block;
}

/* BMI Calculator Components */
.bmi-readout {
  display: flex;
  align-items: center;
  gap: 16px;
}

.bmi-value {
  color: var(--primary-color);
}

.bmi-bar-wrap {
  margin-top: 12px;
}

.bmi-bar {
  position: relative;
  height: 14px;
  display: flex;
  border-radius: 20px;
  overflow: visible;
  background: #e2e8f0;
}

.bmi-seg {
  height: 100%;
}

.seg-under { width: 18.5%; background: #38bdf8; border-top-left-radius: 20px; border-bottom-left-radius: 20px; }
.seg-normal { width: 26%; background: #22c55e; }
.seg-over { width: 20%; background: #eab308; }
.seg-obese { width: 35.5%; background: #ef4444; border-top-right-radius: 20px; border-bottom-right-radius: 20px; }

.bmi-marker {
  position: absolute;
  top: -6px;
  width: 4px;
  height: 26px;
  background: #0f172a;
  border-radius: 2px;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.4);
  opacity: 0;
  transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.2s ease;
}

.bmi-marker.is-visible {
  opacity: 1;
}

.cat-under { background-color: #e0f2fe; color: #0284c7; }
.cat-normal { background-color: #dcfce7; color: #16a34a; }
.cat-over { background-color: #fef9c3; color: #ca8a04; }
.cat-obese { background-color: #fee2e2; color: #dc2626; }

/* Blood Pressure Badges */
.bp-badge {
  transition: all 0.3s ease;
}

.bp-normal { background-color: #dcfce7; border-color: #86efac; color: #16a34a; }
.bp-elevated { background-color: #fef9c3; border-color: #fef08a; color: #ca8a04; }
.bp-stage1 { background-color: #ffedd5; border-color: #fed7aa; color: #ea580c; }
.bp-stage2 { background-color: #fee2e2; border-color: #fca5a5; color: #dc2626; }
.bp-crisis { background-color: #7f1d1d; border-color: #991b1b; color: #ffffff; }

/* ---------- Forms & Cards ---------- */
.hero-card, .contact-form-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid var(--border-light);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.06);
  padding: 30px;
}

.form-control, .form-select {
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  padding: 12px 16px;
  font-size: 0.95rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus, .form-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(14, 154, 131, 0.15);
}

.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: #ffffff;
  font-weight: 600;
  padding: 12px 28px;
  border-radius: 8px;
  transition: all 0.25s ease;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
  color: #ffffff;
  transform: translateY(-1px);
}

/* ---------- Doctean Theme Footer Styles ---------- */
.footer {
  background-color: #14181d !important;
  color: #a0aec0 !important;
}

.primary-footer {
  padding: 80px 0 40px;
}

.footer p {
  color: #a0aec0 !important;
  font-size: 0.95rem;
  line-height: 1.7;
}

.widget-title {
  color: #ffffff !important;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.15rem;
  margin-bottom: 24px;
  position: relative;
}

.footer ul li {
  margin-bottom: 12px;
}

.footer ul li a {
  color: #cbd5e1 !important;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.25s ease, padding-left 0.25s ease;
}

.footer ul li a:hover {
  color: #ffffff !important;
  padding-left: 4px;
}

.working-hours-item {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
}

.working-hours-item:last-child {
  border-bottom: none;
}

.working-day {
  color: #cbd5e1 !important;
  font-weight: 500;
}

.working-time {
  color: var(--primary-color) !important;
  font-weight: 700;
}

.footer-cntct ul li {
  color: #cbd5e1 !important;
  font-size: 0.95rem;
}

.footer-cntct ul li span {
  color: #ffffff !important;
  font-weight: 600;
}

.footer-cntct ul li a {
  color: var(--primary-color) !important;
}

.secondary-footer {
  background-color: #0e1217 !important;
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
  padding: 24px 0;
}

.secondary-footer .copyright {
  color: #8f9cae !important;
  font-size: 0.9rem;
}

.secondary-footer .social-icons a {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff !important;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.secondary-footer .social-icons a:hover {
  background: var(--primary-color);
  color: #ffffff !important;
  transform: translateY(-3px);
}

/* ---------- Toast Notifications & Announcements ---------- */
.announcement {
  background: var(--secondary-color);
  color: #ffffff;
  font-size: 0.9rem;
}

.announcement-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  max-width: 1200px;
  margin: 0 auto;
}

.announcement-close {
  background: transparent;
  border: none;
  color: #ffffff;
  cursor: pointer;
  margin-left: auto;
}

.toast {
  position: fixed;
  top: 100px;
  right: 20px;
  z-index: 9999;
  background: #ffffff;
  border-left: 4px solid var(--primary-color);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.toast-success { border-left-color: #22c55e; }
.toast-error { border-left-color: #ef4444; }

.toast-close {
  background: transparent;
  border: none;
  cursor: pointer;
  color: #94a3b8;
}

/* ---------- Topbar & Header Login Badges ---------- */
.topbar-login-pill {
  background: rgba(19, 68, 254, 0.1);
  color: #1344fe;
  padding: 4px 14px;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid rgba(19, 68, 254, 0.25);
  transition: all 0.2s ease;
}
.topbar-login-pill:hover {
  background: #1344fe;
  color: #ffffff;
}

.header-login-btn {
  background: #eef2ff !important;
  color: #1344fe !important;
  border: 1.5px solid #c7d2fe !important;
  padding: 9px 20px !important;
  border-radius: 100px !important;
  font-weight: 700 !important;
  font-size: 13px !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: all 0.25s ease;
}
.header-login-btn:hover {
  background: #1344fe !important;
  color: #ffffff !important;
  border-color: #1344fe !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(19, 68, 254, 0.25);
}

.mobile-quick-login-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  background: #e0e7ff;
  color: #1e40af;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  margin-left: auto;
  margin-right: 8px;
  white-space: nowrap;
  transition: all 0.2s ease;
}
.mobile-quick-login-btn:hover {
  background: #1e40af;
  color: #ffffff;
}

/* ---------- Emergency Line strict No-Wrap ---------- */
.emergency-details {
  min-width: 0;
  flex-shrink: 1;
}
.emergency-num {
  white-space: nowrap !important;
  font-size: clamp(0.72rem, 2.2vw, 0.95rem) !important;
  display: block !important;
  line-height: 1.2 !important;
}
.emergency-lbl {
  white-space: nowrap !important;
  font-size: 0.62rem !important;
  letter-spacing: 0.5px !important;
  line-height: 1 !important;
}

/* ---------- Desktop Hero Arrow Clearance ---------- */
@media (min-width: 992px) {
  .banner-content {
    padding-left: clamp(20px, 6vw, 85px) !important;
  }
  .banner-slider .banner-button-prev {
    top: 68% !important;
    left: 20px !important;
    transform: translateY(-50%) !important;
  }
  .banner-slider .banner-button-next {
    top: 68% !important;
    right: 20px !important;
    transform: translateY(-50%) !important;
  }
}

/* ---------- Mobile Header & Drawer Navigation ---------- */
#menu-toggle.nav-menu-toggle {
  display: none;
}

@media (max-width: 1199.98px) {
  #menu-toggle.nav-menu-toggle {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    font-size: 26px;
    margin: 0 10px 0 12px;
    color: var(--themeht-primary-color);
    background: #f8fafc;
    border-radius: 8px;
    border: 1.5px solid #e2e8f0;
    cursor: pointer;
    padding: 0;
    order: -1;
    flex-shrink: 0;
    transition: all 0.2s ease;
  }
  #menu-toggle.nav-menu-toggle:hover {
    background: #e2e8f0;
  }

  .main-nav {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: auto !important;
    width: min(320px, 85vw) !important;
    height: 100vh !important;
    background: #ffffff !important;
    z-index: 999999 !important;
    box-shadow: 6px 0 30px rgba(0, 0, 0, 0.2) !important;
    display: flex !important;
    flex-direction: column !important;
    padding: 20px 20px 30px !important;
    transform: translateX(-100%) !important;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
    overflow-y: auto !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
  body.menu-active .main-nav,
  .main-nav.menu-active,
  .main-nav.active {
    transform: translateX(0) !important;
  }

  .mobile-drawer-header {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    padding-bottom: 14px !important;
    margin-bottom: 12px !important;
    border-bottom: 1px solid #e2e8f0 !important;
    position: relative !important;
  }
  .mobile-drawer-title {
    font-weight: 700 !important;
    font-size: 1.05rem !important;
    color: #0f172a !important;
    display: flex !important;
    align-items: center !important;
    margin: 0 !important;
    line-height: 1.2 !important;
  }
  .closepanel {
    position: static !important;
    inset: auto !important;
    margin: 0 !important;
    cursor: pointer;
    color: #64748b;
    font-size: 18px;
    line-height: 1;
    padding: 6px 8px;
    border-radius: 8px;
    background: #f1f5f9;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.2s ease;
  }
  .closepanel:hover {
    color: #0f172a;
    background: #e2e8f0;
  }

  .mobile-menu-login-card {
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 16px;
  }
  .login-icon-badge {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #e0e7ff;
    color: #1e40af;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
  }

  .main-nav .menu {
    display: flex !important;
    flex-direction: column !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
  }
  .main-nav .menu li {
    border-bottom: 1px solid #f1f5f9 !important;
    margin: 0 !important;
  }
  .main-nav .menu li a {
    display: block !important;
    padding: 12px 6px !important;
    color: #334155 !important;
    font-size: 0.92rem !important;
    font-weight: 600 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    text-decoration: none !important;
    transition: color 0.2s ease, transform 0.2s ease !important;
  }
  .main-nav .menu li.current-menu-item a,
  .main-nav .menu li a:hover {
    color: #1344fe !important;
    transform: translateX(3px) !important;
  }

  .ht-mobile-menu-bg {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background: rgba(3, 27, 78, 0.6) !important;
    backdrop-filter: blur(4px) !important;
    -webkit-backdrop-filter: blur(4px) !important;
    z-index: 999990 !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transform: none !important;
    transition: opacity 0.3s ease, visibility 0.3s ease !important;
    display: block !important;
  }
  body.menu-active .ht-mobile-menu-bg,
  .ht-mobile-menu-bg.active {
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
  }
}

/* ---------- Additional Responsive Polish ---------- */
@media (max-width: 768px) {
  .toolkit-tabs {
    flex-direction: column;
  }
  .toolkit-tab {
    width: 100%;
    text-align: left;
  }
  .marquee-inner {
    gap: 1.5rem;
  }
  .banner-content {
    padding: 100px 0 60px;
  }
}

@media (max-width: 575.98px) {
  .emergency-phone-icon {
    font-size: 1.25rem !important;
  }
  .header-number {
    gap: 6px !important;
  }
}
