/* Ranjith Kumar blog theme — matches the portfolio (dark, violet, Inter / JetBrains Mono).
   Layered on top of GeneratePress; remove this file to return to the stock look. */

:root {
  --rk-bg: #06000f;
  --rk-surface: rgba(255, 255, 255, 0.04);
  --rk-surface-hover: rgba(255, 255, 255, 0.07);
  --rk-border: rgba(255, 255, 255, 0.08);
  --rk-border-accent: rgba(167, 139, 250, 0.4);
  --rk-text: #ede9fe;
  --rk-heading: #f5f3ff;
  --rk-muted: #a89bc4;
  --rk-accent: #a78bfa;
  --rk-accent-2: #e879f9;
  --rk-code-bg: #0d0820;
  --rk-radius: 16px;
  --rk-sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --rk-mono: "JetBrains Mono", "Fira Code", Consolas, monospace;
}

/* ---------- Page ---------- */
body {
  background-color: var(--rk-bg) !important;
  background-image:
    radial-gradient(ellipse at 15% 15%, rgba(139, 92, 246, 0.28) 0%, transparent 50%),
    radial-gradient(ellipse at 85% 80%, rgba(217, 70, 239, 0.18) 0%, transparent 50%),
    radial-gradient(ellipse at 5% 75%, rgba(168, 85, 247, 0.16) 0%, transparent 45%) !important;
  background-attachment: fixed !important;
  color: var(--rk-text) !important;
  font-family: var(--rk-sans) !important;
  -webkit-font-smoothing: antialiased;
}
::selection { background: rgba(167, 139, 250, 0.35); color: var(--rk-text); }

.site, .site-content, .container, .grid-container { background: transparent !important; }

h1, h2, h3, h4, h5, h6,
.entry-title, .entry-title a, .page-title, .widget-title {
  color: var(--rk-heading) !important;
  font-family: var(--rk-sans) !important;
  letter-spacing: -0.015em;
}
.entry-title { font-weight: 800 !important; line-height: 1.2 !important; }
.entry-content h2, .entry-content h3 { font-weight: 700; margin-top: 1.8em; }

a { color: var(--rk-accent); transition: color .2s ease; }
a:hover, a:focus { color: var(--rk-accent-2); }
.entry-title a:hover { color: var(--rk-accent) !important; }

/* ---------- Header & navigation ---------- */
.site-header {
  background: rgba(6, 0, 15, 0.6) !important;
  background-image: none !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--rk-border);
}
.inside-header { background: transparent !important; }

.main-navigation,
.main-navigation .inside-navigation,
.main-navigation ul ul { background: transparent !important; }
.main-navigation .main-nav ul li a,
.main-navigation .menu-toggle,
.main-navigation .menu-bar-items {
  color: var(--rk-muted) !important;
  font-family: var(--rk-sans);
  font-weight: 500;
}
.main-navigation .main-nav ul li:hover > a,
.main-navigation .main-nav ul li:focus > a,
.main-navigation .main-nav ul li.sfHover > a,
.main-navigation .main-nav ul li[class*="current-menu-"] > a {
  color: var(--rk-heading) !important;
  background: rgba(167, 139, 250, 0.12) !important;
}
.main-navigation .main-nav > ul > li > a { border-radius: 999px; }
.main-navigation ul ul {
  background: #120a24 !important;
  border: 1px solid var(--rk-border);
  border-radius: 12px;
}
/* Mobile menu */
.main-navigation.toggled .main-nav > ul,
.main-navigation.toggled .main-nav ul ul {
  background: #0c061a !important;
  border: 1px solid var(--rk-border);
  border-radius: 12px;
}

/* ---------- Cards (posts, sidebar widgets, comments, pagination) ---------- */
.separate-containers .inside-article,
.separate-containers .comments-area,
.separate-containers .page-header,
.separate-containers .paging-navigation,
.one-container .container,
.sidebar .widget,
.post-navigation {
  background: var(--rk-surface) !important;
  border: 1px solid var(--rk-border);
  border-radius: var(--rk-radius);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.05), 0 8px 32px rgba(0, 0, 0, 0.35);
  transition: border-color .3s ease, background .3s ease;
}
.blog .inside-article:hover,
.archive .inside-article:hover,
.search .inside-article:hover {
  background: var(--rk-surface-hover) !important;
  border-color: var(--rk-border-accent);
}

