/* Hugo Mini Theme CSS - extracted from inline template */
html[theme='dark-mode'] {
  filter: invert(1) hue-rotate(180deg);
}

body {
  line-height: 1;
  font: normal 15px/1.5em 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: #404040;
  line-height: 1.75;
  letter-spacing: 0.008em;
}

a {
  text-decoration: none;
  color: #5badf0;
}

a:hover {
  color: #0366d6;
}

/* Typography */
h1, h2, h3 {
  font-weight: 400;
  color: #404040;
}

p {
  margin-block-start: 1.5em;
  margin-block-end: 1.5em;
}

p, pre {
  word-break: normal;
  overflow-wrap: anywhere;
}

/* Code Typography */
p code {
  font-family: SFMono-Regular, Consolas, Liberation Mono, Menlo, Courier, monospace;
  font-size: inherit;
  background-color: rgba(0, 0, 0, 0.06);
  padding: 0 2px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 2px 2px;
  line-height: inherit;
  word-wrap: break-word;
  text-indent: 0;
}

pre code {
  font-family: SFMono-Regular, Consolas, Liberation Mono, Menlo, Courier, monospace;
}

/* Chroma Syntax Highlighting */
.chroma {
  background-color: #f8f8f8;
  border: 1px solid #e1e4e8;
  border-radius: 6px;
  margin: 16px 0;
  overflow-x: auto;
}

.chroma pre {
  margin: 0;
  padding: 16px;
  overflow-x: auto;
  line-height: 1.45;
  font-size: 14px;
}

.chroma code {
  font-family: SFMono-Regular, Consolas, Liberation Mono, Menlo, Courier, monospace;
  background: transparent;
  border: none;
  padding: 0;
}

/* Line numbers for Chroma */
.chroma .ln {
  color: #666;
  user-select: none;
  padding-right: 16px;
  min-width: 2em;
  text-align: right;
  display: inline-block;
}

/* Legacy highlight support */
.highlight pre {
  padding: 16px;
  overflow-x: auto;
  background-color: #f8f8f8;
  border: 1px solid #e1e4e8;
  border-radius: 6px;
  margin: 16px 0;
}

.highlight {
  max-width: 100%;
  overflow-x: auto;
}

/* Markdown Content Styling */
blockquote {
  margin-top: 5px;
  margin-bottom: 5px;
  padding-left: 1em;
  margin-left: 0px;
  border-left: 3px solid #eee;
  color: #757575;
}

hr {
  display: block;
  border: none;
  height: 2px;
  margin: 40px auto;
  background: #eee;
}

table {
  width: 100%;
  margin: 40px 0;
  border-collapse: collapse;
  line-height: 1.5em;
}

th, td {
  text-align: left;
  padding-right: 20px;
  vertical-align: top;
}

table td, td {
  border-spacing: none;
  border-style: solid;
  padding: 10px 15px;
  border-width: 1px 0 0 0;
}

thead th, th {
  text-align: left;
  padding: 10px 15px;
  height: 20px;
  font-size: 13px;
  font-weight: bold;
  color: #444;
  cursor: default;
  white-space: nowrap;
  border: 1px solid #dadadc;
}

tr>td {
  border: 1px solid #dadadc;
}

tr:nth-child(odd)>td {
  background: #fcfcfc;
}

.markdown-image img {
  max-width: 100%;
}

.anchor { 
  font-size: 100%; 
  visibility: hidden; 
  color: silver;
}

h1:hover a, h2:hover a, h3:hover a, h4:hover a { 
  visibility: visible
}

/* Layout System */
.main {
  width: 100%;
  margin: 0 auto;
}

/* Navigation */
nav.navigation {
  padding: 20px 20px 10px;
  background: #fff;
  background: rgba(255, 255, 255, 0.9);
  margin: 0 auto;
  text-align: center;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: wrap;
}

nav.navigation a {
  padding: 8px 12px;
  color: #5badf0;
  font-size: 13px;
  line-height: 1.35;
  text-decoration: none;
  border-radius: 3px;
  white-space: nowrap;
  flex-shrink: 0;
}

nav.navigation a:hover {
  color: #0366d6;
}

nav.navigation a.button {
  background: #5badf0;
  color: #fff;
  margin-left: 12px;
}

