@import url("https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@300;400;600;700&display=swap");

:root {
  --background: #ffffff;
  --foreground: #111827;
  --muted: #f3f4f6;
  --muted-foreground: #6b7280;
  --primary: #111827; /* deep indigo / slate */
  --primary-foreground: #f9fafb;
  --accent: #0891b2; /* teal */
  --accent-soft: rgba(8, 145, 178, 0.08);
  --border: #e5e7eb;
  --card: #faf9f7;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Source Sans Pro", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--background);
  color: var(--foreground);
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

header.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background-color: var(--primary);
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: flex-start; /* logo hugs left like hero text */
  height: 80px;
}

.logo {
  font-size: 1.1rem;
  letter-spacing: 0.5rem;
  color: var(--primary-foreground);
  font-weight: 600;
  text-transform: uppercase;
}

/* Hamburger menu button */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  margin-left: auto;
  color: var(--primary-foreground);
  flex-direction: column;
  gap: 4px;
  z-index: 100;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--primary-foreground);
  transition: all 0.3s ease;
}

.menu-toggle.menu-toggle--open span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.menu-toggle.menu-toggle--open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.menu-toggle--open span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

nav.main-nav {
  display: flex;
  gap: 1.5rem;
  margin-left: auto; /* push nav to the right side */
}

.nav-link {
  color: rgba(249, 250, 251, 0.8);
  font-size: 0.95rem;
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
}

.nav-link:hover {
  color: #ffffff;
}

.nav-link.active {
  color: #ffffff;
  border-color: var(--accent);
}

main {
  padding-top: 80px; /* match header height */
}

/* Hero */
.hero {
  position: relative;
  color: var(--primary-foreground);
  min-height: 55vh;
  display: block;            /* let inner container control width/position */
  background-size: cover;
  background-position: center;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(17, 24, 39, 0.4), rgba(17, 24, 39, 0.2));
}

/* Home hero slider: no overlay */
#home-hero::before {
  background: transparent;
}

.hero-inner {
  position: relative;
  z-index: 1;
  min-height: 55vh;
  display: flex;
  align-items: center;      /* vertical centering */
  justify-content: flex-start;
  max-width: 1120px;
  margin: 0 auto;
  padding: 3rem 1.5rem;     /* same horizontal padding as .container */
}

.hero-title {
  margin: 0 0 0.75rem;
  font-size: 1.9rem;
  font-weight: 700;
}

.hero-subtitle {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: rgba(249, 250, 251, 0.9);
}

/* Sections */
.section {
  padding: 3rem 0;
}

/* Home profile layout */
.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 260px) minmax(0, 1fr);
  gap: 2.5rem;
}

.profile-sidebar img {
  width: 190px;
  height: 190px;
  border-radius: 999px;
  object-fit: cover;
  margin-bottom: 1.5rem;
}

.profile-name {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.profile-role {
  font-size: 0.95rem;
  color: var(--muted-foreground);
  margin-bottom: 1.5rem;
}

.profile-sections-title {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.profile-sections-nav {
  border-left: 1px solid var(--border);
  padding-left: 0.75rem;
}

.profile-section-link {
  display: block;
  padding: 0.4rem 0.5rem;
  font-size: 0.9rem;
  color: var(--muted-foreground);
  border-radius: 0.25rem;
}

.profile-section-link--active {
  color: var(--accent);
  background-color: var(--accent-soft);
  font-weight: 600;
}

.profile-main h2 {
  font-size: 1.7rem;
  margin-bottom: 0.25rem;
}

.profile-main .accent-line {
  width: 70px;
  height: 4px;
  background-color: var(--accent);
  margin-bottom: 1.75rem;
}

.profile-contact {
  margin-bottom: 2rem;
  font-size: 0.9rem;
  color: var(--muted-foreground);
}

.profile-contact a {
  color: var(--accent);
}

.profile-block {
  margin-bottom: 2rem;
}

.profile-block h3 {
  font-size: 1.2rem;
  margin: 0 0 0.5rem;
}

.profile-block p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--muted-foreground);
}

/* Toggleable profile sections */
.profile-section-content {
  display: none;
}

.profile-section-content.profile-section-content--active {
  display: block;
}

.edu-entry {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1rem;
}

.edu-label {
  min-width: 48px;
  font-size: 0.85rem;
  color: var(--muted-foreground);
}

.edu-content {
  border-left: 2px solid var(--accent);
  padding-left: 0.75rem;
}

.edu-title {
  font-weight: 600;
  font-size: 0.95rem;
}

.edu-subtitle {
  font-size: 0.85rem;
  color: var(--muted-foreground);
}

/* Cards */
.card-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.card {
  background-color: var(--card);
  border-radius: 0.75rem;
  padding: 1.5rem;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .card {
    flex-direction: row;
    padding: 2rem;
  }
}

.card-image {
  flex-shrink: 0;
}

.card-image img {
  width: 100%;
  max-width: 192px;
  height: 144px;
  object-fit: cover;
  border-radius: 0.5rem;
  background-color: var(--muted);
}

@media (max-width: 767px) {
  .card-image img {
    max-width: 100%;
    height: 200px;
  }
}

