/*
Theme Name: UnSSH
Theme URI: https://unssh.com
Description: Modern, SEO-friendly WordPress theme for AI tech blog - Clean, fast, and beautiful
Author: UnSSH
Author URI: https://unssh.com
Version: 2.0
Tags: blog, two-columns, responsive, custom-menu, featured-images, threaded-comments, translation-ready
Text Domain: unssh
Requires at least: 5.0
Tested up to: 6.4
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
*/

/* ==========================================================================
   CSS Variables & Theme Colors
   ========================================================================== */

:root {
    --brand-primary: 28 89% 52%;
    --brand-secondary: 28 79% 69%;
    --background: 0 0% 100%;
    --foreground: 222.2 84% 4.9%;
    --card: 0 0% 100%;
    --card-foreground: 222.2 84% 4.9%;
    --popover: 0 0% 100%;
    --popover-foreground: 222.2 84% 4.9%;
    --primary: var(--header-accent);
    --primary-foreground: 210 40% 98%;
    --secondary: 210 40% 96.1%;
    --secondary-foreground: 222.2 47.4% 11.2%;
    --muted: 210 40% 96.1%;
    --muted-foreground: 215.4 16.3% 46.9%;
    --accent: var(--brand-secondary);
    --accent-foreground: 222.2 47.4% 11.2%;
    --destructive: 0 84.2% 60.2%;
    --destructive-foreground: 210 40% 98%;
    --border: 214.3 31.8% 91.4%;
    --input: 214.3 31.8% 91.4%;
    --ring: 222.2 84% 4.9%;
    --radius: .5rem;
    --sidebar-background: 0 0% 98%;
    --sidebar-foreground: 240 5.3% 26.1%;
    --sidebar-primary: 240 5.9% 10%;
    --sidebar-primary-foreground: 0 0% 98%;
    --sidebar-accent: 240 4.8% 95.9%;
    --sidebar-accent-foreground: 240 5.9% 10%;
    --sidebar-border: 220 13% 91%;
    --sidebar-ring: 217.2 91.2% 59.8%;
    --header-accent: 211 66% 20%;
    --cta: 0 0% 13%;
    --cta-foreground: 0 0% 100%;
    --button-secondary: 0 0% 73%;
    --button-secondary-foreground: 0 0% 13%;
    --gradient-primary: linear-gradient(135deg, hsl(var(--brand-primary)), hsl(var(--brand-secondary)));
    --shadow-brand: 0 10px 30px -10px hsl(var(--brand-primary) / .35);
}

.dark {
    --background: 222.2 84% 4.9%;
    --foreground: 210 40% 98%;
    --card: 222.2 84% 4.9%;
    --card-foreground: 210 40% 98%;
    --popover: 222.2 84% 4.9%;
    --popover-foreground: 210 40% 98%;
    --primary: var(--header-accent);
    --primary-foreground: 210 40% 98%;
    --secondary: 217.2 32.6% 17.5%;
    --secondary-foreground: 210 40% 98%;
    --muted: 217.2 32.6% 17.5%;
    --muted-foreground: 215 20.2% 65.1%;
    --accent: 28 70% 60%;
    --accent-foreground: 210 40% 98%;
    --destructive: 0 62.8% 30.6%;
    --destructive-foreground: 210 40% 98%;
    --border: 217.2 32.6% 17.5%;
    --input: 217.2 32.6% 17.5%;
    --ring: 212.7 26.8% 83.9%;
    --sidebar-background: 240 5.9% 10%;
    --sidebar-foreground: 240 4.8% 95.9%;
    --sidebar-primary: 224.3 76.3% 48%;
    --sidebar-primary-foreground: 0 0% 100%;
    --sidebar-accent: 240 3.7% 15.9%;
    --sidebar-accent-foreground: 240 4.8% 95.9%;
    --sidebar-border: 240 3.7% 15.9%;
    --sidebar-ring: 217.2 91.2% 59.8%;
}

/* ==========================================================================
   CSS Reset & Base Styles
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    border-width: 0;
    border-style: solid;
    border-color: hsl(var(--border));
}

/* Prevent horizontal scroll on all devices */
html, body {
    max-width: 100vw;
    overflow-x: hidden;
}

img, video, iframe, embed, object {
    max-width: 100%;
    height: auto;
}

html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    font-size: 16px;
    scroll-behavior: smooth;
    line-height: 1.5;
    -moz-tab-size: 4;
    tab-size: 4;
    font-family: Inter, ui-sans-serif, system-ui, Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, sans-serif;
    font-feature-settings: normal;
    font-variation-settings: normal;
    -webkit-tap-highlight-color: transparent;
    overflow-x: hidden;
    width: 100%;
}

body {
    margin: 0;
    padding: 0;
    line-height: inherit;
    background-color: hsl(var(--background));
    font-family: Inter, ui-sans-serif, system-ui, Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, sans-serif;
    color: hsl(var(--foreground));
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    width: 100%;
    position: relative;
}

hr {
    height: 0;
    color: inherit;
    border-top-width: 1px;
}

h1, h2, h3, h4, h5, h6 {
    font-size: inherit;
    font-weight: inherit;
    margin: 0;
}

a {
    color: inherit;
    text-decoration: inherit;
}

