:root {
  --bg: #0f172a;
  --panel: rgba(255, 255, 255, 0.12);
  --panel-strong: rgba(255, 255, 255, 0.18);
  --text: #f8fafc;
  --muted: #dbeafe;
  --accent: #60a5fa;
  --border: rgba(255, 255, 255, 0.18);
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
  --radius: 22px;
  --max: 1200px;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: Arial, Helvetica, sans-serif;
  background:
    radial-gradient(circle at top, rgba(96,165,250,0.20), transparent 30%),
    linear-gradient(180deg, #0b1220 0%, #111827 55%, #0f172a 100%);
  color: var(--text);
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  color: var(--accent);
}

.page {
  width: 100%;
  overflow-x: hidden;
}

.wrap {
  width: min(100%, var(--max));
  margin: 0 auto;
  padding: 0 20px;
}

/* Shared top nav for index, about, contact */

.top-nav,
.simple-header {
  padding: 14px 0;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.brand {
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

nav {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--muted);
}

/* Base nav link look */
.nav-link {
  position: relative;
  padding-bottom: 3px;
}

/* Active page highlighting (body class + link class) */
.home .nav-home,
.about .nav-about,
.contact .nav-contact {
  color: var(--accent);
  font-weight: 700;
}

/* Optional underline / marker for active link */
.home .nav-home::after,
.about .nav-about::after,
.contact .nav-contact::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: var(--accent);
}

/* Hero and carousel */

.hero {
  position: relative;
  width: 100%;
  min-height: 72vh;
  overflow: hidden;
  background: #111827;
}

.carousel {
  position: relative;
  width: 100%;
  height: 72vh;
  min-height: 520px;
}

.slides {
  position: absolute;
  inset: 0;
}

.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 700ms ease;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  transform: scale(1.03);
}

.slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.20),
    rgba(0, 0, 0, 0.35) 55%,
    rgba(0, 0, 0, 0.60)
  );
}

/* Replace these with your real images */
.slide.s1 { background-image: url("https://picsum.photos/id/1018/1600/900"); }
.slide.s2 { background-image: url("https://picsum.photos/id/1025/1600/900"); }
.slide.s3 { background-image: url("https://picsum.photos/id/1043/1600/900"); }
.slide.s4 { background-image: url("https://picsum.photos/id/1067/1600/900"); }

.hero-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  padding: 30px 20px 70px;
}

.overlay-box {
  position: relative;
  width: min(900px, 92vw);
  padding: 28px 34px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
  text-align: center;
  overflow: hidden;
}

.overlay-box::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(255,255,255,0.10), rgba(255,255,255,0.02)),
    url("https://picsum.photos/id/1015/1200/700") center/cover no-repeat;
  opacity: 0.18;
  filter: blur(1px);
  transform: scale(1.05);
  z-index: 0;
}

.overlay-box > * {
  position: relative;
  z-index: 1;
}

.overlay-box h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 4.5rem);
  letter-spacing: 0.02em;
  text-shadow: 0 2px 12px rgba(0,0,0,0.45);
}

.overlay-box p {
  margin: 14px 0 0;
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--muted);
}

/* Carousel controls */

.controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 22px;
  z-index: 4;
  display: flex;
  justify-content: center;
  gap: 12px;
}

.controls button {
  width: 13px;
  height: 13px;
  border-radius: 999px;
  border: 2px solid rgba(255,255,255,0.9);
  background: transparent;
  cursor: pointer;
  opacity: 0.8;
  padding: 0;
}

.controls button.active {
  background: white;
  opacity: 1;
}

/* Intro */

.intro {
  padding: 34px 0 12px;
}

.intro-box {
  margin-top: -22px;
  border-radius: var(--radius);
  padding: 18px 22px;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid var(--border);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  text-align: center;
  box-shadow: var(--shadow);
}

.intro-box h2 {
  margin: 0;
  font-size: clamp(1.2rem, 2.5vw, 1.7rem);
  font-weight: 600;
  color: #eff6ff;
}

/* Menus */

.menus {
  padding: 30px 0 40px;
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.menu-card {
  min-height: 260px;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.menu-card h3 {
  margin: 0 0 12px;
  font-size: 1.4rem;
}

.menu-card p {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.55;
}

.link-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}

.link-list a {
  display: block;
  padding: 11px 13px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255,255,255,0.10);
  transition: transform 160ms ease, background 160ms ease;
}

.link-list a:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.14);
}

/* Shared hero for inner pages (about/contact) */

.hero-inner {
  min-height: auto;
  background: transparent;
  padding: 56px 0 24px;
}

.hero-inner .hero-box {
  margin: 0 auto;
}

/* Sections / cards */

.section {
  padding: 22px 0 46px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.about-grid .card,
.contact-grid .card {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.card h2 {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 1.35rem;
}

.card p, .card li {
  color: var(--muted);
  line-height: 1.65;
}

.card ul {
  margin: 0;
  padding-left: 18px;
}

/* Contact form */

label {
  display: block;
  margin: 12px 0 8px;
  color: #eff6ff;
  font-size: 0.95rem;
}

input, textarea {
  width: 100%;
  padding: 13px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.16);
  background: rgba(15, 23, 42, 0.55);
  color: var(--text);
  outline: none;
  font: inherit;
}

textarea {
  min-height: 150px;
  resize: vertical;
}

button {
  margin-top: 14px;
  padding: 13px 18px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
  color: white;
  font-weight: 700;
  cursor: pointer;
}

button:hover {
  filter: brightness(1.05);
}

.info-list {
  display: grid;
  gap: 14px;
}

.info-item {
  padding: 14px;
  border-radius: 16px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.10);
  color: var(--muted);
  line-height: 1.6;
}

/* Footer */

footer {
  padding: 18px 0 30px;
  border-top: 1px solid rgba(255,255,255,0.10);
  background: rgba(3, 7, 18, 0.45);
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 20px;
  align-items: center;
  justify-content: space-between;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 18px;
  color: var(--muted);
}

copyright {
  color: rgba(255,255,255,0.75);
  font-size: 0.95rem;
}

/* Responsive */

@media (max-width: 900px) {
  .menu-grid {
    grid-template-columns: 1fr;
  }
  .carousel {
    height: 64vh;
    min-height: 460px;
  }
}

@media (max-width: 800px) {
  .grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .overlay-box {
    padding: 22px 20px;
  }
  .intro-box {
    margin-top: -12px;
  }
  .footer-row {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ===========================================================
   About page additions — append to style.css
   Adds one full-width "history & purpose" block above the two
   existing cards (What You'll Find Here / Stay Connected).
   =========================================================== */

/* Full-width card: spans both columns of the 2-col .about-grid.
   On screens <= 800px the grid already collapses to one column,
   so this still works (it simply spans the single track). */
.about-grid .card-full {
  grid-column: 1 / -1;
}

/* Comfortable reading measure + rhythm for the long narrative. */
.card-full p {
  max-width: 72ch;
  margin: 0 0 16px;
}

.card-full p:last-child {
  margin-bottom: 0;
}

/* Lead / opening paragraph stands out. */
.card-full .lead {
  color: var(--text);
  font-size: 1.08rem;
  font-weight: 600;
}

/* Keep italicized publication titles (BITS OF DEMENTS) legible
   against the muted body text. */
.card-full em {
  color: var(--text);
  font-style: italic;
}
