:root{
  --bg:#ffffff;
  --text:#111827;
  --muted:#6b7280;
  --border:#e5e7eb;
  --card:#ffffff;
  --accent:#1f9d3a;
  --link:#4f46e5;
}

*{ box-sizing:border-box; }
body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color:var(--text);
  background:var(--bg);
}

a{ color:var(--link); text-decoration:none; }
a:hover{ text-decoration:underline; }

.container{
  max-width: 980px;
  margin: 0 auto;
  padding: 16px;
}

/* Header */
.header{
  border-bottom:1px solid var(--border);
  background:#fff;
}
.header__inner{
  display:flex;
  gap:16px;
  align-items:center;
  padding:12px 0;
}
.nav{
  display:flex;
  gap:14px;
  flex-wrap:wrap;
}
.nav a{
  font-weight:600;
}
.search{
  margin-left:auto;
  display:flex;
  gap:8px;
}
.input, select{
  height:34px;
  padding:6px 10px;
  border:1px solid var(--border);
  border-radius:8px;
  outline:none;
}
.input:focus, select:focus{
  border-color:#c7d2fe;
  box-shadow:0 0 0 3px rgba(99,102,241,.15);
}

/* Buttons */
.btn{
  height:34px;
  padding:6px 12px;
  border-radius:10px;
  border:1px solid var(--border);
  background:#fff;
  cursor:pointer;
  font-weight:600;
}
.btn--primary{
  border-color: var(--accent);
  color: var(--accent);
}
.btn--primary:hover{
  background: rgba(31,157,58,.08);
}
.btn--ghost{
  border-color: transparent;
}
.btn--ghost:hover{
  background:#f3f4f6;
}

/* Cards / layout */
.grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap:16px;
}
@media (max-width: 860px){
  .grid{ grid-template-columns: 1fr; }
}

.card{
  background:var(--card);
  border:1px solid var(--border);
  border-radius:14px;
  padding:14px;
}
.card__row{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:flex-start;
}
.card__title{
  margin:0;
  font-size:18px;
  line-height:1.2;
}
.card__meta{
  margin:6px 0 0;
  color:var(--muted);
  font-size:13px;
}
.price{
  font-weight:800;
}
.badges{
  display:flex;
  gap:10px;
  margin-top:10px;
}
.pill{
  border:1px solid var(--border);
  border-radius:12px;
  padding:8px 10px;
  flex:1;
}
.pill h4{
  margin:0 0 6px;
  font-size:13px;
}
.pill ul{
  margin:0;
  padding-left:16px;
  color:var(--text);
  font-size:13px;
}
.pill .empty{
  color:var(--muted);
}

/* Pagination */
.pagination{
  margin-top:18px;
  display:flex;
  gap:12px;
  align-items:center;
}

/* Homepage - Latest Articles */

.latest-articles-section {
    margin-bottom: 32px;
}

.latest-articles-title {
    margin: 0 0 14px;
    font-size: 32px;
    font-weight: 800;
}

.latest-articles-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.article-card {
    position: relative;
    border: 1px solid #eaeaea;
    border-radius: 18px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.article-card-image-wrapper {
    position: relative;
}

.article-card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.55), transparent);
}

.article-card-image-title {
    position: absolute;
    bottom: 12px;
    left: 12px;
    right: 12px;
    color: #fff;
    font-weight: 800;
    font-size: 18px;
}

.article-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
}

.article-card-image-link {
    display: block;
    position: relative;
    text-decoration: none;
}

.article-card:active {
  transform: scale(0.98);
}

.article-card-image {
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    font-size: 28px;
    font-weight: 800;
    color: #fff;
    text-align: center;
}

.article-card-real-image {
    width: 100%;
    height: 185px;
    object-fit: cover;
    display: block;
}