nav.navigation a.tag-link {
  padding: 8px 12px;
  background: none;
  border: none;
  border-radius: 0;
  font-size: 13px;
  transition: color 0.2s ease;
  margin: 0;
  color: #5badf0;
  text-decoration: none;
}

nav.navigation a.tag-link:hover {
  background: none;
  color: #0366d6;
}

nav.navigation a.active {
  background: #5badf0;
  color: #fff;
}

nav.navigation a.tag-link.active {
  background: none;
  color: #0366d6;
  font-weight: bold;
}

nav.navigation a.tag-link.active:hover {
  background: none;
  color: #0366d6;
}

/* Removed tag categorization - all tags display inline */

/* Post Count Indicators - Hidden */
.tag-count {
  display: none;
}

/* Smooth Transitions - Simplified */
.tag-link {
  transition: color 0.2s ease;
  transform: none;
}

.tag-link:hover {
  transform: none;
  box-shadow: none;
}

/* Tag Page Layout - matches home page */
.tag-header {
  text-align: center;
  margin: 40px 0 20px 0;
}

.tag-header h2 {
  font-size: 24px;
  font-weight: 400;
  color: #404040;
}

#tag-page {
  max-width: 580px;
  margin: 0 auto;
  padding: 0 24px;
}

#tag-page .item {
  margin: 12px 0;
}

#tag-page .title {
  display: inline-block;
  color: #404040;
  font-size: 20px;
  font-weight: 400;
  margin: 0;
  width: 80%;
}

#tag-page .title a {
  color: #404040;
  display: block;
}

#tag-page .title a:hover {
  color: #0366d6;
}

#tag-page .date {
  width: 20%;
  float: right;
  text-align: right;
  position: relative;
  top: 1px;
  color: #bbb;
}

#tag-page .summary {
  color: #757575;
  margin-top: 12px;
  word-break: normal;
  overflow-wrap: anywhere;
  margin-bottom: 36px;
}

/* Tag display on tag pages and post previews */
.tags {
  text-align: center;
  margin: 1rem 0;
}

.tag {
  display: inline-block;
  margin: 0 0.5rem 0.5rem 0;
  padding: 0.25rem 0.5rem;
  background: transparent;
  color: #5badf0;
  text-decoration: none;
  font-size: 0.9rem;
  border-radius: 0;
  transition: color 0.2s ease;
}

.tag:hover {
  color: #0366d6;
  background: transparent;
}

.back-link {
  max-width: 580px;
  margin: 40px auto;
  padding: 0 24px;
  text-align: center;
}

.back-link a {
  color: #5badf0;
  text-decoration: none;
}

.back-link a:hover {
  color: #0366d6;
}

/* Profile/Header */
.profile {
  margin: 60px auto 0 auto;
  text-align: center;
}

.profile .avatar {
  display: inline-block;
  width: 80px;
  height: 80px;
  border-radius: 50%;
}

.profile h1 {
  font-weight: 400;
  letter-spacing: 0px;
  font-size: 20px;
  color: #404040;
  margin-bottom: 0;
  margin-top: 0;
}

.profile h2 {
  font-size: 20px;
  font-weight: 300;
  color: #757575;
  margin-top: 0;
}

/* Post List Layout (Home Page) */
#list-page {
  max-width: 580px;
  margin: 0 auto;
  padding: 0 24px;
}

#list-page .item {
  margin: 12px 0;
}

#list-page .title {
  display: inline-block;
  color: #404040;
  font-size: 20px;
  font-weight: 400;
  margin: 0;
  width: 80%;
}

#list-page .title a {
  color: #404040;
  display: block;
}

#list-page .title a:hover {
  color: #0366d6;
}

#list-page .date {
  width: 20%;
  float: right;
  text-align: right;
  position: relative;
  top: 1px;
  color: #bbb;
}

#list-page .summary {
  color: #757575;
  margin-top: 12px;
  word-break: normal;
  overflow-wrap: anywhere;
  margin-bottom: 36px;
}

#list-page .pagination {
  margin: 48px 0;
  width: 100%;
  height: 32px;
  margin-top: 48px;
}

#list-page .pagination .pre {
  float: left;
}

#list-page .pagination .next {
  float: right;
}