.card-content {
  flex: 1;
  min-width: 0;
}

.card h3 {
  margin-top: 0;
  margin-bottom: 1rem;
  font-size: 1.25rem;
  line-height: 1.3;
}

@media (min-width: 768px) {
  .card h3 {
    font-size: 1.5rem;
  }
}

.card-meta {
  font-size: 0.85rem;
  color: var(--muted-foreground);
  margin-bottom: 0.75rem;
}

.card p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--muted-foreground);
}

.card a.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.75rem;
  font-size: 0.9rem;
  color: var(--accent);
  font-weight: 600;
}

/* Gallery grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)); /* 3 items per row on desktop */
  gap: 1.25rem;
}

.gallery-item {
  border-radius: 0.75rem;
  overflow: hidden;
  /* simpler look: no big card effect */
  box-shadow: none;
}

.gallery-item img {
  width: 100%;        /* use full card width */
  height: auto;       /* natural height */
  max-height: 280px;  /* keep rows reasonably even */
  object-fit: contain;/* show full image without cropping */
}

.gallery-item-caption {
  padding: 0.75rem 1rem;
  font-size: 0.9rem;
  color: var(--muted-foreground);
}

/* Media cards */
.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.media-card {
  background-color: var(--card);
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
}

.media-card img {
  height: 180px;
  object-fit: cover;
}

.media-card-body {
  padding: 1rem 1.25rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

.media-source {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted-foreground);
}

.media-title {
  font-size: 0.95rem;
  font-weight: 600;
}

.media-link {
  margin-top: auto;
  font-size: 0.9rem;
  color: var(--accent);
  font-weight: 600;
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.2fr);
  gap: 2.5rem;
  align-items: flex-start;
}

.contact-block h3 {
  margin-top: 0;
  margin-bottom: 0.75rem;
}

.contact-block p {
  margin: 0.25rem 0;
  font-size: 0.95rem;
  color: var(--muted-foreground);
}

.contact-block a {
  color: var(--accent);
}

footer.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0 2rem;
  margin-top: 2rem;
  font-size: 0.85rem;
  color: var(--muted-foreground);
}

/* Responsive */
@media (max-width: 768px) {
  .site-header-inner {
    height: 64px;
    padding: 0 1rem;
  }

  .logo {
    font-size: 0.9rem;
    letter-spacing: 0.25rem;
  }

  .menu-toggle {
    display: flex;
  }

  nav.main-nav {
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    background-color: var(--primary);
    flex-direction: column;
    padding: 0;
    gap: 0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    margin-left: 0;
    z-index: 99;
  }

  nav.main-nav.nav-open {
    max-height: 500px;
    padding: 0.5rem 0;
  }

  .nav-link {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid rgba(249, 250, 251, 0.1);
    width: 100%;
    display: block;
  }

  .nav-link:last-child {
    border-bottom: none;
  }

  main {
    padding-top: 64px;
  }

  .hero {
    min-height: 35vh;
  }

  .hero-title {
    font-size: 1.5rem;
    line-height: 1.2;
  }

  .hero-inner {
    min-height: 35vh;
    padding: 1.5rem 1rem;
  }

  .container {
    padding: 0 1rem;
  }

  .section {
    padding: 1.5rem 0;
  }

  .section-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
  }

  .profile-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
  }

  .profile-sidebar {
    text-align: center;
  }

  .profile-sidebar img {
    margin-left: auto;
    margin-right: auto;
    max-width: 200px;
  }

  .profile-section-link {
    font-size: 0.9rem;
    padding: 0.75rem 0;
  }

  .card {
    flex-direction: column;
    padding: 1.25rem;
    gap: 1rem;
  }

  .card-image {
    width: 100%;
  }

  .card-image img {
    max-width: 100%;
    height: auto;
    max-height: 200px;
    object-fit: cover;
  }

  .card-content {
    width: 100%;
  }

  .card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
  }

  .card-meta {
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
  }

  .card p {
    font-size: 0.9rem;
  }

  .contact-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
  }

  .contact-block h3 {
    font-size: 1.1rem;
  }

  .gallery-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
  }

  .gallery-item img {
    max-height: 250px;
  }

  .media-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
  }

  .media-card img {
    height: 160px;
  }

  .media-title {
    font-size: 0.9rem;
  }

  footer.site-footer {
    padding: 1rem 0;
    font-size: 0.8rem;
    text-align: center;
  }
}

/* Small laptops / tablets */
@media (min-width: 769px) and (max-width: 1024px) {
  .container {
    padding: 0 1.25rem;
    max-width: 960px;
  }

  .hero {
    min-height: 50vh;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-inner {
    padding: 2.5rem 1.25rem;
  }

  .section {
    padding: 2.5rem 0;
  }

  .card {
    padding: 1.75rem;
    gap: 1.25rem;
  }

  .card-image img {
    max-width: 180px;
    height: 140px;
    object-fit: cover;
  }

  .card h3 {
    font-size: 1.2rem;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
  }

  .gallery-item img {
    max-height: 300px;
  }

  .media-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
  }

  .profile-grid {
    gap: 2rem;
  }

  .contact-grid {
    gap: 2rem;
  }
}
