/* =========================================================
   Midnight Bold — scottsauber.com (Nucleare theme)
   Replace ALL existing Additional CSS with this file.
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --bg:           #0a1628;
  --bg-2:         #0d1c33;
  --surface:      #0f1f38;
  --surface-2:    #13284a;
  --border:       #1b2c46;
  --brand:        #4da3ff;
  --brand-2:      #1e88e5;
  --brand-deep:   #1069b6;
  --text:         #ffffff;
  --text-body:    #c9d6e6;
  --text-muted:   #8aa4c4;
  --radius:       16px;
  --font:         Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono:         Monaco, Consolas, "Andale Mono", "DejaVu Sans Mono", monospace;
}

/* --- Base --- */
html, body, body.custom-background {
  background: var(--bg) !important;
}
body {
  color: var(--text-body);
  font-family: var(--font) !important;
  -webkit-font-smoothing: antialiased;
}
body button, body input, body select, body textarea,
.wf-active body, .wf-active h1, .wf-active h2, .wf-active h3,
.wf-active h4, .wf-active h5, .wf-active h6,
.wf-active .site-title, .wf-active .entry-title, .wf-active .widget-title,
.wf-active .site-description {
  font-family: var(--font) !important;
}
h1, h2, h3, h4, h5, h6 { color: var(--text); font-weight: 700 !important; letter-spacing: -0.01em; }

a, .entry-title a:hover, .entry-title a:focus { color: var(--brand); transition: color .2s ease; }
a:hover, a:focus { color: #8cc4ff; }

::selection { background: var(--brand-deep); color: #fff; }

/* --- Layout widths (kept from old CSS) --- */
.navigation-block, .site-branding, .site-content { max-width: 1340px; }
.site-content { position: relative; z-index: 2; }

/* --- Navigation bar --- */
.navigation-bar {
  background: rgba(10, 22, 40, .85) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  box-shadow: none;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.main-navigation a,
.main-navigation ul li a {
  color: var(--text-muted) !important;
  font-weight: 500;
}
.main-navigation a:hover,
.main-navigation a:focus,
.main-navigation .current_page_item > a,
.main-navigation .current-menu-item > a {
  color: #fff !important;
}
.main-navigation li,
.current_page_item { background: transparent !important; }
.main-navigation .current_page_item > a { box-shadow: inset 0 -2px 0 var(--brand); }
.main-navigation ul ul { background: var(--surface) !important; border: 1px solid var(--border); }
.main-navigation div > ul > li > ul:before { border-bottom-color: var(--border) !important; }
.menu-toggle, .menu-toggle:hover, .menu-toggle:focus { background: var(--surface) !important; color: #fff !important; }

.social-links .top-search,
.social-links .top-search a {
  background: transparent !important;
  color: var(--text-muted) !important;
  border-left: 1px solid var(--border);
}
.social-links .top-search:hover { color: #fff !important; }
.search-full, .search-container { background: var(--bg-2) !important; }

/* --- Header → hero --- */
.site-header {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  margin: 0 auto 2em;
  padding: 0;
  position: relative;
  overflow: visible;
}
.site-branding {
  position: relative;
  text-align: left !important;
  padding: 80px 24px 56px !important;
  margin: 0 auto;
}
.site-branding::before {
  content: "Microsoft MVP · Speaker · Developer";
  position: relative;
  z-index: 1;
  display: block;
  color: var(--brand);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.site-branding::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(77, 163, 255, .35) 1px, transparent 1.5px);
  background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,.9), transparent 90%);
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.9), transparent 90%);
  pointer-events: none;
  z-index: 0;
}
.site-title {
  position: relative;
  z-index: 1;
  font-size: clamp(40px, 6vw, 68px) !important;
  line-height: 1.05 !important;
  font-weight: 800 !important;
  margin: 0;
}
.site-title a {
  color: #ffffff !important;
}
.site-title a:hover,
.site-title a:focus {
  color: var(--brand) !important;
}
.site-description {
  position: relative;
  z-index: 1;
  color: var(--text-muted) !important;
  font-size: clamp(16px, 2vw, 20px) !important;
  margin-top: 18px !important;
  max-width: 680px;
  text-align: left !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
}

/* Hide the hero on single posts/pages so content comes first */
body:not(.home) .site-branding { padding: 40px 24px 20px !important; }
body:not(.home) .site-branding::before,
body:not(.home) .site-description { display: none; }
body:not(.home) .site-title { font-size: 28px !important; }

