/* ===== Dr. Harjot Singh Gurudatta — site styles ===== */

:root {
  --navy: #0e2a47;
  --navy-deep: #091d33;
  --teal: #0f8b8d;
  --teal-dark: #0b6e70;
  --teal-soft: #e0f0f0;
  --amber: #f4a259;
  --ink: #22303f;
  --muted: #5b6b7b;
  --tint: #f2f7f7;
  --line: #dde6ec;
  --white: #ffffff;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(14, 42, 71, 0.10);
  --shadow-lg: 0 24px 60px rgba(14, 42, 71, 0.16);
  --font-head: "Playfair Display", Georgia, serif;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--white);
  line-height: 1.65;
  overflow-x: hidden;
}

.container { width: min(1120px, 92%); margin: 0 auto; }

h1, h2, h3 { font-family: var(--font-head); color: var(--navy); line-height: 1.15; }
h1 { font-size: clamp(2.1rem, 5vw, 3.5rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); margin-bottom: 0.5em; }
h3 { font-size: 1.15rem; margin-bottom: 0.4em; }

p { margin-bottom: 1em; }

.center { text-align: center; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--teal);
  margin-bottom: 1em;
}
.eyebrow::before {
  content: "";
  width: 2.2em;
  height: 2px;
  background: linear-gradient(90deg, var(--teal), var(--amber));
  border-radius: 2px;
}
.eyebrow.center { justify-content: center; display: flex; }

/* ===== Buttons ===== */
.btn {
  display: inline-block;
  padding: 0.85em 1.7em;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  font-size: 0.95rem;
  position: relative;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,0.25) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.6s ease;
}
.btn:hover::after { transform: translateX(120%); }
.btn:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.btn-primary { background: linear-gradient(135deg, var(--teal), var(--teal-dark)); color: var(--white); }
.btn-outline { border: 2px solid var(--teal); color: var(--teal-dark); }
.btn-outline:hover { background: var(--teal-soft); }
.btn-light { background: var(--white); color: var(--navy); }

/* ===== Header / nav ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow 0.3s ease;
}
.site-header.scrolled { box-shadow: 0 6px 24px rgba(14, 42, 71, 0.10); }
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
}
.brand {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--navy);
  text-decoration: none;
}
.brand span { color: var(--teal); }
.nav-links {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  list-style: none;
}
.nav-links a {
  text-decoration: none;
  color: var(--ink);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}
.nav-links a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--teal), var(--amber));
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
.nav-links a:not(.btn):hover::after { transform: scaleX(1); }
.nav-links a:hover { color: var(--teal-dark); }
.btn-nav { padding: 0.55em 1.2em; color: var(--white); }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; }
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--navy);
  margin: 5px 0;
  transition: 0.2s;
}

/* ===== Hero ===== */
.hero {
  background: linear-gradient(160deg, var(--tint) 55%, #e3f0f0 100%);
  padding: 4.5rem 0 4.5rem;
  position: relative;
  overflow: hidden;
}
.hero::before, .hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.5;
  animation: drift 14s ease-in-out infinite alternate;
  pointer-events: none;
}
.hero::before {
  width: 420px; height: 420px;
  background: radial-gradient(circle, rgba(15,139,141,0.35), transparent 70%);
  top: -140px; right: -100px;
}
.hero::after {
  width: 340px; height: 340px;
  background: radial-gradient(circle, rgba(244,162,89,0.30), transparent 70%);
  bottom: -120px; left: -80px;
  animation-delay: -7s;
}
@keyframes drift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(30px, 24px) scale(1.08); }
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 3rem;
  align-items: center;
  position: relative;
  z-index: 1;
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(120deg, var(--teal) 0%, var(--teal-dark) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--teal);
}
.lede { font-size: 1.1rem; color: var(--muted); max-width: 34em; }
.hero-actions { display: flex; gap: 0.9rem; flex-wrap: wrap; margin: 1.6rem 0; }
.hero-stats {
  display: flex;
  gap: 2.5rem;
  list-style: none;
  margin-top: 1.8rem;
  padding-top: 1.4rem;
  border-top: 1px solid var(--line);
}
.hero-stats li { display: flex; flex-direction: column; }
.hero-stats strong { color: var(--navy); font-size: 1rem; }
.hero-stats span { color: var(--muted); font-size: 0.9rem; }

