/*
 * Juniebug Theme for Hugo
 * A modern, bold minimalistic theme for DevOps engineers and system administrators
 */

/* Base styles */
:root {
  --secondary-color: #6C7A89;
  --background-color: #EFEFEF;
  --header-color: black;
  --link-color: #4A6FA5;
  --link-hover-color: #2C3E50;
  --code-bg-color: #ADADAD;
  --header-height: 600px;
  --sidebar-width: 280px;
  --sidebar-bg-color: #f5f5f5;
  --toc-active-color: #4A6FA5;

  --content-width: 90ch;
  --text-width: 70ch;
  --primary-color: #2563eb;
  --text-color: #1f2937;
  --light-gray: #f8fafc;
  --border-color: #e5e7eb;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--background-color);
  color: var(--text-color);
  font-family: "Source Sans Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  font-size: 16px;
}

h1, h2, h3, h4, h5, h6 {
  font-family: "Arvo", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  margin-bottom: 1rem;
  line-height: 1.2;
}

h1 {
  font-size: 2.5rem;
}

h2 {
  font-size: 2rem;
}

h3 {
  font-size: 1.5rem;
}

p {
  margin-bottom: 1.5rem;
}

a {
  color: var(--link-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--link-hover-color);
}

img {
  max-width: 100%;
  height: auto;
}

/*pre {*/
/*  background-color: var(--code-bg-color);*/
/*  border-radius: 3px;*/
/*  border: 1px solid #939393;*/
/*  padding: 1.5em;*/
/*  margin: 15px 0;*/
/*  overflow-x: auto;*/
/*  font-family: "Source Code Pro", -apple-system, BlinkMacSystemFont, "Consolas", Roboto, Helvetica, Arial, sans-serif;*/
/*}*/

/*pre code {*/
/*  padding: 0.125rem 0.3125rem 0.0625rem;*/
/*  border: 0;*/
/*  background-color: transparent !important;*/
/*  font-family: "Source Code Pro", -apple-system, BlinkMacSystemFont, "Consolas", Roboto, Helvetica, Arial, sans-serif;*/
/*  font-weight: 400;*/
/*  color: #0A0A0A;*/
/*}*/

/* Navigation bar */

#topnav {
  z-index: 2;
  position: relative;
  background-color: var(--header-color);

  .container {
    width: 100%;
    max-width: 1300px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1.25rem;
    gap: 1rem;
  }

  .logo img {
    max-height: 44px;
    min-width: 5em;
    margin-top: 0.3em;
  }

  .menu {
    display: flex;
    align-items: center;
    justify-content: space-around;
    flex: 1;
  }

  .menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
  }

  .bar {
    display: block;
    width: 22px;
    height: 2px;
    margin: 5px auto;
    background-color: #fff;
    transition: all 0.3s ease;
  }

  .menu-toggle.active .bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }
  .menu-toggle.active .bar:nth-child(2) {
    opacity: 0;
  }
  .menu-toggle.active .bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .nav-menu {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 0.25rem;
  }

  .nav-item {
    margin-left: 0;
  }

  .nav-link {
    font-family: "Josefin Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-shadow: none;
    padding: 0.5rem 0.85rem;
    border-radius: 6px;
    transition: color 0.2s, background-color 0.2s;
  }

  .nav-link:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
  }

  .has-dropdown {
    position: relative;
  }

  .dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #fff;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    min-width: 200px;
    z-index: 3;
    list-style: none;
    padding: 0.5rem 0;
    margin-top: 0.5rem;
  }

  .has-dropdown:hover .dropdown-menu {
    display: block;
  }

  .dropdown-item {
    margin: 0;
  }

  .dropdown-link {
    display: block;
    padding: 0.5rem 1rem;
    color: var(--text-color);
    text-shadow: none;
    font-family: "Josefin Sans", sans-serif;
    font-size: 0.9rem;
    transition: background-color 0.15s;
  }

  .dropdown-link:hover {
    background-color: #f5f5f5;
  }

  /* Expandable search */
  .search {
    display: flex;
    align-items: center;
  }

  .search-form {
    display: flex;
    align-items: center;
    position: relative;
  }

  .search-input {
    width: 0;
    padding: 0;
    border: none;
    background: transparent;
    color: #fff;
    font-family: "Josefin Sans", sans-serif;
    font-size: 0.9rem;
    outline: none;
    transition: width 0.3s ease, padding 0.3s ease, background-color 0.3s ease;
    border-radius: 6px 0 0 6px;
  }

  .search-form.expanded .search-input {
    width: 200px;
    padding: 0.5rem 0.75rem;
    background-color: rgba(255, 255, 255, 0.15);
  }

  .search-form.expanded .search-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
  }

  .search-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: color 0.2s, background-color 0.2s;
  }

  .search-toggle:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
  }

  .search-form.expanded .search-toggle {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 0 6px 6px 0;
  }

  /* Hide old search button class if any leftover */
  .search-button {
    display: none;
  }
}

/* Header layout setup. */

/* Default setup -> about 25%  50% 25 %, but decided by content width. Content width is 90ch (give or take).
That means that our content is X - content width - X where X is the remaining width divided by 2. So 3 columns.
On our default hero panel, that means that content is located (XYZ) in the Y panel only, and meta info is in the Z.
Since this is our header, perhaps we can bump the content section here up to 110ch? I don't know, just trying something new I guess.
 */
#header {
  display: flex;
  /* flex wrap? check later */
  .info {

  }

}



/* Main Content */
#blogpost, #listing, #introduction {
  background-color: #fff;
  padding: 50px;
  border: 1px solid var(--border-color);
  margin-bottom: 2rem;
  position: relative;
  z-index: 2;
}

#title {
  font-size: 2.1em;
  margin-bottom: 1.5rem;
}

/*#content {*/
/*  line-height: 1.8;*/
/*}*/

/*#content h2 {*/
/*  font-size: 1.4em;*/
/*  font-weight: normal;*/
/*  border-bottom: 1px dotted #D1D1D1;*/
/*  margin-top: 2rem;*/
/*}*/


/* Blog Listing -> most of these are only used on gallery page.*/
#blog-listing, #blog-post-listing-gallery{

  .blog-posts {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
  }

  .blog-post-link {
    display: block;
    color: inherit;
    text-decoration: none;
  }

  .blog-post {
    background-color: #fff;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }

  .blog-post:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  }

  .blog-post-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
  }

  .blog-post-content {
    padding: 1rem;
  }

  .blog-post h2 {
    font-size: 1.4em;
    margin-bottom: 0.5rem;
    color: #65667B;
  }

  .blog-post-description {
    color: #8B8B8B;
    font-size: 0.9em;
  }

  .hero-image {
    min-height: 200px;
  }
  /* TODO cleanup */
  .hero-title {
    background: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0px);
    color: white;
    text-shadow: 1px 0 black, 0 1px black, 1px 0 black, 0 -1px black;
  }
}


/* Responsive */
@media (max-width: 900px) {

  #topnav {
    .menu-toggle {
      display: block;
    }

    .nav-menu {
      position: fixed;
      left: -100%;
      top: 0;
      flex-direction: column;
      background-color: #1a1a2e;
      width: 280px;
      height: 100vh;
      padding-top: 5rem;
      text-align: left;
      transition: left 0.3s ease;
      box-shadow: 4px 0 20px rgba(0, 0, 0, 0.3);
      gap: 0;
      z-index: 10;
    }

    .nav-menu.active {
      left: 0;
    }

    .nav-item {
      margin: 0;
      width: 100%;
    }

    .nav-link {
      display: block;
      color: rgba(255, 255, 255, 0.85);
      font-size: 1rem;
      padding: 0.85rem 1.5rem;
      border-radius: 0;
    }

    .nav-link:hover {
      background-color: rgba(255, 255, 255, 0.08);
    }

    .dropdown-menu {
      position: static;
      display: none;
      width: 100%;
      box-shadow: none;
      border-radius: 0;
      background-color: rgba(0, 0, 0, 0.15);
      padding: 0;
      margin: 0;
    }

    .has-dropdown:hover .dropdown-menu {
      display: none;
    }

    .has-dropdown.active .dropdown-menu {
      display: block;
    }

    .dropdown-link {
      color: rgba(255, 255, 255, 0.7);
      padding: 0.65rem 1.5rem 0.65rem 2.5rem;
      font-size: 0.9rem;
    }

    .dropdown-link:hover {
      background-color: rgba(255, 255, 255, 0.08);
    }
  }

  .footer {
    .footer-content {
      flex-direction: column;
      text-align: center;
    }
  }

  #blogpost, #listing, #introduction {
    padding: 1.5rem;
  }

  .sidebar {
    width: 100%;
    position: static;
    margin-top: 2rem;
    max-height: none;
  }
}


/* EXPERIMENTING WITH LAYOUT */
/* Hero Section */
.hero-section {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr min(var(--content-width), 100%) 1fr;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  position: relative;
  overflow: hidden;
}

