/* ================================================================
   GLOBAL STYLES — Dr. Aishath Ali Naaz Portfolio
   Shared across all pages
   ================================================================ */

/* RESET */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* VARIABLES */
:root {
  --black: #0a0a0a;
  --off-white: #d1cec5;
  --white: #ffffff;
  --mid: #888880;
  --light: #ccc8bf;
  --accent: #b8a070;
  --accent-dark: #8a6a30;
}

/* BASE */
html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Jost', sans-serif;
  background: var(--black);
  color: var(--off-white);
  overflow-x: hidden;
}





/* SKIP-TO-CONTENT LINK */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  background: var(--accent);
  color: var(--black);
  padding: 8px 16px;
  z-index: 10000;
  font-size: .75rem;
  font-weight: 400;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 0 0 4px 4px;
}

.skip-link:focus {
  top: 0;
}

/* ---- NAVIGATION ---- */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 28px 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  mix-blend-mode: difference;
}

.nav-logo {
  font-family: 'EB Garamond', serif;
  font-size: .95rem;
  font-weight: 400;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--white);
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
}

.nav-links a {
  font-size: .72rem;
  font-weight: 300;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--white);
  text-decoration: none;
  opacity: .6;
  transition: opacity .2s;
}

.nav-links a:hover,
.nav-links a.active {
  opacity: 1;
}

/* HAMBURGER TOGGLE */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  z-index: 101;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 1.5px;
  background: var(--white);
  transition: transform .3s ease, opacity .3s ease;
  transform-origin: center;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: rotate(45deg) translate(4px, 5px);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: rotate(-45deg) translate(4px, -5px);
}

/* ---- UNIFIED PAGE HEADER UTILITY ---- */
/*
 * Shared base for all dark page headers:
 * #services-header, #conf-header, #community-header,
 * #contact-header, #research-header
 * Apply class="page-header" to each section element.
 */
.page-header {
  min-height: 60vh;
  background: var(--black);
  padding: 160px 12vw 80px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  position: relative;
  overflow: hidden;
}

.page-header::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: .035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-size: 200px;
}

@media (max-width: 900px) {
  .page-header {
    padding: 120px 6vw 60px;
  }
}

/* ---- SHARED PAGE HEADER ---- */
.page-label,
.sec-label {
  font-size: .62rem;
  letter-spacing: .35em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}

.page-h1 {
  font-family: 'EB Garamond', serif;
  font-size: clamp(3.5rem, 7vw, 8rem);
  font-weight: 400;
  line-height: .92;
  color: var(--white);
}

.page-h1 em {
  font-style: italic;
  color: var(--accent);
}

.header-line {
  width: 100%;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, .08), transparent);
  margin-top: 60px;
}

/* ---- SHARED PHILOSOPHY COMPONENTS ---- */
.ph-label {
  font-size: .62rem;
  letter-spacing: .35em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 28px;
}

.ph-quote {
  font-family: 'EB Garamond', serif;
  font-size: clamp(1.8rem, 3.2vw, 2.8rem);
  font-weight: 400;
  line-height: 1.35;
  max-width: 900px;
}

.ph-quote em {
  font-style: italic;
}

.ph-attr {
  margin-top: 32px;
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
}

/* ---- SHARED BUTTONS ---- */
.btn-primary {
  display: inline-block;
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  padding: 16px 36px;
  background: var(--black);
  color: var(--white);
  text-decoration: none;
  transition: background .3s;
  white-space: nowrap;
}

.btn-primary:hover {
  background: var(--accent-dark);
}

.btn-outline {
  display: inline-block;
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  padding: 16px 36px;
  border: 1px solid rgba(0, 0, 0, .25);
  color: #333;
  text-decoration: none;
  transition: all .3s;
}

.btn-outline:hover {
  border-color: var(--accent-dark);
  color: var(--accent-dark);
}

/* ---- FOOTER ---- */
/* ---- FOOTER ---- */
footer {
  background: #050505;
  color: rgba(223, 223, 223, 0.651);
  padding: 60px 12vw;
  border-top: 1px solid rgba(255, 255, 255, .05);
  text-align: center;
  font-size: .65rem;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.footer-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-line span {
  opacity: .5;
}

@media (max-width: 600px) {
  footer {
    padding: 40px 6vw;
  }

  .footer-line {
    gap: 8px;
    line-height: 1.8;
  }
}

/* ---- ANIMATIONS ---- */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  opacity: 0;
}

.fade-in.visible {
  animation: fadeUp .8s cubic-bezier(.22, 1, .36, 1) both;
}

/* ================================================================
   RESPONSIVE — GLOBAL
   ================================================================ */
@media (max-width: 900px) {
  nav {
    padding: 20px 24px;
  }

  /* When menu is open, disable blend mode so overlay renders correctly */
  nav.menu-open {
    mix-blend-mode: normal;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    inset: 0;
    background: rgba(10, 10, 10, .97);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 32px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s ease;
  }

  .nav-links.open {
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links a {
    font-size: .9rem;
    letter-spacing: .2em;
    opacity: .7;
  }

  .nav-links a:hover,
  .nav-links a.active {
    opacity: 1;
  }
}

/* ---- SCREEN-READER ONLY ---- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---- CONTACT INLINE LINKS ---- */
.cd-item a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid rgba(0, 0, 0, .15);
  transition: border-color .2s;
}

.cd-item a:hover {
  border-color: var(--accent-dark);
  color: var(--accent-dark);
}

/* ================================================================
   REDUCED MOTION — Accessibility
   ================================================================ */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .fade-in {
    opacity: 1;
  }
}