.article-theme-gaming {
    background: linear-gradient(135deg, #1e1b4b, #4338ca);
}

.article-theme-office {
    background: linear-gradient(135deg, #0f172a, #334155);
}

.article-theme-budget {
    background: linear-gradient(135deg, #14532d, #22c55e);
}

.article-theme-default {
    background: linear-gradient(135deg, #374151, #6b7280);
}

.article-card-content {
  margin-top: -15px;
  position: relative;
  z-index: 2;
  background: white;
  border-radius: 18px;
  padding: 16px;
}

.article-card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.article-card-badge {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 999px;
    background: #eef2ff;
    color: #4338ca;
    text-decoration: none;
    font-size: 12px;
    font-weight: 700;
}

.article-card-badge:hover {
    background: #e0e7ff;
}

.article-card-date {
    color: #666;
    font-size: 13px;
}

.article-card-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 8px;
    color: #111;
    font-size: 20px;
    font-weight: 800;
    line-height: 1.3;
    text-decoration: none;
    transition: color 0.2s ease;
}

.article-card-title:hover {
    color: #4338ca;
}

.article-card-excerpt {
    margin: 0;
    color: #444;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .latest-articles-grid {
        grid-template-columns: 1fr;
    }

    .latest-articles-title {
        font-size: 26px;
    }

    .article-card-image {
        height: 150px;
        font-size: 24px;
    }
}

/* Article Detail */

.article-detail {
    max-width: 900px;
    margin: 0 auto;
    padding: 24px 16px 40px;
}

.article-detail-title {
    margin: 0 0 14px;
    font-size: 48px;
    line-height: 1.15;
    font-weight: 800;
    color: #0f172a;
}

.article-detail-category {
    margin: 0 0 18px;
    font-size: 16px;
    color: #475569;
}

.article-detail-category a {
    color: #4338ca;
    text-decoration: none;
    font-weight: 600;
}

.article-detail-hero {
    width: 100%;
    max-height: 460px;
    overflow: hidden;
    border-radius: 22px;
    margin: 0 0 24px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
}

.article-detail-hero-image {
    width: 100%;
    height: 100%;
    max-height: 460px;
    object-fit: cover;
    display: block;
}

.article-detail-content {
    color: #1f2937;
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 32px;
}

.article-detail-content p {
    white-space: pre-wrap;
    margin: 0;
}

/* =========================
   Premium Article Detail
========================= */

.article-page {
    max-width: 1180px;
    margin: 0 auto;
    padding: 42px 18px 64px;
}

.article-header {
    max-width: 860px;
    margin: 0 auto 26px;
}

.article-category-badge {
    display: inline-block;
    padding: 7px 13px;
    margin-bottom: 16px;
    border-radius: 999px;
    background: #eef2ff;
    color: #4338ca;
    text-decoration: none;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.2px;
}

.article-category-badge:hover {
    background: #e0e7ff;
}

.article-title {
    margin: 0 0 12px;
    font-size: 58px;
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -1.4px;
    color: #0f172a;
}

.article-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 18px;
    color: #64748b;
    font-size: 14px;
    font-weight: 600;
}

.article-excerpt {
    margin: 0;
    max-width: 760px;
    font-size: 22px;
    line-height: 1.65;
    color: #334155;
}

.article-hero {
    max-width: 1180px;
    margin: 0 auto 34px;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 16px 46px rgba(0, 0, 0, 0.1);
}

.article-hero-image {
    width: 100%;
    height: 500px;
    object-fit: cover;
    display: block;
}

.article-main-content {
    max-width: 860px;
    margin: 0 auto;
}

.article-quick-summary {
    margin-bottom: 28px;
}

.quick-summary-card {
    padding: 24px;
    border: 1px solid #e5e7eb;
    border-radius: 24px;
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
}

.quick-summary-label {
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #6366f1;
}

.quick-summary-text {
    margin: 0;
    font-size: 18px;
    line-height: 1.75;
    color: #1f2937;
}

.quick-summary-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.quick-summary-chip {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: #eef2ff;
    color: #4338ca;
    font-size: 13px;
    font-weight: 700;
}

.article-body-card {
    padding: 28px 30px;
    border: 1px solid #e5e7eb;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.03);
    margin-bottom: 40px;
}

.article-content-body {
    font-size: 19px;
    line-height: 1.95;
    color: #1f2937;
    min-width: 0;
    max-width: 100%;
    overflow-x: hidden;
}

.article-content-body table th,
.article-content-body table td {
  padding: 14px 16px;
  text-align: left;
  vertical-align: top;
}


.article-content-body p {
    margin: 0 0 1.4em;
}

.article-content-body p {
    margin: 0 0 1.4em;
}

.article-content-body h2 {
    margin: 2.2em 0 0.8em;
    margin-top: 2.5em;
    font-size: 32px;
    line-height: 1.2;
    font-weight: 900;
    color: #0f172a;
}

.article-content-body h3 {
    margin: 1.8em 0 0.7em;
    margin-top: 2.5em;
    font-size: 24px;
    line-height: 1.25;
    font-weight: 800;
    color: #0f172a;
}

.article-content-body ul,
.article-content-body ol {
    margin: 0 0 1.5em 1.4em;
    padding: 0;
}

.article-content-body li {
    margin-bottom: 0.55em;
}

.article-content-body strong {
    color: #111827;
}

.article-content-body a {
    color: #4338ca;
    font-weight: 700;
    text-decoration: none;
}

.article-content-body a:hover {
    text-decoration: underline;
}

.article-content-body blockquote {
    margin: 1.8em 0;
    padding: 18px 20px;
    border-left: 4px solid #4338ca;
    background: #f8fafc;
    border-radius: 14px;
    color: #334155;
}

.article-content-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.8em 0;
    overflow: hidden;
    border-radius: 14px;
    border: 1px solid #e5e7eb;
    background: #fff;
    table-layout: fixed;
}