b, strong {
    font-weight: bolder;
}

code, kbd, samp, pre {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace;
    font-feature-settings: normal;
    font-variation-settings: normal;
    font-size: 1em;
}

small {
    font-size: 80%;
}

sub, sup {
    font-size: 75%;
    line-height: 0;
    position: relative;
    vertical-align: baseline;
}

sub {
    bottom: -0.25em;
}

sup {
    top: -0.5em;
}

table {
    text-indent: 0;
    border-color: inherit;
    border-collapse: collapse;
}

button, input, optgroup, select, textarea {
    font-family: inherit;
    font-feature-settings: inherit;
    font-variation-settings: inherit;
    font-size: 100%;
    font-weight: inherit;
    line-height: inherit;
    letter-spacing: inherit;
    color: inherit;
    margin: 0;
    padding: 0;
}

button, select {
    text-transform: none;
}

button, input:where([type=button]), input:where([type=reset]), input:where([type=submit]) {
    -webkit-appearance: button;
    background-color: transparent;
    background-image: none;
}

img, svg, video, canvas, audio, iframe, embed, object {
    display: block;
    vertical-align: middle;
    max-width: 100%;
    height: auto;
}

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

/* ==========================================================================
   Typography
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 0.875rem;
    color: hsl(var(--foreground));
    letter-spacing: -0.02em;
}

h1 { font-size: 1.75rem; }
h2 { font-size: 1.375rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.125rem; }
h5 { font-size: 1.0625rem; }
h6 { font-size: 0.9375rem; }

/* Archive/Index page headings - increased */
.archive .entry-title,
.home .entry-title,
.blog .entry-title,
.index .entry-title,
h2.entry-title {
    font-size: 1.625rem;
    line-height: 1.3;
    margin-bottom: 0.875rem;
}

@media (min-width: 768px) {
    .archive .entry-title,
    .home .entry-title,
    .blog .entry-title,
    .index .entry-title,
    h2.entry-title {
        font-size: 1.875rem;
        line-height: 1.35;
    }
}

/* Single post title - increased more */
.single .entry-title,
.single h1.entry-title {
    font-size: 1.875rem;
    line-height: 1.3;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .single .entry-title,
    .single h1.entry-title {
        font-size: 2.25rem;
        line-height: 1.3;
    }
}

@media (min-width: 640px) {
    h1 { font-size: 2.125rem; line-height: 2.375rem; }
}

@media (min-width: 768px) {
    h1 { font-size: 2.125rem; line-height: 2.375rem; }
    h2 { font-size: 1.375rem; line-height: 1.875rem; }
}

@media (min-width: 1024px) {
    h1 { font-size: 3.5rem; line-height: 1; }
}

p {
    margin: 0 0 1.25rem;
    line-height: 1.7;
    font-size: 1rem;
    color: hsl(var(--foreground));
}

a {
    color: hsl(var(--primary));
    text-decoration: none;
    transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover,
a:focus {
    color: hsl(var(--brand-primary));
    text-decoration: underline;
}

a:focus {
    outline: none;
}

a:focus-visible {
    outline: 2px solid hsl(var(--ring));
    outline-offset: 2px;
}

ul, ol {
    margin: 0 0 1.5rem;
    padding-left: 2rem;
    list-style: none;
}

ul {
    list-style: disc;
}

ol {
    list-style: decimal;
}

blockquote {
    margin: 1.5rem 0 0.75rem 0;
    padding: 0.875rem 1.25rem 0.5rem 1.25rem;
    border-left: 4px solid hsl(var(--brand-primary));
    background: hsl(var(--muted));
    font-style: italic;
    color: hsl(var(--muted-foreground));
    border-radius: var(--radius);
}

blockquote p:last-child {
    margin-bottom: 0;
}

blockquote p {
    margin-bottom: 0.75rem;
}

/* Command blocks - styled like quotes but for code/commands
 * Usage in WordPress editor:
 * 1. Add a Blockquote block
 * 2. Add class "command-block" in Advanced > Additional CSS class
 * 3. Paste your command inside
 * 
 * Or use pre/code blocks with class "command-block"
 */
blockquote.command-block,
.command-block,
pre.command-block,
.entry-content blockquote.command-block,
.entry-content pre.command-block {
    margin: 1.25rem 0;
    padding: 0.75rem 1rem 0.75rem 1.25rem;
    border-left: 4px solid hsl(28, 89%, 52%);
    background: #1a1a1a;
    color: #f0f0f0;
    font-style: normal;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace;
    font-size: 0.9375rem;
    line-height: 1.6;
    border-radius: var(--radius);
    position: relative;
    overflow-x: auto;
    border-top: none;
    border-right: none;
    border-bottom: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    white-space: pre-wrap;
    word-wrap: break-word;
}

.command-block code,
blockquote.command-block code,
pre.command-block code,
.command-block *,
blockquote.command-block *,
pre.command-block * {
    background: transparent;
    padding: 0;
    color: #f0f0f0 !important;
    border: none;
    font-size: inherit;
    font-family: inherit;
}

.command-block,
blockquote.command-block,
pre.command-block {
    color: #f0f0f0 !important;
}

.command-block p,
blockquote.command-block p {
    margin: 0;
    padding: 0;
    color: #f0f0f0 !important;
}

.command-block p + p,
blockquote.command-block p + p {
    margin-top: 0.5rem;
}

.command-block strong,
blockquote.command-block strong,
.command-block b,
blockquote.command-block b {
    color: #ffffff !important;
    font-weight: 600;
}

/* Copy button for command blocks */
.command-copy-btn {
    position: absolute;
    top: 50%;
    right: 0.75rem;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    background-color: rgba(255, 255, 255, 0.1);
    color: #f0f0f0;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 0.375rem 1.125rem;
    border-radius: calc(var(--radius) - 2px);
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.375rem;
    transition: all 0.2s ease;
    opacity: 0.9;
    font-family: Inter, ui-sans-serif, system-ui, sans-serif;
    z-index: 10;
    white-space: nowrap;
    user-select: none;
    -webkit-user-select: none;
}

.command-copy-btn:hover {
    background: hsl(28, 89%, 52%);
    background-color: hsl(28, 89%, 52%);
    color: #fff;
    opacity: 1;
    padding-left: 1.375rem;
    padding-right: 1.375rem;
    transform: translateY(-50%) translateY(-1px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    border-color: hsl(28, 89%, 52%);
}

.command-copy-btn:active {
    transform: translateY(-50%) translateY(0);
}

.command-copy-btn:focus {
    outline: none;
    transform: translateY(-50%);
}

.command-copy-btn:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.4);
    outline-offset: 2px;
    transform: translateY(-50%);
}

