/* ================================================================
   Modern Tech Blog — Blue × Orange Glassmorphism Design System
   ================================================================ */

/* ---------- Design Tokens ---------- */
:root {
  --primary: #3B82F6;
  --primary-dark: #2563EB;
  --primary-light: #60A5FA;
  --primary-glow: rgba(59, 130, 246, 0.3);
  --accent: #F97316;
  --accent-dark: #EA580C;
  --accent-glow: rgba(249, 115, 22, 0.25);
  --success: #10B981;
  --warning: #F59E0B;

  --bg: #F0F4F8;
  --bg-alt: #E2E8F0;
  --surface: rgba(255, 255, 255, 0.6);
  --surface-strong: rgba(255, 255, 255, 0.8);
  --card: rgba(255, 255, 255, 0.72);
  --card-hover: rgba(255, 255, 255, 0.88);
  --glass-border: rgba(148, 163, 184, 0.18);
  --text: #0F172A;
  --text-secondary: #334155;
  --text-muted: #64748B;
  --divider: rgba(100, 116, 139, 0.12);

  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 20px;

  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow: 0 4px 16px rgba(15, 23, 42, 0.08), 0 2px 6px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.12), 0 4px 12px rgba(15, 23, 42, 0.06);
  --shadow-xl: 0 24px 64px rgba(15, 23, 42, 0.16), 0 8px 24px rgba(15, 23, 42, 0.08);

  --blur: blur(18px) saturate(140%);
  --blur-light: blur(10px) saturate(120%);
}

[data-theme='dark'] {
  --bg: #070C15;
  --bg-alt: #111827;
  --surface: rgba(15, 23, 42, 0.55);
  --surface-strong: rgba(30, 41, 59, 0.75);
  --card: rgba(30, 41, 59, 0.65);
  --card-hover: rgba(30, 41, 59, 0.85);
  --glass-border: rgba(71, 85, 105, 0.22);
  --text: #E2E8F0;
  --text-secondary: #CBD5E1;
  --text-muted: #94A3B8;
  --divider: rgba(148, 163, 184, 0.1);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.2);
  --shadow: 0 4px 16px rgba(0, 0, 0, 0.25), 0 2px 6px rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.35), 0 4px 12px rgba(0, 0, 0, 0.2);
  --shadow-xl: 0 24px 64px rgba(0, 0, 0, 0.45);
}

/* ---------- Base ---------- */
html {
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  color: var(--text);
  background:
    radial-gradient(ellipse 80% 60% at 15% 10%, rgba(59, 130, 246, 0.08), transparent 50%),
    radial-gradient(ellipse 60% 50% at 85% 15%, rgba(249, 115, 22, 0.06), transparent 50%),
    radial-gradient(ellipse 50% 40% at 50% 85%, rgba(16, 185, 129, 0.04), transparent 50%),
    var(--bg);
  letter-spacing: 0.01em;
  min-height: 100vh;
}

::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: var(--primary);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary-dark);
}

::selection {
  background: var(--primary);
  color: #fff;
  text-shadow: none;
}

/* ---------- Navbar ---------- */
#page-header.nav-fixed #nav,
#nav {
  background: rgba(255, 255, 255, 0.7) !important;
  border-bottom: 1px solid var(--glass-border);
  box-shadow: var(--shadow-sm);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

#nav.show {
  background: rgba(255, 255, 255, 0.82) !important;
  box-shadow: var(--shadow);
}

[data-theme='dark'] #page-header.nav-fixed #nav,
[data-theme='dark'] #nav {
  background: rgba(7, 12, 21, 0.7) !important;
  border-bottom-color: rgba(71, 85, 105, 0.25);
}

[data-theme='dark'] #nav.show {
  background: rgba(15, 23, 42, 0.85) !important;
}

#nav a,
#nav #site-name,
#nav .site-name,
#nav .site-page {
  color: var(--text) !important;
  text-shadow: none;
  transition: color 0.2s ease;
}

#nav a:hover,
#nav .site-page:hover {
  color: var(--primary) !important;
}

[data-theme='dark'] #nav a,
[data-theme='dark'] #nav #site-name,
[data-theme='dark'] #nav .site-name,
[data-theme='dark'] #nav .site-page {
  color: var(--text) !important;
}

#nav.show a,
#nav.show #site-name,
#nav.show .site-name {
  color: var(--text) !important;
  text-shadow: none;
}

[data-theme='dark'] #nav.show a,
[data-theme='dark'] #nav.show #site-name,
[data-theme='dark'] #nav.show .site-name {
  color: var(--text) !important;
}

