:root{
  --primary:#15396F;   /* dark blue */
  --text:#374151;
  --muted:#6b7280;
  --border:#e5e7eb;
  --shadow:0 10px 30px rgba(0,0,0,.08);
}

*{ box-sizing:border-box; }

body{
  margin:0;
  font-family:system-ui, Arial, sans-serif;
  background:#fff;
  color:var(--text);
}

.auth-alert{
  margin: 0 0 14px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #f9fafb;
  color: var(--text);
  font-weight: 600;
}
.auth-alert--error{
  border-color:#fecaca;
  background:#fef2f2;
  color:#991b1b;
}

.top-line{
  height:6px;
  background:var(--primary);
}

/* HEADER */
.header{
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav-wrap{
  max-width:1200px;
  margin:0 auto;
  padding:14px 18px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
}

/* BRAND LEFT */
.brand{
  display:flex;
  align-items:center;
  gap:12px;
  min-width: 220px;

  /* REMOVE underline */
  text-decoration: none;
  color: inherit;
}

/* make sure underline never appears */
.brand:hover,
.brand:focus,
.brand:active{
  text-decoration: none;
  color: inherit;
}

/* HEADER LOGO */
.brand-logo{
  width:46px;
  height:46px;
  object-fit:contain;

  border: none;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
}

.brand-text{
  line-height: 1.05;
}
.brand-title{
  font-weight:800;
  color:var(--primary);
  letter-spacing:.4px;
}
.brand-sub{
  font-size:12px;
  color:var(--muted);
  font-weight:700;
  letter-spacing:.6px;
}

/* NAV RIGHT */
.nav-list{
  list-style:none;
  margin:0;
  padding:0;
  display:flex;
  align-items:center;
  gap:22px;
}

.nav-list a{
  position: relative; 
  text-decoration:none;
  color:var(--text);
  font-weight:500;
  padding:8px 12px;
  border-radius:10px;
  transition: background .15s ease, color .15s ease;
}


.nav-list a:hover{
  background:#f3f4f6;
  color:var(--primary);
}

/* =========================
   ACTIVE TOPBAR LINK
   ========================= */
.nav-list a.active,
.mobile-nav a.active{
  background:#f3f4f6;
  color:var(--primary);
  font-weight:700;
}

/* underline indicator (desktop) */
.nav-list a.active::after{
  content:"";
  position:absolute;
  left:10px;
  right:10px;
  bottom:4px;
  height:2px;
  background:var(--primary);
  border-radius:2px;
}

/* =========================
   MOBILE MENU
   ========================= */

/* Menu button */
.menu-btn{
  display: none;
  border: 1px solid var(--border);
  background: #fff;
  padding: 8px 12px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 600;
}

/* Mobile nav (dropdown drawer) */
.mobile-nav{
  display: none;
}

@media (max-width: 780px){
  .menu-btn{
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .mobile-nav{
    position: fixed;
    top: 70px;              /* adjust if header height changes */
    left: 14px;
    right: 14px;
    z-index: 999;

    padding: 12px;
    border-radius: 18px;

    background: rgba(255,255,255,.92);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(0,0,0,.08);
    box-shadow: 0 20px 60px rgba(0,0,0,.18);
  }

  .mobile-nav.open{
    display: block;
    animation: mobileDrop .18s ease;
  }

  @keyframes mobileDrop{
    from{ opacity: 0; transform: translateY(-8px); }
    to{ opacity: 1; transform: translateY(0); }
  }

  .mobile-nav a{
    display: flex;
    align-items: center;
    padding: 14px 14px;
    border-radius: 14px;
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
  }

  .mobile-nav a:hover{
    background: #f3f4f6;
    color: var(--primary);
  }

  /* Mobile active style */
  .mobile-nav a.active{
    background: #eef2ff;
    color: var(--primary);
    border-left: 5px solid var(--primary);
    padding-left: 10px;
  }
}

/* HERO */
.hero{
  min-height: calc(100vh - 120px);
  display:grid;
  place-items:center;
  padding: 20px 0 60px;
}

.hero-inner{
  text-align:center;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap: 26px;
}
/* Big seal circle */
.logo-frame{
  width: min(560px, 82vw);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  display:grid;
  place-items:center;
  background: #ffffff;
  box-shadow: var(--shadow);
  border: 1px solid rgba(0,0,0,.06);
  overflow:hidden;

  /* new animation */
  animation: bounceRotate 4.5s ease-in-out infinite;
  transform-origin: center;
}

/* bouncing + rotation animation */
@keyframes bounceRotate{
  0%{
    transform: translateY(0) rotate(0deg);
    box-shadow: 0 10px 30px rgba(0,0,0,.08);
  }

  20%{
    transform: translateY(-22px) rotate(4deg);
    box-shadow: 0 22px 40px rgba(0,0,0,.12);
  }

  40%{
    transform: translateY(0) rotate(0deg);
    box-shadow: 0 12px 30px rgba(0,0,0,.09);
  }

  60%{
    transform: translateY(-12px) rotate(-3deg);
    box-shadow: 0 18px 34px rgba(0,0,0,.11);
  }

  80%{
    transform: translateY(0) rotate(0deg);
    box-shadow: 0 10px 30px rgba(0,0,0,.08);
  }

  100%{
    transform: translateY(0) rotate(0deg);
    box-shadow: 0 10px 30px rgba(0,0,0,.08);
  }
}



.hero-logo{
  width: 86%;
  height: 86%;
  object-fit: contain;
  display:block;
}

.hero-title{
  margin:0;
  font-size: clamp(34px, 4.2vw, 64px);
  font-weight: 320;
  color: #4b5563;
  letter-spacing:.2px;
}
.hero-title span{
  color: var(--primary);
  font-weight: 500;
}

/* =========================
   SERVICES CARDS
   ========================= */

.services-cards{
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 18px 64px;
  border-top: 1px solid var(--border);
}

.services-title{
  margin: 0 0 22px;
  text-align: center;
  font-size: clamp(22px, 2.4vw, 34px);
  font-weight: 350;
  color: #4b5563;
}

.cards-grid{
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 34px;
  align-items: start;
}

.service-card{
  text-decoration: none;
  color: inherit;
  padding: 10px 6px;
  border-radius: 16px;
  transition: .18s ease;
}

.service-card:hover{
  background: #f8fafc;
  transform: translateY(-2px);
}

.service-icon{
  width: 54px;
  height: 54px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 26px;
  color: var(--primary);
  background: #ffffff;
  border: 1px solid rgba(21,57,111,.18);
  box-shadow: 0 10px 18px rgba(0,0,0,.06);
  margin: 0 auto 12px;
}

.service-title{
  margin: 0;
  text-align: center;
  font-size: 18px;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: .2px;
}

.service-desc{
  margin: 10px 0 0;
  text-align: center;
  color: var(--muted);
  line-height: 1.6;
  font-size: 14px;
}

/* Sections */
.section{
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 18px;
  border-top: 1px solid var(--border);
}
.section h2{
  margin: 0 0 10px;
  color: var(--primary);
}
.section p{
  margin:0;
  color: var(--muted);
  line-height: 1.6;
}

/* Scroll to top */
.to-top{
  position:fixed;
  right:18px;
  bottom:18px;
  width:52px;
  height:52px;
  border:none;
  border-radius:12px;
  background: var(--primary);
  color:#fff;
  cursor:pointer;
  box-shadow: var(--shadow);
  opacity:0;
  pointer-events:none;
  transform: translateY(10px);
  transition: .2s ease;
}
.to-top.show{
  opacity:1;
  pointer-events:auto;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 980px){
  .cards-grid{
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
  }
}

@media (max-width: 520px){
  .cards-grid{
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .service-card{
    padding: 14px 12px;
    border: 1px solid var(--border);
    background: #fff;
  }
  .service-card:hover{
    transform: none;
  }
}

@media (max-width: 780px){
  .nav{ display:none; }
  .menu-btn{ display:block; }
  .brand{ min-width: auto; }
}
/* =========================
   CONTACT SECTION (Map)
   ========================= */

.contact-section{
  border-top: 1px solid var(--border);
  padding: 56px 18px 70px;
  background: #fff;
}

.contact-title{
  margin: 0 0 24px;
  text-align: center;
  font-size: clamp(28px, 4vw, 56px);
  font-weight: 320;
  color: #4b5563;
  letter-spacing: .2px;
}

.contact-wrap{
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.6fr .9fr;
  gap: 18px;
  align-items: stretch;
}

.contact-map{
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  background: #fff;
  min-height: 420px;
}

.contact-map iframe{
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  min-height: 420px;
}

.contact-info{
  border-radius: 18px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 18px 18px 16px;
  background: #fff;
}

.contact-info h3{
  margin: 0 0 10px;
  color: var(--primary);
  font-size: 18px;
}

.contact-info p{
  margin: 0 0 10px;
  color: var(--muted);
  line-height: 1.6;
  font-size: 14px;
}

.contact-btn{
  display: inline-block;
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  text-decoration: none;
  background: var(--primary);
  color: #fff;
  font-weight: 600;
  font-size: 14px;
  transition: .15s ease;
}

.contact-btn:hover{
  transform: translateY(-1px);
  filter: brightness(1.05);
}

/* Responsive */
@media (max-width: 980px){
  .contact-wrap{
    grid-template-columns: 1fr;
  }
  .contact-map{
    min-height: 360px;
  }
  .contact-map iframe{
    min-height: 360px;
  }
}
/* =========================
   FOOTER
   ========================= */

.site-footer{
  background: #3e4b57;
  color: #ffffff;
  padding: 26px 18px;
}

.footer-wrap{
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.footer-left p{
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
}

.footer-sub{
  opacity: .85;
  font-size: 13px;
}

.footer-right{
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-social{
  width: 42px;
  height: 42px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,.12);
  transition: .15s ease;
}

.footer-social:hover{
  background: rgba(255,255,255,.2);
  transform: translateY(-2px);
}

.footer-social svg{
  width: 20px;
  height: 20px;
  fill: #ffffff;
}

/* Responsive */
@media (max-width: 640px){
  .footer-wrap{
    flex-direction: column;
    text-align: center;
  }
}


/* =========================
   SIGN IN PAGE (AUTH)
   ========================= */

/* Only on sign in page */
.signin-body{
  min-height: 100vh;
  background: url("/CITYHEALTH/assets/images/signinBG.png") center/cover no-repeat fixed;
}

/* overlay for readability */
.signin-body::before{
  content:"";
  position: fixed;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,.15),
    rgba(0,0,0,.45)
  );
  z-index: 0;
}

/* keep content above overlay */
.signin-body .top-line,
.signin-body .header,
.signin-body .auth-page,
.signin-body .site-footer{
  position: relative;
  z-index: 1;
}

/* layout */
.auth-page{
  min-height: calc(100vh - 140px); /* adjust if header/footer height changes */
  display: flex;                  /* switch to flex for better control */
  align-items: center;            /* vertical center */
  justify-content: center;        /* horizontal center */
  padding: 40px 16px;
  background: transparent;
}

.auth-card{
  width: min(520px, 92vw);
  margin: 0 auto;                 /* force horizontal centering */
  box-sizing: border-box;

  border-radius: 22px;
  padding: 26px 26px 20px;

  /* glass effect */
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.22);
  box-shadow: 0 18px 60px rgba(0,0,0,.30);
  backdrop-filter: blur(14px);
}


.auth-head{
  text-align: center;
  margin-bottom: 14px;
}




/* title uses your primary */
.auth-title{
  margin: 0;
  font-size: 32px;
  font-weight: 750;
  color: var(--primary);
}

/* subtitle uses your muted, but readable on bg */
.auth-subtitle{
  margin: 6px 0 0;
  color: rgba(255,255,255,.85);
  font-size: 14px;
}

.auth-form{
  margin-top: 16px;
}

.field{
  margin-bottom: 14px;
}

/* labels readable on bg */
.field label{
  display: block;
  font-weight: 650;
  margin-bottom: 6px;
  color: rgba(255,255,255,.90);
  font-size: 14px;
}

/* inputs glass style but keep your palette */
.field input{
  width: 100%;
  padding: 11px 12px;
  border-radius: 12px;
  outline: none;
  font-size: 14px;
  transition: .15s ease;

  background: rgba(255,255,255,.10);
  border: 1px solid rgba(255,255,255,.22);
  color: #fff;
}

.field input::placeholder{
  color: rgba(255,255,255,.60);
}

.field input:focus{
  border-color: rgba(255,255,255,.45);
  box-shadow: 0 0 0 4px rgba(255,255,255,.10);
}

.password-wrap{
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}

/* toggle button fits glass style */
.pw-toggle{
  border: 1px solid rgba(255,255,255,.22);
  background: rgba(255,255,255,.12);
  padding: 10px 12px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 650;
  color: rgba(255,255,255,.92);
  transition: .15s ease;
}

.pw-toggle:hover{
  background: rgba(255,255,255,.18);
}

.auth-row{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 6px 0 14px;
}

.check{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: rgba(255,255,255,.85);
}

.check input{
  width: 16px;
  height: 16px;
}

/* link keeps your primary */
.link{
  font-size: 14px;
  color: var(--primary);
  text-decoration: none;
  font-weight: 700;
}

.link:hover{
  text-decoration: underline;
}

/* main button keep your primary */
.auth-btn{
  width: 100%;
  border: none;
  background: var(--primary);
  color: #fff;
  padding: 12px 14px;
  border-radius: 14px;
  font-weight: 750;
  cursor: pointer;
  box-shadow: 0 14px 26px rgba(21,57,111,.22);
  transition: .15s ease;
}

.auth-btn:hover{
  transform: translateY(-1px);
  filter: brightness(1.06);
}

.auth-note{
  margin: 12px 0 0;
  font-size: 12.5px;
  color: rgba(255,255,255,.80);
  line-height: 1.5;
  text-align: center;
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce){
  .signin-body{ background-attachment: initial; }
}
/* =========================
   SIGNIN: FORCE MENU ON TOP
   ========================= */

.signin-body::before{
  z-index: 0;
}
.signin-body .header{
  position: sticky;
  top: 0;
  z-index: 5000;  /* HIGH */
}
@media (max-width: 780px){
  .signin-body .mobile-nav{
    z-index: 6000;  
    top: 86px;      
  }

  .signin-body .nav-backdrop{
    z-index: 5500;  
  }
}

/* ensure auth card doesn't overlap menu */
.signin-body .auth-page,
.signin-body .auth-card{
  position: relative;
  z-index: 1;
}

