/*!
 * Theme Name:  BrandStudio
 * Theme URI:   https://brandstudio.dev
 * Author:      BrandStudio Team
 * Author URI:  https://brandstudio.dev
 * Description: A lightning-fast, secure, and fully-featured WordPress theme. Zero jQuery dependency, sub-1s load time, full plugin support, and military-grade security hardening.
 * Version:     1.0.0
 * Requires at least: 6.0
 * Tested up to: 6.6
 * Requires PHP: 7.4
 * License:     GPL-2.0-or-later
 * License URI: https://www.gnu.org/licenses/gpl-2.0.html
 * Text Domain: brandstudio
 * Tags:        blog, e-commerce, portfolio, grid-layout, one-column, two-columns, left-sidebar, right-sidebar,
 *              custom-background, custom-colors, custom-header, custom-logo, custom-menu, featured-images,
 *              footer-widgets, full-width-template, rtl-language-support, sticky-post, theme-options,
 *              threaded-comments, translation-ready, accessibility-ready, wide-blocks, block-styles
 */

/* ============================================================
   CSS CUSTOM PROPERTIES (Design Tokens)
   ============================================================ */
:root {
    /* Brand Colors */
    --bs-primary:          #001e00;
    --bs-primary-dark:     #000f00;
    --bs-primary-mid:      #003300;
    --bs-primary-light:    #004d00;
    --bs-accent:           #2e7d32;
    --bs-accent-hover:     #1b5e20;
    --bs-accent-light:     #4caf50;

    /* Neutral Palette */
    --bs-white:            #ffffff;
    --bs-body-bg:          #ffffff;
    --bs-body-color:       #2c2c2c;
    --bs-heading-color:    #001e00;
    --bs-muted:            #6b7280;
    --bs-border:           #d8e4d8;
    --bs-light-bg:         #f4f7f4;
    --bs-card-bg:          #ffffff;

    /* Typography */
    --bs-font-body:        'Kanit', sans-serif;
    --bs-font-heading:     'Kanit', sans-serif;
    --bs-font-mono:        'Courier New', Courier, monospace;
    --bs-font-size-base:   16px;
    --bs-font-size-sm:     14px;
    --bs-font-size-xs:     12px;
    --bs-font-weight-normal: 300;
    --bs-font-weight-medium: 400;
    --bs-font-weight-semibold: 500;
    --bs-font-weight-bold: 600;
    --bs-line-height:      1.75;
    --bs-line-height-sm:   1.4;

    /* Heading Sizes */
    --bs-h1: clamp(2rem, 4vw, 2.85rem);
    --bs-h2: clamp(1.6rem, 3vw, 2.15rem);
    --bs-h3: clamp(1.3rem, 2.5vw, 1.65rem);
    --bs-h4: clamp(1.1rem, 2vw, 1.35rem);
    --bs-h5: 1.1rem;
    --bs-h6: 1rem;

    /* Layout */
    --bs-container-width:  1320px;
    --bs-container-pad:    clamp(1rem, 4vw, 2rem);
    --bs-content-width:    800px;
    --bs-sidebar-width:    310px;
    --bs-gap:              2rem;

    /* Header */
    --bs-header-bg:        #001e00;
    --bs-header-color:     #ffffff;
    --bs-header-height:    68px;
    --bs-nav-link-color:   rgba(255,255,255,0.88);
    --bs-nav-link-hover:   #ffffff;
    --bs-nav-dropdown-bg:  #001e00;

    /* Buttons */
    --bs-btn-bg:           #001e00;
    --bs-btn-color:        #ffffff;
    --bs-btn-hover-bg:     #003300;
    --bs-btn-radius:       6px;
    --bs-btn-padding:      0.6rem 1.4rem;

    /* Cards & Boxes */
    --bs-radius-sm:        4px;
    --bs-radius:           8px;
    --bs-radius-lg:        12px;
    --bs-radius-xl:        20px;
    --bs-shadow-xs:        0 1px 2px rgba(0,30,0,0.06);
    --bs-shadow-sm:        0 2px 8px rgba(0,30,0,0.08);
    --bs-shadow:           0 4px 20px rgba(0,30,0,0.12);
    --bs-shadow-lg:        0 8px 40px rgba(0,30,0,0.18);

    /* Transitions */
    --bs-transition:       all 0.25s ease;
    --bs-transition-fast:  all 0.15s ease;

    /* Footer */
    --bs-footer-bg:        #001e00;
    --bs-footer-color:     rgba(255,255,255,0.8);
    --bs-footer-heading:   #ffffff;
    --bs-footer-border:    rgba(255,255,255,0.12);
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: var(--bs-font-size-base);
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    font-family: var(--bs-font-body);
    font-size: 1rem;
    font-weight: var(--bs-font-weight-normal);
    line-height: var(--bs-line-height);
    color: var(--bs-body-color);
    background-color: var(--bs-body-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

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

a {
    color: var(--bs-accent);
    text-decoration: none;
    transition: var(--bs-transition-fast);
}

a:hover {
    color: var(--bs-accent-hover);
    text-decoration: underline;
}

a:focus-visible {
    outline: 3px solid var(--bs-accent-light);
    outline-offset: 2px;
    border-radius: 2px;
}

ul, ol { list-style: none; }
table { border-collapse: collapse; width: 100%; }

/* ============================================================
   ACCESSIBILITY
   ============================================================ */
.screen-reader-text {
    clip: rect(1px,1px,1px,1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: var(--bs-white);
    border-radius: var(--bs-radius-sm);
    box-shadow: var(--bs-shadow);
    clip: auto !important;
    clip-path: none;
    color: var(--bs-primary);
    display: block;
    font-size: .875rem;
    font-weight: var(--bs-font-weight-bold);
    height: auto;
    left: 6px;
    line-height: normal;
    padding: .75rem 1.5rem;
    text-decoration: none;
    top: 7px;
    width: auto;
    z-index: 100000;
}

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--bs-font-heading);
    font-weight: var(--bs-font-weight-bold);
    line-height: var(--bs-line-height-sm);
    color: var(--bs-heading-color);
    margin-bottom: 0.6em;
}

h1 { font-size: var(--bs-h1); }
h2 { font-size: var(--bs-h2); }
h3 { font-size: var(--bs-h3); }
h4 { font-size: var(--bs-h4); }
h5 { font-size: var(--bs-h5); }
h6 { font-size: var(--bs-h6); }

p { margin-bottom: 1.25rem; }
p:last-child { margin-bottom: 0; }

strong, b { font-weight: var(--bs-font-weight-bold); }
em, i { font-style: italic; }

small { font-size: var(--bs-font-size-sm); }

blockquote {
    border-left: 4px solid var(--bs-primary);
    margin: 1.75rem 0;
    padding: 1rem 1.5rem;
    background: var(--bs-light-bg);
    border-radius: 0 var(--bs-radius) var(--bs-radius) 0;
    font-style: italic;
    color: var(--bs-muted);
}

blockquote cite {
    display: block;
    margin-top: 0.5rem;
    font-size: var(--bs-font-size-sm);
    font-style: normal;
    font-weight: var(--bs-font-weight-bold);
    color: var(--bs-primary);
}

pre, code {
    font-family: var(--bs-font-mono);
    font-size: .875rem;
}

code {
    background: var(--bs-light-bg);
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius-sm);
    padding: .2em .45em;
    color: var(--bs-primary);
}

