/* Reset & Base Styles */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--body-color, #333);
    background-color: var(--body-bg, #fff);
}

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

p{
    margin-bottom: 1rem;
}

a {
    color: #0066cc;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header */
.site-header {
    background: var(--body-bg, #fff);
    border-bottom: 1px solid #ddd;
    padding: 0.5rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.site-header .container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.header-top {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.5rem;
    width: 100%;
}

.logo {
    flex-shrink: 0;
}

.logo img {
    max-height: 60px;
    width: auto;
}

.site-subtitle {
    font-size: 0.875rem;
    color: #666;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: #333;
    margin: 3px 0;
    transition: 0.3s;
}

/* Navigation */
.main-nav > ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

.main-nav li {
    position: relative;
    display: flex;
    align-items: center;
}

.main-nav a {
    padding: 0.25rem 0;
    display: inline;
}

.dropdown-toggle,
.submenu-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
    margin-left: 0.25rem;
    position: relative;
    font-size: 1.5rem;
    line-height: 1;
}

.dropdown-toggle .caret,
.submenu-toggle .caret {
    display: none !important;
}

.dropdown-toggle::before,
.dropdown-toggle::after,
.submenu-toggle::before,
.submenu-toggle::after {
    display: none !important;
    content: none !important;
    border: none !important;
    width: 0 !important;
    height: 0 !important;
}

.dropdown-menu,
.submenu {
    display: none;
    position: absolute;
    left: 0;
    top: 100%;
    background: var(--body-bg, #fff);
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    min-width: 200px;
    list-style: none;
    padding: 0.5rem 0;
    z-index: 1000;
}

.dropdown-menu .submenu {
    left: 100%;
    top: 0;
}

.dropdown-menu.show,
.submenu.show {
    display: block;
}

.dropdown-menu li,
.submenu li {
    position: relative;
    display: flex;
    align-items: center;
}

.dropdown-menu a,
.submenu a {
    padding: 0.5rem 1rem;
    flex: 1;
    width: auto !important;
}

.dropdown-menu li > .dropdown-toggle,
.submenu li > .submenu-toggle {
    flex: 0 0 auto;
    margin-left: auto;
}

/* Breadcrumb */
.breadcrumb {
    margin-top: 0.35rem;
    margin-bottom: 0;
    padding-top: 0.35rem;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    width: 100%;
}

.breadcrumb ol {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.5rem;
    font-size: 0.8125rem;
    padding: 0;
    margin: 0;
}

.breadcrumb li {
    display: inline-flex;
    align-items: center;
}

.breadcrumb li a {
    color: var(--lightworks-color-link, #636332);
}

.breadcrumb li a:hover {
    color: var(--lightworks-color-hover, blue);
}

.breadcrumb li::after {
    content: " /";
    margin-left: 0.5rem;
    color: #999;
}

.breadcrumb li:last-child::after {
    content: "";
}

.breadcrumb li.active {
    color: #888;
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.product-card {
    border: 1px solid #eee;
    border-radius: 4px;
    padding: 1rem 0.5rem;
    text-align: center;
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: box-shadow 0.2s, border-color 0.2s;
}

.product-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border-color: #ccc;
}

.product-card a {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.product-card img {
    max-width: 150px;
    max-height: 150px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    margin: 0 auto 0.75rem auto;
}

.product-card h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0.25rem 0;
    color: var(--lightworks-color-link, #636332);
}

.product-card-price {
    font-size: 0.9rem;
    color: #333;
    margin-top: 0.25rem;
}

.product-card-notes {
    font-size: 0.85rem;
    color: #666;
    font-style: italic;
    margin-top: 0.25rem;
}

/* Product Page */
.product-page {
    margin-top: 1rem;
}

.product-page .page-header {
    margin-bottom: 1.5rem;
}

.product-page .product-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.product-page .item-image {
    flex: 0 0 auto;
    max-width: 350px;
}

.product-page .item-image img {
    max-width: 100%;
    height: auto;
    display: block;
    border: 1px solid #eee;
    padding: 4px;
    background: #fff;
}

.product-page .product-details {
    flex: 1 1 320px;
}

.product-page .price {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.product-page .notes {
    font-size: 0.95rem;
    color: #666;
    font-style: italic;
    margin-bottom: 1rem;
}

.product-page .product-description {
    margin-top: 1rem;
}

.product-specs {
    margin-top: 1rem;
}

.product-specs table,
.product-page .product-description table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 0.5rem;
    border: 1px solid #ddd;
}

.product-specs th,
.product-specs td,
.product-page .product-description th,
.product-page .product-description td {
    padding: 0.75rem;
    border: 1px solid #ddd;
    vertical-align: top;
    text-align: left;
}

.product-specs th {
    width: 25%;
    font-weight: 600;
    background-color: transparent;
}

.product-specs td p {
    margin: 0 0 0.5rem 0;
}

.product-specs td p:last-child {
    margin-bottom: 0;
}

.product-specs td ul,
.product-specs .option-list,
.spec-options ul {
    margin: 0.25rem 0 0.75rem 1.25rem;
    padding: 0;
    column-count: 2;
    column-gap: 2rem;
    -webkit-column-count: 2;
    -webkit-column-gap: 2rem;
    -moz-column-count: 2;
    -moz-column-gap: 2rem;
}

.product-specs td ul:last-child,
.product-specs .option-list:last-child,
.spec-options ul:last-child {
    margin-bottom: 0;
}

.product-specs td li,
.product-specs .option-list li,
.spec-options li {
    margin-bottom: 0.25rem;
    break-inside: avoid;
    -webkit-column-break-inside: avoid;
    page-break-inside: avoid;
}

.product-specs td {
    vertical-align: text-top;
}

/* Options Tables */
.options-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1.5rem;
    margin-bottom: 2rem;
}

.options-table tr {
    border-bottom: 1px solid #ddd;
}

.options-table tr:last-child {
    border-bottom: none;
}

.options-table td {
    padding: 1rem 0.75rem;
    vertical-align: top;
}

.options-table td.option-image {
    width: 180px;
    max-width: 25%;
    text-align: center;
}

.options-table td.option-image img {
    max-width: 150px;
    max-height: 150px;
    width: auto;
    height: auto;
    border-radius: 4px;
    border: 1px solid #eee;
    display: inline-block;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.options-table td.option-details {
    vertical-align: top;
}

.options-table td.option-details h3,
.options-table td.option-details h4 {
    margin-top: 0;
    margin-bottom: 0.5rem;
    font-size: 1.15rem;
}

.options-table td.option-details p {
    margin: 0 0 0.5rem 0;
    line-height: 1.5;
}

.options-table td.option-details p:last-child {
    margin-bottom: 0;
}

/* Shopping Links */
.shopping-links {
    list-style: none;
    padding-left: 0px;
    padding-right: 10px;
    margin: 0 auto;
    text-align: center;
}

.shopping-links li {
    padding: 10px;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.shopping-links img {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* Tags */
.tags {
    margin: 0;
    padding: 0;
}

.tags .list-inline-item {
    margin: 0;
}

/* Site Content */
.site-content {
    min-height: 60vh;
    padding: 1rem 0 2rem 0;
}

/* Footer */
.site-footer,
.container-footer,
.footer1,
.footer2 {
    background: var(--body-bg, #f8f8f8);
    border-top: 1px solid #ddd;
    padding: 1.5rem 0;
    text-align: center;
    color: var(--lightworks-color-text);
    font-size: 0.875rem;
}

/* Responsive Design */
@media (max-width: 900px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .site-header {
        position: relative;
    }

    .site-header .container {
        display: flex;
        flex-direction: row;
        align-items: center;
        padding: 0.75rem 1rem;
        position: relative;
        flex-wrap: wrap;
    }

    .header-top {
        flex: 1;
        margin-right: auto;
    }

    .site-subtitle {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
        position: relative;
        top: auto;
        right: auto;
        z-index: 1001;
        margin-left: 0;
    }

    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--body-bg, #FBF2E3);
        border-bottom: 1px solid #ddd;
        padding: 0;
        z-index: 1000;
    }

    .main-nav.show {
        display: block;
    }

    .main-nav > ul {
        flex-direction: column;
        gap: 0;
        margin: 0;
        padding: 0;
        list-style: none;
    }

    .main-nav > ul > li {
        border-bottom: none;
        padding: 0;
        margin: 0;
    }

    .main-nav > ul > li > a {
        padding: 0 1rem;
        display: block;
        border-bottom: none;
        margin: 0;
    }

    .dropdown-menu,
    .submenu {
        position: static;
        border: none;
        box-shadow: none;
        background: var(--body-bg, #FBF2E3);
        padding: 0;
        min-width: 100%;
    }

    .dropdown-menu a,
    .submenu a {
        padding: 0.5rem 1rem 0.5rem 2rem;
        display: block;
        border-bottom: none;
        margin: 0;
    }

    .dropdown-menu .dropdown-menu a,
    .submenu .submenu a {
        padding-left: 3rem;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .product-page {
        grid-template-columns: 1fr;
    }

    .breadcrumb {
        width: 100%;
        margin-top: 0.5rem;
    }

    .breadcrumb ol {
        font-size: 0.8125rem;
    }
}

@media (max-width: 600px) {
    .product-specs td ul,
    .product-specs .option-list,
    .spec-options ul {
        column-count: 1;
        -webkit-column-count: 1;
        -moz-column-count: 1;
    }

    .product-grid {
        grid-template-columns: 1fr;
    }

    .options-table td.option-image {
        width: 120px;
    }

    .options-table td.option-image img {
        max-width: 100px;
        max-height: 100px;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1025px) {
    .product-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}