.hero-image {
  grid-column: 1 / 3;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><rect fill="%23667eea" width="1200" height="600"/><path fill="%23764ba2" d="M0,300 Q300,100 600,300 T1200,300 L1200,600 L0,600 Z"/><circle fill="rgba(255,255,255,0.1)" cx="200" cy="150" r="80"/><circle fill="rgba(255,255,255,0.1)" cx="800" cy="450" r="120"/><rect fill="rgba(255,255,255,0.05)" x="400" y="200" width="400" height="200" rx="20"/></svg>') center/cover;
  position: relative;
  min-height: var(--header-height);
}

.hero-title {
  position: absolute;
  right: 0;
  bottom: 2rem;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 1.5rem 2rem;
  border-radius: 12px;
  backdrop-filter: blur(10px);
  max-width: calc(var(--content-width) * 0.8);
  margin-right: 2rem;
}

.hero-title h1 {
  font-size: 2.5rem;
  font-weight: bold;
  line-height: 1.2;
  margin-bottom: 0.5rem;
}

.hero-subtitle {
  font-size: 1.1rem;
  opacity: 0.9;
}

.hero-meta {
  grid-column: 3;
  background: rgb(249 249 249);
  backdrop-filter: blur(10px);
  padding: 2rem;
  display: flex;
  flex-direction: column-reverse;
  gap: 1.5rem;
  border-left: 1px solid var(--border-color);
  min-width: 0;
  overflow: hidden;
}

.meta-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.meta-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.meta-value {
  font-weight: 500;
}

.author-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.author-avatar {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary-color), #1d4ed8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  background: var(--light-gray);
  color: var(--primary-color);
  padding: 0.25rem 0.75rem;
  border-radius: 16px;
  font-size: 0.875rem;
  font-weight: 500;
}

.tag:hover {
  color: #fff;
  transition: all 0.4s;
  background-color: #efefef;
}

/* Content Section */
.content-section {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr min(var(--content-width), 100%) 1fr;
  background: rgb(249 249 249);
  position: relative;
}

/*.content-texture {*/
/*  grid-column: 1;*/
/*  background:*/
/*          radial-gradient(circle at 20% 50%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),*/
/*          radial-gradient(circle at 80% 20%, rgba(255, 206, 84, 0.3) 0%, transparent 50%),*/
/*          radial-gradient(circle at 40% 80%, rgba(255, 118, 117, 0.3) 0%, transparent 50%);*/
/*  position: relative;*/
/*}*/

/*.content-texture::before {*/
/*  content: '';*/
/*  position: absolute;*/
/*  inset: 0;*/
/*  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="60" height="60" viewBox="0 0 60 60"><g fill="none" fill-rule="evenodd"><g fill="rgba(0,0,0,0.02)" fill-opacity="0.4"><circle cx="7" cy="7" r="1"/><circle cx="17" cy="17" r="1"/><circle cx="27" cy="27" r="1"/><circle cx="37" cy="37" r="1"/><circle cx="47" cy="47" r="1"/></g></g></svg>') repeat;*/
/*}*/

.content-main {
  grid-column: 2;
  padding: 3rem 2rem;
  background: rgba(255, 255, 255, 0.8);
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
  position: relative;
  min-width: 0;
}

.table-of-contents {
  grid-column: 3;
  padding: 3rem 5rem;
  background: rgb(249 249 249);
  position: sticky;
  top: 80px;
  height: fit-content;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 1;
  display: none;
  min-width: 0;
}

.table-of-contents.toc-visible {
  display: block;
}

.toc-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-color);
}

.toc-list {
  list-style: none;
}

.toc-list li {
  margin-bottom: 0.5rem;
}

.toc-list a {
  color: #6b7280;
  text-decoration: none;
  font-size: 0.9rem;
  display: block;
  padding: 0.25rem 0;
  border-left: 3px solid transparent;
  padding-left: 0.75rem;
  transition: all 0.2s;
}

.toc-list a:hover,
.toc-list a.active {
  color: var(--primary-color);
  border-left-color: var(--primary-color);
  background: rgba(37, 99, 235, 0.05);
}

.article-content {
  font-size: 1.1rem;
  line-height: 1.8;
}

.article-content h2 {
  font-size: 1.8rem;
  margin: 2rem 0 1rem 0;
  color: var(--text-color);
  scroll-margin-top: 100px;
}

.article-content h3 {
  font-size: 1.4rem;
  margin: 1.5rem 0 0.75rem 0;
  color: var(--text-color);
  scroll-margin-top: 100px;
}

.article-content p {
  margin-bottom: 1.5rem;
}

/*.article-content code {*/
/*  background: var(--light-gray);*/
/*  padding: 0.25rem 0.5rem;*/
/*  border-radius: 4px;*/
/*  font-family: "Source Code Pro", -apple-system, BlinkMacSystemFont, "Consolas", Roboto, Helvetica, Arial, sans-serif;*/
/*  font-size: 0.9em;*/
/*}*/

/*.article-content pre {*/
/*  background: #1f2937;*/
/*  color: #f9fafb;*/
/*  padding: 1.5rem;*/
/*  border-radius: 8px;*/
/*  overflow-x: auto;*/
/*  margin: 1.5rem 0;*/
/*  font-family: "Source Code Pro", -apple-system, BlinkMacSystemFont, "Consolas", Roboto, Helvetica, Arial, sans-serif;*/
/*}*/

.article-content a {
  color: var(--primary-color);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-bottom 0.2s;
}

.article-content a:hover {
  border-bottom-color: var(--primary-color);
}

/* Author Section - Currently un-used. */
/*.author-section {*/
/*  grid-column: 1 / -1;*/
/*  display: grid;*/
/*  grid-template-columns: 1fr var(--content-width) 1fr;*/
/*  background: var(--light-gray);*/
/*  border-top: 1px solid var(--border-color);*/
/*}*/

/*.author-block {*/
/*  grid-column: 2;*/
/*  padding: 3rem 2rem;*/
/*  text-align: center;*/
/*}*/

/*.author-card {*/
/*  display: flex;*/
/*  align-items: center;*/
/*  gap: 2rem;*/
/*  background: white;*/
/*  padding: 2rem;*/
/*  border-radius: 16px;*/
/*  box-shadow: var(--shadow);*/
/*  max-width: 600px;*/
/*  margin: 0 auto;*/
/*}*/

/*.author-card .author-avatar {*/
/*  width: 80px;*/
/*  height: 80px;*/
/*  font-size: 1.5rem;*/
/*}*/

/*.author-details h3 {*/
/*  font-size: 1.3rem;*/
/*  margin-bottom: 0.5rem;*/
/*}*/

/*.author-details p {*/
/*  color: #6b7280;*/
/*  line-height: 1.6;*/
/*}*/

/* Navigation Section */
.post-navigation {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr min(var(--content-width), 100%) 1fr;
  background: white;
  border-top: 1px solid var(--border-color);

  .nav-buttons {
    grid-column: 2;
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    gap: 2rem;
  }

  .nav-btn {
    flex: 1;
    padding: 1.5rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.2s;
    box-shadow: var(--shadow);
  }

  .nav-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  }

  .nav-btn-label {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
  }

  .nav-btn-title {
    font-weight: 600;
  }
}

/* Footer */
.footer {
  width: 100%;
  background: #1f2937;
  color: white;
  padding: 3rem 0;

  .footer-content {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
  }
}



/* Intermediate: narrower TOC and meta */
@media (max-width: 1300px) {
  .table-of-contents {
    padding: 2rem 1.5rem;
  }

  .hero-meta {
    padding: 1.5rem;
  }
}

/* Hide hero-meta, hero full width */
@media (max-width: 1024px) {
  .hero-section {
    grid-template-columns: 1fr;
  }

  .hero-image {
    grid-column: 1;
  }

  .hero-meta {
    display: none;
  }
}

/* Hide TOC, content full width */
@media (max-width: 880px) {
  .hero-section {
    grid-template-columns: 1fr;
  }

  .hero-image {
    grid-column: 1;
  }

  .hero-meta {
    display: none;
  }

  .hero-title {
    left: 0;
    right: 0;
    bottom: 0;
    margin-right: 0;
    max-width: none;
    border-radius: 0;
    padding: 1.25rem 1.5rem;
  }

  .hero-title h1 {
    font-size: 2rem;
  }

  .table-of-contents,
  .table-of-contents.toc-visible {
    display: none !important;
  }

  .content-section {
    grid-template-columns: 1fr;
  }

  .content-main {
    grid-column: 1;
    border-left: none;
    border-right: none;
  }
}

/* Small mobile */
@media (max-width: 768px) {
  .hero-title h1 {
    font-size: 1.6rem;
  }

  .hero-subtitle {
    font-size: 0.9rem;
  }

  .article-content {
    max-width: none;
  }

  .author-section,
  .post-navigation {
    grid-template-columns: 1fr;
  }

  .author-block,
  .nav-buttons {
    grid-column: 1;
  }

  .author-card {
    flex-direction: column;
    text-align: center;
  }
}


/* Mobile search width */
@media (max-width: 500px) {
  #topnav .search-form.expanded .search-input {
    width: 140px;
  }
}

/* Footer */
.footer {
  width: 100%;
  background: #1f2937;
  color: white;
  padding: 3rem 0;

  .footer-content {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
  }
}