.article-content-body th,
.article-content-body td {
    padding: 12px 14px;
    border-bottom: 1px solid #e5e7eb;
    text-align: left;
    vertical-align: top;
    word-break: normal;
    overflow-wrap: break-word;
}

/* Control column widths */
.article-content-body th:nth-child(1),
.article-content-body td:nth-child(1) {
  width: 38%;
}

.article-content-body th:nth-child(2),
.article-content-body td:nth-child(2) {
  width: 37%;
}

.article-content-body th:nth-child(3),
.article-content-body td:nth-child(3) {
  width: 25%;
  text-align: right;
  white-space: nowrap;
}

/* Prevent ugly breaks */
.article-content-body td {
  word-break: break-word;
}

.article-content-body th {
    background: #f8fafc;
    font-weight: 800;
    color: #111827;
}

.article-content-body hr {
    border: 0;
    border-top: 1px solid #e5e7eb;
    margin: 2em 0;
}

.article-content-body code {
    padding: 2px 6px;
    border-radius: 8px;
    background: #f3f4f6;
    font-size: 0.95em;
}

.article-content-body pre {
    margin: 1.6em 0;
    padding: 16px;
    border-radius: 16px;
    background: #0f172a;
    color: #e5e7eb;
    overflow-x: auto;
}

.article-content-body pre code {
    background: transparent;
    padding: 0;
    color: inherit;
}

.article-products-section {
    margin-top: 10px;
}

.article-section-header {
    margin-bottom: 18px;
}

.article-section-kicker {
    margin: 0 0 6px;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #6366f1;
}

.article-section-title {
    margin: 0;
    font-size: 34px;
    line-height: 1.15;
    font-weight: 900;
    color: #0f172a;
}

.article-products-grid {
    display: grid;
    gap: 18px;
}

.article-product-card {
    display: grid;
    grid-template-columns: 140px 1fr 160px;
    gap: 20px;
    align-items: start;
    padding: 20px;
    border: 1px solid #e5e7eb;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.03);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.article-product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.05);
}

.article-product-image {
    width: 140px;
    height: 140px;
    object-fit: cover;
    display: block;
    border-radius: 18px;
    background: #f8fafc;
}

.article-product-image-placeholder {
    width: 140px;
    height: 140px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    color: #94a3b8;
    font-weight: 700;
}

.article-product-topline {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 12px;
    margin-bottom: 8px;
}

.article-product-title {
    margin: 0;
    font-size: 24px;
    line-height: 1.25;
}

.article-product-title a {
    color: #111827;
    text-decoration: none;
    font-weight: 900;
}

.article-product-title a:hover {
    color: #4338ca;
}

.article-product-rating {
    flex-shrink: 0;
    padding: 6px 10px;
    border-radius: 999px;
    background: #fef3c7;
    color: #92400e;
    font-size: 13px;
    font-weight: 800;
}

.article-product-price {
    margin: 0 0 10px;
    font-size: 18px;
    font-weight: 800;
    color: #111827;
}

.article-product-description {
    margin: 0 0 16px;
    color: #4b5563;
    line-height: 1.65;
    font-size: 15px;
}