.command-copy-btn.copied {
    background: #10b981 !important;
    background-color: #10b981 !important;
    opacity: 1;
}

.command-copy-btn.copied span::after {
    content: '!';
}

.command-copy-btn svg {
    width: 14px;
    height: 14px;
    fill: currentColor;
    flex-shrink: 0;
}

.command-copy-btn span {
    display: inline-block;
}

/* Responsive adjustments for command blocks */
@media (max-width: 768px) {
    blockquote.command-block,
    .command-block,
    pre.command-block {
        padding: 0.625rem 0.875rem 0.625rem 1rem;
        font-size: 0.875rem;
    }
    
    .command-copy-btn {
        top: 50%;
        right: 0.5rem;
        transform: translateY(-50%);
        padding: 0.3125rem 0.875rem;
        font-size: 0.6875rem;
    }
    
    .command-copy-btn:hover {
        padding-left: 1rem;
        padding-right: 1rem;
        transform: translateY(-50%) translateY(-1px);
    }
    
    .command-copy-btn:active {
        transform: translateY(-50%) translateY(0);
    }
    
    .command-copy-btn span {
        display: none;
    }
    
    .command-copy-btn.copied span {
        display: inline;
    }
}

code {
    background: hsl(var(--muted));
    padding: 0.25rem 0.5rem;
    border-radius: calc(var(--radius) - 2px);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace;
    font-size: 0.875em;
    color: hsl(var(--destructive));
    border: 1px solid hsl(var(--border));
}

pre {
    background: hsl(var(--card));
    color: hsl(var(--card-foreground));
    padding: 1.5rem;
    border-radius: var(--radius);
    overflow-x: auto;
    margin: 1.5rem 0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    border: 1px solid hsl(var(--border));
}

pre code {
    background: none;
    padding: 0;
    color: inherit;
    border: none;
}

/* ==========================================================================
   Layout
   ========================================================================== */

#page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    width: 100%;
    position: relative;
}

.site-main {
    flex: 1;
}

.container {
    width: 100%;
    margin-right: auto;
    margin-left: auto;
    padding-right: 1rem;
    padding-left: 1rem;
    box-sizing: border-box;
    overflow-x: hidden;
}

@media (min-width: 1600px) {
    .container {
        max-width: 1600px;
    }
}

.content-wrapper {
    max-width: 1300px;
    margin: 0 auto;
    padding: 2.5rem 1rem;
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 3rem;
    width: 100%;
    box-sizing: border-box;
}

/* Hide sidebar when it's empty */
#secondary:empty {
    display: none;
}

/* Make content full width when sidebar doesn't exist (no-sidebar body class) */
body.no-sidebar .content-wrapper {
    grid-template-columns: 1fr;
}

/* Also handle when sidebar element doesn't exist in DOM */
.content-wrapper:not(:has(#secondary)) {
    grid-template-columns: 1fr;
}

/* When sidebar is empty, make content full width */
.content-wrapper:has(#secondary:empty) {
    grid-template-columns: 1fr;
}

@media (max-width: 768px) {
    .content-wrapper {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 1rem;
        width: 100%;
        max-width: 100%;
    }
}

/* ==========================================================================
   Top Navigation Bar (Page Links)
   ========================================================================== */

.top-navigation-bar {
    background: hsl(var(--header-accent));
    border-bottom: 1px solid hsl(var(--border));
    padding: 0.25rem 0;
    position: sticky;
    top: 0;
    z-index: 1002;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.08);
    width: 100%;
    left: 0;
    right: 0;
    overflow: hidden;
    isolation: isolate;
}

.top-navigation-container {
    max-width: 1200px;
    margin: 0;
    padding: 0 1rem;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

.top-navigation-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.25rem;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
}