pre {
    background: var(--bs-primary-dark);
    color: #a8ff78;
    border-radius: var(--bs-radius);
    padding: 1.25rem 1.5rem;
    overflow-x: auto;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

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

hr {
    border: none;
    border-top: 1px solid var(--bs-border);
    margin: 2rem 0;
}

/* ============================================================
   LAYOUT
   ============================================================ */
.bs-container {
    width: 100%;
    max-width: var(--bs-container-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--bs-container-pad);
    padding-right: var(--bs-container-pad);
}

.bs-site { display: flex; flex-direction: column; min-height: 100vh; }
.bs-content-wrap { flex: 1; }

/* Content + Sidebar Layout */
.bs-layout-wrap {
    display: grid;
    gap: var(--bs-gap);
    grid-template-columns: 1fr;
    padding: 2.5rem 0;
}

.bs-layout-wrap.bs-has-sidebar-right {
    grid-template-columns: 1fr var(--bs-sidebar-width);
}

.bs-layout-wrap.bs-has-sidebar-left {
    grid-template-columns: var(--bs-sidebar-width) 1fr;
}

.bs-layout-wrap.bs-sidebar-left .bs-primary-sidebar {
    order: -1;
}

/* ============================================================
   HEADER
   ============================================================ */
.bs-site-header {
    background-color: var(--bs-header-bg);
    color: var(--bs-header-color);
    position: sticky;
    top: 0;
    z-index: 999;
    box-shadow: 0 2px 12px rgba(0,0,0,0.25);
}

.bs-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--bs-header-height);
    gap: 1.5rem;
}