.article-product-points {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.article-product-points-title {
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.article-product-points-title-pros {
    color: #166534;
}

.article-product-points-title-cons {
    color: #991b1b;
}

.article-product-list {
    margin: 0;
    padding-left: 18px;
    line-height: 1.7;
    font-size: 14px;
}

.article-product-list-pros li::marker {
    color: #16a34a;
}

.article-product-list-cons li::marker {
    color: #dc2626;
}

.article-product-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.article-product-secondary-btn,
.article-product-primary-btn {
    text-decoration: none;
    font-weight: 800;
    border-radius: 14px;
    padding: 11px 16px;
    transition: all 0.18s ease;
    text-align: center;
}

.article-product-secondary-btn {
    border: 1px solid #d1d5db;
    color: #111827;
    background: #fff;
}

.article-product-secondary-btn:hover {
    border-color: #9ca3af;
    background: #f9fafb;
}

.article-product-primary-btn {
    background: #4338ca;
    color: #fff;
    border: 1px solid #4338ca;
}

.article-product-primary-btn:hover {
    background: #3730a3;
    border-color: #3730a3;
}

.article-empty-products-card {
    padding: 20px;
    border: 1px dashed #d1d5db;
    border-radius: 18px;
    color: #6b7280;
    background: #fff;
}

.article-bottom-nav {
    margin-top: 28px;
}

.article-back-link {
    display: inline-block;
    text-decoration: none;
    color: #4338ca;
    font-weight: 800;
}

@media (max-width: 980px) {
    .article-title {
        font-size: 42px;
    }

    .article-excerpt {
        font-size: 18px;
    }

    .article-hero-image {
        height: 320px;
    }

    .article-body-card {
        padding: 22px 20px;
    }

    .article-content-body {
        font-size: 17px;
        line-height: 1.85;
    }

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

    .article-product-image,
    .article-product-image-placeholder {
        width: 100%;
        max-width: 180px;
        height: 180px;
    }

    .article-product-actions {
        width: 100%;
    }

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

@media (max-width: 640px) {
    .article-page {
        padding: 28px 14px 46px;
    }

    .article-title {
        font-size: 34px;
        line-height: 1.08;
    }

    .article-excerpt {
        font-size: 17px;
    }

    .article-hero {
        border-radius: 18px;
    }

    .article-hero-image {
        height: 240px;
    }

    .quick-summary-card,
    .article-body-card {
        border-radius: 18px;
        padding: 18px;
    }

    .article-content-body {
        font-size: 16px;
    }

    .article-section-title {
        font-size: 28px;
    }
}

.article-content-body a.button-link {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 16px;
    border-radius: 12px;
    background: #4338ca;
    color: #fff;
    font-weight: 800;
    text-decoration: none;
}

.article-content-body a.button-link:hover {
    background: #3730a3;
}

.article-content-body table tr:hover {
    background: #f9fafb;
}

.inline-product-card {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 18px;
    align-items: center;
    margin: 28px 0;
    padding: 18px;
    border: 1px solid #e5e7eb;
    border-radius: 22px;
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.04);
}

.inline-product-card-media {
    width: 140px;
}

.inline-product-card-image-link {
    display: block;
    text-decoration: none;
}

.inline-product-image-wrap {
    margin: 28px 0;
    text-align: center;
}

.inline-product-image-link {
    display: inline-block;
    text-decoration: none;
}

.inline-product-image {
    max-width: 100%;
    width: 420px;
    height: auto;
    display: block;
    border-radius: 18px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
}

.inline-product-image-placeholder {
    width: 420px;
    max-width: 100%;
    height: 240px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    background: #f1f5f9;
    color: #94a3b8;
    font-weight: 700;
}

.inline-product-image-caption {
    margin-top: 10px;
    color: #475569;
    font-weight: 700;
    font-size: 14px;
    text-align: center;
}

.inline-product-button-wrap {
    margin: 20px 0 28px;
}

.inline-product-button {
    display: inline-block;
    padding: 12px 18px;
    border-radius: 14px;
    background: #4338ca;
    color: #ffffff !important;
    text-decoration: none;
    font-weight: 800;
    line-height: 1;
    transition: background 0.18s ease, transform 0.18s ease;
}

.inline-product-button:visited {
    color: #ffffff !important;
}

.inline-product-button:hover {
    background: #3730a3;
    color: #ffffff !important;
    text-decoration: none;
    transform: translateY(-1px);
}

.inline-product-button:focus,
.inline-product-button:active {
    color: #ffffff !important;
    text-decoration: none;
}

/* =========================
   Category Detail Page
========================= */

.category-page {
    max-width: 1180px;
    margin: 0 auto;
    padding: 42px 18px 64px;
}

.category-header {
    margin-bottom: 34px;
}

.category-kicker,
.section-kicker {
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #6366f1;
}

.category-title {
    margin: 0 0 10px;
    font-size: 44px;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #0f172a;
}

.category-description {
    margin: 0;
    max-width: 760px;
    font-size: 18px;
    line-height: 1.6;
    color: #475569;
}

.section-heading {
    margin-bottom: 20px;
}

.section-title {
    margin: 0;
    font-size: 26px;
    line-height: 1.2;
    font-weight: 800;
    color: #0f172a;
}

.category-featured-articles {
    margin-bottom: 38px;
}

.category-articles-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}


.category-products-section {
    margin-top: 8px;
}

.category-products-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.category-product-card {
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.04);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.category-product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.06);
}