.top-navigation-menu li {
    margin: 0;
}

.top-navigation-menu a {
    display: block;
    padding: 0.3125rem 0.75rem;
    color: hsl(var(--primary-foreground));
    text-decoration: none;
    border-radius: var(--radius);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    font-size: 0.6875rem;
    position: relative;
    overflow: hidden;
    opacity: 0.9;
}

.top-navigation-menu a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.top-navigation-menu a:hover::before {
    left: 100%;
}

.top-navigation-menu a:hover {
    background: hsl(var(--background) / 0.15);
    color: hsl(var(--primary-foreground));
    opacity: 1;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.top-navigation-menu .current_page_item > a {
    background: hsl(var(--background) / 0.2);
    color: hsl(var(--primary-foreground));
    opacity: 1;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
    .top-navigation-bar {
        display: none;
    }
    
    /* Ensure no horizontal scroll on mobile */
    body, html {
        position: relative;
        overflow-x: hidden;
        width: 100%;
    }
    
    /* Fix header stacking on mobile */
    .site-header {
        position: sticky;
        top: 0;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .header-container {
        padding: 0.75rem 0.75rem;
        gap: 0.75rem;
    }
    
    .site-title {
        font-size: 1.0625rem;
    }
    
    .content-wrapper {
        padding: 1rem 0.5rem;
        gap: 1.5rem;
    }
    
    #primary {
        padding: 1rem 0.75rem;
    }
    
    #secondary {
        padding: 1rem 0.75rem;
    }
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
    background: hsl(var(--header-accent));
    color: hsl(var(--primary-foreground));
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid hsl(var(--border));
    width: 100%;
    left: 0;
    right: 0;
    overflow: hidden;
    isolation: isolate;
}

body:has(.top-navigation-bar) .site-header {
    top: 0;
}

/* Ensure header stays on top when scrolling */
.site-header,
.top-navigation-bar {
    will-change: transform;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

/* Ensure content doesn't show through header */
.site-main {
    position: relative;
    z-index: 1;
}

.header-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0.875rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
    box-sizing: border-box;
}

.site-branding {
    flex: 1;
    min-width: 200px;
}

.site-title {
    font-size: 1.25rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.03em;
    line-height: 1.2;
}

.site-title a {
    color: hsl(var(--primary-foreground));
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
}

.site-title a:hover {
    opacity: 0.8;
}

.site-description {
    font-size: 0.75rem;
    color: hsl(var(--muted-foreground));
    margin: 0.25rem 0 0;
    font-weight: 400;
    line-height: 1.3;
}

.custom-logo-link {
    display: inline-block;
    line-height: 1;
    transition: opacity 0.3s ease;
}

.custom-logo-link:hover {
    opacity: 0.9;
}

.custom-logo {
    width:300px;
    height: 100px;
    display: block;
    object-fit: fill; /* Stretches logo to fill exact dimensions */
}

/* Navigation */
.main-navigation {
    flex: 1;
    display: flex;
    justify-content: center;
}

.menu-toggle {
    display: none;
    background: transparent;
    border: 2px solid hsl(var(--primary-foreground));
    color: hsl(var(--primary-foreground));
    padding: 0.5rem 1rem;
    cursor: pointer;
    border-radius: var(--radius);
    font-size: 1rem;
    align-items: center;
    gap: 0.5rem;
}

.menu-toggle:hover {
    background: hsl(var(--muted));
}

.menu-toggle-icon {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 20px;
}

.menu-toggle-icon span {
    display: block;
    height: 2px;
    width: 100%;
    background: hsl(var(--primary-foreground));
    transition: all 0.3s ease;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-icon span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle[aria-expanded="true"] .menu-toggle-icon span:nth-child(2) {
    opacity: 0;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-icon span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

#primary-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.5rem;
    flex-wrap: wrap;
}

#primary-menu li {
    margin: 0;
}

#primary-menu a {
    display: block;
    padding: 0.5rem 1rem;
    color: hsl(var(--primary-foreground));
    text-decoration: none;
    border-radius: var(--radius);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    font-size: 0.8125rem;
    position: relative;
}

#primary-menu a:hover,
#primary-menu .current-menu-item > a {
    background: hsl(var(--accent) / 0.2);
    color: hsl(var(--primary-foreground));
}