#blog-post-listing {

  /*.blog-posts-list {*/
  /*  margin: 2rem 0;*/
  /*}*/

  .blog-entry {
    margin: 0.95rem 0;
  }

  .date {
    color: #666;
    font-size: 0.9rem;
    margin-right: 1rem;
  }

  .title {
    text-decoration: none;
    color: #000;
  }


  h2 {
    font-size: 1.25rem;
    border-bottom: 2px solid #6C7A89;
    padding-bottom: 0.5rem;
    margin-bottom: 0.25rem;
    margin-top: 2rem;
    width: 3.5ch;
  }
  .hero-image {
    min-height: 200px;
  }

  /* TODO */
  .hero-title {
    background: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0px);
    color: white;
    text-shadow: 1px 0 black, 0 1px black, 1px 0 black, 0 -1px black;
  }

  .hero-meta {
    flex-direction: column;

    /* This is used to limit the size of for example the RSS feed icon. */
    img {
      max-height: 16px;
    }
  }
}
/* TODO Where do we use this? */
.content-main li {
  margin-left: 1.5rem;
}


#homepage {

  .hero-title {
    max-width: calc(var(--content-width) * 0.5);
    backdrop-filter: none;
    background: none;
  }

  .hero-image {
    min-height: 450px;
  }

  #avatar {
    border-radius: 55%;
    background: peachpuff;
  }

  .socialicons {

    ul {
      /*list-style: none;*/
      display: flex;
      justify-content: center;
      padding: 0;
    }
    li {
      display: inline;
      margin-right: 10px;
    }
    img {
      width: 30px;
      height: 30px;
    }
  }

}

#introduction {
  margin: 0;
  padding: 0;
  display: grid;
  border: 0;

  /* Mobile-first: single column layout */
  grid-template-columns: 1fr;
  grid-template-rows: auto auto auto;
  grid-column-gap: 0px;
  grid-row-gap: 0px;

  /* Hide decorative elements on mobile */
  .accent-image,
  .side {
    display: none;
  }

  /* Avatar and socials as one unit on mobile */
  .avatar {
    background-color: white;
    grid-area: 1 / 1 / 2 / 2;
    padding: 1rem;
    padding-top: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    img {
      border-radius: 32px;
      /*box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);*/
    }
  }

  .socials {
    grid-area: 2 / 1 / 3 / 2;
    padding: 0 1rem 1rem 1rem;

    ul {
      display: flex;
      justify-content: center;
      padding: 0;
      margin: 0;
    }
    li {
      display: inline;
      margin-right: 10px;
    }
    img {
      width: 30px;
      height: 30px;
    }
  }

  .bio {
    grid-area: 3 / 1 / 4 / 2;
    padding: 1rem 2rem 2rem 2rem;
    width: 100%;
    box-sizing: border-box;
    h2 {
      font-size: 1.25rem;
      font-weight: normal;
    }
  }
}

/* Start scaling down avatar earlier */
@media (max-width: 768px) {
  #introduction {
    .avatar {
      transform: scale(0.8);
      padding: 0.8rem;
      padding-top: 1.5rem;
    }
  }
}

/* Medium screens - show avatar alongside bio if there's enough space */
@media (min-width: 640px) {
  #introduction {
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;

    .avatar {
      grid-area: 1 / 1 / 2 / 2;
      align-self: start;
    }

    .socials {
      grid-area: 2 / 1 / 3 / 2;
      padding: 0 1rem 1rem 1rem;
    }

    .bio {
      grid-area: 1 / 2 / 3 / 3;
      padding: 2rem;
    }
  }
}

/* Large screens - full desktop layout */
@media (min-width: 1024px) {
  #introduction {
    grid-template-columns: 1fr 35ch 110ch 1fr;
    grid-template-rows: repeat(2, auto);

    /* Show decorative elements */
    .accent-image,
    .side {
      display: block;
    }

    .accent-image {
      grid-area: 1 / 1 / 3 / 2;
      background-image: url("/img/headers/slate.jpg");
      background-size: cover;
    }

    .avatar {
      margin-top: 1.5rem;
      background-color: white;
      grid-area: 1 / 2 / 2 / 3;
      padding: 1rem;
      padding-top: 2rem;
      display: block; /* Reset flex behavior from mobile */
    }

    .socials {
      grid-area: 2 / 2 / 3 / 3;
      padding: 0; /* Reset mobile padding */
    }

    .bio {
      margin-top: 2rem;
      margin-bottom: 2rem;
      grid-area: 1 / 3 / 3 / 4;
      padding: 2rem;
    }

    .side {
      grid-area: 1 / 4 / 3 / 5;
      background-color: #f9f9f9;
      background-image: url("/img/headers/slate.jpg");
      background-size: cover;
      transform: scaleX(-1);
    }
  }
}

/* Very narrow screens - stack everything and center socials */
@media (max-width: 480px) {
  #introduction {
    .avatar {
      display: none;
    }

    .socials {
      grid-area: 2 / 1 / 3 / 2;
      padding: 1rem;
      text-align: center;
    }

    .bio {
      grid-area: 1 / 1 / 2 / 2;
      padding: 1rem;
    }
  }
}



/* Complete breakout CSS system for Kevin Petit's website */

/*!* Updated sidebar CSS - no backdrop-filter to avoid stacking context *!*/
/*.table-of-contents {*/
/*  grid-column: 3;*/
/*  padding: 3rem 2rem;*/
/*  background: rgb(249 249 249);*/
/*  !* backdrop-filter: blur(10px); *! !* Removed - creates stacking context *!*/
/*  position: static; !* No sticky positioning *!*/
/*  height: fit-content;*/
/*  max-height: calc(100vh - 100px);*/
/*  overflow-y: auto;*/
/*  z-index: 1;*/
/*  border-radius: 8px;*/
/*  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); !* Add shadow for depth instead of blur *!*/
/*}*/

/* Ensure the content-section is positioned for absolute children if using custom sticky */
.content-section {
  position: relative;
}

/* Basic breakout classes */
.breakout-wide {
  width: calc(100% + 20ch); /* Extend 10ch on each side */
  margin-left: -10ch;
  margin-top: 2rem;
  margin-bottom: 2rem;
  padding: 2rem;
  background-color: #ffffff;
  border-radius: 8px;
  border-left: 1px solid #e4e6ea;
  border-right: 1px solid #e4e6ea;
  position: relative;
  z-index: 10;
}

.breakout-medium {
  width: calc(100% + 40ch); /* Extend 20ch on each side */
  margin-left: -20ch;
  margin-top: 2rem;
  margin-bottom: 2rem;
  padding: 2rem;
  background-color: #ffffff;
  border-radius: 8px;
  border-left: 1px solid #d5d5d5;
  border-right: 1px solid #e4e6ea;
  position: relative;
  z-index: 10;
}

.breakout-full {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-top: 3rem;
  margin-bottom: 3rem;
  padding: 3rem 2rem;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  text-align: center;
  position: relative;
  border: 1px solid #e4e6ea;
  z-index: 10;
}

.breakout-left {
  width: calc(100% + 15ch);
  margin-left: -15ch;
  margin-top: 2rem;
  margin-bottom: 2rem;
  display: grid;
  grid-template-columns: 15ch 1fr;
  gap: 2rem;
  align-items: start;
  padding: 2rem;
  background-color: #ffffff;
  border-left: 1px solid #e4e6ea;
  border-radius: 8px;
  position: relative;
  z-index: 10;
}

.breakout-right {
  width: calc(100% + 15ch);
  margin-right: -15ch;
  margin-top: 2rem;
  margin-bottom: 2rem;
  display: grid;
  grid-template-columns: 1fr 15ch;
  gap: 2rem;
  align-items: start;
  padding: 2rem;
  background-color: #ffffff;
  border-right: 1px solid #e4e6ea;  border-radius: 8px;
  position: relative;
  z-index: 10;
}

/* Image styling */
.breakout-image {
  width: 100%;
  height: auto;
  /*border-radius: 8px;*/
  /*box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);*/
  display: block;
}

/* Quote styling */
.breakout-quote {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  padding: 3rem 2rem;
  text-align: center;
  border-left: 4px solid #007acc;
  font-size: 1.25rem;
  font-style: italic;
  line-height: 1.6;
  position: relative;
  border-radius: 8px;
  margin: 2rem 0;
}

.breakout-quote::before {
  content: '"';
  font-size: 4rem;
  color: #007acc;
  position: absolute;
  top: 1rem;
  left: 2rem;
  line-height: 1;
  font-family: Georgia, serif;
}

.breakout-quote cite {
  display: block;
  margin-top: 1rem;
  font-size: 0.9rem;
  font-style: normal;
  color: #666;
  font-weight: 500;
}

/* Video container */
.breakout-video {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.breakout-video iframe,
.breakout-video video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Callout boxes */
.breakout-callout {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 2rem;
  margin: 2rem 0;
  position: relative;
}

.breakout-callout::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: #6c757d;
  border-radius: 8px 0 0 8px;
}

.breakout-callout.info::before {
  background: #007acc;
}

.breakout-callout.info {
  background: #e7f3ff;
  border-color: #007acc;
}

.breakout-callout.warning::before {
  background: #ffc107;
}

.breakout-callout.warning {
  background: #fff3cd;
  border-color: #ffc107;
}

