/* Anatole Theme CSS - Proper Structure */

/* Import fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700&display=swap');

/* CSS Variables */
:root {
  --primary-color: #667eea;
  --secondary-color: #764ba2;
  --accent-color: #f093fb;
  --text-primary: #2c3e50;
  --text-secondary: #7f8c8d;
  --bg-light: #f8f9fa;
  --shadow-light: 0 4px 20px rgba(0,0,0,0.08);
  --shadow-medium: 0 8px 30px rgba(0,0,0,0.12);
  --border-radius: 12px;
}

/* Reset and base styles */
* {
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.6;
  margin: 0;
  padding: 0;
  background-color: #f8f9fa;
  color: #333;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
}

/* Wrapper layout */
.wrapper {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.wrapper__sidebar {
  width: 300px;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  color: white;
  position: fixed;
  height: 100vh;
  overflow-y: auto;
  z-index: 1000;
}

.sidebar {
  padding: 2rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.sidebar__content {
  flex: 1;
}

.sidebar__introduction {
  text-align: center;
  margin-bottom: 2rem;
}

.sidebar__introduction-profileimage {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin: 0 auto 1rem;
  display: block;
  border: 3px solid rgba(255,255,255,0.3);
  transition: transform 0.3s ease;
}

.sidebar__introduction-profileimage:hover {
  transform: scale(1.05);
}

.sidebar__introduction-title h1,
.sidebar__introduction-title a {
  color: white;
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
  font-weight: 600;
  text-decoration: none;
}

.sidebar__introduction-description p {
  color: rgba(255,255,255,0.9);
  font-size: 1rem;
  margin-bottom: 1rem;
  line-height: 1.6;
}

/* Social icons */
.sidebar__list {
  list-style: none;
  padding: 0;
  margin: 2rem 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

.sidebar__list-item {
  margin: 0;
}

.sidebar__list-item a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  background: rgba(255,255,255,0.2);
  color: white;
  border-radius: 50%;
  text-decoration: none;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.3);
}

.sidebar__list-item a:hover {
  transform: translateY(-5px) scale(1.1);
  background: rgba(255,255,255,0.3);
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

/* Main content */
.wrapper__main {
  flex: 1;
  margin-left: 300px;
  padding: 2rem;
  min-height: 100vh;
}

.wrapper__main--fullscreen {
  margin-left: 0;
}

/* Posts */
.posts {
  max-width: 800px;
}

.post {
  background: white;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-light);
  padding: 2rem;
  margin-bottom: 2rem;
  transition: all 0.3s ease;
  border: 1px solid rgba(0,0,0,0.05);
}

.post:hover {
  box-shadow: var(--shadow-medium);
  transform: translateY(-2px);
}

.post-title,
.post__title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.post-title a,
.post__title a {
  color: inherit;
  text-decoration: none;
  background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  transition: all 0.3s ease;
}

.post-title a:hover,
.post__title a:hover {
  background: linear-gradient(135deg, var(--accent-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.post-date,
.post__date {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1rem;
  font-weight: 500;
}

.post-content,
.post__content {
  line-height: 1.7;
  color: var(--text-primary);
}

.post-content h2,
.post__content h2 {
  color: var(--text-primary);
  font-weight: 600;
  margin: 2rem 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--primary-color);
}

.post-content h3,
.post__content h3 {
  color: #34495e;
  font-weight: 600;
  margin: 1.5rem 0 1rem;
}

.post-content p,
.post__content p {
  margin-bottom: 1rem;
}

.post-content a,
.post__content a {
  color: var(--primary-color);
  text-decoration: none;
}

.post-content a:hover,
.post__content a:hover {
  text-decoration: underline;
}

/* Tags */
.post-tags,
.post__tags {
  margin-top: 1.5rem;
}

.post-tags .tag,
.post__tags .tag {
  background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
  display: inline-block;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.post-tags .tag:hover,
.post__tags .tag:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Buttons */
.btn {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  color: white;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 25px;
  text-decoration: none;
  display: inline-block;
  font-weight: 600;
  transition: all 0.3s ease;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
  color: white;
}

/* Code blocks */
code {
  background: var(--bg-light);
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-size: 0.9em;
  color: var(--accent-color);
}

pre {
  background: #2d3748;
  color: #e2e8f0;
  padding: 1.5rem;
  border-radius: var(--border-radius);
  overflow-x: auto;
  margin: 2rem 0;
}

pre code {
  background: none;
  color: inherit;
  padding: 0;
}

/* Blockquotes */
blockquote {
  background: var(--bg-light);
  border-left: 4px solid var(--primary-color);
  padding: 1.5rem;
  margin: 2rem 0;
  border-radius: 0 var(--border-radius) var(--border-radius) 0;
  font-style: italic;
}

/* Navigation menu */
.menu,
.navigation {
  margin-top: 2rem;
}

.menu__list,
.navigation__list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.menu__list-item,
.navigation__item {
  margin-bottom: 0.5rem;
}

.menu__list-item a,
.navigation__link {
  display: block;
  padding: 0.5rem 0;
  color: rgba(255,255,255,0.8);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
}

.menu__list-item a:hover,
.navigation__link:hover,
.menu__list-item a.active,
.navigation__link.active {
  color: white;
  background: rgba(255,255,255,0.1);
  padding-left: 1rem;
  border-radius: 8px;
}

/* Footer */
.footer {
  margin-top: auto;
  padding-top: 2rem;
  text-align: center;
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
}

/* Responsive design */
@media (max-width: 768px) {
  .wrapper {
    flex-direction: column;
  }
  
  .wrapper__sidebar {
    position: relative;
    width: 100%;
    height: auto;
  }
  
  .wrapper__main {
    margin-left: 0;
    padding: 1rem;
  }
  
  .sidebar {
    padding: 1.5rem;
  }
  
  .post {
    padding: 1.5rem;
  }
  
  .post-title,
  .post__title {
    font-size: 1.5rem;
  }
  
  .sidebar__list {
    justify-content: center;
  }
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.post {
  animation: fadeInUp 0.6s ease-out;
}

.post:nth-child(2) { animation-delay: 0.1s; }
.post:nth-child(3) { animation-delay: 0.2s; }
.post:nth-child(4) { animation-delay: 0.3s; }

.animated.fadeInDown {
  animation: fadeInDown 0.6s ease-out;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Dark mode support */
.theme--dark {
  --bg-light: #2d3748;
  --text-primary: #ffffff;
  --text-secondary: #cbd5e0;
  background-color: #1a202c;
  color: #ffffff;
}

.theme--dark .post {
  background: #2d3748;
  color: #ffffff;
  border-color: rgba(255,255,255,0.1);
}

.theme--dark .wrapper__main {
  background: #1a202c;
  color: #ffffff;
}
/* Header and Navigation Styling */
.header {
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0,0,0,0.1);
  padding: 1rem 2rem;
  position: sticky;
  top: 0;
  z-index: 999;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

/* Navigation */
.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav__list {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 2rem;
  align-items: center;
}

.nav__list--end {
  margin-left: auto;
}

.nav__list-item {
  margin: 0;
}

.nav__list-item a {
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  transition: all 0.3s ease;
  position: relative;
}

.nav__list-item a:hover,
.nav__link--active {
  color: var(--primary-color);
  background: rgba(102, 126, 234, 0.1);
}

/* Mobile navigation burger */
.navbar-burger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  padding: 0.5rem;
  background: none;
  border: none;
}

.navbar-burger__line {
  width: 25px;
  height: 3px;
  background: var(--text-primary);
  margin: 3px 0;
  transition: 0.3s;
  border-radius: 2px;
}

/* Theme switcher */
.themeswitch a {
  color: var(--text-secondary);
  font-size: 1.2rem;
  padding: 0.5rem;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.themeswitch a:hover {
  color: var(--primary-color);
  background: rgba(102, 126, 234, 0.1);
}

/* Dropdown menus */
.optionswitch {
  position: relative;
}

.optionswitch__label {
  cursor: pointer;
  color: var(--text-primary);
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.optionswitch__label:hover {
  color: var(--primary-color);
  background: rgba(102, 126, 234, 0.1);
}

.optionswitch__picker:checked ~ .optionswitch__list {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.optionswitch__list {
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  border-radius: 8px;
  box-shadow: var(--shadow-medium);
  padding: 0.5rem 0;
  min-width: 150px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  z-index: 1000;
  list-style: none;
  margin: 0.5rem 0 0 0;
}

.optionswitch__list-item {
  margin: 0;
}

.optionswitch__list-item a {
  display: block;
  padding: 0.5rem 1rem;
  color: var(--text-primary);
  text-decoration: none;
  transition: all 0.3s ease;
}

.optionswitch__list-item a:hover {
  background: var(--bg-light);
  color: var(--primary-color);
}

.optionswitch__triangle {
  position: absolute;
  top: -5px;
  left: 1rem;
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-bottom: 5px solid white;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.optionswitch__picker:checked ~ .optionswitch__triangle {
  opacity: 1;
}

/* Mobile responsive navigation */
@media (max-width: 768px) {
  .navbar-burger {
    display: flex;
  }
  
  .nav__list {
    position: fixed;
    top: 0;
    left: -100%;
    width: 80%;
    height: 100vh;
    background: white;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 2rem;
    transition: left 0.3s ease;
    box-shadow: var(--shadow-medium);
    z-index: 1001;
  }
  
  .nav__list.active {
    left: 0;
  }
  
  .nav__list--end {
    margin-left: 0;
    margin-top: auto;
  }
  
  .nav__list-item {
    width: 100%;
    margin-bottom: 1rem;
  }
  
  .nav__list-item a {
    display: block;
    width: 100%;
    padding: 1rem;
    border-radius: 8px;
  }
  
  .header {
    padding: 1rem;
  }
}

/* Dark theme adjustments for navigation */
.theme--dark .header {
  background: rgba(26, 32, 44, 0.95);
  border-bottom-color: rgba(255,255,255,0.1);
}

.theme--dark .nav__list-item a {
  color: #ffffff;
}

.theme--dark .nav__list-item a:hover,
.theme--dark .nav__link--active {
  color: var(--primary-color);
  background: rgba(102, 126, 234, 0.2);
}

.theme--dark .optionswitch__list {
  background: #2d3748;
  border: 1px solid rgba(255,255,255,0.1);
}

.theme--dark .optionswitch__triangle {
  border-bottom-color: #2d3748;
}

.theme--dark .navbar-burger__line {
  background: #ffffff;
}

/* Archive page dark theme */
.theme--dark .archive__heading {
  color: #ffffff;
}

.theme--dark .archive__list-title {
  color: #ffffff;
}

.theme--dark .archive__list-date {
  color: #cbd5e0;
}

/* Additional dark theme text improvements */
.theme--dark h1,
.theme--dark h2,
.theme--dark h3,
.theme--dark h4,
.theme--dark h5,
.theme--dark h6 {
  color: #ffffff;
}

.theme--dark p {
  color: #ffffff;
}

.theme--dark strong,
.theme--dark b {
  color: #ffffff;
}

.theme--dark em,
.theme--dark i {
  color: #f7fafc;
}

@media (max-width: 768px) {
  .theme--dark .nav__list {
    background: #1a202c;
  }
}
/* Enhanced Theme Switcher Styling */
.themeswitch a {
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
}

.themeswitch a:hover {
  transform: scale(1.1);
}

/* Dark Theme Enhancements */
.theme--dark {
  background-color: #1a202c;
  color: #ffffff;
}

.theme--dark .wrapper__main {
  background-color: #1a202c;
  color: #ffffff;
}

.theme--dark .post {
  background: #2d3748;
  color: #ffffff;
  border-color: rgba(255,255,255,0.1);
}

.theme--dark .post-title,
.theme--dark .post__title {
  color: #ffffff;
}

.theme--dark .post-content h2,
.theme--dark .post__content h2 {
  color: #ffffff;
  border-bottom-color: var(--primary-color);
}

.theme--dark .post-content h3,
.theme--dark .post__content h3 {
  color: #f7fafc;
}

.theme--dark .post-date,
.theme--dark .post__date {
  color: #cbd5e0;
}

.theme--dark .post-content,
.theme--dark .post__content {
  color: #ffffff;
}

.theme--dark .post-content p,
.theme--dark .post__content p {
  color: #ffffff;
}

.theme--dark .post-content li,
.theme--dark .post__content li {
  color: #ffffff;
}

.theme--dark blockquote {
  background: #2d3748;
  border-left-color: var(--primary-color);
  color: #ffffff;
}

.theme--dark code {
  background: #4a5568;
  color: #fbb6ce;
}

/* Smooth theme transition */
html {
  transition: background-color 0.3s ease, color 0.3s ease;
}

.wrapper__main,
.post,
.header {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Mobile burger menu animation */
.navbar-burger.is-active .navbar-burger__line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.navbar-burger.is-active .navbar-burger__line:nth-child(2) {
  opacity: 0;
}

.navbar-burger.is-active .navbar-burger__line:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}

/* Theme switcher icon rotation */
.themeswitch a i {
  transition: transform 0.3s ease;
}

/* Improved focus states for accessibility */
.themeswitch a:focus,
.nav__list-item a:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Better hover states */
.nav__list-item a:hover {
  transform: translateY(-1px);
}

.themeswitch a:hover i {
  transform: rotate(180deg);
}
/* Video Embed Styling */
.video-container {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  margin: 2rem 0;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-medium);
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Enhanced video styling for posts */
.post .video-container {
  background: #000;
  transition: all 0.3s ease;
}

.post .video-container:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-heavy);
}

/* Dark theme video container */
.theme--dark .video-container {
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
}

/* Responsive video embeds */
@media (max-width: 768px) {
  .video-container {
    margin: 1.5rem 0;
    border-radius: 8px;
  }
}

/* Additional Dark Theme Text Fixes for Post Content */
.theme--dark .post-content *,
.theme--dark .post__content * {
  color: #ffffff !important;
}

.theme--dark .post-content h1,
.theme--dark .post__content h1,
.theme--dark .post-content h2,
.theme--dark .post__content h2,
.theme--dark .post-content h3,
.theme--dark .post__content h3,
.theme--dark .post-content h4,
.theme--dark .post__content h4,
.theme--dark .post-content h5,
.theme--dark .post__content h5,
.theme--dark .post-content h6,
.theme--dark .post__content h6 {
  color: #ffffff !important;
}

.theme--dark .post-content p,
.theme--dark .post__content p,
.theme--dark .post-content div,
.theme--dark .post__content div,
.theme--dark .post-content span,
.theme--dark .post__content span,
.theme--dark .post-content li,
.theme--dark .post__content li,
.theme--dark .post-content ul,
.theme--dark .post__content ul,
.theme--dark .post-content ol,
.theme--dark .post__content ol {
  color: #ffffff !important;
}

.theme--dark .post-content strong,
.theme--dark .post__content strong,
.theme--dark .post-content b,
.theme--dark .post__content b {
  color: #ffffff !important;
}

.theme--dark .post-content em,
.theme--dark .post__content em,
.theme--dark .post-content i,
.theme--dark .post__content i {
  color: #f7fafc !important;
}

/* Fix for any remaining text elements */
.theme--dark article,
.theme--dark article *,
.theme--dark .content,
.theme--dark .content * {
  color: #ffffff !important;
}

/* Ensure links remain visible but distinct */
.theme--dark .post-content a,
.theme--dark .post__content a {
  color: #90cdf4 !important;
}

.theme--dark .post-content a:hover,
.theme--dark .post__content a:hover {
  color: #63b3ed !important;
}

/* Fix for any Hugo-generated content */
.theme--dark .hugo-content,
.theme--dark .hugo-content *,
.theme--dark .markdown-content,
.theme--dark .markdown-content * {
  color: #ffffff !important;
}