/* Single Post Layout */
#single {
  max-width: 680px;
  margin: 60px auto 0 auto;
  padding: 0 64px;
}

#single .title {
  text-align: center;
  font-size: 32px;
  font-weight: 400;
  line-height: 48px;
}

#single .tip {
  text-align: center;
  color: #8c8c8c;
  margin-top: 18px;
  font-size: 14px;
}

#single .tip .split {
  margin: 0 4px;
}

#single .content {
  margin-top: 36px;
}

/* Tags */
#single .tags {
  margin-top: 24px;
}

#single .tags a, .tags a {
  background: #f2f2f2;
  padding: 4px 7px;
  color: #757575;
  font-size: 14px;
  margin-right: 3px;
}

#single .tags a:hover, .tags a:hover {
  color: #0366d6;
}

/* Table of Contents */
.toc {
  margin: auto;
  background: #f8f8f8;
  border-radius: 0;
  padding: 10px 7px;
  margin-top: 36px;
}

.toc details summary {
  cursor: zoom-in;
  margin-inline-start: 14px;
  font-weight: 500;
}

.toc details[open] summary {
  cursor: zoom-out;
}

.toc #TableOfContents {
  margin-left: 10px;
}

.toc ul {
  padding-inline-start: 24px;
}

/* Footer */
#footer {
  margin-top: 100px;
  margin-bottom: 100px;
  text-align: center;
  color: #bbbbbb;
  font-size: 14px;
}

#footer .copyright {
  margin: 20px auto;
  font-size: 15px;
}

.powerby {
  margin: 20px auto;
  font-size: 13px;
}

#footer .split {
  cursor: pointer;
}

#footer .split:hover path {
  fill: #ff3356;
  transition: 0.7s ease-out;
  cursor: pointer;
}

#social a {
  margin: 0 4px;
}

/* Responsive Design */
@media (max-width: 700px) {
  nav.navigation {
    padding: 20px 10px 0 10px;
    background: #fff;
    background: rgba(255, 255, 255, 0.9);
    margin: 0 auto;
    z-index: 100;
    justify-content: center;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  nav.navigation a {
    top: 8px;
    right: 6px;
    padding: 8px 8px;
    color: #5badf0;
    font-size: 13px;
    line-height: 1.35;
    border-radius: 3px;
  }

  #single {
    padding: 0 18px;
    margin: 20px auto 0 auto;
  }
  
  #single .title {
    font-size: 24px;
    line-height: 32px;
  }
}

@media (max-width: 324px) {
  nav.navigation a.button {
    display: none;
  }
  
  nav.navigation {
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
  }
}

/* Enhanced Mobile Navigation for Tags */
@media (max-width: 768px) {
  nav.navigation {
    overflow-x: auto;
    padding-bottom: 8px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #ddd transparent;
  }
  
  nav.navigation::-webkit-scrollbar {
    height: 3px;
  }
  
  nav.navigation::-webkit-scrollbar-track {
    background: transparent;
  }
  
  nav.navigation::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 3px;
  }
  
  .tag-category {
    margin-left: 6px;
    flex-shrink: 0;
  }
  
  .tag-link {
    font-size: 11px;
    padding: 3px 8px;
    margin-right: 4px;
  }
  
  .tag-count {
    font-size: 9px;
    padding: 0px 3px;
  }
  
  /* Touch-friendly targets */
  .tag-link {
    min-height: 28px;
    display: inline-flex;
    align-items: center;
    touch-action: manipulation;
  }
}
  
  nav.navigation a.tag-link {
    display: inline-block;
    margin-left: 4px;
    font-size: 11px;
  }
}

/* Legacy support for existing classes */
.header {
  border-bottom: 1px solid #eee;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
}

.nav {
  margin-bottom: 2rem;
}

.nav a {
  margin-right: 1rem;
  text-decoration: none;
  color: #5badf0;
}

.post-list {
  list-style: none;
  padding: 0;
}

.post-item {
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #f0f0f0;
}

.post-title {
  margin: 0 0 0.5rem 0;
}

.post-meta {
  color: #757575;
  font-size: 0.9rem;
}

.tag {
  background: #f2f2f2;
  padding: 4px 7px;
  color: #757575;
  font-size: 14px;
  margin-right: 3px;
}

.tag:hover {
  color: #0366d6;
}