/* --- Post cards --- */
.post, .hentry, .page {
  background: var(--surface) !important;
  border: 1px solid var(--border) !important;
  border-radius: var(--radius) !important;
  box-shadow: none !important;
  overflow: hidden;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.blog .hentry:hover,
.archive .hentry:hover,
.search .hentry:hover {
  transform: translateY(-3px);
  border-color: #2a4a75 !important;
  box-shadow: 0 18px 40px rgba(0, 0, 0, .35), 0 0 0 1px rgba(77, 163, 255, .15) !important;
}
.home.blog .site-main > .hentry:first-of-type {
  background: linear-gradient(160deg, #123a66 0%, var(--surface) 70%) !important;
  border-color: #24456f !important;
}
.home.blog .site-main > .hentry:first-of-type .entry-title { font-size: clamp(26px, 3vw, 34px) !important; }

.entry-title,
.entry-title a,
h2 span,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
  color: var(--text) !important;
  font-weight: 700 !important;
}
.entry-title a:hover { color: var(--brand) !important; }

/* Legacy "fake headings": paragraphs with inline brand-blue color in older posts */
.entry-content p[style*="#0f69b6" i],
.entry-content p[style*="#1069b6" i],
.entry-content p[style*="#1271c3" i],
.entry-content p[style*="rgb(15, 105, 182)"] {
  color: #fff !important;
  font-weight: 700;
  font-size: 22px !important;
  line-height: 1.35;
  letter-spacing: -0.01em;
  margin: 1.8em 0 .7em;
  padding-left: .7em;
  border-left: 3px solid var(--brand);
}
.entry-content span[style*="#0f69b6" i],
.entry-content span[style*="#1069b6" i],
.entry-content span[style*="#1271c3" i] {
  color: var(--brand) !important;
}

.entry-meta, .entry-meta a,
.entry-bottom, .entry-bottom a,
.small-part, .small-part a {
  color: var(--text-muted) !important;
}
.entry-meta .fa, .entry-bottom .fa { color: var(--brand); }

.entry-content, .entry-summary {
  color: var(--text-body) !important;
  line-height: 1.8;
}
.entry-content a { text-decoration: underline; text-decoration-color: rgba(77, 163, 255, .45); text-underline-offset: 3px; }
.entry-content a:hover { text-decoration-color: currentColor; }
.entry-content strong, .entry-content b { color: #fff; }
.entry-content hr { border-color: var(--border); background: var(--border); }
.entry-content img { border-radius: 10px; }

.more-link {
  background: transparent !important;
  color: var(--brand) !important;
  border: 1px solid var(--brand) !important;
  border-radius: 8px;
}
.more-link:hover { background: var(--brand) !important; color: var(--bg) !important; }

/* --- Blockquotes --- */
blockquote, .wp-block-quote {
  border-left: 3px solid var(--brand) !important;
  border-color: var(--brand) !important;
  background: var(--bg-2);
  color: var(--text-body);
  padding: 1em 1.4em;
  border-radius: 0 10px 10px 0;
}

/* --- Inline code & pre --- */
code, kbd, tt {
  color: #9fd0ff;
  background: #0b1a30;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: .9em;
  padding: 2px 6px;
  word-wrap: break-word;
  font-family: var(--mono) !important;
}
pre, .wp-block-code {
  background: #071222 !important;
  color: #dbe6f3;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.2em;
  overflow-x: auto;
}
pre code { background: none; border: 0; padding: 0; }

/* --- GitHub Gist embeds (dark) --- */
.gist .gist-file { border: 1px solid var(--border) !important; border-radius: 12px !important; overflow: hidden; }
.gist .gist-data { background: #071222 !important; border-bottom: 1px solid var(--border) !important; }
.gist .blob-wrapper, .gist .highlight, .gist table, .gist tr, .gist td { background: #071222 !important; border: 0 !important; }
.gist .blob-code, .gist .blob-code-inner { color: #dbe6f3 !important; font-family: var(--mono) !important; }
.gist .blob-num { color: #4b6585 !important; background: #071222 !important; }
.gist .blob-num, .gist .blob-code { padding-top: 0 !important; padding-bottom: 0 !important; line-height: 1.6 !important; font-size: 13px !important; }
.gist .gist-meta { background: var(--surface-2) !important; color: var(--text-muted) !important; }
.gist .gist-meta a { color: var(--brand) !important; }
.gist .pl-k, .gist .pl-kos.pl-k { color: #ff7b72 !important; }
.gist .pl-s, .gist .pl-pds, .gist .pl-s .pl-s1 { color: #a5d6ff !important; }
.gist .pl-c { color: #6e86a6 !important; }
.gist .pl-en, .gist .pl-e { color: #d2a8ff !important; }
.gist .pl-c1, .gist .pl-smi, .gist .pl-v { color: #79c0ff !important; }
.gist .pl-ent { color: #7ee787 !important; }
.gist .pl-s1, .gist .pl-kos, .gist .pl-token { color: #dbe6f3 !important; }

/* --- Tables --- */
.entry-content table, .styled-table { border-collapse: collapse; color: var(--text-body); }
.entry-content th, .entry-content td { border-color: var(--border) !important; }
.styled-table thead { background: var(--brand-deep); color: #fff; }
.styled-table th, .styled-table td { padding: 10px 15px; }
.styled-table tbody tr { border-bottom: 1px solid var(--border); }
.styled-table tbody tr:nth-of-type(even) { background: var(--bg-2); }

/* --- Buttons --- */
button, .button, input[type="button"], input[type="reset"], input[type="submit"],
.wp-block-button__link, .wp-block-file__button, #infinite-handle span {
  background: var(--brand-2) !important;
  color: #fff !important;
  border: 0;
  border-radius: 8px;
  font-weight: 600;
  transition: background .2s ease, transform .15s ease, box-shadow .2s ease;
}
button:hover, .button:hover, input[type="submit"]:hover,
.wp-block-button__link:hover, .wp-block-file__button:hover, #infinite-handle span:hover {
  background: var(--brand) !important;
  color: var(--bg) !important;
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(77, 163, 255, .3);
}
.wp-block-file a:not(.wp-block-file__button) { color: var(--brand); }
.wp-block-file__embed { border-radius: 10px; border: 1px solid var(--border); }

/* --- Forms --- */
input[type="text"], input[type="email"], input[type="url"], input[type="search"],
input[type="password"], textarea, select, .search-field {
  background: var(--bg-2) !important;
  color: #fff !important;
  border: 1px solid var(--border) !important;
  border-radius: 8px;
}
input:focus, textarea:focus, .search-field:focus {
  border-color: var(--brand) !important;
  outline: none;
  box-shadow: 0 0 0 3px rgba(77, 163, 255, .2);
}
.search-submit { color: #fff !important; }

/* --- Sidebar --- */
.widget-area .widget, .widget {
  background: var(--surface) !important;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: none;
  padding: 1.4em;
  margin-bottom: 1.5em;
  color: var(--text-body) !important;
}
.widget-title {
  color: var(--brand) !important;
  font-size: 13px !important;
  letter-spacing: .12em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--border);
  padding-bottom: .7em;
  margin-bottom: 1em;
}
.widget a { color: var(--text-body) !important; }
.widget a:hover, .widget a:focus { color: #fff !important; }
.widget .textwidget a {
  color: var(--brand) !important;
  text-decoration: underline !important;
  text-decoration-color: rgba(77, 163, 255, .5) !important;
  text-underline-offset: 3px;
}
.widget .textwidget a:hover { text-decoration-color: currentColor !important; }
.widget-area .widget li {
  padding: .45em 0 .45em .75em;
  border-left: 2px solid transparent;
  transition: border-color .2s ease;
}
.widget-area .widget li:hover { border-left-color: var(--brand); }
.avatar { border: 2px solid var(--brand); border-radius: 50%; }

/* --- Comments --- */
.comment-body {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1em 1.2em;
}
.comment-author, .comment-author a, .comment-metadata a { color: var(--text-muted) !important; }
.comment-content { color: var(--text-body); }

/* --- Pagination --- */
.paging-navigation a, .post-navigation a, .nav-links a {
  color: var(--brand) !important;
}

/* --- Footer --- */
.site-footer, .site-info {
  background: transparent !important;
  color: #5d7594 !important;
  border-top: 1px solid var(--border);
}
.site-info a { color: var(--text-muted) !important; }
.site-info a:hover { color: #fff !important; }
.to-top, #toTop {
  background: var(--surface-2) !important;
  color: #fff !important;
  border: 1px solid var(--border);
  border-radius: 10px;
}

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: #22406a; border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: var(--brand-deep); }

/* --- Mobile --- */
@media (max-width: 782px) {
  .site-branding { padding: 48px 20px 32px !important; }
  .main-navigation ul { background: var(--bg) !important; }
}

#infinite-footer { display: none !important; }