.breakout-callout.success::before {
  background: #28a745;
}

.breakout-callout.success {
  background: #d1edda;
  border-color: #28a745;
}

.breakout-callout h3 {
  margin-top: 0;
  margin-bottom: 1rem;
  color: #495057;
  font-weight: 600;
}

/* Two-column layout */
.breakout-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin: 2rem 0;
}

/* Code blocks */
.breakout-code {
  background: #f8f8f8;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  overflow-x: auto;
  margin: 2rem 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.breakout-code pre {
  margin: 0;
  padding: 1.5rem;
  font-family: 'Monaco', 'Menlo', 'Source Code Pro', monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  /*color: #333;*/
}

/* Gallery */
.breakout-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.breakout-gallery img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease;
}

.breakout-gallery img:hover {
  transform: translateY(-2px);
}

/* Framework comparison grid */
.breakout-framework-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

.framework-card {
  background: white;
  border: 1px solid #e9ecef;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

.framework-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.framework-card h3 {
  margin-top: 0;
  color: #333;
  font-weight: 600;
}

.framework-card .status {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  margin-top: 1rem;
}

.framework-card .status.active {
  background: #d1edda;
  color: #155724;
}

.framework-card .status.deprecated {
  background: #f8d7da;
  color: #721c24;
}

/* Tech stack grid */
.tech-stack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.tech-badge {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease;
}

.tech-badge:hover {
  transform: translateY(-2px);
}

.breakout-terminal {
  background: #1e1e1e;
  color: #00ff00;
  border-radius: 8px;
  padding: 1rem;
  font-family: 'Source Code Pro', 'Monaco', 'Menlo', monospace;
  margin: 2rem 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.terminal-header {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #333;
}

.terminal-dots {
  display: flex;
  gap: 0.5rem;
}

.terminal-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.terminal-dot.red { background: #ff5f56; }
.terminal-dot.yellow { background: #ffbd2e; }
.terminal-dot.green { background: #27ca3f; }

.terminal-title {
  margin-left: 1rem;
  color: #ccc;
  font-size: 0.9rem;
}

.terminal-content {
  color: #00ff00;
  line-height: 1.4;
}

.terminal-prompt {
  color: #888;
  margin-bottom: 0.5rem;
}

/* Timeline */
.breakout-timeline {
  position: relative;
  margin: 3rem 0;
}

.timeline-line {
  position: absolute;
  left: 2rem;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #e0e0e0;
}

.timeline-item {
  position: relative;
  margin-bottom: 2rem;
  padding-left: 5rem;
}

.timeline-dot {
  position: absolute;
  left: 1rem;
  top: 0.5rem;
  width: 1rem;
  height: 1rem;
  background: #007acc;
  border-radius: 50%;
  border: 3px solid white;
  box-shadow: 0 0 0 3px #e0e0e0;
}

.timeline-content {
  background: white;
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.timeline-content h4 {
  margin-top: 0;
  color: #333;
  font-weight: 600;
}

/* Project showcase */
.project-showcase {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 4rem 2rem;
  border-radius: 12px;
  color: white;
  text-align: center;
  margin: 3rem 0;
}

.project-image {
  max-width: 600px;
  width: 100%;
  border-radius: 8px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  margin: 0 auto 2rem auto;
  display: block;
}

.project-title {
  font-size: 2rem;
  margin: 0 0 1rem 0;
  font-weight: 600;
}

.project-description {
  font-size: 1.1rem;
  line-height: 1.6;
  max-width: 600px;
  margin: 0 auto 2rem auto;
}

.project-link {
  display: inline-block;
  padding: 0.75rem 2rem;
  background: rgba(255,255,255,0.2);
  color: white;
  text-decoration: none;
  border-radius: 50px;
  border: 2px solid rgba(255,255,255,0.3);
  transition: all 0.3s ease;
}

.project-link:hover {
  background: rgba(255,255,255,0.3);
  transform: translateY(-2px);
}

/* Performance metrics display */
.performance-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.metric-card {
  text-align: center;
  padding: 2rem 1rem;
  background: #f8f9fa;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
}

.metric-value {
  font-size: 2.5rem;
  font-weight: bold;
  color: #007acc;
  margin-bottom: 0.5rem;
}

.metric-label {
  color: #666;
  font-size: 0.9rem;
}

/* Responsive behavior */
@media (max-width: 880px) {
  .breakout-wide,
  .breakout-medium,
  .breakout-left,
  .breakout-right {
    width: 100%;
    margin-left: 0;
    margin-right: 0;
  }

  .breakout-left,
  .breakout-right {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .breakout-left .breakout-image,
  .breakout-right .breakout-image {
    order: -1;
  }

  .breakout-columns {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .breakout-gallery {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }

  .breakout-framework-grid {
    grid-template-columns: 1fr;
  }

  .tech-stack-grid {
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  }

  .breakout-quote {
    padding: 2rem 1rem;
    font-size: 1.1rem;
  }

  .breakout-quote::before {
    font-size: 3rem;
    top: 0.5rem;
    left: 1rem;
  }

  .breakout-full {
    width: calc(100vw - 2rem);
    margin-left: calc(50% - 50vw + 1rem);
    padding: 2rem 1rem;
  }

  .performance-metrics {
    grid-template-columns: 1fr 1fr;
  }

  .timeline-item {
    padding-left: 4rem;
  }

  .project-showcase {
    padding: 3rem 1rem;
  }

  .project-title {
    font-size: 1.5rem;
  }
}

@media (max-width: 480px) {
  .breakout-callout {
    padding: 1.5rem;
  }

  .breakout-quote {
    padding: 1.5rem 1rem;
    font-size: 1rem;
  }

  .breakout-gallery {
    grid-template-columns: 1fr 1fr;
  }

  .breakout-gallery img {
    height: 150px;
  }

  .framework-card {
    padding: 1.5rem;
  }

  .performance-metrics {
    grid-template-columns: 1fr;
  }

  .metric-value {
    font-size: 2rem;
  }

  .tech-badge {
    padding: 0.75rem;
    font-size: 0.9rem;
  }
}










/* ==========================================================================
   HOMEPAGE
   ========================================================================== */

/* Hero */
.home-hero {
  display: grid;
  grid-template-columns: 1fr min(var(--content-width), 100%) 1fr;
  background: rgb(249, 249, 249);
  position: relative;
  overflow: hidden;
}

.home-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
          radial-gradient(circle at 15% 50%, rgba(37, 99, 235, 0.04) 0%, transparent 50%),
          radial-gradient(circle at 85% 30%, rgba(37, 99, 235, 0.03) 0%, transparent 40%),
          url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23000000' fill-opacity='0.018'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.home-hero-inner {
  grid-column: 2;
  display: flex;
  align-items: center;
  gap: 3rem;
  padding: 4rem 2rem;
  position: relative;
  z-index: 1;
}

.hero-avatar { flex-shrink: 0; }

#home .hero-avatar img {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: peachpuff;
  object-fit: cover;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.hero-text h1 { font-size: 2.4rem; margin-bottom: 0.5rem; }

.hero-tagline {
  font-size: 1.2rem;
  color: var(--secondary-color);
  margin-bottom: 1.25rem;
  line-height: 1.5;
}
.hero-tagline strong { color: var(--text-color); }

/* Dark hero with background image */
.home-hero.has-hero-bg { background: #0f172a; }
.has-hero-bg .hero-text h1 { color: #fff; }
.has-hero-bg .hero-tagline { color: rgba(255,255,255,0.7); }
.has-hero-bg .hero-tagline strong { color: #fff; }
.has-hero-bg .social-links a {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.2);
}
.has-hero-bg .social-links a:hover {
  background: rgba(255,255,255,0.95);
  border-color: rgba(255,255,255,0.95);
}
.has-hero-bg .social-links a:hover img { filter: brightness(0); }
.has-hero-bg .social-links img { filter: brightness(0) invert(1); }

.social-links {
  display: flex;
  gap: 1rem;
  list-style: none;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--background-color);
  border: 1px solid var(--border-color);
  transition: all 0.2s;
}
.social-links a:hover { background: var(--text-color); border-color: var(--text-color); }
.social-links img { width: 18px; height: 18px; }
.social-links a:hover img { filter: brightness(0) invert(1); }

/* Hire bar */
.hire-bar {
  display: grid;
  grid-template-columns: 1fr var(--content-width) 1fr;
  background: var(--text-color);
}

.hire-bar-inner { grid-column: 2; }

.hire-bar-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.9rem 2rem;
  color: white;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  transition: background 0.2s;
  letter-spacing: 0.01em;
}
.hire-bar-link:hover { background: rgba(255,255,255,0.08); color: white; }
.hire-bar-subtle { font-weight: 400; opacity: 0.65; margin-left: 0.25rem; }

/* Home sections */
.home-section {
  display: grid;
  grid-template-columns: 1fr var(--content-width) 1fr;
  background: rgb(249, 249, 249);
}

.home-section-inner {
  grid-column: 2;
  padding: 3rem 2rem;
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.8);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 1.75rem;
}
.section-header h2 { font-size: 1.5rem; }
.section-header a { font-size: 0.95rem; font-weight: 600; }

.section-divider {
  grid-column: 2;
  border: none;
  border-top: 1px solid var(--border-color);
  margin: 0 2rem;
}

/* Post list */
.post-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--border-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
}

.post-item {
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
  padding: 1.1rem 1.25rem;
  background: white;
  transition: background 0.15s;
  text-decoration: none;
  color: inherit;
}
.post-item:hover { background: var(--light-gray); }

.post-date {
  flex-shrink: 0;
  font-size: 0.875rem;
  color: var(--secondary-color);
  font-family: "Source Code Pro", monospace;
  min-width: 10ch;
}

.post-title {
  font-weight: 600;
  color: var(--text-color);
  font-size: 1.05rem;
}
.post-item:hover .post-title { color: var(--primary-color); }

.post-tags {
  display: flex;
  gap: 0.4rem;
  margin-left: auto;
  flex-shrink: 0;
}

.post-tag {
  background: var(--light-gray);
  color: var(--secondary-color);
  padding: 0.15rem 0.6rem;
  border-radius: 12px;
  font-size: 0.78rem;
  font-weight: 500;
}

/* Project grid (homepage) */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.project-card {
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1.5rem;
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
}
.project-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.08); }
.project-card h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }
.project-card p { font-size: 0.95rem; color: var(--secondary-color); line-height: 1.5; flex-grow: 1; margin-bottom: 1rem; }

.project-tech { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.project-tech span {
  background: var(--light-gray);
  border: 1px solid var(--border-color);
  color: var(--secondary-color);
  padding: 0.15rem 0.6rem;
  border-radius: 4px;
  font-size: 0.78rem;
  font-family: "Source Code Pro", monospace;
}

/* Parks teaser */
.parks-teaser {
  display: flex;
  align-items: center;
  gap: 2rem;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1.75rem;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
  color: inherit;
}
.parks-teaser:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.08); }

.parks-teaser-stack {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.parks-emoji { font-size: 3rem; flex-shrink: 0; line-height: 1; }
.parks-text h3 { font-size: 1.15rem; margin-bottom: 0.35rem; }
.parks-text p { color: var(--secondary-color); font-size: 0.95rem; margin-bottom: 0.5rem; }
.parks-stats { display: flex; gap: 1.5rem; font-size: 0.85rem; }
.parks-stats span { color: var(--secondary-color); }
.parks-stats strong { color: var(--text-color); }

/* Homepage responsive */
@media (max-width: 768px) {
  .home-hero, .hire-bar, .home-section { grid-template-columns: 1fr; }

  .home-hero-inner {
    grid-column: 1; flex-direction: column; text-align: center;
    padding: 2.5rem 1.5rem; gap: 1.5rem;
  }
  .social-links { justify-content: center; }
  .hire-bar-inner { grid-column: 1; }

  .home-section-inner {
    grid-column: 1; border-left: none; border-right: none; padding: 2rem 1.5rem;
  }
  .section-divider { grid-column: 1; }

  .post-item { flex-direction: column; gap: 0.25rem; }
  .post-tags { margin-left: 0; margin-top: 0.5rem; }
  .project-grid { grid-template-columns: 1fr; }
  .parks-teaser { flex-direction: column; text-align: center; }
  .parks-stats { justify-content: center; }
  .hero-text h1 { font-size: 1.8rem; }
}


/* ==========================================================================
   PAGE HEADER WITH MUTED BACKGROUND
   ========================================================================== */

.page-header-muted {
  display: grid;
  grid-template-columns: 1fr var(--content-width) 1fr;
  background: rgb(249, 249, 249);
  border-bottom: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
}

.page-header-muted::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
          radial-gradient(circle at 15% 50%, rgba(37, 99, 235, 0.04) 0%, transparent 50%),
          radial-gradient(circle at 85% 30%, rgba(37, 99, 235, 0.03) 0%, transparent 40%),
          url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23000000' fill-opacity='0.018'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.page-header-inner {
  grid-column: 2;
  padding: 3rem 2rem 2.5rem;
  position: relative;
  z-index: 1;
}

.page-header-inner h1 { font-size: 2.2rem; margin-bottom: 0.4rem; }
.page-description { font-size: 1.1rem; color: var(--secondary-color); max-width: 60ch; }

/* Page content area (shared) */
.page-content {
  display: grid;
  grid-template-columns: 1fr var(--content-width) 1fr;
  background: rgb(249, 249, 249);
}

.page-main {
  grid-column: 2;
  padding: 3rem 2rem;
  background: rgba(255, 255, 255, 0.8);
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
}

@media (max-width: 768px) {
  .page-header-muted, .page-content { grid-template-columns: 1fr; }
  .page-header-inner { grid-column: 1; padding: 2rem 1.5rem; }
  .page-main { grid-column: 1; padding: 2rem 1.5rem; border: none; }
}


/* ==========================================================================
   RESUME
   ========================================================================== */

.resume-header {
  display: grid;
  grid-template-columns: 1fr var(--content-width) 1fr;
  background: rgb(249, 249, 249);
  border-bottom: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
}

.resume-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
          radial-gradient(circle at 15% 50%, rgba(37, 99, 235, 0.04) 0%, transparent 50%),
          radial-gradient(circle at 85% 30%, rgba(37, 99, 235, 0.03) 0%, transparent 40%),
          url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23000000' fill-opacity='0.018'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.resume-header-inner {
  grid-column: 2;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
  padding: 3rem 2rem;
  position: relative;
  z-index: 1;
}