/* ============================================================
   SITE BRANDING
   ============================================================ */
.bs-site-branding {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
    text-decoration: none;
}

.bs-site-branding:hover { text-decoration: none; }

.bs-custom-logo {
    max-height: 44px;
    width: auto;
}

.bs-site-title {
    font-family: var(--bs-font-heading);
    font-size: 1.4rem;
    font-weight: var(--bs-font-weight-bold);
    color: var(--bs-white);
    line-height: 1;
    letter-spacing: -0.02em;
    margin: 0;
}

.bs-site-title a {
    color: inherit;
    text-decoration: none;
}

.bs-site-title a:hover { color: rgba(255,255,255,0.8); text-decoration: none; }

.bs-tagline {
    font-size: var(--bs-font-size-xs);
    color: rgba(255,255,255,0.6);
    margin-top: 2px;
    font-weight: var(--bs-font-weight-normal);
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.bs-nav-primary { display: flex; align-items: center; margin-left: auto; }

.bs-main-nav {
    display: flex;
    align-items: center;
    gap: 0;
    list-style: none;
    margin: 0;
    padding: 0;
}

.bs-main-nav > li { position: relative; }

.bs-main-nav > li > a {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.55rem 1rem;
    color: var(--bs-nav-link-color);
    font-size: 0.9rem;
    font-weight: var(--bs-font-weight-medium);
    text-decoration: none;
    border-radius: var(--bs-radius-sm);
    transition: var(--bs-transition-fast);
    white-space: nowrap;
}

.bs-main-nav > li > a:hover,
.bs-main-nav > li.current-menu-item > a,
.bs-main-nav > li.current-page-ancestor > a {
    color: var(--bs-nav-link-hover);
    background: rgba(255,255,255,0.1);
    text-decoration: none;
}

/* Dropdown */
.bs-main-nav li.menu-item-has-children > a::after {
    content: '▾';
    font-size: 0.65rem;
    opacity: 0.7;
    transition: var(--bs-transition-fast);
}

.bs-main-nav li.menu-item-has-children:hover > a::after { opacity: 1; }

.bs-main-nav .sub-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    background: var(--bs-nav-dropdown-bg);
    border-radius: var(--bs-radius);
    box-shadow: var(--bs-shadow-lg);
    min-width: 200px;
    padding: 0.4rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: var(--bs-transition);
    z-index: 100;
    list-style: none;
    border: 1px solid rgba(255,255,255,0.08);
}

.bs-main-nav li.menu-item-has-children:hover .sub-menu,
.bs-main-nav li.menu-item-has-children:focus-within .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.bs-main-nav .sub-menu li a {
    display: block;
    padding: 0.5rem 1rem;
    color: rgba(255,255,255,0.85);
    font-size: 0.875rem;
    border-radius: var(--bs-radius-sm);
    text-decoration: none;
    transition: var(--bs-transition-fast);
}

.bs-main-nav .sub-menu li a:hover {
    background: rgba(255,255,255,0.1);
    color: #fff;
    text-decoration: none;
}

/* WooCommerce Cart Icon */
.bs-cart-icon {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.5rem 0.85rem;
    color: var(--bs-nav-link-color);
    font-size: 0.875rem;
    border-radius: var(--bs-radius-sm);
    transition: var(--bs-transition-fast);
    position: relative;
}

.bs-cart-icon:hover { color: #fff; background: rgba(255,255,255,0.1); text-decoration: none; }

.bs-cart-count {
    background: var(--bs-accent-light);
    color: #fff;
    font-size: 10px;
    font-weight: var(--bs-font-weight-bold);
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 2px;
    right: 2px;
}

/* Mobile Menu Toggle */
.bs-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: var(--bs-radius-sm);
    color: var(--bs-white);
    transition: var(--bs-transition-fast);
}

