/* Base Styles and Reset */
:root {
    --primary-font: 'Montserrat', sans-serif;
    --heading-font: 'Playfair Display', serif;
    --primary-color: #1a1a1a;
    --secondary-color: #333;
    --accent-color: #777;
    --transition: all 0.3s ease;
    --gap: 4px; /* Reduced gap for tighter fit */
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--primary-font);
    line-height: 1.6;
    color: var(--primary-color);
    background-color: white;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

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

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

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

a:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

ul {
    list-style: none;
}

main {
    flex: 1;
}

/* Accessibility Helpers */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.noscript-message {
    padding: 2rem;
    text-align: center;
/*    background-color: #f8f8f8; */
    border-radius: 4px;
}

/* Header Styles */
header {
    padding: 1.5rem 2rem;
    position: sticky;
    top: 0;
    z-index: 100;
    background-color: white;
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header-logo {
    height: 40px;
    width: auto;
    object-fit: contain;
}

@media (max-width: 768px) {
    .header-logo {
        height: 32px;
    }
}

.logo {
    font-family: var(--heading-font);
    font-weight: 400;
    font-size: 1.5rem;
    letter-spacing: 2px;
}

.logo a {
    color: var(--primary-color);
}

nav ul {
    display: flex;
}

nav li {
    margin-left: 2rem;
}

nav a {
    color: var(--primary-color);
    font-weight: 400;
    font-size: 0.9rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

nav a:hover,
nav a.active {
    color: var(--accent-color);
}

/* Gallery Section */
.section {
    display: none;
    padding: 0;
}

.section.active {
    display: block;
}

/* Dynamic Masonry-Style Gallery Layout */
.gallery-container {
    max-width: 100%;
    margin: 0 auto;
    padding: var(--gap);
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(500px, 1fr));
    grid-auto-rows: 1px; /* This will be adjusted by JavaScript */
    grid-gap: var(--gap);
    background-color: white;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    background-color: #f0f0f0;
    grid-row-end: span var(--span); /* Dynamic span set by JavaScript */
    width: 100%;
    height: 100%;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    will-change: transform;
    display: block;
}

.gallery-item:hover img {
    transform: scale(1.03);
}

.gallery-item img.gallery-img-loading {
    filter: blur(8px) grayscale(0.7) brightness(1.1);
    transform: scale(1.04);
    opacity: 0.7;
    transition: filter 0.6s cubic-bezier(.22,.61,.36,1), transform 0.6s cubic-bezier(.22,.61,.36,1), opacity 0.4s;
}
.gallery-item img.gallery-img-loaded {
    filter: none;
    transform: none;
    opacity: 1;
    transition: filter 0.6s cubic-bezier(.22,.61,.36,1), transform 0.6s cubic-bezier(.22,.61,.36,1), opacity 0.4s;
}
.gallery-img-spinner {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 38px;
    height: 38px;
    margin: -19px 0 0 -19px;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}
.gallery-img-spinner:after {
    content: '';
    display: block;
    width: 32px;
    height: 32px;
    border: 4px solid #bbb;
    border-top: 4px solid var(--accent-color, #777);
    border-radius: 50%;
    animation: gallerySpinner 0.8s linear infinite;
}
@keyframes gallerySpinner {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Loading indicator */
.loading-more {
    column-span: all; /* Span across all columns */
    text-align: center;
    padding: 1rem 0;
    font-style: italic;
    color: var(--accent-color);
    margin: 0;
    line-height: 1.6; /* Reset line height for text */
}

/* About Section */
.about-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0 4rem;
}

.about-content {
    padding: 1rem;
}

.about-content h2 {
    font-family: var(--heading-font);
    font-weight: 400;
    font-size: 2rem;
    margin-bottom: 2rem;
    letter-spacing: 1px;
}

.about-content h3 {
    font-family: var(--heading-font);
    font-weight: 400;
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.about-content p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    color: #444;
}

.about-tirabytes {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #eee;
}

.about-tirabytes p {
    font-style: italic;
    color: #555;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    margin: 2.5rem 0;
}

.social-links a {
    color: var(--primary-color);
    font-size: 1.2rem;
    transition: transform 0.3s ease, color 0.3s ease;
}

.social-links a:hover {
    color: var(--accent-color);
    transform: translateY(-3px);
}

.contact-info {
    margin-top: 2rem;
    border-top: 1px solid #eee;
    padding-top: 2rem;
}

.contact-info p {
    display: flex;
    align-items: center;
    margin-bottom: 0.8rem;
}

.contact-info i {
    margin-right: 10px;
    color: var(--accent-color);
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    transition: opacity 0.3s ease;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.lightbox.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

#lightbox-img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
}

.close-lightbox {
    position: absolute;
    top: -40px;
    right: 0;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-lightbox:hover {
    color: #ddd;
}

.lightbox-nav {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 20px;
}

.lightbox-btn {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.lightbox-btn:hover {
    color: #ddd;
}

/* Footer Styles */
footer {
    padding: 1.5rem 2rem;
    text-align: center;
    font-size: 0.8rem;
    color: var(--accent-color);
    border-top: 1px solid #eee;
    line-height: 1.6; /* Reset line height for text */
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
}

/* Responsive adjustments for gallery */
@media screen and (max-width: 1600px) {
    .gallery-container {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }
}

@media screen and (max-width: 1200px) {
    .gallery-container {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    }
}

@media screen and (max-width: 900px) {
    .gallery-container {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    nav li {
        margin-left: 1rem;
        margin-right: 1rem;
    }
}

@media screen and (max-width: 600px) {
    .gallery-container {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }
}

@media screen and (max-width: 400px) {
    .gallery-container {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    }
}

/* Reduced Motion Preferences */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Gallery Item Animation */
@keyframes galleryFadeInScale {
    0% {
        opacity: 0;
        transform: scale(0.96);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.gallery-item-animate {
    animation: galleryFadeInScale 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) both;
}

/* Lightbox Watermark */
#lightbox-watermark {
    position: absolute;
    bottom: 4%;
    right: 4%;
    width: 15%;
    height: auto;
    opacity: 0.6;
    pointer-events: none;
    z-index: 2;
    user-select: none;
    max-width: 100%;
}

.lightbox-img-wrapper {
    position: relative;
    width: 100%;
    display: inline-block;
}

@media (max-width: 600px) {
    #lightbox-watermark {
        width: 135px;
        bottom: 8px;
        right: 8px;
    }
}

.about-card {
    background: #fff;
    border-radius: 1.2rem;
    box-shadow: 0 4px 32px 0 rgba(30,30,60,0.10), 0 1.5px 6px 0 rgba(30,30,60,0.06);
    padding: 2.5rem 2.5rem 2rem 2.5rem;
    margin: 2.5rem auto 0 auto;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: fadeInUp 1s cubic-bezier(.22,.61,.36,1) both;
}

.about-profile-img-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 1.5rem;
    position: relative;
    width: 140px;
    height: 140px;
}
.about-profile-img-wrapper img {
    width: 140px;
    height: 140px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid #f5f5f5;
    box-shadow: 0 2px 16px 0 rgba(30,30,60,0.10);
    background: #fafafa;
    user-select: none;
    pointer-events: none;
    -webkit-user-drag: none;
}
.about-profile-img-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 2;
    background: transparent;
    pointer-events: auto;
}

.about-card h2 {
    font-family: var(--heading-font);
    font-size: 2.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
    text-align: center;
}

.about-tagline {
    font-size: 1.1rem;
    color: var(--accent-color);
    font-style: italic;
    margin-bottom: 1.2rem;
    text-align: center;
}

.about-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    justify-content: center;
    margin-bottom: 2.2rem;
}
.badge {
    background: #f3f3f7;
    color: var(--primary-color);
    border-radius: 2rem;
    padding: 0.4rem 1.1rem;
    font-size: 0.92rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    box-shadow: 0 1px 4px 0 rgba(30,30,60,0.06);
    border: 1px solid #ececec;
    transition: background 0.2s, color 0.2s;
}
.badge:hover {
    background: var(--accent-color);
    color: #fff;
}

.about-divider {
    border: none;
    border-top: 1.5px solid #eee;
    margin: 2.5rem 0 1.5rem 0;
    width: 100%;
}

.fade-in {
    opacity: 0;
    animation: fadeInUp 1s cubic-bezier(.22,.61,.36,1) 0.1s forwards;
}
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(40px);
    }
    100% {
        opacity: 1;
        transform: none;
    }
}