/* Full page (top) nav — transparent */
#page-header.full_page:not(.nav-fixed) #nav {
  background: rgba(7, 12, 20, 0.14) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: none;
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
}

#page-header.full_page:not(.nav-fixed) #nav a,
#page-header.full_page:not(.nav-fixed) #nav #site-name,
#page-header.full_page:not(.nav-fixed) #nav .site-name,
#page-header.full_page:not(.nav-fixed) #nav .site-page {
  color: rgba(255, 255, 255, 0.95) !important;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

/* ---------- Theme Toggle Button ---------- */
.nav-theme-toggle {
  display: inline-grid;
  width: 2.25rem;
  height: 2.25rem;
  margin-left: 0.25rem;
  padding: 0;
  place-items: center;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  color: var(--text);
  background: var(--surface);
  cursor: pointer;
  font: inherit;
  line-height: 1;
  backdrop-filter: var(--blur-light);
  -webkit-backdrop-filter: var(--blur-light);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-theme-toggle:hover {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 4px 16px var(--primary-glow);
  transform: translateY(-1px);
}

#page-header.full_page:not(.nav-fixed) #nav .nav-theme-toggle {
  color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
}

#page-header.full_page:not(.nav-fixed) #nav .nav-theme-toggle:hover {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

/* ---------- Page Header ---------- */
#page-header.full_page,
#page-header.not-top-img {
  background-position: center;
  background-size: cover;
}

#page-header:before {
  background: linear-gradient(180deg, rgba(7, 12, 21, 0.15), rgba(7, 12, 21, 0.55));
}

#site-title {
  font-weight: 900;
  letter-spacing: -0.02em;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.25);
}

#site-subtitle {
  margin-top: 0.65rem;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

#post-info .post-title {
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

/* ---------- Homepage Article Cards ---------- */
#recent-posts > .recent-post-item {
  overflow: hidden;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  background: var(--card);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  box-shadow: var(--shadow);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1),
              border-color 0.3s ease;
}

#recent-posts > .recent-post-item:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-xl), 0 0 0 1px var(--primary-glow);
  transform: translateY(-6px);
}

#recent-posts > .recent-post-item .post_cover img,
.aside-list-item .thumbnail img {
  filter: saturate(1.06) contrast(1.03);
  border-radius: var(--radius);
  transition: transform 0.4s ease;
}

#recent-posts > .recent-post-item:hover .post_cover img {
  transform: scale(1.04);
}

#recent-posts > .recent-post-item .recent-post-info .article-title {
  color: var(--text);
  font-weight: 750;
  line-height: 1.35;
  transition: color 0.2s ease;
}

#recent-posts > .recent-post-item:hover .recent-post-info .article-title {
  color: var(--primary);
}

#recent-posts > .recent-post-item .recent-post-info .article-meta-wrap,
#recent-posts > .recent-post-item .content {
  color: var(--text-muted);
}

/* Card dark mode */
[data-theme='dark'] #recent-posts > .recent-post-item,
[data-theme='dark'] .card-widget,
[data-theme='dark'] #post,
[data-theme='dark'] #page,
[data-theme='dark'] #archive,
[data-theme='dark'] #tag,
[data-theme='dark'] #category,
[data-theme='dark'] #post-comment {
  background: var(--card);
  border-color: var(--glass-border);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

[data-theme='dark'] #recent-posts > .recent-post-item .recent-post-info .article-title,
[data-theme='dark'] .card-widget .item-headline,
[data-theme='dark'] .card-info .author-info-name {
  color: var(--text);
}

/* ---------- Sidebar Cards ---------- */
.card-widget {
  border: 1px solid var(--glass-border);
  border-radius: var(--radius) !important;
  background: var(--card);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  box-shadow: var(--shadow);
  padding: 1.2rem;
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.card-widget:hover {
  box-shadow: var(--shadow-lg);
  border-color: rgba(59, 130, 246, 0.2);
}

.card-widget .item-headline {
  color: var(--text);
  font-weight: 800;
  font-size: 1.05rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--primary);
  display: inline-block;
}

