:root {
  --primary: #0a2351;
  --accent: #00a8e8;
  --text: #333;
  --light-bg: #ffffff;
  --section-bg: #f4f7f9;
  --nav-height: 80px;
}

/* Base Styles */
* { 
  margin: 0; 
  padding: 0; 
  box-sizing: border-box; 
}

html {
  scroll-behavior: smooth;
}

body { 
  font-family: 'Inter', sans-serif; 
  color: var(--text); 
  line-height: 1.6; 
  background: var(--section-bg);
  overflow-x: hidden;
}

/* Navigation */
.glass-nav {
  position: fixed;
  top: 0;
  width: 100%;
  height: var(--nav-height);
  padding: 0 50px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(10, 35, 81, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 9999; 
  color: white;
  transition: all 0.3s ease;
}

.logo { font-weight: 700; font-size: 1.2rem; text-transform: uppercase; letter-spacing: 1px; }
.logo span { color: var(--accent); }
.nav-links { display: flex; list-style: none; }
.nav-links li a { 
  color: white; 
  text-decoration: none; 
  margin-left: 30px; 
  font-weight: 600; 
  transition: 0.3s; 
}
.nav-links li a:hover { color: var(--accent); }

/* Anchor Offset Logic - CRITICAL FOR CLICKABLE LINKS */
header, section {
  scroll-margin-top: var(--nav-height);
  position: relative; /* Ensures sections are indexed correctly by the browser */
}

/* Hero Section */
.hero {
  height: 100vh;
  background: linear-gradient(rgba(10, 35, 81, 0.7), rgba(10, 35, 81, 0.7)), 
              url('https://images.unsplash.com/photo-1576089172869-4f5f6f315620?auto=format&fit=crop&q=80') center/cover;
  display: flex; 
  align-items: center; 
  justify-content: center;
  text-align: center; 
  color: white; 
  padding: 0 20px;
}

.hero h1 { font-size: 3.2rem; margin-bottom: 20px; max-width: 950px; line-height: 1.2; }
.hero p { font-size: 1.25rem; margin-bottom: 40px; max-width: 750px; opacity: 0.9; }

/* Buttons */
.btn { padding: 14px 35px; border-radius: 5px; text-decoration: none; font-weight: 700; transition: 0.3s; display: inline-block; cursor: pointer; border: none; }
.primary { background: var(--accent); color: white; }
.secondary { border: 2px solid white; color: white; margin-left: 15px; }
.btn:hover { transform: translateY(-3px); box-shadow: 0 5px 15px rgba(0,0,0,0.2); }

/* Stats Strip */
.stats-strip {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  padding: 50px 10%;
  background: var(--light-bg);
  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
  position: relative;
  z-index: 10;
}
.stat-item { text-align: center; padding: 10px; }
.stat-item h3 { color: var(--accent); font-size: 2.2rem; margin-bottom: 5px; }
.stat-item p { font-weight: 600; color: var(--primary); }

/* Section Titles */
.section-title {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--primary);
  text-align: center;
  margin-bottom: 50px;
  position: relative;
}
.section-title::after {
  content: "";
  display: block;
  width: 70px;
  height: 4px;
  background: var(--accent);
  margin: 15px auto 0;
  border-radius: 2px;
}

/* Content Sections */
.about1, .quality, .services, .therapeutic, .contact1 { 
  padding: 100px 10%; 
}

.about1 { background: var(--light-bg); text-align: center; }
.about1 p { margin-bottom: 25px; font-size: 1.15rem; color: #444; max-width: 800px; margin-left: auto; margin-right: auto; }

/* Grid Layouts */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 35px;
}

/* Flip Cards */
.glass-card { perspective: 1000px; cursor: pointer; }
.card-inner {
  position: relative;
  width: 100%;
  height: 300px; 
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}
.glass-card.active .card-inner { transform: rotateY(180deg); }

.card-front, .card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 15px;
  padding: 30px;
  background: var(--light-bg);
  box-shadow: 0 10px 25px rgba(0,0,0,0.06);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.card-back { transform: rotateY(180deg); text-align: left; overflow-y: auto; background: #fdfdfd; border: 1px solid #eee; }
.card-back h3 { font-size: 1.3rem; margin-bottom: 10px; color: var(--primary); border-bottom: 1px solid #eee; padding-bottom: 5px; }
.card-back ul { list-style: none; padding: 0; }
.card-back li { margin-bottom: 8px; position: relative; padding-left: 20px; font-size: 0.95rem; }
.card-back li::before { content: "→"; position: absolute; left: 0; color: var(--accent); font-weight: bold; }

/* Quality Section Styling */
.sop-item {
  transition: 0.3s;
  padding: 25px;
  background: #f4f7f9;
  border-left: 4px solid var(--accent);
  border-radius: 5px;
  margin-bottom: 20px;
}
.sop-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}

/* Contact */
.contact { background: var(--primary); color: white; text-align: center; }
.contact h2 { color: white; }
.contact p { margin-bottom: 40px; opacity: 0.9; }

/* Footer */
.site-footer {
  background-color: #001533;
  color: #fff;
  text-align: center;
  padding: 40px 0;
}
.footer-links {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 40px;
  margin-bottom: 25px;
}
.footer-links a { color: #4da6ff; text-decoration: none; transition: 0.3s; font-weight: 500; }
.footer-links a:hover { color: white; }

/* Responsive Adjustments */
@media (max-width: 768px) {
  .hero h1 { font-size: 2.2rem; }
  .glass-nav { padding: 0 20px; }
  .nav-links { display: none; } 
  .hero, .about1, .services, .quality, .therapeutic, .contact1 { padding: 60px 5%; }
}

/* Custom Scrollbar for cards */
.card-back::-webkit-scrollbar { width: 5px; }
.card-back::-webkit-scrollbar-track { background: #f1f1f1; }
.card-back::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 10px; }