:root {
  --theme-orange: #f97316;
  --theme-orange-dark: #d35400;
  --theme-orange-soft: #fff3e0;
  --theme-bg: #fff7f0;
  --theme-bg-light: #fff3e2;
  --theme-bg-dark: #181818;
  --theme-text: #1f2937;
  --theme-muted: #713f10;
}

* {
  box-sizing: border-box;
}

body {
  background-color: var(--theme-bg);
  color: var(--theme-text);
  min-height: 100vh;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a,
.text-link,
.link-text,
.card-title a,
.page-link,
.badge {
  color: var(--theme-orange);
}

a:hover,
.text-link:hover,
.link-text:hover,
.navbar-nav .nav-link:hover,
.card-title a:hover,
.page-link:hover {
  color: var(--theme-orange-dark);
}

/* Override legacy fixed sidebar layout from theme-5.css */
header,
.header {
  position: relative !important;
  left: auto !important;
  top: auto !important;
  width: 100% !important;
  height: auto !important;
  background: transparent !important;
  color: #fff !important;
}

.main-wrapper {
  margin-left: 0 !important;
  background: transparent !important;
}

.header .navbar {
  padding: 0 !important;
}

.header .blog-name {
  position: static !important;
  width: auto !important;
  top: auto !important;
  left: auto !important;
}

.header .btn-primary {
  width: auto !important;
  background: var(--theme-orange) !important;
  border-color: var(--theme-orange) !important;
}

.navbar {
  background-color: rgba(18, 18, 18, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.navbar-brand {
  font-weight: 700;
}

.navbar-brand .text-white-75 {
  color: rgba(255,255,255,0.85);
}

.navbar-nav {
  align-items: center;
  gap: 0.5rem;
}

.navbar-nav .nav-link {
  color: #fff;
  padding: 0.5rem 1.25rem;
  margin: 0 0.25rem;
  border-radius: 999px;
  transition: all 0.2s ease;
  font-weight: 500;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {````
`  color: #ffffff;
  background-color: rgba(249, 115, 22, 0.2);
  transform: translateY(-1px);
}

.navbar-toggler {
  border-color: rgba(255,255,255,0.3);
}

.navbar-toggler-icon {
  filter: invert(1);
}

.social-button {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255,255,255,0.16);
  transition: all 0.2s ease;
}

.social-button:hover {
  color: #fff;
  background-color: rgba(249, 115, 22, 0.18);
  border-color: rgba(249, 115, 22, 0.35);
}

/* Pagination styling */
.pagination {
  gap: 0.25rem;
}

.page-link {
  color: var(--theme-orange);
  border-color: rgba(249, 115, 22, 0.3);
  border-radius: 0.375rem;
  padding: 0.5rem 0.75rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.page-link:hover {
  color: #fff;
  background-color: var(--theme-orange);
  border-color: var(--theme-orange);
  transform: translateY(-2px);
}

.page-item.active .page-link {
  background-color: var(--theme-orange);
  border-color: var(--theme-orange);
  color: #fff;
}

.page-item.disabled .page-link {
  color: rgba(0, 0, 0, 0.25);
  background-color: #fff;
  border-color: #dee2e6;
  cursor: not-allowed;
}

.profile-section {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 1.25rem;
  padding: 1.5rem;
}

.profile-section .bio a {
  color: #fff;
  text-decoration: underline;
}

.main-wrapper {
  padding-top: 1rem;
}

.title,
.heading,
.blog-post-header .title,
.cta-section .heading {
  color: var(--theme-orange-dark);
  font-weight: 700;
}

/* Headings on dark backgrounds */
footer h1,
footer h2,
footer h3,
footer h4,
footer h5,
footer h6,
.theme-bg-dark h1,
.theme-bg-dark h2,
.theme-bg-dark h3,
.theme-bg-dark h4,
.theme-bg-dark h5,
.theme-bg-dark h6 {
  color: #fff;
}

.theme-bg-light {
  background-color: var(--theme-bg-light) !important;
}

footer.theme-bg-dark {
  background-color: #161616 !important;
  color: #f8fafc;
  padding: 2.5rem 0;
}

footer.theme-bg-dark a {
  color: #f8fafc;
}

.text-white-75 {
  color: rgba(255, 255, 255, 0.8) !important;
}

.navbar {
  background-color: #131313;
}

.navbar-brand,
.navbar-nav .nav-link,
.social-list a {
  color: rgba(255, 255, 255, 0.95);
}

.navbar-brand .small {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.75);
}

.navbar-brand,
.navbar-nav .nav-link,
.social-list a {
  color: #fff;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
  color: #ffe8d1;
}

.btn-outline-light {
  color: #fff;
  border-color: rgba(255,255,255,0.6);
}

.btn-outline-light:hover,
.btn-outline-light:focus,
.btn-outline-light:active {
  color: #212121;
  background-color: #fff;
  border-color: #fff;
}

.btn-primary,
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background-color: var(--theme-orange);
  border-color: var(--theme-orange);
}

.btn-outline-primary {
  color: var(--theme-orange);
  border-color: var(--theme-orange);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active {
  background-color: rgba(249, 115, 22, 0.08);
  border-color: var(--theme-orange-dark);
  color: var(--theme-orange-dark);
}

.btn {
  padding: 0.5rem 1rem;
  font-weight: 600;
  line-height: 1.4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: auto;
  height: auto;
}

.btn-sm {
  padding: 0.25rem 0.625rem;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
}

.btn-warning {
  background-color: var(--theme-orange);
  border-color: var(--theme-orange);
}

.btn-warning:hover {
  background-color: var(--theme-orange-dark);
  border-color: var(--theme-orange-dark);
}

.card,
.blog-post-header,
.about-section,
.contact-section,
.comment-section,
.promo-section,
.blog-list .item,
.category-card {
  border: none;
  border-radius: 1.5rem;
  box-shadow: 0 24px 48px rgba(91, 34, 0, 0.08);
  background-color: #fff;
}

.card {
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 32px 64px rgba(91, 34, 0, 0.12);
}

.blog-post-body p,
.about-section p,
.contact-section p,
.comment-policy p {
  color: #3b2413;
  line-height: 1.8;
}

.blog-banner img,
.category-card img,
.profile-section img,
.about-section img,
.contact-section img,
.promo-figure img,
.item img,
.card-img-top {
  border-radius: 1rem;
}

.card-img-top {
  height: 240px;
  object-fit: cover;
}

.img-fluid,
.object-fit-cover {
  max-width: 100%;
  height: auto;
}

.object-fit-cover {
  object-fit: cover;
}

.btn-outline-primary,
.btn-outline-light {
  transition: all 0.2s ease;
}

.card-body {
  padding: 1.5rem;
}

.section-heading,
.section-title {
  margin-bottom: 1.5rem;
}

.section-intro {
  max-width: 720px;
  color: #6f4c27;
}

.single-col-max-width {
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.blog-post .meta,
.blog-list .meta,
.category-posts-card .card-text,
.category-posts-card .card-title {
  color: #4e342e;
}

.meta span,
.blog-post .meta span {
  display: inline-block;
  margin-right: 1rem;
}

.blog-post .blog-nav .nav-link,
.blog-nav .nav-link {
  color: var(--theme-orange-dark);
}

.blog-post .blog-nav .nav-link.active,
.blog-post .blog-nav .nav-link:hover {
  color: #fff;
  background-color: var(--theme-orange);
}

.comment-section {
  background-color: var(--theme-bg-light);
}

blockquote,
ul {
  color: #5e381d;
}

blockquote {
  padding-left: 1.5rem;
  border-left: 4px solid var(--theme-orange);
  font-style: italic;
  color: #5e381d;
}

/* Blog post body content styling */
.blog-post-body {
  line-height: 1.8;
  font-size: 1.05rem;
}

.blog-post-body h1,
.blog-post-body .h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #222;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.blog-post-body h2,
.blog-post-body .h2 {
  font-size: 2rem;
  font-weight: 700;
  color: #333;
  margin-top: 1.8rem;
  margin-bottom: 0.8rem;
}

.blog-post-body h3,
.blog-post-body .h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: #444;
  margin-top: 1.5rem;
  margin-bottom: 0.6rem;
}

.blog-post-body h4,
.blog-post-body .h4 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #555;
  margin-top: 1.2rem;
  margin-bottom: 0.4rem;
}

.blog-post-body p {
  margin-bottom: 1.5rem;
  color: #4f2c10;
}

.blog-post-body ul,
.blog-post-body ol {
  margin-bottom: 1.5rem;
  padding-left: 2rem;
  color: #5e381d;
}

.blog-post-body li {
  margin-bottom: 0.6rem;
}

.blog-post-body code {
  background-color: #f5f5f5;
  padding: 0.2rem 0.4rem;
  border-radius: 0.25rem;
  font-family: 'Menlo', 'Monaco', monospace;
  color: #c41d7f;
}

.blog-post-body pre {
  background-color: #1e1e1e;
  color: #d4d4d4;
  padding: 1.5rem;
  border-radius: 0.75rem;
  overflow-x: auto;
  margin-bottom: 1.5rem;
}

.blog-post-body pre code {
  background-color: transparent;
  color: inherit;
  padding: 0;
}

.blog-banner {
  margin: 2rem 0;
  border-radius: 1rem;
  overflow: hidden;
}

.blog-banner img {
  width: 100%;
  height: auto;
  border-radius: 1rem;
}

.image-caption {
  color: #888;
  font-size: 0.9rem;
  margin-top: 0.75rem;
}

.image-caption a {
  text-decoration: underline;
}

/* GitHub repo section styling */
.repo-section {
  background: linear-gradient(135deg, var(--theme-orange) 0%, rgba(249, 115, 22, 0.9) 100%);
  border-radius: 1.5rem;
  margin: 2rem 0;
}

.repo-section .title {
  color: #fff;
  font-size: 1.75rem;
}

.repo-section a {
  color: #fff;
  text-decoration: underline;
}

.repo-section a:hover {
  color: #fff;
  text-decoration-thickness: 2px;
}

/* Blog navigation styling */
.blog-nav {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin: 3rem 0;
}

.blog-nav .nav-link {
  flex: 1;
  border-radius: 1rem;
  background-color: rgba(249, 115, 22, 0.08);
  border: 1px solid var(--theme-border);
  transition: all 0.2s ease;
  padding: 1.5rem;
  text-decoration: none;
}

.blog-nav .nav-link:hover {
  background-color: rgba(249, 115, 22, 0.16);
  border-color: var(--theme-orange);
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(91, 34, 0, 0.1);
}

.blog-nav .nav-link-prev {
  text-align: left;
}

.blog-nav .nav-link-next {
  text-align: right;
}

/* Promo section styling */
.promo-section {
  border-radius: 1.5rem;
  margin: 2rem 0;
}

.promo-section .title {
  color: var(--theme-orange-dark);
  font-size: 1.75rem;
  margin-bottom: 1rem;
}

.promo-section p {
  color: #6f4c27;
  font-size: 1rem;
}

.promo-figure {
  margin-top: 1.5rem;
  border-radius: 1rem;
  overflow: hidden;
}

/* Comment section styling */
.comment-section {
  border-radius: 1.5rem;
  margin-top: 3rem;
  padding: 2rem;
}

.comment-section h2 {
  color: var(--theme-orange-dark);
  margin-bottom: 1.5rem;
}

@media (max-width: 767px) {
  .profile-section {
    padding: 1rem;
  }
  
  .blog-nav {
    flex-direction: column;
  }
  
  .blog-post-body h1,
  .blog-post-body .h1 {
    font-size: 1.75rem;
  }
  
  .blog-post-body h2,
  .blog-post-body .h2 {
    font-size: 1.5rem;
  }
}