@media (max-width: 768px) {
    .header-container {
        padding: 0.75rem 1rem;
        gap: 0.875rem;
    }
    
    .site-branding {
        min-width: auto;
        flex: 0 1 auto;
    }
    
    .site-title {
        font-size: 1.0625rem;
    }
    
    .site-description {
        font-size: 0.6875rem;
        margin-top: 0.125rem;
    }
    
    .main-navigation {
        flex: 0 0 auto;
        order: 3;
        width: 100%;
    }
    
    .header-actions {
        flex: 0 0 auto;
        order: 2;
        gap: 0.5rem;
    }
    
    .search-form {
        display: none;
    }
    
    .menu-toggle {
        display: flex;
        width: 100%;
        justify-content: space-between;
    }
    
    #primary-menu {
        display: none;
        flex-direction: column;
        width: 100%;
        margin-top: 1rem;
        padding: 0;
    }
    
    .menu-toggle[aria-expanded="true"] + #primary-menu,
    #primary-menu.active {
        display: flex;
    }
    
    .category-menu {
        padding: 0 1rem;
    }
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.search-form {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-field {
    padding: 0.5rem 0.875rem;
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    background: hsl(var(--background) / 0.1);
    color: hsl(var(--primary-foreground));
    font-size: 0.75rem;
    width: 200px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.search-field:focus {
    width: 240px;
    background: hsl(var(--background) / 0.15);
    border-color: hsl(var(--ring));
    box-shadow: 0 0 0 3px hsl(var(--ring) / 0.1);
    outline: none;
}

.search-field::placeholder {
    color: hsl(var(--muted-foreground));
}

.search-submit {
    background: hsl(var(--brand-primary));
    border: none;
    color: hsl(var(--primary-foreground));
    padding: 0.5rem;
    border-radius: var(--radius);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-brand);
    min-width: 36px;
    height: 36px;
}

.search-submit:hover {
    background: hsl(var(--brand-secondary));
    transform: translateY(-1px);
}

.social-links {
    display: flex;
    gap: 0.5rem;
}

.social-link {
    color: hsl(var(--primary-foreground));
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius);
    transition: all 0.3s ease;
    background: hsl(var(--background) / 0.05);
    border: 1px solid hsl(var(--border));
    min-width: 36px;
    height: 36px;
}

.social-link:hover {
    background: hsl(var(--accent) / 0.2);
    color: hsl(var(--primary-foreground));
    transform: translateY(-1px) scale(1.05);
}

/* Category Navigation */
.category-navigation {
    background: hsl(var(--secondary));
    border-top: 1px solid hsl(var(--border));
    width: 100%;
    overflow-x: hidden;
    position: relative;
}

.category-menu {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    list-style: none;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 0;
    scrollbar-width: thin;
    scrollbar-color: hsl(var(--border)) transparent;
    -ms-overflow-style: -ms-autohiding-scrollbar;
    width: 100%;
    box-sizing: border-box;
    -webkit-overflow-scrolling: touch;
}

.category-menu::-webkit-scrollbar {
    height: 4px;
}

.category-menu::-webkit-scrollbar-track {
    background: transparent;
}

.category-menu::-webkit-scrollbar-thumb {
    background: hsl(var(--border));
    border-radius: 2px;
}

.category-menu::-webkit-scrollbar-thumb:hover {
    background: hsl(var(--muted-foreground) / 0.3);
}

.category-menu li {
    margin: 0;
}

.category-menu a {
    display: block;
    padding: 0.625rem 1rem;
    color: hsl(var(--foreground));
    text-decoration: none;
    white-space: nowrap;
    border-bottom: 2px solid transparent;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    font-size: 0.875rem;
    position: relative;
}

.category-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.category-menu a:hover::after,
.category-menu .current-cat > a::after {
    width: 80%;
}

.category-menu a:hover,
.category-menu .current-cat > a {
    color: hsl(var(--brand-primary));
    background: hsl(var(--accent) / 0.1);
}

/* ==========================================================================
   Content Area
   ========================================================================== */

#primary {
    background: hsl(var(--card));
    padding: 2.5rem;
    border-radius: var(--radius);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid hsl(var(--border));
    transition: box-shadow 0.3s ease;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

#primary:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

@media (max-width: 768px) {
    #primary {
        padding: 1.5rem;
        width: 100%;
        max-width: 100%;
    }
}

/* Posts */
.post {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid hsl(var(--border));
    transition: all 0.3s ease;
    position: relative;
}

.post:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Remove bottom border on single posts and reduce spacing */
.single .post {
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 1rem;
}

.post h2 {
    font-size: 1.75rem;
    margin-bottom: 0.625rem;
    line-height: 1.4;
}

@media (min-width: 768px) {
    .post h2 {
        font-size: 2rem;
    }
}

.post h2 a {
    color: hsl(var(--foreground));
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
}

.post h2 a:hover {
    color: hsl(var(--brand-primary));
    text-decoration: none;
}

.post .meta1 {
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
    margin-bottom: 1rem;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.post .meta1 span {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
}

.post .meta1 a {
    color: hsl(var(--brand-primary));
    font-weight: 500;
    transition: all 0.2s ease;
    padding: 0.25rem 0.5rem;
    border-radius: calc(var(--radius) - 2px);
}

.post .meta1 a:hover {
    background: hsl(var(--accent));
    color: hsl(var(--accent-foreground));
}

.post .meta2 {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    text-align: right;
    display: block;
}

.post .meta2 a {
    color: hsl(var(--primary-foreground));
    font-weight: 500;
    font-size: 0.875rem;
    letter-spacing: 0.3px;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    background: var(--gradient-primary);
    transition: all 0.3s ease;
    box-shadow: var(--shadow-brand);
    text-decoration: none;
    vertical-align: middle;
}

.post .meta2 a:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px -10px hsl(var(--brand-primary) / .45);
    text-decoration: none;
}

/* Read more button aligned to right on archive pages */
.archive .post .entry-content,
.home .post .entry-content,
.blog .post .entry-content,
.index .post .entry-content {
    display: block;
}