@media (max-width: 700px) {
    .about-card {
        padding: 1.2rem 0.5rem 1.5rem 0.5rem;
        max-width: 98vw;
    }
    .about-profile-img-wrapper img {
        width: 90px;
        height: 90px;
    }
    .about-badges {
        gap: 0.4rem;
    }
}

.goodies-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 3rem 0 4rem;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}
.goodies-card {
    background: #fff;
    border-radius: 1.2rem;
    box-shadow: 0 4px 32px 0 rgba(30,30,60,0.10), 0 1.5px 6px 0 rgba(30,30,60,0.06);
    padding: 2.5rem 2.5rem 2rem 2.5rem;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: fadeInUp 1s cubic-bezier(.22,.61,.36,1) both;
}
.goodies-card h2 {
    font-family: var(--heading-font);
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 0.7rem;
    letter-spacing: 1px;
    text-align: center;
}
.goodies-desc {
    color: #888;
    font-size: 1.08rem;
    margin-bottom: 2.2rem;
    text-align: center;
}
.goodies-links {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    width: 100%;
    align-items: stretch;
}
.goodies-link {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    background: var(--accent-color, #777);
    color: #fff;
    font-size: 1.08rem;
    font-weight: 500;
    border: none;
    border-radius: 2rem;
    padding: 1rem 1.5rem;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
    box-shadow: 0 1px 4px 0 rgba(30,30,60,0.06);
    cursor: pointer;
    justify-content: center;
}
.goodies-link i {
    font-size: 1.2rem;
}
.goodies-link:hover, .goodies-link:focus {
    background: #444;
    color: #fff;
    box-shadow: 0 2px 12px 0 rgba(30,30,60,0.10);
    text-decoration: none;
}
@media (max-width: 700px) {
    .goodies-container {
        padding: 1.2rem 0.5rem 1.5rem 0.5rem;
        max-width: 98vw;
    }
    .goodies-card {
        padding: 1.2rem 0.5rem 1.5rem 0.5rem;
    }
}

.goodies-divider {
    border: none;
    border-top: 1.5px solid #eee;
    margin: 2.2rem 0 1.2rem 0;
    width: 100%;
}
.goodies-placeholder {
    color: #aaa;
    font-size: 1.02rem;
    text-align: center;
    margin-bottom: 0.5rem;
    letter-spacing: 0.5px;
}

/* Add some keyframes for animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes zoomIn {
    from { transform: scale(0.9); }
    to { transform: scale(1); }
}

/* Articles Section Styles */
.articles-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
    animation: fadeIn 0.8s ease-out;
}