.resume-identity h1 { font-size: 2.2rem; margin-bottom: 0.25rem; }
.resume-role { font-size: 1.2rem; color: var(--secondary-color); margin-bottom: 0.75rem; }
.resume-summary { font-size: 1.05rem; line-height: 1.6; max-width: 55ch; color: #4b5563; }

.resume-meta {
  flex-shrink: 0; text-align: right;
  display: flex; flex-direction: column; gap: 0.5rem;
}
.resume-meta-item { font-size: 0.9rem; color: var(--secondary-color); }
.resume-meta-item a { color: var(--text-color); font-weight: 600; }

.pdf-download {
  display: inline-flex; align-items: center; gap: 0.5rem;
  margin-top: 0.5rem; padding: 0.6rem 1.25rem;
  background: var(--text-color); color: white;
  border-radius: 6px; font-weight: 600; font-size: 0.9rem;
  transition: background 0.2s;
}
.pdf-download:hover { background: var(--primary-color); color: white; }

.resume-content {
  display: grid;
  grid-template-columns: 1fr var(--content-width) 1fr;
  background: rgb(249, 249, 249);
}

.resume-main {
  grid-column: 2;
  padding: 0 2rem 3rem;
  background: rgba(255, 255, 255, 0.8);
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
}

.resume-section {
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border-color);
}
.resume-section:last-child { border-bottom: none; }
.resume-section h2 { font-size: 1.5rem; margin-bottom: 1.5rem; }

/* Experience cards */
.experience-card {
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  margin-bottom: 1.25rem;
  overflow: hidden;
  transition: box-shadow 0.2s;
}
.experience-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.06); }
.experience-card:last-child { margin-bottom: 0; }

.exp-header {
  display: flex; align-items: center; gap: 1.25rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--light-gray);
}

.exp-indicator {
  width: 10px; height: 10px; border-radius: 50%;
  flex-shrink: 0; background: var(--border-color);
}
.exp-indicator.current {
  background: var(--primary-color);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
}

.exp-header-text { flex-grow: 1; }
.exp-company-row { display: flex; align-items: baseline; gap: 0.75rem; flex-wrap: wrap; }
.exp-company { font-family: "Arvo", serif; font-size: 1.15rem; font-weight: 700; }
.exp-title { font-size: 0.95rem; color: var(--secondary-color); }
.exp-period {
  font-size: 0.82rem; font-family: "Source Code Pro", monospace;
  color: var(--secondary-color); margin-left: auto; flex-shrink: 0;
}

.exp-body { padding: 1.25rem 1.5rem; }
.exp-description { font-size: 0.98rem; line-height: 1.7; color: #4b5563; margin-bottom: 1rem; }
.exp-description:last-child { margin-bottom: 0; }

.exp-tech-used { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.tech-pill {
  display: inline-flex; align-items: center; gap: 0.35rem;
  background: var(--light-gray); border: 1px solid var(--border-color);
  border-radius: 6px; padding: 0.25rem 0.65rem;
  font-size: 0.82rem; font-weight: 500; color: var(--text-color);
  transition: all 0.15s;
}
.tech-pill:hover { background: #dbeafe; border-color: #93c5fd; }

/* Tools grid */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
}

.tool-card {
  display: flex; align-items: center; gap: 0.75rem;
  background: white; border: 1px solid var(--border-color);
  border-radius: 8px; padding: 0.85rem 1rem;
  transition: all 0.15s;
}
.tool-card:hover {
  border-color: var(--primary-color);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.08);
  transform: translateY(-1px);
}

.tool-icon-fallback {
  width: 24px; height: 24px; border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; font-weight: 700; color: white; flex-shrink: 0;
}

.tool-name { font-size: 0.9rem; font-weight: 600; color: var(--text-color); }
.tool-level { font-size: 0.72rem; color: var(--secondary-color); display: block; font-weight: 400; }

.skill-category-header {
  font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--secondary-color); font-weight: 700;
  margin-top: 1.75rem; margin-bottom: 0.75rem;
  font-family: "Source Sans Pro", sans-serif;
}
.skill-category-header:first-child { margin-top: 0; }