.category-product-image-link {
    display: block;
    text-decoration: none;
    background: #f8fafc;
}

.category-product-image {
    width: 100%;
    height: 200px;
    object-fit: contain;
    display: block;
    padding: 20px;
}

.category-product-body {
    padding: 20px;
}

.category-product-title {
    margin: 0 0 6px;
    font-size: 20px;
    line-height: 1.3;
}

.category-product-title a {
    text-decoration: none;
    color: #111827;
    font-weight: 900;
}

.category-product-title a:hover {
    color: #4338ca;
}

.category-product-price {
    margin: 0 0 12px;
    font-size: 20px;
    font-weight: 800;
    color: #111827;
}

.category-product-description {
    margin: 0 0 18px;
    color: #4b5563;
    line-height: 1.7;
}

.category-product-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.category-product-secondary-btn,
.category-product-primary-btn {
    display: inline-block;
    padding: 11px 16px;
    border-radius: 14px;
    text-decoration: none;
    font-weight: 800;
    transition: all 0.18s ease;
}

.category-product-secondary-btn {
    border: 1px solid #d1d5db;
    background: #fff;
    color: #111827;
}

.category-product-secondary-btn:hover {
    background: #f9fafb;
    border-color: #9ca3af;
}

.category-product-primary-btn {
    border: 1px solid #4338ca;
    background: #4338ca;
    color: #fff;
}

.category-product-primary-btn:hover {
    background: #3730a3;
    border-color: #3730a3;
}

.category-back-link-wrap {
    margin-top: 30px;
}

.category-back-link {
    text-decoration: none;
    color: #4338ca;
    font-weight: 800;
}

@media (max-width: 900px) {
    .category-title {
        font-size: 42px;
    }

    .category-description {
        font-size: 18px;
    }

    .category-articles-grid,
    .category-products-grid {
        grid-template-columns: 1fr;
    }

    .section-title {
        font-size: 28px;
    }
}

@media (max-width: 640px) {
    .category-page {
        padding: 28px 14px 46px;
    }

    .category-title {
        font-size: 34px;
        line-height: 1.08;
    }

    .category-description {
        font-size: 17px;
    }

    .category-article-card,
    .category-product-card {
        border-radius: 18px;
    }

    .category-article-image {
        height: 200px;
    }

    .category-product-image {
        height: 200px;
    }

    .category-article-card-body,
    .category-product-body {
        padding: 18px;
    }
}

/* =========================
   Articles List Page
========================= */

.articles-page {
    max-width: 1180px;
    margin: 0 auto;
    padding: 42px 18px 64px;
}

.articles-header {
    margin-bottom: 28px;
}

.articles-kicker {
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #6366f1;
}

.articles-title {
    margin: 0 0 10px;
    font-size: 44px;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #0f172a;
}

.articles-description {
    margin: 0;
    max-width: 760px;
    font-size: 18px;
    line-height: 1.6;
    color: #475569;
}

.articles-toolbar {
    margin-bottom: 24px;
}

.articles-search-form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.articles-search-input {
    width: 320px;
    max-width: 100%;
    padding: 12px 14px;
    border: 1px solid #d1d5db;
    border-radius: 14px;
    font-size: 15px;
    outline: none;
    background: #fff;
}

.articles-search-input:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

.articles-search-button {
    padding: 12px 16px;
    border: 1px solid #4338ca;
    border-radius: 14px;
    background: #4338ca;
    color: #fff;
    font-weight: 800;
    cursor: pointer;
}

.articles-search-button:hover {
    background: #3730a3;
    border-color: #3730a3;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.category-article-link {
    text-decoration: none;
    color: #4338ca;
    font-weight: 800;
}

.articles-card-link {
    text-decoration: none;
    color: #4338ca;
    font-weight: 800;
}

.articles-empty {
    color: #6b7280;
}

.articles-pagination {
    margin-top: 28px;
    display: flex;
    gap: 16px;
    align-items: center;
    flex-wrap: wrap;
}

.articles-pagination-link {
    text-decoration: none;
    color: #4338ca;
    font-weight: 800;
}

.articles-pagination-current {
    color: #475569;
    font-weight: 600;
}

