/* Custom styles for the website - Professional Design */

/* ============================================
   Color Palette
   ============================================ */
:root {
  --primary-color: #2563eb;
  --primary-dark: #1e40af;
  --primary-light: #3b82f6;
  --secondary-color: #0891b2;
  --accent-color: #06b6d4;
  --bg-light: #f8fafc;
  --bg-gradient-start: #e0f2fe;
  --bg-gradient-end: #f0f9ff;
  --text-dark: #1e293b;
  --text-medium: #475569;
  --text-light: #64748b;
  --border-color: #e2e8f0;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

/* ============================================
   Global Styles
   ============================================ */
body {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--text-dark);
  background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
  background-attachment: fixed;
}

/* ============================================
   Navigation Bar
   ============================================ */
.navbar {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%) !important;
  box-shadow: var(--shadow-md);
  padding: 1rem 0;
  border-bottom: 3px solid var(--accent-color);
}

.navbar-brand {
  font-weight: 700;
  font-size: 1.4rem;
  color: white !important;
  transition: transform 0.3s ease;
}

.navbar-brand:hover {
  transform: scale(1.05);
}

.navbar-nav .nav-link {
  color: rgba(255, 255, 255, 0.9) !important;
  font-weight: 500;
  padding: 0.5rem 1rem !important;
  margin: 0 0.25rem;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover {
  background-color: rgba(255, 255, 255, 0.15);
  color: white !important;
  transform: translateY(-2px);
}

.navbar-nav .nav-link.active {
  background-color: rgba(255, 255, 255, 0.2);
  color: white !important;
}

/* ============================================
   Main Content Area
   ============================================ */
#quarto-content {
  background-color: white;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  padding: 2.5rem;
  margin-top: 2rem;
  margin-bottom: 2rem;
}

/* ============================================
   Headers
   ============================================ */
h1, h2, h3, h4, h5, h6 {
  margin-top: 2rem;
  margin-bottom: 1.25rem;
  font-weight: 700;
  color: var(--text-dark);
}

h1 {
  font-size: 2.5rem;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  border-bottom: 3px solid var(--accent-color);
  padding-bottom: 0.75rem;
  margin-bottom: 1.5rem;
}

h2 {
  font-size: 1.875rem;
  color: var(--primary-dark);
  border-left: 4px solid var(--accent-color);
  padding-left: 1rem;
  margin-top: 2.5rem;
}

h3 {
  font-size: 1.5rem;
  color: var(--text-dark);
}

/* ============================================
   Hero Section (for homepage)
   ============================================ */
.hero-section {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  color: white;
  padding: 3rem 2rem;
  border-radius: 12px;
  margin-bottom: 2.5rem;
  box-shadow: var(--shadow-lg);
  text-align: center;
}

.hero-section h1 {
  color: white;
  border-bottom: none;
  background: none;
  -webkit-text-fill-color: white;
  margin-bottom: 1rem;
  font-size: 3rem;
}

.hero-section p {
  font-size: 1.25rem;
  opacity: 0.95;
  max-width: 800px;
  margin: 0 auto;
}

/* ============================================
   Cards and Sections
   ============================================ */
.card, .content-card {
  background-color: white;
  border-radius: 10px;
  padding: 1.75rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.card:hover, .content-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.section-divider {
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color) 0%, var(--accent-color) 100%);
  border: none;
  margin: 2.5rem 0;
  border-radius: 2px;
}

/* ============================================
   Links and Buttons
   ============================================ */
a {
  color: var(--primary-color);
  text-decoration: none;
  transition: all 0.2s ease;
}

a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

.btn, button {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  border: none;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
}

.btn:hover, button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* ============================================
   Lists
   ============================================ */
ul, ol {
  margin: 1.5rem 0;
  padding-left: 2rem;
}

li {
  margin-bottom: 0.75rem;
  line-height: 1.7;
}

ul li::marker {
  color: var(--accent-color);
  font-weight: bold;
}

/* Quick links special styling */
.quick-links li {
  background-color: var(--bg-light);
  padding: 0.75rem 1rem;
  margin-bottom: 0.75rem;
  border-radius: 8px;
  border-left: 4px solid var(--accent-color);
  transition: all 0.2s ease;
  list-style: none;
}

.quick-links li:hover {
  background-color: var(--bg-gradient-start);
  transform: translateX(5px);
  box-shadow: var(--shadow-sm);
}

.quick-links li::before {
  content: "→";
  color: var(--accent-color);
  font-weight: bold;
  margin-right: 0.75rem;
}

/* ============================================
   Code Blocks
   ============================================ */
pre {
  background-color: #1e293b;
  color: #e2e8f0;
  border-radius: 8px;
  padding: 1.5rem;
  border-left: 4px solid var(--accent-color);
  box-shadow: var(--shadow-sm);
  overflow-x: auto;
}