.bs-menu-toggle:hover { background: rgba(255,255,255,0.1); }
.bs-menu-toggle span { display: block; width: 22px; height: 2px; background: currentColor; border-radius: 2px; transition: var(--bs-transition); }

/* ============================================================
   HERO / PAGE HEADER
   ============================================================ */
.bs-page-header {
    background: var(--bs-light-bg);
    border-bottom: 1px solid var(--bs-border);
    padding: 2.5rem 0;
    text-align: center;
}

.bs-page-header h1 {
    font-size: var(--bs-h2);
    margin-bottom: 0.5rem;
}

.bs-breadcrumbs {
    font-size: var(--bs-font-size-sm);
    color: var(--bs-muted);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    justify-content: center;
    flex-wrap: wrap;
}

.bs-breadcrumbs a { color: var(--bs-accent); }
.bs-breadcrumbs a:hover { color: var(--bs-accent-hover); }
.bs-breadcrumbs .sep { opacity: 0.5; }

/* ============================================================
   POSTS — LOOP (Blog Grid)
   ============================================================ */
.bs-posts-grid {
    display: grid;
    gap: 1.75rem;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.bs-post-card {
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius-lg);
    overflow: hidden;
    transition: var(--bs-transition);
    display: flex;
    flex-direction: column;
}

.bs-post-card:hover {
    box-shadow: var(--bs-shadow);
    transform: translateY(-3px);
    border-color: var(--bs-primary-light);
}

.bs-card-thumb {
    overflow: hidden;
    aspect-ratio: 16/9;
    background: var(--bs-light-bg);
}

.bs-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.bs-post-card:hover .bs-card-thumb img { transform: scale(1.04); }

.bs-card-body {
    padding: 1.35rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.bs-card-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: var(--bs-font-size-xs);
    color: var(--bs-muted);
    margin-bottom: 0.65rem;
}

.bs-card-meta a { color: var(--bs-accent); font-weight: var(--bs-font-weight-medium); }
.bs-card-meta a:hover { color: var(--bs-accent-hover); text-decoration: none; }
.bs-meta-sep { opacity: 0.4; }

.bs-card-title {
    font-size: 1.1rem;
    font-weight: var(--bs-font-weight-semibold);
    margin-bottom: 0.6rem;
    line-height: 1.4;
}

.bs-card-title a { color: var(--bs-heading-color); }
.bs-card-title a:hover { color: var(--bs-accent); text-decoration: none; }

.bs-card-excerpt {
    font-size: var(--bs-font-size-sm);
    color: var(--bs-muted);
    line-height: 1.65;
    flex: 1;
    margin-bottom: 1rem;
}

.bs-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 0.85rem;
    border-top: 1px solid var(--bs-border);
}

.bs-read-more {
    font-size: var(--bs-font-size-sm);
    font-weight: var(--bs-font-weight-semibold);
    color: var(--bs-primary);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.bs-read-more:hover { color: var(--bs-accent); text-decoration: none; }
.bs-read-more::after { content: '→'; transition: var(--bs-transition-fast); }
.bs-read-more:hover::after { transform: translateX(3px); }

/* ============================================================
   SINGLE POST
   ============================================================ */
.bs-single-article {
    background: var(--bs-card-bg);
    border-radius: var(--bs-radius-lg);
    overflow: hidden;
    border: 1px solid var(--bs-border);
}

.bs-entry-header {
    padding: 2rem 2.5rem 0;
}

.bs-entry-cat-badge {
    display: inline-block;
    background: var(--bs-primary);
    color: #fff;
    font-size: var(--bs-font-size-xs);
    font-weight: var(--bs-font-weight-bold);
    padding: 0.2rem 0.75rem;
    border-radius: 20px;
    text-decoration: none;
    letter-spacing: 0.03em;
    margin-bottom: 0.75rem;
}

.bs-entry-cat-badge:hover { background: var(--bs-accent); color: #fff; text-decoration: none; }

.bs-entry-title {
    font-size: var(--bs-h1);
    margin-bottom: 1rem;
}

.bs-entry-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
    font-size: var(--bs-font-size-sm);
    color: var(--bs-muted);
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--bs-border);
    margin-bottom: 0;
}