@media (max-width: 900px) {
    .articles-grid {
        grid-template-columns: 1fr;
    }

    .articles-title {
        font-size: 36px;
    }

    .articles-card-title {
        font-size: 22px;
    }
}

@media (max-width: 640px) {
    .articles-page {
        padding: 28px 14px 46px;
    }

    .articles-title {
        font-size: 32px;
    }

    .articles-description {
        font-size: 16px;
    }

    .articles-card {
        border-radius: 18px;
    }

    .articles-card-image {
        height: 200px;
    }

    .articles-card-body {
        padding: 16px 18px 18px;
    }
}

/* =========================
   Product List Page
========================= */

.products-page {
    max-width: 1180px;
    margin: 0 auto;
    padding: 42px 18px 64px;
}

.products-header {
    margin-bottom: 28px;
}

.products-kicker {
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #6366f1;
}

.products-title {
    margin: 0 0 10px;
    font-size: 44px;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #0f172a;
}

.products-description {
    margin: 0;
    max-width: 760px;
    font-size: 18px;
    line-height: 1.6;
    color: #475569;
}

.products-toolbar {
    margin-bottom: 24px;
}

.products-toolbar-form {
    display: grid;
    grid-template-columns: minmax(240px, 1.4fr) 180px 150px auto;
    gap: 12px;
    align-items: center;
}

.products-toolbar-input,
.products-toolbar-select {
    height: 46px;
    padding: 0 14px;
    border: 1px solid #d1d5db;
    border-radius: 14px;
    font-size: 15px;
    background: #fff;
    outline: none;
    box-sizing: border-box;
}

.products-toolbar-input {
    width: 280px;
    max-width: 100%;
}

.products-toolbar-input:focus,
.products-toolbar-select:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

.products-toolbar-button {
    height: 46px;
    padding: 0 18px;
    border: 1px solid #4338ca;
    border-radius: 14px;
    background: #4338ca;
    color: #fff;
    font-weight: 800;
    cursor: pointer;
    box-sizing: border-box;
}

.products-toolbar-button:hover {
    background: #3730a3;
    border-color: #3730a3;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.product-card {
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.04);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.06);
}

.product-card-image-link {
    display: block;
    text-decoration: none;
}

.product-card-image {
    width: 100%;
    height: 250px;
    object-fit: contain;
    display: block;
    padding: 18px;
    background: #f8fafc;
}

.product-card-image-placeholder {
    width: 100%;
    height: 150px;
    border: 1px dashed #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #777;
    background: #f8fafc;
}

.product-card-body {
    padding: 16px;
}

.product-card-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    margin-top: 2px;
}

.product-card-title {
    margin: 0;
    font-size: 20px;
    line-height: 1.25;
    font-weight: 800;
}

.product-card-title a {
    text-decoration: none;
    color: #4338ca;
}

.product-card-title a:hover {
    color: #312e81;
}

.product-card-rating {
    white-space: nowrap;
    display: flex;
    align-items: center;
}

.product-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin: 10px 0 12px;
}

.product-card-category-badge {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 999px;
    background: #eef2ff;
    color: #4338ca;
    text-decoration: none;
    font-size: 12px;
    font-weight: 700;
}

.product-card-category-badge--muted {
    background: #f3f4f6;
    color: #6b7280;
}

.product-card-price {
    font-weight: 800;
    font-size: 18px;
    color: #111827;
}

.product-card-description {
    margin: 0 0 12px;
    color: #374151;
    line-height: 1.6;
    min-height: 52px;
}

.product-card-points {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin: 12px 0 14px;
}

.product-card-points-box {
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 12px;
}

.product-card-points-title {
    font-weight: 800;
    margin-bottom: 6px;
    color: #111827;
}

.product-card-list {
    margin: 0;
    padding-left: 18px;
    color: #374151;
}

.product-card-empty {
    color: #777;
}

.product-card-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: 4px;
}

.product-card-buy {
    display: inline-block;
    padding: 10px 12px;
    border: 1px solid #2e9b45;
    border-radius: 10px;
    text-decoration: none;
    color: #2e9b45;
    font-weight: 700;
}

.product-card-buy:hover {
    background: #f3fff7;
}

.product-card-details {
    display: inline-block;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    text-decoration: none;
    color: #4338ca;
    font-weight: 700;
}

.product-card-details:hover {
    background: #f9fafb;
}

.products-empty {
    color: #6b7280;
}

