/* Custom Styles for Hugo Personal Notes Site */

/* Selection */
::selection {
  background-color: #c45d3e;
  color: white;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #f5f2ed;
}

::-webkit-scrollbar-thumb {
  background: #d4cfc5;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #c45d3e;
}

/* Note Card */
.note-card {
  @apply pb-8 border-b border-paper-200;
  animation: fadeIn 0.3s ease-out both;
}

.note-card:last-child {
  @apply border-b-0 pb-0;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.note-card:nth-child(1) { animation-delay: 0ms; }
.note-card:nth-child(2) { animation-delay: 50ms; }
.note-card:nth-child(3) { animation-delay: 100ms; }
.note-card:nth-child(4) { animation-delay: 150ms; }
.note-card:nth-child(5) { animation-delay: 200ms; }
.note-card:nth-child(6) { animation-delay: 250ms; }

/* Tag */
.tag {
  @apply inline-block px-2 py-0.5 text-xs rounded;
  background-color: #f0ebe4;
  color: #6b6b6b;
  transition: all 0.2s ease;
}

.tag:hover {
  background-color: #c45d3e;
  color: white;
  cursor: pointer;
}

/* Prose Styles - Markdown Content */
.prose-custom {
  line-height: 1.8;
  font-size: 1.0625rem;
}

.prose-custom > * + * {
  margin-top: 1.5em;
}

.prose-custom h1,
.prose-custom h2,
.prose-custom h3,
.prose-custom h4 {
  font-family: 'Noto Serif SC', Georgia, serif;
  font-weight: 600;
  color: #2c2c2c;
  margin-top: 2em;
  margin-bottom: 0.75em;
}

.prose-custom h1 {
  font-size: 1.875rem;
}

.prose-custom h2 {
  font-size: 1.5rem;
}

.prose-custom h3 {
  font-size: 1.25rem;
}

.prose-custom h4 {
  font-size: 1.125rem;
}

.prose-custom p {
  margin-bottom: 1.5em;
}

.prose-custom a {
  color: #c45d3e;
  text-decoration: none;
  position: relative;
  display: inline-block;
}

.prose-custom a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #c45d3e;
  transition: width 0.3s ease;
}

.prose-custom a:hover::after {
  width: 100%;
}

.prose-custom strong {
  font-weight: 600;
  color: #2c2c2c;
}

.prose-custom em {
  font-style: italic;
}

.prose-custom ul,
.prose-custom ol {
  padding-left: 1.5em;
  margin-bottom: 1.5em;
}

.prose-custom li {
  margin-bottom: 0.5em;
}

.prose-custom li::marker {
  color: #c45d3e;
}

.prose-custom blockquote {
  border-left: 3px solid #c45d3e;
  padding-left: 1.25em;
  margin-left: 0;
  margin-right: 0;
  color: #6b6b6b;
  font-style: italic;
}

.prose-custom blockquote p:last-child {
  margin-bottom: 0;
}

.prose-custom code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.875em;
  background-color: #2d2a24;
  color: #e8e4dc;
  padding: 0.2em 0.4em;
  border-radius: 4px;
}

.prose-custom pre {
  background-color: #2d2a24;
  color: #e8e4dc;
  padding: 1.25em;
  border-radius: 8px;
  overflow-x: auto;
  margin: 1.5em 0;
}

.prose-custom pre code {
  background: none;
  padding: 0;
  font-size: 0.875em;
  line-height: 1.6;
}

.prose-custom hr {
  border: none;
  height: 1px;
  background-color: #e5e0d8;
  margin: 2em 0;
}

.prose-custom img {
  max-width: 100%;
  border-radius: 8px;
  margin: 1.5em 0;
}

.prose-custom table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5em 0;
  font-size: 0.9375rem;
}

.prose-custom th,
.prose-custom td {
  border: 1px solid #e5e0d8;
  padding: 0.75em 1em;
  text-align: left;
}

.prose-custom th {
  background-color: #f5f2ed;
  font-weight: 600;
}

.prose-custom tr:hover {
  background-color: #faf8f5;
}

/* Inline code not in pre */
.prose-custom p code,
.prose-custom li code {
  background-color: #f0ebe4;
  color: #c45d3e;
  padding: 0.2em 0.4em;
  border-radius: 4px;
  font-size: 0.875em;
}

/* Focus states */
a:focus-visible,
button:focus-visible {
  outline: 2px solid #c45d3e;
  outline-offset: 2px;
  border-radius: 2px;
}