/* Author Card */
.card-info .avatar-img img {
  border: 3px solid var(--primary);
  box-shadow: 0 8px 32px var(--primary-glow);
  border-radius: 50%;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-info .avatar-img img:hover {
  transform: rotate(4deg) scale(1.05);
  box-shadow: 0 12px 40px rgba(59, 130, 246, 0.45);
}

.card-info .author-info-name {
  color: var(--text);
  font-weight: 900;
  font-size: 1.25rem;
}

.card-info .author-info-description,
.announcement_content,
.aside-list .content time {
  color: var(--text-muted);
}

#card-info-btn {
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--primary), #1D4ED8);
  border: none;
  box-shadow: 0 6px 24px var(--primary-glow);
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#card-info-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(59, 130, 246, 0.4);
}

/* ---------- Post / Page Container ---------- */
#post,
#page,
#archive,
#tag,
#category,
#post-comment {
  border: 1px solid var(--glass-border) !important;
  border-radius: var(--radius) !important;
  background: var(--card) !important;
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  box-shadow: var(--shadow);
  padding: 2rem 2.2rem;
}

#post-comment {
  margin-top: 1.5rem;
  padding: 1.5rem 2rem;
}

#post-comment .comment-headline {
  color: var(--text);
  font-weight: 800;
  font-size: 1.2rem;
}

/* ---------- Article Content ---------- */
#article-container {
  color: var(--text);
  line-height: 1.95;
  font-size: 1.02rem;
}

#article-container h1,
#article-container h2,
#article-container h3,
#article-container h4 {
  color: var(--text);
  font-weight: 800;
  letter-spacing: -0.01em;
  scroll-margin-top: 5rem;
}

#article-container h1 {
  font-size: 2.1rem;
  margin: 1.8rem 0 1.2rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--divider);
}

#article-container h2 {
  font-size: 1.55rem;
  margin-top: 2.2rem;
  margin-bottom: 1rem;
  padding-left: 0.9rem;
  border-left: 4px solid var(--primary);
  position: relative;
}

#article-container h2::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 28px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), transparent);
  border-radius: 2px;
}

#article-container h3 {
  font-size: 1.25rem;
  color: var(--primary);
  margin-top: 1.6rem;
}

[data-theme='dark'] #article-container h3 {
  color: var(--primary-light);
}

#article-container p,
#article-container li,
#article-container table {
  color: var(--text);
}

#article-container a {
  color: var(--primary);
  text-decoration: none;
  background: linear-gradient(var(--primary), var(--primary)) left bottom / 0% 2px no-repeat;
  transition: background-size 0.3s ease;
  padding-bottom: 2px;
}

#article-container a:hover {
  background-size: 100% 2px;
}

/* Blockquote */
#article-container blockquote {
  border-left: 4px solid var(--accent);
  background: rgba(249, 115, 22, 0.06);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 0.9rem 1.2rem;
  margin: 1.2rem 0;
  color: var(--text-secondary);
  backdrop-filter: var(--blur-light);
  -webkit-backdrop-filter: var(--blur-light);
}

[data-theme='dark'] #article-container blockquote {
  background: rgba(249, 115, 22, 0.08);
}

/* Tables */
#article-container table {
  overflow: hidden;
  border-radius: var(--radius-sm);
  box-shadow: inset 0 0 0 1px var(--glass-border);
  border-collapse: separate;
  border-spacing: 0;
}

#article-container th {
  background: rgba(59, 130, 246, 0.1);
  color: var(--text);
  font-weight: 700;
  border: none;
}

#article-container td {
  border-color: var(--divider);
}

#article-container tr:last-child td {
  border-bottom: none;
}

/* Inline Code */
#article-container code {
  border-radius: 6px;
  padding: 0.15em 0.4em;
  background: rgba(59, 130, 246, 0.08);
  color: var(--primary-dark);
  font-family: "JetBrains Mono", "Fira Code", Consolas, monospace;
  font-size: 0.88em;
  border: 1px solid rgba(59, 130, 246, 0.1);
}

[data-theme='dark'] #article-container code {
  color: #93C5FD;
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.15);
}

/* Code Blocks */
#article-container figure.highlight,
#article-container pre {
  border-radius: var(--radius-sm);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

#article-container figure.highlight .highlight-tools {
  background: rgba(15, 23, 42, 0.04);
  border-bottom: 1px solid var(--glass-border);
}

[data-theme='dark'] #article-container figure.highlight .highlight-tools {
  background: rgba(0, 0, 0, 0.3);
  border-bottom-color: var(--glass-border);
}

/* ---------- Post Meta Tags ---------- */
.post-meta__tags {
  border: 1px solid rgba(59, 130, 246, 0.25);
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.08);
  color: var(--primary-dark);
  padding: 0.25rem 0.75rem;
  font-size: 0.85rem;
  font-weight: 600;
  transition: all 0.2s ease;
}