code {
  background-color: var(--bg-light);
  color: var(--primary-dark);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  font-size: 0.9em;
}

pre code {
  background-color: transparent;
  color: inherit;
  padding: 0;
}

/* ============================================
   Blockquotes
   ============================================ */
blockquote {
  background-color: var(--bg-light);
  border-left: 5px solid var(--accent-color);
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0;
  border-radius: 0 8px 8px 0;
  color: var(--text-medium);
  font-style: italic;
  box-shadow: var(--shadow-sm);
}

/* ============================================
   Tables
   ============================================ */
table {
  margin: 2rem 0;
  border-collapse: collapse;
  width: 100%;
  box-shadow: var(--shadow-sm);
  border-radius: 8px;
  overflow: hidden;
}

thead {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
}

thead th {
  padding: 1rem;
  font-weight: 600;
  text-align: left;
}

tbody tr {
  border-bottom: 1px solid var(--border-color);
  transition: background-color 0.2s ease;
}

tbody tr:hover {
  background-color: var(--bg-light);
}

tbody td {
  padding: 0.875rem 1rem;
}

tbody tr:last-child {
  border-bottom: none;
}

/* ============================================
   Images
   ============================================ */
img {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  margin: 1.5rem 0;
  box-shadow: var(--shadow-md);
  transition: transform 0.3s ease;
}

img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

/* ============================================
   Lab Notebook Listing
   ============================================ */
.quarto-listing {
  margin-top: 2rem;
}

.quarto-listing-category {
  background-color: var(--accent-color);
  color: white;
  padding: 0.375rem 0.75rem;
  border-radius: 20px;
  font-size: 0.875rem;
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
  display: inline-block;
  transition: all 0.2s ease;
}

.quarto-listing-category:hover {
  background-color: var(--secondary-color);
  transform: scale(1.05);
}

.listing-item {
  background-color: white;
  padding: 1.5rem;
  margin-bottom: 1.25rem;
  border-radius: 10px;
  border-left: 4px solid var(--accent-color);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

.listing-item:hover {
  box-shadow: var(--shadow-md);
  transform: translateX(5px);
}

/* ============================================
   Footer
   ============================================ */
.nav-footer {
  background: linear-gradient(135deg, var(--text-dark) 0%, var(--text-medium) 100%);
  color: white;
  margin-top: 4rem;
  padding: 2rem 0;
  border-top: 3px solid var(--accent-color);
  box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1);
}

.nav-footer a {
  color: rgba(255, 255, 255, 0.9);
  transition: color 0.2s ease;
}

.nav-footer a:hover {
  color: white;
  text-decoration: none;
}

/* ============================================
   Task Lists
   ============================================ */
.task-list-item {
  list-style-type: none;
  background-color: var(--bg-light);
  padding: 0.5rem;
  margin-bottom: 0.5rem;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.task-list-item:hover {
  background-color: var(--bg-gradient-start);
}

.task-list-item input[type="checkbox"] {
  margin-right: 0.75rem;
  width: 1.25rem;
  height: 1.25rem;
  cursor: pointer;
}

/* ============================================
   Table of Contents
   ============================================ */
#quarto-margin-sidebar .toc-actions,
#quarto-margin-sidebar nav[role="navigation"] {
  background-color: white;
  padding: 1.25rem;
  border-radius: 10px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
}

#TOC a {
  color: var(--text-medium);
  transition: all 0.2s ease;
}

#TOC a:hover {
  color: var(--primary-color);
  padding-left: 0.5rem;
}

#TOC .active {
  color: var(--primary-color);
  font-weight: 600;
  border-left: 3px solid var(--accent-color);
  padding-left: 0.5rem;
}

/* ============================================
   Search
   ============================================ */
#quarto-search {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  transition: all 0.3s ease;
}

#quarto-search:hover {
  background-color: rgba(255, 255, 255, 0.3);
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 768px) {
  #quarto-content {
    padding: 1.5rem;
  }
  
  h1 {
    font-size: 2rem;
  }
  
  .hero-section h1 {
    font-size: 2.25rem;
  }
  
  .hero-section {
    padding: 2rem 1.5rem;
  }
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#quarto-content > * {
  animation: fadeIn 0.6s ease-out;
}

/* ============================================
   Utility Classes
   ============================================ */
.text-center {
  text-align: center;
}

.mt-4 {
  margin-top: 2rem;
}

.mb-4 {
  margin-bottom: 2rem;
}

.highlight-box {
  background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-light) 100%);
  border-left: 4px solid var(--accent-color);
  padding: 1.5rem;
  border-radius: 8px;
  margin: 1.5rem 0;
  box-shadow: var(--shadow-sm);
}