/* ---------- Post text ---------- */
.entry-content, .entry-summary, .comment-content {
  font-size: 17px;
  line-height: 1.75;
  color: var(--rk-text);
}
.entry-content p, .entry-summary p { color: rgba(237, 233, 254, 0.88); }
.entry-content strong { color: var(--rk-heading); }
.entry-content img { border-radius: 12px; }
.entry-content hr, hr { background: var(--rk-border) !important; border: 0; height: 1px; }

.entry-meta, .entry-meta a,
.cat-links, .tags-links, .comments-link,
.byline, .posted-on, .comment-metadata a {
  color: var(--rk-muted) !important;
  font-size: 13px;
}
.entry-meta a:hover { color: var(--rk-accent) !important; }
.cat-links a, .tags-links a {
  display: inline-block;
  padding: 1px 10px;
  margin: 2px 2px 2px 0;
  border: 1px solid var(--rk-border);
  border-radius: 999px;
  background: rgba(167, 139, 250, 0.08);
  color: #c4b5fd !important;
}
.cat-links a:hover, .tags-links a:hover { border-color: var(--rk-border-accent); color: var(--rk-heading) !important; }
.cat-links .gp-icon, .tags-links .gp-icon, .comments-link .gp-icon { color: var(--rk-muted); }

/* "Read more" as a pill button */
a.read-more, .read-more-container a {
  display: inline-block;
  margin-top: 6px;
  padding: 6px 16px;
  border-radius: 12px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  background: rgba(139, 92, 246, 0.18);
  color: #c4b5fd !important;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none !important;
}
a.read-more:hover { background: rgba(139, 92, 246, 0.3); border-color: rgba(167, 139, 250, 0.6); color: #fff !important; }

blockquote {
  border-left: 3px solid var(--rk-accent) !important;
  background: rgba(167, 139, 250, 0.07);
  border-radius: 0 12px 12px 0;
  color: var(--rk-text);
  padding: 14px 20px !important;
}
table, th, td { border-color: var(--rk-border) !important; }
th { background: rgba(167, 139, 250, 0.1); color: var(--rk-heading); }

/* Inline code */
:not(pre) > code {
  font-family: var(--rk-mono);
  font-size: 0.88em;
  padding: 2px 6px;
  border-radius: 6px;
  background: rgba(167, 139, 250, 0.14);
  color: #ddd6fe;
}

/* ---------- Code blocks ---------- */
pre.wp-block-code,
pre.wp-block-preformatted,
.entry-content pre {
  position: relative;
  margin: 1.6em 0;
  padding: 44px 0 0 !important;
  background: var(--rk-code-bg) !important;
  border: 1px solid var(--rk-border);
  border-radius: 14px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  overflow: hidden;
  color: #e4e0f5;
  font-family: var(--rk-mono) !important;
}
/* window-style top bar */
.entry-content pre::before {
  content: "";
  position: absolute;
  top: 16px; left: 16px;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #ff5f57;
  box-shadow: 16px 0 0 #febc2e, 32px 0 0 #28c840;
  opacity: .85;
}
.entry-content pre > code,
.entry-content pre > code.hljs {
  display: block;
  padding: 4px 20px 18px !important;
  background: transparent !important;
  overflow-x: auto;
  font-family: var(--rk-mono) !important;
  font-size: 14px !important;
  line-height: 1.65 !important;
  white-space: pre;
  tab-size: 4;
}
.rk-code-lang {
  position: absolute;
  top: 11px; left: 72px;
  font: 500 11px/20px var(--rk-mono);
  color: var(--rk-muted);
  text-transform: lowercase;
  letter-spacing: .04em;
}
.rk-copy-btn {
  position: absolute;
  top: 8px; right: 10px;
  padding: 3px 12px;
  font: 600 12px/20px var(--rk-sans);
  color: #c4b5fd;
  background: rgba(139, 92, 246, 0.16);
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: 8px;
  cursor: pointer;
  transition: background .2s ease, color .2s ease;
}
.rk-copy-btn:hover { background: rgba(139, 92, 246, 0.32); color: #fff; }
.rk-copy-btn.is-copied { color: #6ee7b7; border-color: rgba(110, 231, 183, 0.5); background: rgba(16, 185, 129, 0.14); }

/* Softer, on-brand syntax colours on top of the highlight.js base theme */
.hljs-keyword, .hljs-selector-tag, .hljs-built_in { color: #c4b5fd !important; }
.hljs-string, .hljs-attr + .hljs-string { color: #86efac !important; }
.hljs-title, .hljs-title.function_, .hljs-section { color: #f0abfc !important; }
.hljs-number, .hljs-literal { color: #fdba74 !important; }
.hljs-comment, .hljs-quote { color: #7c6d9a !important; font-style: italic; }
.hljs-attr, .hljs-variable, .hljs-template-variable, .hljs-params { color: #93c5fd !important; }

/* ---------- Sidebar ---------- */
.sidebar .widget ul li { border-color: var(--rk-border) !important; }
.sidebar .widget a { color: #c4b5fd; }
.sidebar .widget a:hover { color: var(--rk-accent-2); }
.widget-title { font-size: 15px !important; text-transform: uppercase; letter-spacing: .12em !important; color: var(--rk-muted) !important; }

/* ---------- Forms (search, comments) ---------- */
input[type="text"], input[type="email"], input[type="url"], input[type="search"], textarea, select,
.search-field {
  background: rgba(255, 255, 255, 0.05) !important;
  border: 1px solid var(--rk-border) !important;
  border-radius: 10px !important;
  color: var(--rk-text) !important;
}
input:focus, textarea:focus, .search-field:focus {
  border-color: var(--rk-border-accent) !important;
  outline: none;
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.18);
}
::placeholder { color: var(--rk-muted) !important; opacity: 1; }
button, input[type="submit"], .search-submit, .wp-block-button__link {
  background: linear-gradient(135deg, #8b5cf6 0%, #c026d3 100%) !important;
  border: 0 !important;
  border-radius: 10px !important;
  color: #fff !important;
}
button:hover, input[type="submit"]:hover, .search-submit:hover { filter: brightness(1.12); }
.main-navigation .menu-toggle {
  background: rgba(139, 92, 246, 0.16) !important;
  border: 1px solid rgba(167, 139, 250, 0.3) !important;
  color: #c4b5fd !important;
}
.main-navigation .menu-toggle:hover { background: rgba(139, 92, 246, 0.3) !important; filter: none; }
.rk-copy-btn { background: rgba(139, 92, 246, 0.16) !important; border: 1px solid rgba(167, 139, 250, 0.3) !important; border-radius: 8px !important; color: #c4b5fd !important; }
.rk-copy-btn:hover { background: rgba(139, 92, 246, 0.32) !important; color: #fff !important; filter: none; }
.rk-copy-btn.is-copied { color: #6ee7b7 !important; border-color: rgba(110, 231, 183, 0.5) !important; background: rgba(16, 185, 129, 0.14) !important; }

/* ---------- Pagination ---------- */
.nav-links .page-numbers {
  display: inline-block;
  min-width: 36px;
  padding: 4px 10px;
  margin: 0 2px;
  text-align: center;
  border-radius: 10px;
  border: 1px solid var(--rk-border);
  color: var(--rk-muted);
}
.nav-links .page-numbers.current,
.nav-links a.page-numbers:hover {
  color: #fff;
  border-color: var(--rk-border-accent);
  background: rgba(139, 92, 246, 0.25);
}
.nav-links .page-numbers.dots { border: 0; }

/* ---------- Comments ---------- */
.comment-author, .comment-author a, .comments-title, .comment-reply-title { color: var(--rk-heading) !important; }
.comment-body { border-color: var(--rk-border) !important; }
.depth-1.parent > .children { border-color: var(--rk-border) !important; }

/* ---------- Footer ---------- */
.site-footer, .site-info, .inside-site-info {
  background: transparent !important;
  color: var(--rk-muted) !important;
  border-top: 1px solid var(--rk-border);
}
.site-info a { color: var(--rk-accent) !important; }

/* Back-to-top button */
a.generate-back-to-top { background: rgba(139, 92, 246, 0.5) !important; color: #fff !important; border-radius: 10px; }

/* ---------- Preview badge (only rendered in preview mode) ---------- */
.rk-preview-badge {
  position: fixed;
  left: 16px; bottom: 16px;
  z-index: 9999;
  padding: 6px 14px;
  font: 600 12px/1.4 var(--rk-sans);
  color: #fff;
  background: linear-gradient(135deg, #8b5cf6, #c026d3);
  border-radius: 999px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  text-decoration: none !important;
}
.rk-preview-badge:hover { color: #fff; filter: brightness(1.1); }

@media (max-width: 768px) {
  .entry-content, .entry-summary { font-size: 16px; }
  .entry-content pre > code { font-size: 13px !important; }
}