.bs-entry-meta a { color: var(--bs-accent); }
.bs-entry-meta a:hover { color: var(--bs-accent-hover); }
.bs-meta-icon { opacity: 0.7; }

.bs-featured-image {
    width: 100%;
    aspect-ratio: 16/6;
    object-fit: cover;
}

.bs-entry-content {
    padding: 2rem 2.5rem;
    font-size: 1rem;
    line-height: var(--bs-line-height);
    /* max-width: 72ch; */
}

.bs-entry-content > * + * { margin-top: 1.3rem; }

.bs-entry-content h2 { border-left: 4px solid var(--bs-primary); padding-left: 1rem; }
.bs-entry-content h3 { color: var(--bs-accent); }

.bs-entry-content ul, .bs-entry-content ol {
    padding-left: 1.5rem;
    list-style: disc;
}

.bs-entry-content ol { list-style: decimal; }

.bs-entry-content li + li { margin-top: 0.35rem; }

.bs-entry-content img { border-radius: var(--bs-radius); }

.bs-entry-content a { text-decoration: underline; text-underline-offset: 3px; }

.bs-entry-content table th, .bs-entry-content table td {
    padding: 0.6rem 1rem;
    border: 1px solid var(--bs-border);
    text-align: left;
}

.bs-entry-content table th {
    background: var(--bs-primary);
    color: #fff;
    font-weight: var(--bs-font-weight-semibold);
}

.bs-entry-footer {
    padding: 1.25rem 2.5rem;
    border-top: 1px solid var(--bs-border);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.bs-tags-label { font-size: var(--bs-font-size-sm); color: var(--bs-muted); font-weight: var(--bs-font-weight-medium); }

.bs-tag-badge {
    display: inline-block;
    background: var(--bs-light-bg);
    color: var(--bs-body-color);
    border: 1px solid var(--bs-border);
    padding: 0.2rem 0.65rem;
    border-radius: 20px;
    font-size: var(--bs-font-size-xs);
    text-decoration: none;
    transition: var(--bs-transition-fast);
}

.bs-tag-badge:hover { background: var(--bs-primary); color: #fff; border-color: var(--bs-primary); text-decoration: none; }

/* Author Box */
.bs-author-box {
    display: flex;
    gap: 1.25rem;
    padding: 1.75rem 2.5rem;
    background: var(--bs-light-bg);
    border-top: 1px solid var(--bs-border);
    align-items: flex-start;
}

.bs-author-avatar img {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
}

.bs-author-name { font-weight: var(--bs-font-weight-bold); font-size: 1rem; color: var(--bs-heading-color); }
.bs-author-name a { color: inherit; }
.bs-author-bio { font-size: var(--bs-font-size-sm); color: var(--bs-muted); margin-top: 0.25rem; }

/* Post Navigation */
.bs-post-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin: 2rem 0;
}

.bs-nav-previous, .bs-nav-next {
    background: var(--bs-light-bg);
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius);
    padding: 1rem 1.25rem;
    transition: var(--bs-transition);
}

.bs-nav-previous:hover, .bs-nav-next:hover {
    background: var(--bs-primary);
    border-color: var(--bs-primary);
}

.bs-nav-previous:hover a, .bs-nav-next:hover a { color: #fff; }
.bs-nav-next { text-align: right; }

.bs-nav-label { font-size: var(--bs-font-size-xs); color: var(--bs-muted); text-transform: uppercase; letter-spacing: 0.08em; font-weight: var(--bs-font-weight-bold); margin-bottom: 0.25rem; }
.bs-nav-title { font-size: var(--bs-font-size-sm); font-weight: var(--bs-font-weight-semibold); color: var(--bs-heading-color); line-height: 1.4; }
.bs-nav-title a { color: inherit; text-decoration: none; }

/* ============================================================
   SIDEBAR
   ============================================================ */
.bs-primary-sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.bs-widget {
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius-lg);
    padding: 1.5rem;
}