.products-pagination {
    margin-top: 18px;
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.products-pagination-link {
    text-decoration: none;
    color: #4338ca;
    font-weight: 700;
}

.products-pagination-current {
    color: #475569;
    font-weight: 600;
}

@media (max-width: 900px) {
    .products-grid {
        grid-template-columns: 1fr;
    }

    .products-title {
        font-size: 36px;
    }

    .product-card-title {
        font-size: 22px;
    }
}

@media (max-width: 640px) {
    .products-page {
        padding: 28px 14px 46px;
    }

    .products-toolbar-form {
        grid-template-columns: 1fr;
    }

    .products-title {
        font-size: 32px;
    }

    .products-description {
        font-size: 16px;
    }

    .product-card {
        border-radius: 18px;
    }

    .product-card-image,
    .product-card-image-placeholder {
        height: 180px;
    }

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

/* =========================
   REAL Mobile Fix (your layout)
========================= */
@media (max-width: 768px) {

  /* Header layout */
  .header__inner {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 12px 0;
  }

  .nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 14px;
    align-items: center;
    justify-content: flex-start;
  }

  .search {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    align-items: center;
  }


  .nav a {
    font-size: 0.98rem;
    line-height: 1.2;
    white-space: nowrap;
  }

  .search input {
    width: 100%;
    flex: 1;
  }

  .search .input {
    min-width: 0;
    width: 100%;
  }

  .search .btn {
    white-space: nowrap;
  }

  /* Products grid fix */
  .products-grid {
    grid-template-columns: 1fr;
  }

  /* Product card layout fix */
  .product-card {
    padding: 14px;
  }

  .product-card-title {
    font-size: 18px;
    word-break: break-word;
  }

  .product-card-image {
    height: 200px;
  }

  .product-card-actions {
    flex-direction: column;
    gap: 8px;
  }

  .product-card-actions a {
    width: 100%;
    text-align: center;
  }

  /* Article grids */
  .articles-grid,
  .latest-articles-grid,
  .category-articles-grid {
    grid-template-columns: 1fr;
  }

  /* Category products */
  .category-products-grid {
    grid-template-columns: 1fr;
  }

  /* Toolbar (filters/search) */
  .products-toolbar-form {
    grid-template-columns: 1fr;
  }

  .articles-search-form {
    flex-direction: column;
  }

  .articles-search-input {
    width: 100%;
  }

}

.home-section {
  margin-bottom: 26px;
}

.home-section--small {
  margin-bottom: 10px;
}

.home-section-title {
  margin: 0 0 10px;
}

.home-product-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.home-product-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid #eee;
  border-radius: 16px;
  padding: 14px;
  box-sizing: border-box;
  background: #fff;
  min-width: 0;
}

.home-product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.home-product-image {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 12px;
  display: block;
}

.home-product-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  margin-top: 10px;
}

.home-product-name {
  font-weight: 700;
  font-size: 16px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.home-product-category {
  font-size: 13px;
  color: #666;
  margin-top: 2px;
}

.home-product-rating {
  white-space: nowrap;
  flex: 0 0 auto;
}

.home-product-meta,
.home-product-submeta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}

.home-product-clicks {
  font-size: 12px;
  color: #666;
  white-space: nowrap;
}

.home-product-price {
  margin-top: 8px;
}