.articles-container h1 {
    font-family: var(--heading-font);
    font-size: 2.5rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 2.5rem;
    color: #333;
}

.article-card {
    background: #fff;
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 24px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
}

.article-title a {
    font-family: var(--heading-font);
    font-size: 1.8rem;
    font-weight: 500;
    text-decoration: none;
    color: #222;
    transition: color 0.3s ease;
}

.article-title a:hover {
    color: var(--primary-color);
}

.article-meta {
    font-size: 0.9rem;
    color: #777;
    margin-top: 0.5rem;
    margin-bottom: 1rem;
}

.article-description {
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
}

/* Individual Article Page Styles */
.post-container {
    padding-top: 140px;
    padding-bottom: 4rem;
}

.post-card {
    background: #fff;
    border-radius: 1.2rem;
    box-shadow: 0 4px 32px 0 rgba(30,30,60,0.10), 0 1.5px 6px 0 rgba(30,30,60,0.06);
    padding: 2.5rem 2.5rem 2rem 2.5rem;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

.post-title {
    font-family: var(--heading-font);
    font-size: 2.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    letter-spacing: 1px;
}

.post-date {
    color: #888;
    font-size: 0.98rem;
    margin-bottom: 2rem;
}

.post-content {
    font-size: 1.1rem;
    line-height: 1.7;
    color: #333;
}

.post-content h3 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.post-content p {
    margin-bottom: 1rem;
}

.post-content ul {
    padding-left: 20px;
    margin-bottom: 1rem;
}

.post-content li {
    margin-bottom: 0.5rem;
}

.post-content code {
    background: #eee;
    padding: 2px 5px;
    border-radius: 4px;
    font-family: monospace;
}

.article-navigation {
    max-width: 1200px;
    margin: 2rem auto 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.article-nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--accent-color, #777);
    color: #fff;
    font-size: 1rem;
    font-weight: 500;
    border: none;
    border-radius: 2rem;
    padding: 0.8rem 1.2rem;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
    box-shadow: 0 1px 4px 0 rgba(30,30,60,0.06);
    cursor: pointer;
}

.article-nav-link:hover, .article-nav-link:focus {
    background: #444;
    color: #fff;
    box-shadow: 0 2px 12px 0 rgba(30,30,60,0.10);
    text-decoration: none;
}

.article-nav-link i {
    font-size: 1.1rem;
}

.article-nav-link.home {
    background: #1a73e8;
}

.article-nav-link.next {
    background: #34a853;
}

@media (max-width: 600px) {
    .article-navigation {
        flex-direction: column;
        gap: 1rem;
    }
    
    .article-nav-link {
        width: 100%;
        justify-content: center;
    }
}

/* Centralized from inline and <style> blocks */
.center-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2rem;
}
.pagination-controls {
    text-align: center;
    margin-top: 2rem;
}
.page-indicator {
    margin: 0 1rem;
    font-weight: 500;
}
.article-navigation.centered {
    justify-content: center;
}
.about-profile-img-wrapper {
    position: relative;
    display: inline-block;
}
.about-profile-img-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    background: transparent;
    pointer-events: auto;
}
.hosting-info-text {
    text-align: center;
    font-size: 0.9rem;
    color: #888;
    margin: 0;
}
.hosting-link {
    color: #888;
    text-decoration: underline;
}
.lightbox-img-wrapper {
    position: relative;
    width: 100%;
    display: inline-block;
}
/* Article-specific overrides from your-next-article.html */
.about-container {
    max-width: 800px; /* Same as articles-container in style.css */
}
.about-card {
    max-width: none;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 4px 24px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.about-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
}
.about-content p {
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
}
.about-card h2 {
    font-size: 1.8rem;
    font-weight: 500;
    color: #222;
}