.post-meta__tags:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

[data-theme='dark'] .post-meta__tags {
  color: var(--primary-light);
}

/* Post Copyright */
.post-copyright {
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  background: rgba(59, 130, 246, 0.04);
  backdrop-filter: var(--blur-light);
  -webkit-backdrop-filter: var(--blur-light);
}

[data-theme='dark'] .post-copyright {
  background: rgba(59, 130, 246, 0.06);
}

/* ---------- TOC ---------- */
#aside-content .toc-widget .toc-link {
  color: var(--text-muted);
  transition: color 0.2s ease, padding-left 0.2s ease;
}

#aside-content .toc-widget .toc-link:hover,
#aside-content .toc-widget .toc-link.active {
  color: var(--primary);
  padding-left: 0.35rem;
}

#aside-content .toc-widget .toc-link.active {
  font-weight: 700;
}

/* ---------- Pagination ---------- */
#pagination .page-number {
  border-radius: var(--radius-sm);
  color: var(--text);
  border: 1px solid var(--glass-border);
  background: var(--surface);
  backdrop-filter: var(--blur-light);
  -webkit-backdrop-filter: var(--blur-light);
  transition: all 0.2s ease;
}

#pagination .page-number:hover {
  border-color: var(--primary);
  color: var(--primary);
}

#pagination .page-number.current {
  background: linear-gradient(135deg, var(--primary), #1D4ED8);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 16px var(--primary-glow);
}

/* ---------- Right Side Buttons ---------- */
#rightside > div > button,
#rightside > div > a {
  border-radius: var(--radius-sm);
  background: var(--card);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  transition: all 0.25s ease;
}

#rightside > div > button:hover,
#rightside > div > a:hover {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 6px 20px var(--primary-glow);
  transform: translateY(-2px);
}

/* ---------- Footer ---------- */
#footer {
  color: var(--text-muted);
  background: var(--surface);
  border-top: 1px solid var(--glass-border);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  padding: 2rem 1rem;
}

#footer:before {
  display: none;
}

#footer a,
#footer .footer-copyright,
#footer .framework-info,
#footer .footer_custom_text {
  color: var(--text-muted);
  text-shadow: none;
  transition: color 0.2s ease;
}

#footer a:hover {
  color: var(--primary);
}

[data-theme='dark'] #footer {
  color: var(--text-muted);
  background: rgba(7, 12, 21, 0.7);
}

/* ---------- Waline Comments ---------- */
#waline-wrap {
  --waline-theme-color: var(--primary);
  --waline-active-color: var(--accent);
  --waline-border: 1px solid var(--glass-border);
  --waline-border-radius: var(--radius-sm);
  --waline-bg-color: var(--card);
  --waline-bg-color-light: var(--surface);
  --waline-color: var(--text);
  --waline-dark-bg-color: var(--card);
}

.waline-wrapper .wl-panel {
  border-radius: var(--radius-sm) !important;
}

/* ---------- Tags & Categories Page ---------- */
.tag-cloud a,
.category-list a {
  color: var(--text) !important;
  background: var(--surface);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  padding: 0.4rem 0.85rem;
  backdrop-filter: var(--blur-light);
  -webkit-backdrop-filter: var(--blur-light);
  transition: all 0.25s ease;
}

.tag-cloud a:hover,
.category-list a:hover {
  background: var(--primary) !important;
  color: #fff !important;
  border-color: var(--primary);
  box-shadow: 0 4px 16px var(--primary-glow);
  transform: translateY(-2px);
}

/* ---------- Related Posts ---------- */
.relatedPosts {
  margin-top: 2rem;
}

.relatedPosts > .relatedPosts-list > div {
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  backdrop-filter: var(--blur-light);
  -webkit-backdrop-filter: var(--blur-light);
  overflow: hidden;
  transition: all 0.3s ease;
}

.relatedPosts > .relatedPosts-list > div:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateY(-3px);
}

/* ---------- Category/Tag Page Cards ---------- */
.category-lists .category-list-item,
.tag-cloud-list a,
ul.tag-cloud-list .tag-list-item {
  transition: transform 0.25s ease;
}

/* ---------- Archive Timeline ---------- */
#archive .article-sort-item {
  border-bottom: 1px solid var(--divider);
  padding: 0.75rem 0;
  transition: padding-left 0.2s ease;
}

#archive .article-sort-item:hover {
  padding-left: 0.5rem;
}