.home-product-actions {
  display: flex;
  gap: 10px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.home-category-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Mobile */
@media (max-width: 768px) {
  .home-product-row {
    display: flex;
    flex-wrap: nowrap;
    gap: 16px;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 8px;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
  }

  .home-product-row > * {
    flex: 0 0 85%;
    max-width: 85%;
    min-width: 85%;
    scroll-snap-align: start;
  }

  .home-product-row::-webkit-scrollbar,
  .home-category-row::-webkit-scrollbar {
    height: 6px;
  }

  .home-product-header,
  .home-product-meta,
  .home-product-submeta {
    flex-wrap: wrap;
  }

  .home-product-rating {
    white-space: normal;
  }

  .home-product-actions {
    gap: 12px;
  }

  .home-category-row {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 6px;
    -webkit-overflow-scrolling: touch;
  }

  .home-category-row > * {
    flex: 0 0 auto;
  }
}

@media (max-width: 480px) {
  .header__inner {
    gap: 10px;
  }

  .nav {
    gap: 8px 12px;
  }

  .nav a {
    font-size: 0.92rem;
  }

  .search {
    grid-template-columns: 1fr auto;
    gap: 8px;
  }

  .search .btn {
    padding-left: 12px;
    padding-right: 12px;
  }
}

.page-title {
  margin: 0 0 8px;
  font-size: 2.4rem;
  line-height: 1.1;
}

.page-subtitle {
  margin: 0 0 20px;
  color: #666;
  font-size: 1rem;
}

.top-products-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

@media (max-width: 1024px) {
  .top-products-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .page-title {
    font-size: 2rem;
  }

  .top-products-grid {
    display: flex;
    flex-wrap: nowrap;
    gap: 16px;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 8px;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
  }

  .top-products-grid > * {
    flex: 0 0 85%;
    max-width: 85%;
    min-width: 85%;
    scroll-snap-align: start;
  }
}

.rating-stars {
  display: inline-flex;
  gap: 3px;
  align-items: center;
  white-space: nowrap;
}

.rating-star {
  position: relative;
  display: inline-block;
  line-height: 1;
  font-size: 1em;
}

.rating-star.full {
  color: #1f9d3a;
}

.rating-star.empty {
  color: #bbb;
}

.rating-star.half {
  color: #bbb;
}

.rating-star.half::before {
  content: "★";
  position: absolute;
  left: 0;
  top: 0;
  width: 50%;
  overflow: hidden;
  color: #1f9d3a;
}

.rating-text {
  color: #666;
  font-size: 12px;
  margin-left: 6px;
}

@media (max-width: 768px) {
  .article-content-body {
    overflow-x: hidden;
  }
}

@media (max-width: 768px) {
  .article-content-body th,
  .article-content-body td {
    padding: 12px 10px;
    font-size: 0.95rem;
  }

  .article-content-body th:nth-child(1),
  .article-content-body td:nth-child(1) {
    width: 42%;
  }

  .article-content-body th:nth-child(2),
  .article-content-body td:nth-child(2) {
    width: 33%;
  }

  .article-content-body th:nth-child(3),
  .article-content-body td:nth-child(3) {
    width: 25%;
    min-width: 84px;
    text-align: right;
    white-space: nowrap;
  }
}

.analytics-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 20px;
}

.analytics-header {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: flex-end;
  margin-bottom: 32px;
}

.eyebrow {
  color: #4f46e5;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  margin-bottom: 8px;
}

.analytics-header h1 {
  font-size: 2.4rem;
  margin: 0;
}

.page-subtitle {
  color: #666;
  margin-top: 8px;
  max-width: 560px;
}

.analytics-filter {
  display: flex;
  gap: 10px;
  align-items: center;
  background: #fff;
  border: 1px solid #e5e7eb;
  padding: 12px;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

.analytics-filter label {
  font-weight: 600;
}

.analytics-filter select,
.analytics-filter button {
  padding: 9px 12px;
  border-radius: 10px;
  border: 1px solid #d1d5db;
}

.analytics-filter button {
  background: #111827;
  color: #fff;
  cursor: pointer;
  font-weight: 700;
}

.analytics-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}

.analytics-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.07);
}

.card-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 20px;
}

.card-header h2 {
  margin: 0;
  font-size: 1.35rem;
}

.card-header span {
  color: #6b7280;
  font-size: 0.9rem;
}

.top-products-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.top-products-list li {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 13px 0;
  border-bottom: 1px solid #f0f0f0;
}

.top-products-list li:last-child {
  border-bottom: none;
}

.rank {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #eef2ff;
  color: #3730a3;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
}

.top-products-list a {
  font-weight: 600;
  text-decoration: none;
}

.top-products-list a:hover {
  text-decoration: underline;
}

.top-products-list strong {
  white-space: nowrap;
}

.analytics-table {
  width: 100%;
  border-collapse: collapse;
}

.analytics-table th,
.analytics-table td {
  padding: 12px;
  border-bottom: 1px solid #e5e7eb;
  text-align: left;
}

.analytics-table th {
  background: #f9fafb;
  font-size: 0.9rem;
}

.empty-state {
  color: #6b7280;
  background: #f9fafb;
  padding: 16px;
  border-radius: 12px;
}

@media (max-width: 800px) {
  .analytics-header {
    flex-direction: column;
    align-items: stretch;
  }

  .analytics-filter {
    flex-wrap: wrap;
  }

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

  .top-products-list li {
    grid-template-columns: 32px 1fr;
  }

  .top-products-list strong {
    grid-column: 2;
  }
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

.stat-card {
  background: white;
  border-radius: 18px;
  padding: 24px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.stat-card p {
  color: #6b7280;
  margin-bottom: 10px;
}

.stat-card h2 {
  font-size: 2rem;
  margin: 0;
}