/* Resume projects */
.resume-project-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }

.resume-project {
  background: white; border: 1px solid var(--border-color);
  border-radius: 8px; padding: 1.25rem;
  transition: transform 0.15s, box-shadow 0.15s;
}
.resume-project:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
.resume-project h3 { font-size: 1rem; margin-bottom: 0.3rem; }
.resume-project p { font-size: 0.88rem; color: #4b5563; line-height: 1.5; margin-bottom: 0.65rem; }
.resume-project .exp-tech-used { gap: 0.35rem; }
.resume-project .tech-pill { font-size: 0.75rem; padding: 0.2rem 0.55rem; }

/* Languages */
.languages-row { display: flex; gap: 2.5rem; flex-wrap: wrap; }
.language-item { display: flex; align-items: center; gap: 0.75rem; }
.language-name { font-weight: 600; min-width: 6ch; }
.language-level { display: flex; gap: 3px; }
.language-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--border-color); }
.language-dot.filled { background: var(--primary-color); }
.language-label { font-size: 0.85rem; color: var(--secondary-color); margin-left: 0.5rem; }

/* Education */
.education-list { display: flex; flex-direction: column; gap: 1rem; }
.education-item { display: flex; gap: 1.5rem; align-items: baseline; }
.education-year {
  font-family: "Source Code Pro", monospace; font-size: 0.85rem;
  color: var(--secondary-color); min-width: 10ch; flex-shrink: 0;
}
.education-details h3 {
  font-size: 1rem; font-family: "Source Sans Pro", sans-serif;
  font-weight: 600; margin-bottom: 0.1rem;
}
.education-school { font-size: 0.9rem; color: var(--secondary-color); }

/* Resume responsive */
@media (max-width: 768px) {
  .resume-header, .resume-content { grid-template-columns: 1fr; }
  .resume-header-inner { grid-column: 1; flex-direction: column; padding: 2rem 1.5rem; }
  .resume-meta { text-align: left; }
  .resume-main { grid-column: 1; border: none; padding: 0 1.5rem 2rem; }
  .tools-grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  .resume-project-grid { grid-template-columns: 1fr; }
  .exp-header { flex-wrap: wrap; }
  .exp-period { margin-left: 0; width: 100%; margin-top: 0.25rem; }
  .education-item { flex-direction: column; gap: 0.25rem; }
  .languages-row { flex-direction: column; gap: 1rem; }
}


/* ==========================================================================
   PROJECTS LISTING
   ========================================================================== */

.category-label {
  font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--secondary-color); font-weight: 700;
  margin-bottom: 1.25rem; margin-top: 2.5rem;
  padding-bottom: 0.5rem; border-bottom: 2px solid var(--border-color);
}
.category-label:first-child { margin-top: 0; }

.project-detailed {
  background: white; border: 1px solid var(--border-color);
  border-radius: 10px; margin-bottom: 2rem;
  overflow: hidden; transition: box-shadow 0.2s;
}
.project-detailed:hover { box-shadow: 0 4px 20px rgba(0,0,0,0.06); }
.project-detailed:last-child { margin-bottom: 0; }

.project-top {
  display: flex; align-items: flex-start;
  justify-content: space-between; gap: 1.5rem;
  padding: 1.5rem 1.75rem 0;
}
.project-title-area h2 { font-size: 1.35rem; margin-bottom: 0.15rem; }
.project-one-liner { font-size: 1.05rem; color: var(--secondary-color); }

