/* Lil'Log-inspired soft dark theme styles */

/* Color variables matching theme-dark.scss */
:root {
  --bg-primary: #1d1e20;
  --bg-secondary: #2e2e33;
  --bg-tertiary: #37383e;
  --text-primary: #dadada;
  --text-secondary: #c4c4c5;
  --text-muted: #9b9c9d;
  --border-color: #333333;
  --accent: #75A8D9;
}

/* Profile section */
.profile-pic {
  border-radius: 50%;
  max-width: 100px;
  height: auto;
}

.profile-header .quarto-layout-row {
  align-items: flex-start;
}

/* Reset all margins inside profile header cells for top alignment */
.profile-header .quarto-layout-cell {
  padding-top: 0;
}

.profile-header .quarto-layout-cell p,
.profile-header .quarto-layout-cell figure {
  margin-top: 0;
  margin-bottom: 0;
}

.profile-header .profile-pic {
  margin: 0;
}

@media (max-width: 600px) {
  .profile-pic {
    display: none;
  }
}

@media (min-width: 600px) {
  .profile-header .quarto-layout-row {
    flex-direction: row;
  }
}

/* Title and description styling */
.quarto-title-block h1.title {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

.quarto-title-block .description {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 400;
  line-height: 1.6;
  margin-top: 0.5rem;
}

@media (max-width: 768px) {
  .quarto-title-block h1.title {
    font-size: 1.5rem;
  }
  
  .quarto-title-block .description {
    font-size: 1rem;
  }
}

/* Section styling */
.section-header {
  margin-top: 2rem;
  margin-bottom: 1rem;
}

/* Blog listings - table style */
#blog-listings {
  margin-top: 1.5rem;
  width: 100%;
  overflow-x: auto;
}

.quarto-listing-table {
  width: 100%;
}

.quarto-listing-table th {
  border-bottom: 2px solid var(--border-color);
  padding: 0.75rem 0.5rem;
  text-align: left;
  font-weight: 600;
  color: var(--text-primary);
}

.quarto-listing-table td {
  padding: 0.75rem 0.5rem;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-secondary);
}

.quarto-listing-table tr:hover {
  background-color: rgba(117, 168, 217, 0.05);
}

/* Links in table */
.quarto-listing-table a {
  text-decoration: none;
  color: var(--accent);
}

.quarto-listing-table a:hover {
  text-decoration: underline;
}

/* Responsive table for mobile */
@media (max-width: 768px) {
  #blog-listings table {
    font-size: 0.9rem;
  }
  
  #blog-listings th,
  #blog-listings td {
    padding: 0.5rem;
  }
}

@media (max-width: 480px) {
  #blog-listings table,
  #blog-listings thead,
  #blog-listings tbody,
  #blog-listings th,
  #blog-listings td,
  #blog-listings tr {
    display: block;
  }
  
  #blog-listings thead tr {
    position: absolute;
    top: -9999px;
    left: -9999px;
  }
  
  #blog-listings tr {
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
  }
  
  #blog-listings td {
    border: none;
    position: relative;
    padding-left: 40%;
    text-align: right;
  }
  
  #blog-listings td:before {
    position: absolute;
    left: 6px;
    width: 35%;
    white-space: nowrap;
    text-align: left;
    font-weight: bold;
  }
  
  #blog-listings td:nth-of-type(1):before {
    content: "Date";
  }
  #blog-listings td:nth-of-type(2):before {
    content: "Title";
  }
}

/* Filter/search input styling */
input[type="search"] {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--border-color);
  margin-bottom: 1rem;
  color: var(--text-primary);
  background-color: var(--bg-secondary);
  font-size: 16px;
  border-radius: 4px;
}

input[type="search"]:focus {
  outline: none;
  border-color: var(--accent);
}

/* Navbar custom styling */
.navbar {
  border-bottom: 1px solid var(--border-color);
}

.navbar-brand {
  display: none;
}

/* Footer styling */
.nav-footer {
  border-top: 1px solid var(--border-color);
  padding: 1.5rem 0;
}

/* TOC sidebar styling */
#TOC {
  padding-top: 1rem;
}

#TOC a {
  color: var(--text-muted);
  text-decoration: none;
}

#TOC a:hover {
  color: var(--accent);
}

#TOC .active {
  color: var(--accent);
  font-weight: 600;
}

/* Horizontal rule */
hr {
  border: none;
  border-top: 1px solid var(--border-color);
  margin: 2rem 0;
}

/* Content images */
.content img,
.quarto-figure img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1.5rem auto;
  border-radius: 8px;
}

/* Code block styling */
pre {
  background-color: var(--bg-secondary);
  border-radius: 6px;
  padding: 1rem;
}

/* Blockquote styling */
blockquote {
  border-left: 4px solid var(--accent);
  padding-left: 1rem;
  margin-left: 0;
  color: var(--text-secondary);
}

/* Updates/news list styling */
.updates-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.updates-list li {
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border-color);
}

.updates-list li:last-child {
  border-bottom: none;
}

.updates-list strong {
  color: var(--text-primary);
}

/* Emoji headers */
h2 {
  margin-top: 2rem;
  margin-bottom: 1rem;
}

/* Publications styling */
.publications-container {
  max-width: 900px;
}

.pub-year-header {
  margin-top: 2rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.publications-list {
  list-style: disc;
  padding-left: 1.5rem;
}

.publication-item {
  display: list-item;
  margin-bottom: 1rem;
  padding-left: 0.25rem;
}

.pub-title {
  font-weight: 700;
  line-height: 1.3;
  color: var(--text-primary);
}

.pub-title p {
  margin-bottom: 0.1rem;
}

.pub-authors {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.3;
}

.pub-authors p {
  margin-bottom: 0.1rem;
}

.pub-venue {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.3;
}

.pub-venue p {
  margin-bottom: 0;
}

.pub-venue a {
  color: var(--accent);
}

/* Experience Timeline Cards */
.experience-grid {
  position: relative;
  margin-top: 1.5rem;
  padding-left: 2rem;
}

/* Vertical timeline line */
.experience-grid::before {
  content: '';
  position: absolute;
  left: 0.5rem;
  top: 0.5rem;
  bottom: 0.5rem;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), var(--border-color));
}

.experience-card {
  position: relative;
  background: linear-gradient(135deg, #232427 0%, #2a2a2e 100%);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1.25rem;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.experience-card:last-child {
  margin-bottom: 0;
}

/* Timeline dot */
.experience-card::before {
  content: '';
  position: absolute;
  left: -1.75rem;
  top: 1.5rem;
  width: 12px;
  height: 12px;
  background: var(--accent);
  border-radius: 50%;
  border: 2px solid var(--bg-primary);
}

.experience-card:hover {
  transform: translateX(4px);
  border-color: var(--accent);
  box-shadow: 0 4px 20px rgba(117, 168, 217, 0.1);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.5rem;
}

.company-name {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
}

.card-date {
  font-size: 0.8rem;
  color: var(--accent);
  white-space: nowrap;
  padding-left: 0.5rem;
}

.card-role {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  font-weight: 500;
}

.card-description {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.card-description p {
  margin: 0;
}

@media (max-width: 480px) {
  .experience-grid {
    padding-left: 1.5rem;
  }
  
  .experience-card::before {
    left: -1.25rem;
    width: 10px;
    height: 10px;
  }
  
  .experience-grid::before {
    left: 0.25rem;
  }
}

/* Template credit */
.template-credit {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

.template-credit p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0;
}

.template-credit a {
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.template-credit a:hover {
  color: var(--accent);
}