#archive .article-sort-item .article-sort-item-title {
  color: var(--text);
  font-weight: 600;
  transition: color 0.2s ease;
}

#archive .article-sort-item:hover .article-sort-item-title {
  color: var(--primary);
}

/* Archive year marker */
#archive .article-sort-title {
  color: var(--primary);
  font-weight: 800;
  font-size: 1.3rem;
  position: relative;
  padding-left: 1rem;
}

#archive .article-sort-title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 10px var(--primary-glow);
}

/* ---------- Loader ---------- */
#loading-box .loading-left-bg,
#loading-box .loading-right-bg {
  background: var(--bg);
}

[data-theme='dark'] #loading-box .loading-left-bg,
[data-theme='dark'] #loading-box .loading-right-bg {
  background: var(--bg);
}

#loading-box .loading-img {
  border-radius: var(--radius);
}

/* ---------- Search (Local/Algolia) ---------- */
#search-modal .search-dialog {
  border-radius: var(--radius);
  border: 1px solid var(--glass-border);
  background: var(--card);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  box-shadow: var(--shadow-xl);
}

#search-modal .search-dialog .search-input input {
  border-radius: var(--radius-sm);
  border: 1px solid var(--glass-border);
  background: var(--surface);
  color: var(--text);
}

/* ---------- Animations ---------- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

#recent-posts > .recent-post-item {
  animation: fadeInUp 0.5s ease both;
}

#recent-posts > .recent-post-item:nth-child(1) { animation-delay: 0.05s; }
#recent-posts > .recent-post-item:nth-child(2) { animation-delay: 0.1s; }
#recent-posts > .recent-post-item:nth-child(3) { animation-delay: 0.15s; }
#recent-posts > .recent-post-item:nth-child(4) { animation-delay: 0.2s; }
#recent-posts > .recent-post-item:nth-child(5) { animation-delay: 0.25s; }
#recent-posts > .recent-post-item:nth-child(6) { animation-delay: 0.3s; }
#recent-posts > .recent-post-item:nth-child(7) { animation-delay: 0.35s; }
#recent-posts > .recent-post-item:nth-child(8) { animation-delay: 0.4s; }
#recent-posts > .recent-post-item:nth-child(9) { animation-delay: 0.45s; }
#recent-posts > .recent-post-item:nth-child(10) { animation-delay: 0.5s; }

/* ---------- Post Edit Button ---------- */
.post-edit-link {
  color: var(--primary) !important;
}

/* ---------- Photo Frame ---------- */
.fancybox img,
#article-container img {
  border-radius: var(--radius-sm);
}

/* ---------- Horizontal Rule ---------- */
#article-container hr {
  border: none;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary), var(--accent), transparent);
  margin: 2.5rem 0;
  opacity: 0.6;
}

/* ---------- Mobile Responsive ---------- */
@media (max-width: 768px) {
  body {
    background:
      radial-gradient(ellipse 60% 40% at 15% 5%, rgba(59, 130, 246, 0.06), transparent 50%),
      radial-gradient(ellipse 40% 30% at 85% 10%, rgba(249, 115, 22, 0.04), transparent 50%),
      var(--bg);
  }

  #recent-posts > .recent-post-item,
  .card-widget,
  #post,
  #page,
  #archive,
  #tag,
  #category,
  #post-comment {
    border-radius: var(--radius-sm) !important;
    box-shadow: var(--shadow-sm);
  }

  #article-container {
    line-height: 1.85;
    font-size: 0.98rem;
  }

  #article-container h1 { font-size: 1.6rem; }
  #article-container h2 { font-size: 1.3rem; margin-top: 1.6rem; }
  #article-container h3 { font-size: 1.1rem; }

  #post,
  #page {
    padding: 1.2rem;
  }

  #nav {
    backdrop-filter: var(--blur);
    -webkit-backdrop-filter: var(--blur);
  }
}

/* ---------- Mouse Follow Glow ---------- */
#cursor-glow {
  position: fixed;
  z-index: 9999;
  pointer-events: none;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.12), rgba(59, 130, 246, 0.04) 35%, transparent 70%);
  transform: translate(-50%, -50%);
  will-change: left, top;
  transition: left 0.15s linear, top 0.15s linear;
}

[data-theme='dark'] #cursor-glow {
  background: radial-gradient(circle, rgba(59, 130, 246, 0.18), rgba(59, 130, 246, 0.06) 35%, transparent 70%);
}

@media (max-width: 768px) {
  #cursor-glow { display: none; }
}