.bs-widget-title {
    font-size: 1rem;
    font-weight: var(--bs-font-weight-bold);
    color: var(--bs-primary);
    margin-bottom: 1rem;
    padding-bottom: 0.6rem;
    border-bottom: 2px solid var(--bs-primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.bs-widget ul { list-style: none; padding: 0; }
.bs-widget ul li + li { border-top: 1px solid var(--bs-border); }
.bs-widget ul li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 0;
    font-size: var(--bs-font-size-sm);
    color: var(--bs-body-color);
    text-decoration: none;
}
.bs-widget ul li a:hover { color: var(--bs-accent); }

/* Search Widget */
.bs-search-form {
    display: flex;
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius);
    overflow: hidden;
}

.bs-search-form input[type="search"] {
    flex: 1;
    padding: 0.55rem 0.75rem;
    border: none;
    outline: none;
    font-family: var(--bs-font-body);
    font-size: var(--bs-font-size-sm);
    background: var(--bs-white);
    color: var(--bs-body-color);
}

.bs-search-form button {
    background: var(--bs-primary);
    color: #fff;
    border: none;
    padding: 0 0.85rem;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--bs-transition-fast);
}

.bs-search-form button:hover { background: var(--bs-accent); }

/* ============================================================
   PAGINATION
   ============================================================ */
.bs-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 2.5rem;
}

.bs-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 0.6rem;
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius);
    font-size: var(--bs-font-size-sm);
    font-weight: var(--bs-font-weight-medium);
    color: var(--bs-body-color);
    text-decoration: none;
    transition: var(--bs-transition-fast);
    background: var(--bs-white);
}

.bs-pagination .page-numbers:hover,
.bs-pagination .page-numbers.current {
    background: var(--bs-primary);
    border-color: var(--bs-primary);
    color: #fff;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.bs-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: var(--bs-btn-padding);
    background: var(--bs-btn-bg);
    color: var(--bs-btn-color);
    font-family: var(--bs-font-body);
    font-size: 0.9rem;
    font-weight: var(--bs-font-weight-semibold);
    border: 2px solid transparent;
    border-radius: var(--bs-btn-radius);
    cursor: pointer;
    text-decoration: none;
    transition: var(--bs-transition);
    line-height: 1;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.bs-btn:hover {
    background: var(--bs-btn-hover-bg);
    color: #fff;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: var(--bs-shadow-sm);
}

.bs-btn:active { transform: translateY(0); }

.bs-btn-outline {
    background: transparent;
    color: var(--bs-primary);
    border-color: var(--bs-primary);
}

.bs-btn-outline:hover { background: var(--bs-primary); color: #fff; }

.bs-btn-sm {
    font-size: var(--bs-font-size-sm);
    padding: 0.4rem 1rem;
}

.bs-btn-lg {
    font-size: 1rem;
    padding: 0.85rem 2rem;
}

/* ============================================================
   FORMS
   ============================================================ */
.bs-form-group { margin-bottom: 1.25rem; }

.bs-form-label {
    display: block;
    font-size: var(--bs-font-size-sm);
    font-weight: var(--bs-font-weight-medium);
    color: var(--bs-heading-color);
    margin-bottom: 0.4rem;
}

.bs-form-control {
    width: 100%;
    padding: 0.65rem 0.9rem;
    background: var(--bs-white);
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius);
    font-family: var(--bs-font-body);
    font-size: var(--bs-font-size-sm);
    color: var(--bs-body-color);
    transition: var(--bs-transition-fast);
    appearance: none;
}

.bs-form-control:focus {
    outline: none;
    border-color: var(--bs-accent);
    box-shadow: 0 0 0 3px rgba(46,125,50,0.15);
}

.bs-form-control::placeholder { color: var(--bs-muted); }

textarea.bs-form-control { resize: vertical; min-height: 120px; }

/* Comment Form */
.comment-form .comment-form-comment label,
.comment-form .comment-form-author label,
.comment-form .comment-form-email label,
.comment-form .comment-form-url label { font-weight: var(--bs-font-weight-medium); font-size: var(--bs-font-size-sm); margin-bottom: 0.35rem; display: block; }

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: 0.65rem 0.9rem;
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius);
    font-family: var(--bs-font-body);
    font-size: var(--bs-font-size-sm);
    transition: var(--bs-transition-fast);
    background: var(--bs-white);
    color: var(--bs-body-color);
}

