:root {
    --primary: #216efb;
    --dark: #222;
    --gray: #f4f4f4;
    --border: #ddd;
    --text-gray: #666;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Assistant', sans-serif;
    margin: 0;
    background: #f9f9f9;
    color: #333;
}

/* FLUID CANVAS LAYER */
canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    /* Between background and content */
    pointer-events: auto;
}

header {
    background: #fff;
    padding: 20px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    margin-bottom: 0;
    z-index: 10;
    /* Above canvas */
    position: relative;
}

h1 {
    margin: 0;
    font-weight: 800;
    color: var(--dark);
    letter-spacing: -0.5px;
}

/* Sticky Nav */
.sticky-nav {
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 20;
    /* Above canvas and header */
    border-bottom: 1px solid var(--border);
    text-align: center;
    padding: 10px 0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.sticky-nav a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.2s;
    background: #f0f0f0;
    font-size: 0.95rem;
}

.sticky-nav a:hover,
.sticky-nav a.active {
    background: var(--primary);
    color: #fff;
}

/* Layout */
main {
    max-width: 1400px;
    margin: 30px auto;
    padding: 0 20px;
    position: relative;
    z-index: 10;
    /* Above canvas */
}

section {
    margin-bottom: 60px;
    scroll-margin-top: 80px;
}

.section-header {
    display: flex;
    align-items: baseline;
    border-bottom: 3px solid var(--primary);
    padding-bottom: 10px;
    margin-bottom: 30px;
}

.section-header h2 {
    margin: 0;
    font-size: 1.8rem;
    color: var(--dark);
}

.count {
    margin-right: 10px;
    color: var(--text-gray);
    font-size: 1.1rem;
    font-weight: 400;
}

/* Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

/* Card */
.card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
    position: relative;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
    border-color: #ddd;
}

/* Badges */
.badges {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
}

.badge {
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    font-size: 0.75rem;
    padding: 4px 8px;
    border-radius: 4px;
}

/* Images */
.img-container {
    height: 220px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    position: relative;
    border-bottom: 1px solid #f9f9f9;
}

.img-container img.main-img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.3s;
}

.card:hover .img-container img.main-img {
    transform: scale(1.05);
}

.sec-icon {
    position: absolute;
    bottom: 10px;
    left: 10px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #eee;
    background: #fff;
    padding: 2px;
    object-fit: contain;
}

/* Content */
.content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.sku {
    font-family: monospace;
    color: #999;
    font-size: 0.85rem;
    direction: ltr;
    text-align: right;
    margin-bottom: 5px;
}

.sku span {
    float: left;
    letter-spacing: 0.5px;
}

.title {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 8px 0;
    line-height: 1.3;
    color: var(--dark);
    height: 2.6em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.short-desc {
    font-size: 0.9rem;
    color: var(--text-gray);
    margin-bottom: 15px;
    line-height: 1.4;
    height: 2.8em;
    overflow: hidden;
}

/* Specs Grid - 6 fixed items */
.specs-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 20px;
}

.spec-item {
    background: #f7f7f7;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 0.8rem;
    display: flex;
    flex-direction: column;
    border: 1px solid #eee;
}

.spec-label {
    font-size: 0.7rem;
    color: #888;
    margin-bottom: 2px;
}

.spec-val {
    font-weight: 600;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Accordion */
details {
    border-top: 1px solid #eee;
}

summary {
    padding: 12px 0;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--primary);
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

summary::-webkit-details-marker {
    display: none;
}

summary::after {
    content: "+";
    font-size: 1.2rem;
    font-weight: 200;
}

details[open] summary::after {
    content: "−";
}

.details-content {
    padding-bottom: 15px;
    font-size: 0.9rem;
    color: #555;
    line-height: 1.5;
}

ul.bullets {
    margin: 0;
    padding-right: 20px;
}

ul.bullets li {
    margin-bottom: 5px;
}

/* Table in Accordion */
table.specs-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

table.specs-table td,
table.specs-table th {
    padding: 8px;
    border-bottom: 1px solid #eee;
    text-align: right;
}

table.specs-table tr:last-child td {
    border-bottom: none;
}

.tbl-label {
    color: #777;
    width: 40%;
}

.tbl-val {
    color: #000;
    font-weight: 500;
}

footer {
    text-align: center;
    padding: 40px;
    color: #999;
    font-size: 0.8rem;
}