.archive .post .entry-content p,
.home .post .entry-content p,
.blog .post .entry-content p,
.index .post .entry-content p {
    display: block;
    margin-bottom: 0.75rem;
}

.archive .post .entry-footer,
.home .post .entry-footer,
.blog .post .entry-footer,
.index .post .entry-footer {
    margin-top: 0;
    padding-top: 0;
    text-align: right;
    display: block;
}

.archive .post .entry-footer p,
.home .post .entry-footer p,
.blog .post .entry-footer p,
.index .post .entry-footer p {
    margin: 0;
    display: inline-block;
}

.post .image,
.post img {
    border-radius: var(--radius);
    margin: 1rem 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.post .image:hover,
.post img:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.post-thumbnail {
    margin: 1.25rem 0;
    overflow: hidden;
    border-radius: var(--radius);
    position: relative;
}

.post-thumbnail img {
    width: 100%;
    height: auto;
    border-radius: var(--radius);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.post-thumbnail:hover img {
    transform: scale(1.02);
}

.post ul,
.post ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.post ul li,
.post ol li {
    margin-bottom: 0.5rem;
}

/* Entry Content Styling */
.entry-content {
    font-size: 1rem;
    line-height: 1.75;
    color: hsl(var(--foreground));
}

.entry-content p {
    margin-bottom: 1.25rem;
}

/* Override for archive pages */
.archive .entry-content p,
.home .entry-content p,
.blog .entry-content p,
.index .entry-content p {
    margin-bottom: 0.75rem;
    font-size: 1rem;
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: hsl(var(--foreground));
    font-weight: 700;
}

.entry-content h2 {
    font-size: 1.375rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid hsl(var(--border));
}

.entry-content h3 {
    font-size: 1.25rem;
}

.entry-content h4 {
    font-size: 1.125rem;
}

.entry-content ul,
.entry-content ol {
    margin: 1.25rem 0;
    padding-left: 2rem;
}

.entry-content li {
    margin-bottom: 0.625rem;
}

.entry-content a {
    color: hsl(var(--brand-primary));
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: all 0.2s ease;
}

.entry-content a:hover {
    color: hsl(var(--brand-secondary));
    text-decoration: none;
}

/* Ensure command blocks override entry-content styles */
.entry-content blockquote.command-block a,
.entry-content pre.command-block a,
.entry-content .command-block a {
    color: #60a5fa !important;
}

.entry-content blockquote.command-block a:hover,
.entry-content pre.command-block a:hover,
.entry-content .command-block a:hover {
    color: #93c5fd !important;
}

/* ==========================================================================
   Sidebar
   ========================================================================== */

#secondary {
    background: hsl(var(--sidebar-background));
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    border: 1px solid hsl(var(--sidebar-border));
    height: fit-content;
    position: sticky;
    top: 100px;
}

/* Hide sidebar when it's empty or has no widgets */
#secondary:empty,
#secondary:not(:has(.widget)) {
    display: none;
}

@media (max-width: 768px) {
    #secondary {
        position: static;
        padding: 1.5rem;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    
    .content-wrapper {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
    
    #primary {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

.widget {
    margin-bottom: 1.5rem;
    padding: 1.25rem;
    background: transparent;
    border-radius: var(--radius);
    border: none;
    border-bottom: 1px solid hsl(var(--border));
    transition: all 0.3s ease;
}

.widget:hover {
    border-bottom-color: hsl(var(--brand-primary) / 0.3);
}

.widget:last-child {
    margin-bottom: 0;
    border-bottom: none;
}

.widget-title {
    font-size: 0.9375rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid hsl(var(--border));
    color: hsl(var(--foreground));
    font-weight: 600;
    position: relative;
    letter-spacing: 0.2px;
    text-transform: uppercase;
    font-size: 0.8125rem;
}

.widget-title::after {
    display: none;
}

.widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.widget ul li {
    margin-bottom: 0.5rem;
    padding-left: 0;
    position: relative;
    padding: 0.375rem 0;
    border-radius: 0;
    transition: all 0.2s ease;
    border-bottom: none;
}

.widget ul li:hover {
    background: transparent;
    transform: translateX(2px);
}

.widget ul li::before {
    display: none;
}

.widget ul li a {
    color: hsl(var(--foreground));
    transition: all 0.2s ease;
    font-size: 0.875rem;
    display: block;
}

.widget ul li a:hover {
    color: hsl(var(--brand-primary));
    font-weight: 500;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
    background: hsl(var(--header-accent));
    color: hsl(var(--primary-foreground));
    margin-top: 2.5rem;
    padding: 1.5rem 0 1rem;
    border-top: 1px solid hsl(var(--border));
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
}

.footer-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 1rem;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}


.site-info {
    text-align: center;
    padding-top: 0;
    border-top: none;
    font-size: 0.75rem;
    line-height: 1.5;
    color: hsl(var(--primary-foreground));
}

.site-info p {
    margin: 0.25rem 0;
    color: hsl(var(--primary-foreground));
}

.site-info a {
    color: hsl(var(--brand-secondary));
    transition: color 0.2s ease;
}

.site-info a:hover {
    color: hsl(var(--primary-foreground));
    opacity: 0.9;
}

@media (max-width: 768px) {
    .site-footer {
        margin-top: 2rem;
        padding: 1.25rem 0 0.875rem;
    }
    
    .site-info {
        font-size: 0.6875rem;
    }
}

/* ==========================================================================
   Comments
   ========================================================================== */

#comments {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid hsl(var(--border));
}