.project-status {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.3rem 0.85rem; border-radius: 20px;
  font-size: 0.78rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.04em;
  flex-shrink: 0; white-space: nowrap;
}
.project-status.active { background: #dcfce7; color: #166534; }
.project-status.active::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #22c55e; }
.project-status.maintained { background: #dbeafe; color: #1e40af; }
.project-status.maintained::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #3b82f6; }
.project-status.side-project { background: #fef3c7; color: #92400e; }

.project-body { padding: 1rem 1.75rem 1.5rem; }
.project-detailed .project-description {
  font-size: 1rem; line-height: 1.7; color: #4b5563; margin-bottom: 1.25rem;
}

.project-highlights { display: flex; gap: 2rem; margin-bottom: 1.25rem; flex-wrap: wrap; }
.highlight { display: flex; flex-direction: column; }
.highlight-value {
  font-family: "Arvo", serif; font-size: 1.4rem; font-weight: 700;
  color: var(--primary-color); line-height: 1.2;
}
.highlight-label { font-size: 0.8rem; color: var(--secondary-color); }

.project-footer {
  display: flex; justify-content: space-between;
  align-items: flex-end; gap: 1rem; flex-wrap: wrap;
}
.project-tech-pills { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.project-links { display: flex; gap: 0.75rem; }

.project-ext-link {
  display: inline-flex; align-items: center; gap: 0.4rem;
  font-size: 0.9rem; font-weight: 600; color: var(--primary-color);
  padding: 0.35rem 0; border-bottom: 1px solid transparent;
  transition: border-bottom-color 0.2s;
}
.project-ext-link:hover { border-bottom-color: var(--primary-color); color: var(--primary-color); }
.project-ext-link svg {
  stroke: currentColor; fill: none;
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}

@media (max-width: 768px) {
  .project-top { flex-direction: column; gap: 0.75rem; }
  .project-highlights { gap: 1.25rem; }
  .project-footer { flex-direction: column; }
}


/* ==========================================================================
   THEME PARKS RETROSPECTIVE SHORTCODES
   ========================================================================== */

/* Stats bar */
.retro-stats-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 1px;
  background: var(--border-color);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  overflow: hidden;
  margin: 2rem 0;
}

.retro-stat {
  flex: 1;
  min-width: 100px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 1rem;
  background: white;
  text-align: center;
}

.retro-stat-value {
  font-family: "Arvo", serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary-color);
  line-height: 1.1;
}

.retro-stat-label {
  font-size: 0.82rem;
  color: var(--secondary-color);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
  margin-top: 0.25rem;
}

/* When stats bar is the first element in a blog post, overlap the header */
.article-content > .retro-stats-bar:first-child {
  margin: -3rem -2rem 2rem -2rem;
  border-radius: 0;
  border-top: none;
  border-left: none;
  border-right: none;
  position: relative;
  z-index: 10;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

@media (max-width: 600px) {
  .retro-stats-bar { flex-direction: column; }
  .retro-stat {
    flex-direction: row;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem;
  }
  .retro-stat-value { font-size: 1.5rem; }
  .article-content > .retro-stats-bar:first-child {
    margin: -3rem -1rem 1.5rem -1rem;
  }
}

/* CSS Bar Chart */
.retro-chart {
  margin: 2rem 0;
}

.retro-chart-title {
  font-size: 1.2rem;
  margin-bottom: 1.25rem;
}

.retro-chart-bars {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.retro-bar-row {
  display: grid;
  grid-template-columns: minmax(120px, 180px) 1fr auto;
  align-items: center;
  gap: 1rem;
}

.retro-bar-label {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-color);
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.retro-bar-track {
  height: 28px;
  background: var(--light-gray);
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.retro-bar-fill {
  height: 100%;
  border-radius: 5px;
  transition: width 0.6s ease;
  min-width: 3px;
}

.retro-bar-value {
  font-size: 0.88rem;
  font-weight: 700;
  font-family: "Source Code Pro", monospace;
  color: var(--text-color);
  min-width: 5ch;
  text-align: right;
}

@media (max-width: 600px) {
  .retro-bar-row {
    grid-template-columns: 1fr auto;
    gap: 0.5rem;
  }
  .retro-bar-label {
    grid-column: 1 / -1;
    text-align: left;
    margin-bottom: -0.25rem;
  }
  .retro-bar-track { height: 22px; }
}

/* Park Cards */
.retro-park-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 0.75rem;
  margin: 2rem 0;
}

.retro-park-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  transition: transform 0.15s, box-shadow 0.15s;
}

.retro-park-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.retro-park-card.new {
  border-left: 3px solid var(--primary-color);
}

.retro-park-flag {
  font-size: 1.8rem;
  line-height: 1;
  flex-shrink: 0;
}

.retro-park-info {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  min-width: 0;
}

.retro-park-name {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-color);
}

.retro-park-detail {
  font-size: 0.82rem;
  color: var(--secondary-color);
}

.retro-park-badge {
  background: var(--primary-color);
  color: white;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  flex-shrink: 0;
}

@media (max-width: 600px) {
  .retro-park-cards { grid-template-columns: 1fr; }
}

/* Ranking List */
.retro-ranking {
  margin: 2rem 0;
}

.retro-ranking-title {
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

.retro-ranking-cards {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.retro-ranking-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  transition: transform 0.15s;
}

.retro-ranking-card:hover { transform: translateX(4px); }

.retro-rank-number {
  font-family: "Arvo", serif;
  font-size: 1.2rem;
  font-weight: 700;
  min-width: 2.5ch;
  flex-shrink: 0;
}

.retro-rank-info { display: flex; flex-direction: column; }
.retro-rank-name { font-weight: 600; font-size: 1.05rem; color: var(--text-color); }
.retro-rank-note { font-size: 0.85rem; color: var(--secondary-color); }

/* Best variant: gold/silver/bronze */
.retro-ranking.best .rank-1 { border-left: 4px solid #f59e0b; background: #fffbeb; }
.retro-ranking.best .rank-1 .retro-rank-number { color: #d97706; }
.retro-ranking.best .rank-2 { border-left: 4px solid #9ca3af; background: #f9fafb; }
.retro-ranking.best .rank-2 .retro-rank-number { color: #6b7280; }
.retro-ranking.best .rank-3 { border-left: 4px solid #d97706; background: #fffbeb; }
.retro-ranking.best .rank-3 .retro-rank-number { color: #92400e; }

/* Worst variant: red tones */
.retro-ranking.worst .rank-1 { border-left: 4px solid #ef4444; background: #fef2f2; }
.retro-ranking.worst .rank-1 .retro-rank-number { color: #dc2626; }
.retro-ranking.worst .rank-2 { border-left: 4px solid #f87171; background: #fef2f2; }
.retro-ranking.worst .rank-2 .retro-rank-number { color: #ef4444; }
.retro-ranking.worst .rank-3 { border-left: 4px solid #fca5a5; background: #fff5f5; }
.retro-ranking.worst .rank-3 .retro-rank-number { color: #f87171; }

/* Ride Accordion */
.retro-accordion {
  margin: 0.5rem 0;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
  background: white;
}

.retro-accordion + .retro-accordion {
  margin-top: -1px;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

.retro-accordion:first-of-type {
  border-radius: 8px 8px 0 0;
}

.retro-accordion:last-of-type {
  border-radius: 0 0 8px 8px;
}

.retro-accordion:only-of-type {
  border-radius: 8px;
}

/* Reset margin for stacked accordions */
.retro-accordion + .retro-accordion { margin-top: 0; }

.retro-accordion-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  cursor: pointer;
  user-select: none;
  list-style: none; /* remove default marker */
  transition: background 0.15s;
}

.retro-accordion-header:hover { background: var(--light-gray); }

/* Hide default marker in all browsers */
.retro-accordion-header::-webkit-details-marker { display: none; }
.retro-accordion-header::marker { display: none; content: ""; }

.retro-accordion-title {
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--text-color);
  flex-grow: 1;
}

.retro-accordion-count {
  font-size: 0.82rem;
  color: var(--secondary-color);
  font-family: "Source Code Pro", monospace;
  flex-shrink: 0;
}

.retro-accordion-chevron {
  flex-shrink: 0;
  color: var(--secondary-color);
  transition: transform 0.2s;
}

.retro-accordion[open] .retro-accordion-chevron {
  transform: rotate(180deg);
}

.retro-accordion-body {
  padding: 0 1.25rem 1.25rem;
  border-top: 1px solid var(--border-color);
}

.retro-ride-list {
  list-style: none;
  padding: 0;
  margin: 0;
  columns: 2;
  column-gap: 2rem;
}

.retro-ride {
  padding: 0.35rem 0;
  font-size: 0.92rem;
  color: #4b5563;
  break-inside: avoid;
}

.retro-ride.new-ride {
  font-weight: 600;
  color: var(--text-color);
}

.retro-ride-new {
  display: inline-block;
  background: var(--primary-color);
  color: white;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  vertical-align: middle;
  margin-left: 0.25rem;
}

@media (max-width: 600px) {
  .retro-ride-list { columns: 1; }
}


/* ==========================================================================
   CONTACT PAGE
   ========================================================================== */

.contact-card {
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 2.5rem;
  text-align: center;
  margin: 2rem 0;
}

.contact-card p {
  color: var(--secondary-color);
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
  max-width: 50ch;
  margin-left: auto;
  margin-right: auto;
}

.contact-email-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--primary-color);
  color: white;
  font-size: 1.1rem;
  font-weight: 600;
  padding: 0.85rem 2rem;
  border-radius: 8px;
  text-decoration: none;
  transition: background 0.15s, transform 0.15s, box-shadow 0.15s;
}

.contact-email-btn:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
  color: white;
}

.contact-email-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.contact-socials {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.contact-social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.25rem;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-color);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: border-color 0.15s, background 0.15s, transform 0.15s;
}

.contact-social-link:hover {
  border-color: var(--primary-color);
  background: #eff6ff;
  transform: translateY(-1px);
  color: var(--primary-color);
}

.contact-social-link svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.contact-guildlab {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
  color: white;
  border-radius: 10px;
  padding: 1.5rem 2rem;
  margin: 2.5rem 0;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
}

.contact-guildlab:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  color: white;
}

.contact-guildlab-text {
  flex-grow: 1;
}

.contact-guildlab-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.7;
  font-weight: 600;
}

.contact-guildlab-title {
  font-family: "Arvo", serif;
  font-size: 1.2rem;
  font-weight: 700;
  margin-top: 0.15rem;
}

.contact-guildlab-desc {
  font-size: 0.9rem;
  opacity: 0.8;
  margin-top: 0.25rem;
}

.contact-guildlab-arrow {
  font-size: 1.5rem;
  opacity: 0.5;
  flex-shrink: 0;
  transition: opacity 0.15s, transform 0.15s;
}

.contact-guildlab:hover .contact-guildlab-arrow {
  opacity: 1;
  transform: translateX(4px);
}

/* Client details accordion - reuse retro-accordion styles */
.contact-client-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.contact-client-section h2 {
  font-size: 1.1rem;
  color: var(--secondary-color);
  font-weight: 600;
  margin-bottom: 1rem;
}

@media (max-width: 600px) {
  .contact-card { padding: 1.5rem; }
  .contact-socials { flex-direction: column; align-items: center; }
  .contact-guildlab { flex-direction: column; text-align: center; }
  .contact-guildlab-arrow { display: none; }
}

/* Contact code blocks */
.contact-code {
  background: var(--light-gray);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 1rem 1.25rem;
  overflow-x: auto;
  font-size: 0.85rem;
  margin: 0.75rem 0;
}

.contact-code code {
  background: none;
  padding: 0;
  font-size: inherit;
  word-break: break-all;
}

/* ==========================================================================
   DARK MODE
   Auto-detected via prefers-color-scheme.
   ========================================================================== */

@media (prefers-color-scheme: dark) {

  /* --- CSS variable overrides --- */
  :root {
    --text-color: #e2e8f0;
    --secondary-color: #94a3b8;
    --background-color: #1e293b;
    --header-color: #0f172a;
    --link-color: #60a5fa;
    --link-hover-color: #93bbfd;
    --code-bg-color: #334155;
    --sidebar-bg-color: #1e293b;
    --toc-active-color: #60a5fa;
    --primary-color: #3b82f6;
    --light-gray: #1e293b;
    --border-color: #334155;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.4);
  }

  /* --- Base elements --- */
  body { background: #0f172a; color: var(--text-color); }
  a { color: var(--link-color); }
  a:hover { color: var(--link-hover-color); }
  code { background: var(--code-bg-color); color: #e2e8f0; }
  hr { border-color: var(--border-color); }
  blockquote { border-left-color: var(--border-color); color: var(--secondary-color); }
  table th { background: #1e293b; }
  table td, table th { border-color: var(--border-color); }
  img { opacity: 0.92; }

  /* --- Navbar (already dark, minor tweaks) --- */
  #topnav { background-color: #0f172a; }
  #topnav .search-input { background: #1e293b; color: #e2e8f0; border-color: #334155; }

  /* --- Dropdown menu --- */
  #topnav .dropdown-menu { background-color: #1e293b; box-shadow: 0 4px 20px rgba(0,0,0,0.4); }
  #topnav .dropdown-link { color: rgba(255,255,255,0.85); }
  #topnav .dropdown-link:hover { background-color: #334155; }

  /* --- Mobile nav --- */
  @media (max-width: 768px) {
    #topnav .nav-menu.active { background-color: #0f172a; box-shadow: 4px 0 20px rgba(0,0,0,0.5); }
  }

  /* --- Blog listing page --- */
  .blog-post-entry { background-color: #1e293b; border-color: var(--border-color); }
  .blog-post-entry:hover { background-color: #334155; box-shadow: 0 5px 15px rgba(0,0,0,0.3); }
  .blog-post-title { color: var(--text-color); }
  .blog-post-date { color: #64748b; }
  .blog-post-description { color: var(--secondary-color); }
  #blog-post-listing .date { color: var(--secondary-color); }
  #blog-post-listing .title { color: var(--text-color); }
  #blog-post-listing h2 { border-bottom-color: var(--border-color); color: var(--text-color); }

  /* --- Post list (latest posts, project cards) --- */
  .post-item { background: #1e293b; }
  .post-item:hover { background: #334155; }
  .post-date { color: #64748b; }
  .post-tag { background: #334155; color: var(--secondary-color); }

  /* --- Blog post hero --- */
  .hero-section { background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%); }
  .hero-image { background-color: #1e293b; }
  .hero-title { background: rgba(0, 0, 0, 0.7); }

  /* --- Blog content area --- */
  .content-section { background: #0f172a; }
  .content-main { background: rgba(30, 41, 59, 0.8); border-color: var(--border-color); }
  .table-of-contents { background: #0f172a; }
  .toc-list a { color: var(--secondary-color); }
  .toc-list a:hover, .toc-list a.active { color: var(--link-color); background: rgba(59, 130, 246, 0.1); }
  .article-content a { color: var(--link-color); }
  .article-content a:hover { color: var(--link-hover-color); }

  /* --- Post navigation --- */
  .post-navigation { background: #0f172a; border-top-color: var(--border-color); }
  .post-navigation .nav-btn { background: #1e293b; border-color: var(--border-color); color: var(--text-color); }
  .post-navigation .nav-btn:hover { box-shadow: 0 8px 25px rgba(0,0,0,0.4); }
  .post-navigation .nav-btn-label { color: var(--secondary-color); }

  /* --- Hero meta (blog post sidebar) --- */
  .hero-meta { background: #0f172a; }
  .meta-label { color: var(--secondary-color); }
  .meta-value { color: var(--text-color); }

  /* --- Page headers (muted) --- */
  .page-header-muted { background: #0f172a; }
  .page-header-muted::before { opacity: 0.3; }

  /* --- Shared page content wrappers (contact, projects, etc.) --- */
  .page-content { background: #0f172a; }
  .page-main { background: rgba(30, 41, 59, 0.8); border-color: var(--border-color); }

  /* --- Contact page --- */
  .contact-card { background: #1e293b; border-color: var(--border-color); }
  .contact-social-link:hover { background: rgba(59, 130, 246, 0.15); }
  .contact-code { background: #0f172a; border-color: var(--border-color); }

  /* --- Resume projects --- */
  .resume-project { background: #1e293b; border-color: var(--border-color); }
  .resume-project:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
  .resume-project p { color: var(--secondary-color); }

  /* --- Homepage hero --- */
  .home-hero { background: #0f172a; }
  .home-hero::before { opacity: 0.15; }
  .home-hero:not(.has-hero-bg) .hero-text h1 { color: var(--text-color); }
  #home .hero-avatar img { box-shadow: 0 8px 24px rgba(0,0,0,0.3); }
  .social-links a { background: #1e293b; border-color: #334155; }
  .social-links a:hover { background: #e2e8f0; border-color: #e2e8f0; }
  .social-links img { filter: brightness(0) invert(1); }
  .social-links a:hover img { filter: brightness(0); }

  /* --- Hire bar (already dark, tweak) --- */
  .hire-bar { background: #1e293b; }

  /* --- Homepage sections --- */
  .home-section { background: #0f172a; }
  .home-section-inner { background: rgba(30, 41, 59, 0.8); border-color: var(--border-color); }

  /* --- Parks teaser card --- */
  .parks-teaser { background: #1e293b; border-color: var(--border-color); }
  .parks-teaser:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.3); }
  .parks-teaser h3 { color: var(--text-color); }
  .parks-teaser p { color: var(--secondary-color); }
  .parks-stats span { color: var(--secondary-color); }
  .parks-stats strong { color: var(--text-color); }

  /* --- Project cards --- */
  .project-card { background: #1e293b; border-color: var(--border-color); }
  .project-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.3); }
  .project-tech { background: #334155; border-color: #475569; color: var(--secondary-color); }

  /* --- Footer (already dark, subtle tweak) --- */
  .footer { background: #0f172a; }

  /* --- Tags --- */
  .tag a { background: #334155; color: var(--secondary-color); }
  .tag a:hover { background: var(--primary-color); color: white; }

  /* ==========================================================================
     Shortcodes (theme park retrospectives)
     ========================================================================== */

  /* Stats bar */
  .retro-stats-bar { background: var(--border-color); border-color: var(--border-color); }
  .retro-stat { background: #1e293b; }
  .retro-stat-value { color: var(--primary-color); }
  .retro-stat-label { color: var(--secondary-color); }

  /* CSS bar chart */
  .retro-chart { background: #1e293b; border-color: var(--border-color); }
  .retro-chart-title { color: var(--text-color); }
  .retro-bar-label { color: var(--text-color); }
  .retro-bar-track { background: #334155; }
  .retro-bar-value { color: var(--secondary-color); }

  /* Park cards */
  .retro-park-card { background: #1e293b; border-color: var(--border-color); }
  .retro-park-name { color: var(--text-color); }
  .retro-park-visits { color: var(--secondary-color); }
  .retro-park-badge { background: var(--primary-color); color: white; }

  /* Ranking list */
  .retro-ranking-card { background: #1e293b; border-color: var(--border-color); }
  .retro-rank-name { color: var(--text-color); }
  .retro-rank-note { color: var(--secondary-color); }
  .retro-ranking.best .rank-1 { border-left-color: #f59e0b; background: #1c1a0e; }
  .retro-ranking.best .rank-2 { border-left-color: #6b7280; background: #1e293b; }
  .retro-ranking.best .rank-3 { border-left-color: #d97706; background: #1c1a0e; }
  .retro-ranking.worst .rank-1 { border-left-color: #ef4444; background: #1f1215; }
  .retro-ranking.worst .rank-2 { border-left-color: #f87171; background: #1f1215; }
  .retro-ranking.worst .rank-3 { border-left-color: #fca5a5; background: #1f1215; }

  /* Ride accordion */
  .retro-accordion { background: #1e293b; border-color: var(--border-color); }
  .retro-accordion-header { color: var(--text-color); }
  .retro-accordion-body { color: var(--secondary-color); }

  /* ==========================================================================
     Cheatsheet page
     ========================================================================== */
  .cheatsheet-sidebar,
  .cheatsheet-content,
  .cheatsheet-toc-sidebar,
  .cheatsheet-main-content { background-color: #1e293b; border-color: #334155; }

  .cheatsheet-header,
  .cheatsheet-toc-header { background: linear-gradient(135deg, #1e293b 0%, #334155 100%); border-color: #334155; }
  .cheatsheet-header h2,
  .cheatsheet-toc-header h3 { color: var(--text-color); }

  .cheatsheet-section-title { color: #60a5fa; }

  /* ==========================================================================
     Resume page
     ========================================================================== */
  .resume-header { background: #0f172a; border-bottom-color: var(--border-color); }
  .resume-header::before { opacity: 0.15; }
  .resume-name { color: var(--text-color); }
  .resume-role { color: var(--secondary-color); }
  .resume-summary { color: var(--secondary-color); }
  .resume-content { background: #0f172a; }
  .resume-main { background: rgba(30, 41, 59, 0.8); border-color: var(--border-color); }
  .resume-section { border-bottom-color: var(--border-color); }
  .experience-card { background: #1e293b; border-color: var(--border-color); }
  .experience-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.3); }
  .tool-item { background: #334155; color: var(--secondary-color); }
  .project-status.side-project { background: #422006; color: #fbbf24; }
  .pdf-download { background: #e2e8f0; color: #0f172a; }
  .pdf-download:hover { background: var(--primary-color); color: white; }

  /* ==========================================================================
     Terminal component
     ========================================================================== */
  .terminal-window { background: #0f172a; border-color: #334155; box-shadow: 0 4px 12px rgba(0,0,0,0.4); }
  .terminal-bar { background: #1e293b; }
  .code-row { background: #0f172a; }
  .code-row:hover { background: #1e293b; }

  /* ==========================================================================
     Contact page
     ========================================================================== */
  .contact-code { background: #1e293b; border-color: #334155; }

  /* ==========================================================================
     Gallery / Images
     ========================================================================== */
  .lightbox-overlay { background: rgba(0,0,0,0.92); }
  .breakout-gallery img { opacity: 0.92; }

  /* ==========================================================================
     Performance metrics & code comparison (inline styles in shortcodes)
     ========================================================================== */
  .metric-card { background: #1e293b; border-color: #334155; box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
  .metric-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.4); }

  /* ==========================================================================
     Project page (detailed cards)
     ========================================================================== */
  .project-detailed { background: #1e293b; border-color: var(--border-color); }
  .project-detailed:hover { box-shadow: 0 4px 20px rgba(0,0,0,0.3); }
  .project-detailed .project-description { color: var(--secondary-color); }
  .project-status.active { background: #052e16; color: #4ade80; }
  .project-status.active::before { background: #22c55e; }
  .project-status.maintained { background: #172554; color: #60a5fa; }
  .project-status.maintained::before { background: #3b82f6; }

  /* ==========================================================================
     Framework/comparison cards
     ========================================================================== */
  .framework-card { background: #1e293b; border-color: var(--border-color); }
  .framework-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.3); }
  .framework-card h3 { color: var(--text-color); }
  .framework-card .status.active { background: #052e16; color: #4ade80; }

  /* ==========================================================================
     Misc overrides
     ========================================================================== */
  .timeline-content { background: #1e293b; border-color: var(--border-color); }
  .timeline-content h4 { color: var(--text-color); }
  .highlight pre { background: #0f172a !important; }
  .highlight code { background: transparent !important; }
  mark { background: #854d0e; color: #fef3c7; }
  ::selection { background: #1e40af; color: #e2e8f0; }

} /* end prefers-color-scheme: dark */