/* Product grid and card styles for gears page */
.product-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    margin-bottom: 2rem;
    width: 100%;
}
.product-card {
    width: 100%;
    max-width: 1300px;
    box-sizing: border-box;
    margin: 0 auto;
    align-self: center;
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    background: #fff;
    border-radius: 1rem;
    padding: 3rem;
    margin-bottom: 2.5rem;
    box-shadow: 0 4px 24px rgba(0,0,0,0.08);
    gap: 3rem;
    align-items: center;
    overflow: hidden;
}
.product-card.placeholder {
    flex-direction: column;
    text-align: center;
}
.product-image {
    flex: 0 0 300px;
    max-width: 300px;
    margin-right: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.product-image img {
    width: 100%;
    height: auto;
    border-radius: 0.5rem;
    object-fit: contain;
    max-height: 260px;
}
.product-info {
    flex: 1 1 0%;
    min-width: 0;
    overflow-wrap: break-word;
    word-break: break-word;
}
.product-info h3 {
    font-family: var(--heading-font);
    font-size: 2.2rem;
    font-weight: 600;
    color: #222;
    margin-bottom: 0.75rem;
    line-height: 1.2;
    overflow-wrap: break-word;
    word-break: break-word;
}
.product-description {
    font-size: 1.08rem;
    color: #555;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    overflow-wrap: break-word;
    word-break: break-word;
}
.product-rating {
    margin-bottom: 1.5rem;
}
.product-rating .stars {
    color: #ffc107;
    font-size: 1.2rem;
}
.product-rating .stars .fa-star-half-alt {
    color: #ffc107;
}
.product-rating .stars .far {
    color: #e0e0e0;
}
.product-link a {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    padding: 0.8rem 1.5rem;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.3s ease;
}
.product-link a:hover {
    background: #333;
}
@media (max-width: 1300px) {
    .product-card {
        max-width: 98vw;
        padding: 1.2rem;
        gap: 1.2rem;
    }
    .product-image {
        max-width: 180px;
        margin-right: 1.2rem;
    }
}
@media (max-width: 700px) {
    .product-card {
        flex-direction: column;
        max-width: 98vw;
        padding: 1rem;
        gap: 1rem;
    }
    .product-image {
        margin-right: 0;
        margin-bottom: 1rem;
        max-width: 100%;
    }
}
.rating-disclaimer {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin-top: 3rem;
    margin-bottom: 2rem;
}
.rating-disclaimer h4 {
    font-family: var(--heading-font);
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: #333;
    text-align: center;
}
.rating-disclaimer ul {
    list-style: none;
    padding: 0;
    max-width: 600px;
    margin: 0 auto;
}
.rating-disclaimer li {
    margin-bottom: 0.75rem;
    color: #555;
    display: flex;
    align-items: flex-start;
    font-size: 0.95rem;
}
.rating-disclaimer .stars {
    color: #ffc107;
    margin-right: 1rem;
    min-width: 90px;
    font-size: 1rem;
}
.rating-disclaimer .stars .far {
    color: #e0e0e0;
}
.tag-filters {
    text-align: center;
    margin-bottom: 2.5rem;
}
.filter-btn {
    background: #f3f3f7;
    color: var(--primary-color);
    border-radius: 2rem;
    padding: 0.5rem 1.2rem;
    font-size: 1rem;
    font-weight: 500;
    border: 1px solid #ececec;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    margin: 0 0.5rem 0.7rem 0.5rem;
}
.filter-btn:hover,
.filter-btn.active {
    background: var(--accent-color);
    color: #fff;
    border-color: var(--accent-color);
}
.product-tags {
    margin-top: 1.5rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    justify-content: flex-start;
    row-gap: 1.2rem;
    max-width: 100%;
}
.product-tags .tag {
    background: #e9ecef;
    color: #495057;
    border-radius: 4px;
    padding: 0.5rem 1.2rem;
    font-size: 1rem;
    font-weight: 500;
    white-space: nowrap;
    word-break: keep-all;
    letter-spacing: 0.01em;
}
@media (max-width: 1100px) {
    .product-card {
        max-width: 98vw;
        padding: 1.2rem;
        gap: 1.2rem;
    }
    .product-image {
        max-width: 180px;
        margin-right: 1.2rem;
    }
}
@media (max-width: 768px) {
    .product-tags {
        justify-content: center;
    }
}
.product-manufacturer {
    font-size: 1.1rem;
    color: #888;
    margin-bottom: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.02em;
}