.comment-form input[type="text"]:focus,
.comment-form input[type="email"]:focus,
.comment-form input[type="url"]:focus,
.comment-form textarea:focus {
    outline: none;
    border-color: var(--bs-accent);
    box-shadow: 0 0 0 3px rgba(46,125,50,0.15);
}

.comment-form input[type="submit"] {
    display: inline-flex;
    align-items: center;
    padding: 0.6rem 1.4rem;
    background: var(--bs-primary);
    color: #fff;
    border: none;
    border-radius: var(--bs-btn-radius);
    font-family: var(--bs-font-body);
    font-size: 0.9rem;
    font-weight: var(--bs-font-weight-semibold);
    cursor: pointer;
    transition: var(--bs-transition-fast);
}

.comment-form input[type="submit"]:hover { background: var(--bs-accent); }

/* ============================================================
   COMMENTS
   ============================================================ */
.bs-comments {
    margin-top: 2.5rem;
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border);
    border-radius: var(--bs-radius-lg);
    padding: 2rem 2.5rem;
}

.bs-comments-title {
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--bs-border);
}

.comment-list { list-style: none; padding: 0; }
.comment-list .children { list-style: none; padding-left: 2rem; }

.comment-body {
    display: flex;
    gap: 1rem;
    padding: 1.25rem 0;
    border-bottom: 1px solid var(--bs-border);
}

.comment-author .avatar {
    border-radius: 50%;
    width: 44px;
    height: 44px;
    flex-shrink: 0;
}

.comment-author .fn { font-weight: var(--bs-font-weight-bold); font-size: 0.9rem; color: var(--bs-heading-color); }
.comment-metadata { font-size: var(--bs-font-size-xs); color: var(--bs-muted); }
.comment-metadata a { color: var(--bs-muted); }
.comment-content { font-size: var(--bs-font-size-sm); margin-top: 0.35rem; }
.reply { margin-top: 0.5rem; }
.reply a { font-size: var(--bs-font-size-xs); font-weight: var(--bs-font-weight-bold); color: var(--bs-accent); }

/* ============================================================
   FOOTER
   ============================================================ */
.bs-site-footer {
    background: var(--bs-footer-bg);
    color: var(--bs-footer-color);
    margin-top: auto;
}

.bs-footer-widgets {
    padding: 3.5rem 0 2rem;
    border-bottom: 1px solid var(--bs-footer-border);
}

.bs-footer-widgets-grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.bs-footer-widget-title {
    font-size: 0.9rem;
    font-weight: var(--bs-font-weight-bold);
    color: var(--bs-footer-heading);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--bs-footer-border);
}

