/* Google Font Import */
@import url("https://fonts.googleapis.com/css2?family=EB+Garamond:ital,wght@0,400;0,500;0,600;1,400&display=swap");

/* Base Styles */
body {
  font-family: "EB Garamond", Georgia, serif !important;
  background: #f4f4f4;
  color: #333;
  line-height: 1.65;
  font-size: 16px !important;
}

a {
  color: #1a73e8;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* Site Title - Compact */
h1.site-title,
h1.site-title a,
.site-header .site-title,
.site-header .site-title a,
.site-branding .site-title,
.site-branding .site-title a {
  font-size: 26px !important;
  font-weight: 400 !important;
  letter-spacing: 3px !important;
  text-transform: uppercase !important;
  font-family: "EB Garamond", Georgia, serif !important;
}

.site-description {
  font-size: 14px !important;
  font-family: "EB Garamond", Georgia, serif !important;
}

/* Reduce header spacing */
.site-header {
  padding-top: 15px !important;
  padding-bottom: 5px !important;
  margin-bottom: 0 !important;
}
.site-branding {
  padding: 10px 0 5px !important;
  margin: 0 !important;
}
.site-navigation,
.main-navigation,
.primary-navigation,
#site-navigation {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Reduce space between page title and content */
.page .entry-header,
.entry-header {
  margin-bottom: 10px !important;
  padding-bottom: 0 !important;
}
.page .entry-title,
.entry-title {
  margin-bottom: 5px !important;
  font-family: "EB Garamond", Georgia, serif !important;
}
.page .entry-content,
.entry-content {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Content area */
#content,
.site-content {
  padding-top: 10px !important;
  margin-top: 0 !important;
}

/* General typography */
p, li, td, th, span, div {
  font-family: "EB Garamond", Georgia, serif !important;
}

/* Navigation font */
.main-navigation a,
.site-navigation a,
nav a {
  font-family: "EB Garamond", Georgia, serif !important;
}

/* Fix inline images (social icons) */
.entry-content p[align="center"] a,
.entry-content p[align="center"] img,
p[align="center"] a,
p[align="center"] img {
  display: inline !important;
  vertical-align: middle !important;
}
p[align="center"] a {
  margin: 0 10px !important;
}
/* Prevent theme from forcing block images */
.entry-content p img {
  display: inline !important;
}
.entry-content img {
  max-width: 100%;
  height: auto;
}

/* Consistent heading fonts - EB Garamond */
.entry-content h2,
.entry-content h3,
.entry-content h4 {
  font-family: "EB Garamond", Georgia, serif !important;
}

/* Dropdown menu styles */
.main-navigation li {
  position: relative;
}
.main-navigation ul ul {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  background: #fff;
  min-width: 210px;
  box-shadow: 0 3px 12px rgba(0,0,0,0.15);
  padding: 6px 0;
  border-top: 2px solid #333;
}
.main-navigation ul li:hover > ul {
  display: block;
}
.main-navigation ul ul li {
  display: block !important;
  width: 100%;
  float: none !important;
}
.main-navigation ul ul li a {
  display: block !important;
  padding: 8px 20px !important;
  font-size: 14px !important;
  color: #333 !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
  white-space: nowrap;
  font-family: "EB Garamond", Georgia, serif !important;
  font-weight: 400 !important;
}
.main-navigation ul ul li a:hover {
  background: #f0f0f0 !important;
  color: #000 !important;
}

/* Fix site title centering on wide screens */
.site-branding {
  margin: 0 auto !important;
}

/* Fix menu toggle icon - replace checkbox with hamburger */
.menu-toggle {
  background: none !important;
  border: none !important;
  padding: 8px !important;
  cursor: pointer;
}
.menu-toggle .genericon-menu {
  font-size: 0 !important;
  width: 24px;
  height: 20px;
  display: inline-block;
  position: relative;
}
.menu-toggle .genericon-menu::before {
  content: "" !important;
  display: block;
  width: 24px;
  height: 2px;
  background: #333;
  position: absolute;
  top: 0;
  box-shadow: 0 8px 0 #333, 0 16px 0 #333;
}

/* Research page H2 subheadings - match other pages style */
.page-id-23 .entry-content h2.wp-block-heading {
  font-size: 13px !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 2px !important;
  font-family: "EB Garamond", Georgia, serif !important;
  border-bottom: 1px solid #ddd;
  padding-bottom: 8px;
  margin-top: 30px;
}

/* Abstract toggle styling */
.entry-content details summary {
  cursor: pointer;
  font-family: "EB Garamond", Georgia, serif !important;
}

/* Fix mobile submenu icons (broken genericon showing as checkbox) */
.genericon.genericon-expand::before,
.genericon.genericon-collapse::before {
  font-family: inherit !important;
  font-size: 18px !important;
}
.genericon.genericon-expand::before {
  content: "\25BE" !important;
}
.genericon.genericon-collapse::before {
  content: "\25B4" !important;
}
.menu-item-has-children > a > .genericon-expand,
.menu-item-has-children > a > .genericon-collapse {
  font-family: inherit !important;
}