/* staggered entrance animation on page load */
.hero-text > *, .hero-photo {
  animation: rise 0.8s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.hero-text > *:nth-child(1) { animation-delay: 0.05s; }
.hero-text > *:nth-child(2) { animation-delay: 0.15s; }
.hero-text > *:nth-child(3) { animation-delay: 0.25s; }
.hero-text > *:nth-child(4) { animation-delay: 0.35s; }
.hero-text > *:nth-child(5) { animation-delay: 0.45s; }
.hero-photo { animation-delay: 0.3s; }
@keyframes rise {
  from { opacity: 0; transform: translateY(26px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero-photo, .about-photo { position: relative; }
.hero-photo::before {
  content: "";
  position: absolute;
  inset: 14px -14px -14px 14px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--teal-soft), rgba(244,162,89,0.25));
  z-index: 0;
}
.hero-photo img, .about-photo img {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  display: block;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  position: relative;
  z-index: 1;
}
.photo-fallback { display: none; }
.photo-missing img { display: none; }
.photo-missing .photo-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  background: linear-gradient(160deg, var(--navy) 0%, var(--teal-dark) 100%);
  color: var(--white);
  font-family: var(--font-head);
  font-size: 1.4rem;
  padding: 1rem;
  position: relative;
  z-index: 1;
}

/* ===== Sections ===== */
.section { padding: 5rem 0; }
.section-tint { background: var(--tint); }
.section-dark { background: linear-gradient(155deg, var(--navy) 0%, #123a5e 100%); }
.section-dark h2, .section-dark strong { color: var(--white); }
.section-dark p, .section-dark span { color: #c7d5e2; }

/* scroll-reveal (class added by main.js; without JS everything stays visible) */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ===== About ===== */
.about-grid {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 3rem;
  align-items: center;
}
.about-photo::before {
  content: "";
  position: absolute;
  inset: -14px 14px 14px -14px;
  border-radius: var(--radius);
  border: 2px solid var(--teal-soft);
  z-index: 0;
}
.quals { font-weight: 600; color: var(--teal-dark); }
.checklist { list-style: none; margin-top: 0.6rem; }
.checklist li { padding-left: 1.7em; position: relative; margin-bottom: 0.5em; }
.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--teal);
  font-weight: 700;
}

/* ===== Cards ===== */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
  margin-top: 2.2rem;
}
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.9rem 1.7rem;
  position: relative;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.card::before {
  content: "";
  position: absolute;
  top: 0; left: 1.7rem; right: 1.7rem;
  height: 3px;
  border-radius: 0 0 4px 4px;
  background: linear-gradient(90deg, var(--teal), var(--amber));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.card:hover::before { transform: scaleX(1); }
.card p { color: var(--muted); font-size: 0.95rem; margin-bottom: 0; }
.card-icon {
  font-size: 1.7rem;
  margin-bottom: 0.8rem;
  width: 56px; height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: var(--teal-soft);
  transition: transform 0.3s ease;
}
.card:hover .card-icon { transform: scale(1.1) rotate(-6deg); }
.card-link p { margin-bottom: 1em; }
.read-more { color: var(--teal-dark); font-weight: 600; text-decoration: none; }
.read-more:hover { text-decoration: underline; }

/* ===== Book ===== */
.book-grid {
  display: grid;
  grid-template-columns: 0.55fr 1.45fr;
  gap: 3rem;
  align-items: center;
}
.book-cover { position: relative; max-width: 300px; }
.book-cover img {
  width: 100%;
  border-radius: 8px;
  box-shadow: var(--shadow-lg);
  display: block;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.book-cover:hover img { transform: rotate(-2deg) scale(1.03); }
.book-cover .photo-fallback {
  aspect-ratio: 2 / 3;
  border-radius: 8px;
  font-size: 1.8rem;
  line-height: 1.3;
}
.book-cover.photo-missing .photo-fallback { display: flex; }
.book-cover.photo-missing img { display: none; }

/* ===== Contact ===== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}
.contact-list { list-style: none; margin: 1.4rem 0 1.8rem; }
.contact-list li {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 1rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.contact-list a { color: var(--white); text-decoration: none; font-weight: 600; }
.contact-list a:hover { color: var(--amber); }
.map-box iframe {
  width: 100%;
  height: 100%;
  min-height: 380px;
  border: 0;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

/* ===== Footer ===== */
.site-footer {
  background: var(--navy-deep);
  color: #9fb2c4;
  text-align: center;
  padding: 1.8rem 0;
  font-size: 0.9rem;
}
.site-footer p { margin: 0; }
.footer-note { font-size: 0.8rem; opacity: 0.7; }

/* ===== Blog article pages ===== */
.article-page { padding: 3.5rem 0; }
.article-page .container { max-width: 760px; }
.article-page h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin-bottom: 0.4em; }
.article-meta { color: var(--muted); font-size: 0.9rem; margin-bottom: 2rem; }
.article-page h2 { font-size: 1.4rem; margin-top: 1.6em; }
.back-link {
  display: inline-block;
  margin-bottom: 1.5rem;
  color: var(--teal-dark);
  font-weight: 600;
  text-decoration: none;
}
.back-link:hover { text-decoration: underline; }

/* ===== Reduced motion ===== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ===== Mobile ===== */
@media (max-width: 860px) {
  .hero-grid, .about-grid, .contact-grid, .book-grid { grid-template-columns: 1fr; }
  .book-cover { max-width: 220px; }
  .cards { grid-template-columns: 1fr 1fr; }
  .hero-photo { order: -1; max-width: 320px; }
  .about-photo { max-width: 320px; }

  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    align-items: flex-start;
    padding: 1.2rem 4%;
    gap: 1.1rem;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
}

@media (max-width: 560px) {
  .cards { grid-template-columns: 1fr; }
  .hero-stats { gap: 1.4rem; flex-wrap: wrap; }
}