.bs-footer-widget ul { list-style: none; padding: 0; }
.bs-footer-widget ul li + li { margin-top: 0.4rem; }
.bs-footer-widget ul li a {
    font-size: var(--bs-font-size-sm);
    color: var(--bs-footer-color);
    text-decoration: none;
    transition: var(--bs-transition-fast);
}
.bs-footer-widget ul li a:hover { color: #fff; text-decoration: none; }

.bs-footer-bar {
    padding: 1.1rem 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.bs-footer-copyright { font-size: var(--bs-font-size-sm); }

.bs-footer-links {
    display: flex;
    gap: 1.25rem;
    list-style: none;
    padding: 0;
}

.bs-footer-links a {
    font-size: var(--bs-font-size-sm);
    color: var(--bs-footer-color);
    text-decoration: none;
}

.bs-footer-links a:hover { color: #fff; }

/* ============================================================
   PAGE — FULL WIDTH
   ============================================================ */
.page-template-full-width .bs-layout-wrap {
    grid-template-columns: 1fr;
}

/* ============================================================
   SEARCH RESULTS
   ============================================================ */
.bs-search-header {
    margin-bottom: 1.5rem;
}

.bs-search-header h1 span {
    color: var(--bs-accent);
}

.bs-no-results {
    text-align: center;
    padding: 3rem;
    background: var(--bs-light-bg);
    border-radius: var(--bs-radius-lg);
}

/* ============================================================
   ERROR 404
   ============================================================ */
.bs-404 {
    text-align: center;
    padding: 5rem 2rem;
    max-width: 600px;
    margin: 0 auto;
}

.bs-404-code {
    font-size: clamp(6rem, 20vw, 10rem);
    font-weight: var(--bs-font-weight-bold);
    color: var(--bs-primary);
    line-height: 1;
    opacity: 0.12;
    display: block;
}

.bs-404 h1 { margin-top: -1.5rem; }

/* ============================================================
   UTILITIES
   ============================================================ */
.bs-text-center { text-align: center; }
.bs-text-right  { text-align: right; }
.bs-text-muted  { color: var(--bs-muted); }
.bs-text-primary { color: var(--bs-primary); }
.bs-text-accent { color: var(--bs-accent); }
.bs-mb-0 { margin-bottom: 0 !important; }
.bs-mt-0 { margin-top: 0 !important; }

.alignleft  { float: left; margin: 0 1.5rem 1rem 0; }
.alignright { float: right; margin: 0 0 1rem 1.5rem; }
.aligncenter { margin: 0 auto 1rem; display: block; text-align: center; }
.alignwide  { margin-left: -4vw; margin-right: -4vw; }
.alignfull  { margin-left: calc(-50vw + 50%); margin-right: calc(-50vw + 50%); max-width: 100vw; }

.wp-caption { max-width: 100%; }
.wp-caption-text { font-size: var(--bs-font-size-sm); color: var(--bs-muted); text-align: center; margin-top: 0.35rem; }

/* Back to Top */
.bs-back-top {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    width: 42px;
    height: 42px;
    background: var(--bs-primary);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    box-shadow: var(--bs-shadow);
    opacity: 0;
    transform: translateY(10px);
    transition: var(--bs-transition);
    z-index: 500;
}

.bs-back-top.visible { opacity: 1; transform: translateY(0); }
.bs-back-top:hover { background: var(--bs-accent); }

/* ============================================================
   RESPONSIVE — TABLET
   ============================================================ */
@media (max-width: 1024px) {
    .bs-layout-wrap.bs-has-sidebar-right,
    .bs-layout-wrap.bs-has-sidebar-left {
        grid-template-columns: 1fr;
    }
    .bs-primary-sidebar { order: 1; }
}

@media (max-width: 900px) {
    .bs-footer-widgets-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================================
   RESPONSIVE — MOBILE
   ============================================================ */
@media (max-width: 768px) {
    :root {
        --bs-header-height: 58px;
    }

    .bs-menu-toggle { display: flex; }

    .bs-nav-primary {
        position: fixed;
        top: var(--bs-header-height);
        left: 0;
        right: 0;
        background: var(--bs-primary-dark);
        padding: 1rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.35s ease;
        z-index: 998;
    }

    .bs-nav-primary.bs-nav-open {
        max-height: 100vh;
        border-top: 1px solid rgba(255,255,255,0.08);
        box-shadow: var(--bs-shadow-lg);
    }

    .bs-main-nav { flex-direction: column; width: 100%; gap: 0; }
    .bs-main-nav > li > a { padding: 0.75rem 1rem; width: 100%; font-size: 1rem; }
    .bs-main-nav .sub-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        background: rgba(0,0,0,0.15);
        border-radius: 0;
        padding: 0 0 0 1rem;
        display: none;
    }

    .bs-main-nav .sub-menu.bs-sub-open { display: block; }

    .bs-posts-grid { grid-template-columns: 1fr; }
    .bs-post-navigation { grid-template-columns: 1fr; }
    .bs-nav-next { text-align: left; }
    .bs-entry-header, .bs-entry-content, .bs-entry-footer, .bs-author-box, .bs-comments { padding-left: 1.25rem; padding-right: 1.25rem; }
    .bs-footer-bar { flex-direction: column; align-items: center; text-align: center; }
    .bs-footer-widgets-grid { grid-template-columns: 1fr; }
    .bs-comment-form-wrap { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    .bs-posts-grid { grid-template-columns: 1fr; }
    .bs-404-code { font-size: 8rem; }
}

/* ============================================================
   PRINT STYLES
   ============================================================ */
@media print {
    .bs-site-header, .bs-site-footer, .bs-primary-sidebar,
    .bs-nav-primary, .bs-menu-toggle, .bs-back-top,
    .bs-post-navigation, .bs-comments { display: none !important; }
    body { font-size: 12pt; background: #fff; color: #000; }
    a::after { content: " (" attr(href) ")"; }
}
