/* =============================================================================
  Custom CSS for Academic Website (academicpages-inspired)
  ============================================================================= */

/*-- scss:rules --*/

/* Typography - Serif fonts for academic feel */
body {
  font-family: 'Palatino Linotype', 'Book Antiqua', Palatino, 'Times New Roman', serif;
  font-size: 16px;
  line-height: 1.7;
  color: #333;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-weight: 600;
  margin-top: 1.5em;
  margin-bottom: 0.75em;
  color: #1a1a1a;
}

h1 {
  font-size: 2.2em;
  border-bottom: 2px solid #e9ecef;
  padding-bottom: 0.3em;
}

h2 {
  font-size: 1.8em;
  border-bottom: 1px solid #e9ecef;
  padding-bottom: 0.25em;
}

h3 {
  font-size: 1.4em;
}

/* Links */
a {
  color: #2c5282;
  text-decoration: none;
}

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

/* Navigation bar adjustments */
.navbar {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  border-bottom: 1px solid #dee2e6;
}

.navbar-brand {
  font-weight: 600;
  font-size: 1.2em;
}

/* Footer styling */
footer {
  margin-top: 4em;
  padding-top: 2em;
  border-top: 1px solid #dee2e6;
  font-size: 0.9em;
  color: #6c757d;
}

/* Content spacing */
.page-layout-full {
  max-width: 900px;
  margin: 0 auto;
  padding: 2em 1em;
}

/* Publication lists - optimized spacing */
#refs-journal {
  margin-top: 2em;
}

#refs-journal div {
  margin-bottom: 1.5em;
  padding-left: 0;
  text-indent: 0;
}

#refs-journal .csl-entry {
  margin-bottom: 1.2em;
  line-height: 1.6;
}

/* Section styling */
section {
  margin-bottom: 3em;
}

/* News/Updates section */
.news {
  background-color: #f8f9fa;
  border-left: 4px solid #2c5282;
  padding: 1.5em;
  margin: 2em 0;
}

.news p {
  margin-bottom: 1em;
}

.news strong {
  color: #1a365d;
}

/* CV download section */
.download-section {
  text-align: center;
  margin: 2em 0;
  padding: 2em;
  background-color: #f8f9fa;
  border-radius: 8px;
}

.download-section .btn {
  font-size: 1.1em;
  padding: 0.75em 2em;
  border-radius: 6px;
}

.cv-alternative {
  text-align: center;
  font-size: 0.9em;
  color: #6c757d;
  margin-top: 1em;
}

/* Talks archive link */
.talks-archive {
  text-align: center;
  margin: 2em 0;
}

/* Tables for talks */
table {
  width: 100%;
  margin: 2em 0;
  border-collapse: collapse;
}

table th {
  background-color: #f8f9fa;
  border-bottom: 2px solid #dee2e6;
  padding: 0.75em;
  text-align: left;
  font-weight: 600;
}

table td {
  padding: 0.75em;
  border-bottom: 1px solid #dee2e6;
}

table tr:hover {
  background-color: #f8f9fa;
}

/* Now page note */
.now-note {
  background-color: #e7f3ff;
  border-left: 4px solid #0066cc;
  padding: 1em;
  margin: 2em 0;
  font-size: 0.95em;
}

/* Blog listing adjustments */
.quarto-listing {
  margin-top: 2em;
}

.quarto-listing-default .listing-item {
  margin-bottom: 2em;
  padding-bottom: 1.5em;
  border-bottom: 1px solid #e9ecef;
}

.quarto-listing-default .listing-title {
  font-size: 1.4em;
  margin-bottom: 0.3em;
}

.quarto-listing-default .listing-description {
  color: #495057;
  margin-bottom: 0.5em;
}

.quarto-listing-default .listing-date {
  color: #6c757d;
  font-size: 0.9em;
}

.quarto-listing-category {
  display: inline-block;
  background-color: #e9ecef;
  color: #495057;
  padding: 0.2em 0.6em;
  margin-right: 0.3em;
  margin-bottom: 0.3em;
  border-radius: 3px;
  font-size: 0.85em;
}

/* Button styling */
.btn-primary {
  background-color: #2c5282;
  border-color: #2c5282;
}

.btn-primary:hover {
  background-color: #1a365d;
  border-color: #1a365d;
}

.btn-outline-primary {
  color: #2c5282;
  border-color: #2c5282;
}

.btn-outline-primary:hover {
  background-color: #2c5282;
  border-color: #2c5282;
  color: white;
}

/* Code blocks */
pre {
  background-color: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  padding: 1em;
  overflow-x: auto;
}

code {
  font-family: 'Monaco', 'Consolas', 'Courier New', monospace;
  font-size: 0.9em;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  body {
    font-size: 14px;
  }

  h1 {
    font-size: 1.8em;
  }

  h2 {
    font-size: 1.5em;
  }

  .page-layout-full {
    padding: 1em 0.5em;
  }

  table {
    font-size: 0.9em;
  }

  table th,
  table td {
    padding: 0.5em;
  }
}

/* Print styles */
@media print {

  .navbar,
  footer,
  .sidebar {
    display: none;
  }

  body {
    font-size: 12pt;
  }

  a {
    color: #000;
    text-decoration: none;
  }
}

/* Accessibility improvements */
:focus {
  outline: 2px solid #2c5282;
  outline-offset: 2px;
}

.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;
}

/* Research and talks listing styles */
.research.project-list ul.list,
.talks ul.list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.research .project,
.talks .talk {
  margin-bottom: 2.5em;
  padding-bottom: 2em;
  border-bottom: 1px solid #e9ecef;
}

.research .project:last-child,
.talks .talk:last-child {
  border-bottom: none;
}

.listing-pub-info p {
  margin-bottom: 0.75em;
  line-height: 1.6;
}

.project-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5em;
  margin: 0.75em 0;
}

.project-category {
  background-color: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  padding: 0.2em 0.6em;
  font-size: 0.85em;
}

.project-category a {
  color: #495057;
  text-decoration: none;
}

.project-category a:hover {
  color: #2c5282;
  text-decoration: none;
}

.project-details-listing,
.talk-links {
  margin-top: 0.75em;
}

.project-links {
  list-style: none;
  padding-left: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1em;
}

.project-link a {
  color: #2c5282;
  text-decoration: none;
  font-size: 0.95em;
}

.project-link a:hover {
  color: #1a365d;
  text-decoration: underline;
}

.project-link.details a {
  font-weight: 600;
}

/* Talk-specific styles */
.talk-header {
  margin-bottom: 0.5em;
}

.talk-title {
  font-size: 1.15em;
  margin-bottom: 0.3em;
  font-weight: 600;
  color: #1a1a1a;
}

.talk-date {
  font-size: 0.9em;
  color: #6c757d;
  margin-bottom: 0.5em;
}

.talk-details {
  margin-bottom: 0.75em;
}

.talk-description {
  font-style: italic;
  color: #495057;
  margin-bottom: 0.3em;
}

.talk-location {
  font-size: 0.9em;
  color: #6c757d;
}

.talk-location i {
  margin-right: 0.3em;
}