/* Remove top border from comments section on single posts and reduce spacing */
.single #comments {
    border-top: none;
    margin-top: 1.5rem;
    padding-top: 0;
}

/* Reduce bottom margin on entry-content last paragraph for single posts */
.single .entry-content p:last-child {
    margin-bottom: 0.75rem;
}

/* Reduce spacing on entry-footer for single posts */
.single .entry-footer {
    margin-bottom: 0;
    padding-bottom: 0;
}

.commentlist {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem;
}

.commentlist li.comment {
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    background: hsl(var(--card));
    border-radius: var(--radius);
    border-left: 4px solid hsl(var(--brand-primary));
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.3s ease;
}

.commentlist li.comment:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transform: translateX(4px);
}

.comment-author {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.comment-author img {
    border-radius: 50%;
    width: 48px;
    height: 48px;
}

.comment-author cite {
    font-style: normal;
    font-weight: 600;
    color: hsl(var(--foreground));
}

.comment-meta {
    font-size: 0.9375rem;
    color: hsl(var(--muted-foreground));
    margin-bottom: 1rem;
}

.comment-meta a {
    color: hsl(var(--brand-primary));
}

.comment-content {
    margin-bottom: 1rem;
}

.comment-content p {
    margin-bottom: 0.75rem;
}

.reply {
    margin-top: 1rem;
}

.reply a {
    font-size: 0.875rem;
    font-weight: 600;
    color: hsl(var(--brand-primary));
}

.commentlist .children {
    list-style: none;
    margin: 1.5rem 0 0 3rem;
    padding: 0;
}

@media (max-width: 768px) {
    .commentlist .children {
        margin-left: 1rem;
    }
}

/* Comment Form */
#respond {
    margin-top: 3rem;
    padding: 1.5rem;
    background: hsl(var(--card));
    border-radius: var(--radius);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid hsl(var(--border));
}

#respond h2 {
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.comment-form {
    display: grid;
    gap: 0.75rem;
}

.comment-form p {
    margin: 0;
}

.comment-form label {
    display: block;
    margin-bottom: 0.375rem;
    font-weight: 500;
    color: hsl(var(--foreground));
    font-size: 0.875rem;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid hsl(var(--input));
    border-radius: calc(var(--radius) - 2px);
    font-size: 0.9375rem;
    font-family: inherit;
    transition: border-color 0.2s ease;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
}

.comment-form input:focus,
.comment-form textarea:focus {
    outline: none;
    border-color: hsl(var(--ring));
    box-shadow: 0 0 0 3px hsl(var(--ring) / 0.1);
}

.comment-form textarea {
    min-height: 60px;
    resize: vertical;
    max-height: 180px;
}

.comment-form input[type="submit"] {
    background: var(--gradient-primary);
    color: hsl(var(--primary-foreground));
    border: none;
    padding: 0.75rem 1.75rem;
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-brand);
    letter-spacing: 0.3px;
}

.comment-form input[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px hsl(var(--brand-primary) / .4);
}

/* ==========================================================================
   Entry Meta & Tags
   ========================================================================== */

.entry-meta {
    font-size: 0.9375rem;
    color: hsl(var(--muted-foreground));
    margin-bottom: 1rem;
}

.entry-meta a {
    color: hsl(var(--brand-primary));
    font-weight: 500;
}

.tags-links,
.categories-links {
    display: inline-block;
    margin-right: 1rem;
}

.tags-links a,
.categories-links a {
    display: inline-block;
    padding: 0.375rem 0.875rem;
    margin: 0.25rem 0.375rem 0.25rem 0;
    background: hsl(var(--accent));
    color: hsl(var(--accent-foreground));
    border-radius: var(--radius);
    font-size: 0.75rem;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
    border: 1px solid hsl(var(--border));
}

.tags-links a:hover,
.categories-links a:hover {
    background: var(--gradient-primary);
    color: hsl(var(--primary-foreground));
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: var(--shadow-brand);
    border-color: transparent;
}

.edit-link {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid hsl(var(--border));
}

.edit-link a {
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
}

.edit-link a:hover {
    color: hsl(var(--brand-primary));
}

/* ==========================================================================
   Utility Classes
   ========================================================================== */

.clear::after {
    content: "";
    display: table;
    clear: both;
}

.alignleft {
    float: left;
    margin: 0 1.5rem 1rem 0;
}

.alignright {
    float: right;
    margin: 0 0 1rem 1.5rem;
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.alignwide {
    margin-left: -2rem;
    margin-right: -2rem;
}

.alignfull {
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    max-width: 100vw;
    width: 100vw;
}

@media (max-width: 768px) {
    .alignwide,
    .alignfull {
        margin-left: 0;
        margin-right: 0;
        width: 100%;
    }
}

.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.screen-reader-text:focus {
    background-color: hsl(var(--background));
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
    clip: auto !important;
    color: hsl(var(--foreground));
    display: block;
    font-size: 14px;
    font-weight: bold;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 999999;
    padding: 1rem;
    background: hsl(var(--header-accent));
    color: hsl(var(--primary-foreground));
    text-decoration: none;
}

.skip-link:focus {
    left: 6px;
    top: 7px;
}

/* ==========================================================================
   Banners
   ========================================================================== */

.site-banner,
.content-banner {
    text-align: center;
    margin: 1rem auto;
    max-width: 1600px;
    padding: 0 1rem;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

/* ==========================================================================
   Responsive Typography
   ========================================================================== */

@media (max-width: 768px) {
    html {
        font-size: 14px;
    }
    
    h1 { font-size: 1.5rem; }
    h2 { font-size: 1.375rem; }
    h3 { font-size: 1.125rem; }
    
    .post h2 {
        font-size: 1.5rem;
    }
    
    .single .entry-title,
    .single h1.entry-title {
        font-size: 1.625rem;
    }
    
    .archive .entry-title,
    .home .entry-title,
    .blog .entry-title,
    .index .entry-title,
    h2.entry-title {
        font-size: 1.5rem;
    }
}

/* ==========================================================================
   Post Navigation
   ========================================================================== */

.post-navigation {
    margin: 3rem 0;
    padding-top: 2rem;
    border-top: 2px solid hsl(var(--border));
}

.post-navigation .nav-links {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.post-navigation .nav-previous,
.post-navigation .nav-next {
    padding: 0.875rem 1rem;
    background: transparent;
    border-radius: var(--radius);
    transition: all 0.3s ease;
    border: 1px solid hsl(var(--border));
    box-shadow: none;
}

.post-navigation .nav-previous:hover,
.post-navigation .nav-next:hover {
    background: hsl(var(--muted));
    transform: none;
    box-shadow: none;
    border-color: hsl(var(--brand-primary));
}

.post-navigation .nav-subtitle {
    display: block;
    font-size: 0.75rem;
    color: hsl(var(--muted-foreground));
    margin-bottom: 0.375rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.post-navigation .nav-title {
    display: block;
    font-weight: 500;
    color: hsl(var(--foreground));
    font-size: 0.9375rem;
    line-height: 1.4;
}

.post-navigation a {
    text-decoration: none;
}

.post-navigation a:hover .nav-title {
    color: hsl(var(--brand-primary));
}

@media (max-width: 768px) {
    .post-navigation .nav-links {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Pagination
   ========================================================================== */

.posts-navigation,
.pagination {
    margin: 3rem 0;
    padding-top: 2rem;
    border-top: 2px solid hsl(var(--border));
}

.nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.nav-links a,
.nav-links span {
    display: inline-block;
    padding: 0.625rem 1.125rem;
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    text-decoration: none;
    color: hsl(var(--foreground));
    transition: all 0.3s ease;
    font-size: 0.875rem;
    font-weight: 500;
}

.nav-links a:hover {
    background: var(--gradient-primary);
    border-color: hsl(var(--brand-primary));
    color: hsl(var(--primary-foreground));
    transform: translateY(-2px);
    box-shadow: var(--shadow-brand);
}

.nav-links .current {
    background: var(--gradient-primary);
    border-color: hsl(var(--brand-primary));
    color: hsl(var(--primary-foreground));
    box-shadow: var(--shadow-brand);
}

/* ==========================================================================
   Archive Pages
   ========================================================================== */

.archive-header,
.page-header {
    margin-bottom: 2.5rem;
    padding-bottom: 1.25rem;
    border-bottom: 2px solid hsl(var(--border));
    position: relative;
}

.archive-header::after,
.page-header::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 80px;
    height: 2px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.archive-title,
.page-title {
    font-size: 1.625rem;
    margin-bottom: 0.75rem;
    color: hsl(var(--foreground));
    font-weight: 800;
    letter-spacing: -0.02em;
}

.author-description {
    margin-top: 1.25rem;
    padding: 1.25rem;
    background: hsl(var(--card));
    border-radius: var(--radius);
    font-style: italic;
    color: hsl(var(--muted-foreground));
    border-left: 4px solid hsl(var(--brand-primary));
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    font-size: 1rem;
}

/* ==========================================================================
   Search Form
   ========================================================================== */

.search-form {
    display: flex;
    gap: 0.5rem;
    margin: 1.5rem 0;
}

.search-form .search-field {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid hsl(var(--input));
    border-radius: calc(var(--radius) - 2px);
    font-size: 1rem;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
}

.search-form .search-field:focus {
    outline: none;
    border-color: hsl(var(--ring));
    box-shadow: 0 0 0 3px hsl(var(--ring) / 0.1);
}

.search-form .search-submit {
    padding: 0.75rem 1.5rem;
    background: var(--gradient-primary);
    color: hsl(var(--primary-foreground));
    border: none;
    border-radius: calc(var(--radius) - 2px);
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.search-form .search-submit:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-brand);
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
    .site-header,
    .category-navigation,
    #secondary,
    .site-footer,
    .header-actions,
    .menu-toggle {
        display: none;
    }
    
    .content-wrapper {
        grid-template-columns: 1fr;
        max-width: 100%;
    }
    
    a {
        text-decoration: underline;
    }
}
