/* ==========================================================
   SPORTY – Trang con
   ========================================================== */

/* ---------- Shop ---------- */
.shop-layout { display: grid; grid-template-columns: 250px 1fr; gap: 36px; align-items: start; }
.shop-sidebar { position: sticky; top: calc(var(--header-h) + 20px); display: flex; flex-direction: column; gap: 22px; }
.filter-box { padding: 20px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--white); }
.filter-box h3 { margin-bottom: 14px; font-size: 14px; font-weight: 800; text-transform: uppercase; color: var(--dark); }
.filter-list li + li { margin-top: 4px; }
.filter-list button {
  display: flex; justify-content: space-between; width: 100%; padding: 8px 10px;
  border: 0; border-radius: var(--radius); background: none; text-align: left; font-size: 14px;
  transition: background var(--ease), color var(--ease);
}
.filter-list button span { color: var(--muted); font-size: 12px; }
.filter-list button:hover { background: var(--bg-alt); color: var(--primary); }
.filter-list button.is-active { background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.filter-radio { display: flex; align-items: center; gap: 10px; padding: 6px 2px; font-size: 14px; cursor: pointer; }
.filter-radio input { accent-color: var(--primary); width: 16px; height: 16px; }
.filter-promo {
  position: relative; overflow: hidden; display: block; padding: 24px 20px; border-radius: var(--radius-lg);
  background: var(--dark) url('../images/banners/promo-sale.jpg') right center / cover; color: var(--white);
}
.filter-promo::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(16, 27, 41, .95) 40%, rgba(16, 27, 41, .2)); }
.filter-promo > * { position: relative; }
.filter-promo strong { display: block; font-size: 40px; font-weight: 900; font-style: italic; color: #3aa6ff; line-height: 1.1; }
.filter-promo p { margin: 4px 0 14px; font-size: 13px; }

.shop-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.shop-toolbar p { font-size: 14px; color: var(--muted); }
.shop-toolbar p strong { color: var(--dark); }
.shop-toolbar select { height: 42px; padding: 0 36px 0 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); font-size: 13px; }
.shop-toolbar > div { display: flex; gap: 10px; }
.filter-open { display: none; }
.shop-grid { grid-template-columns: repeat(4, 1fr); row-gap: 32px; }
.empty-state { grid-column: 1 / -1; padding: 60px 20px; text-align: center; color: var(--muted); }
.empty-state h3 { margin-bottom: 8px; font-size: 18px; color: var(--dark); }
.empty-state .btn { margin-top: 18px; }

/* ---------- Product detail ---------- */
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.detail-gallery { position: sticky; top: calc(var(--header-h) + 20px); }
.detail-main { position: relative; overflow: hidden; aspect-ratio: 1; border-radius: var(--radius-lg); background: #f2f3f6; cursor: zoom-in; }
.detail-main img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.detail-main:hover img { transform: scale(1.6); }
.detail-main .badge-sale { top: 16px; left: 16px; font-size: 13px; padding: 4px 10px; }
.detail-info h1 { font-size: 30px; font-weight: 800; color: var(--dark); }
.detail-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; margin-top: 12px; font-size: 13px; color: var(--muted); }
.detail-meta .stars { font-size: 15px; }
.detail-meta [data-d-rating] { display: inline-flex; align-items: center; gap: 8px; }
.detail-meta .in-stock { color: #16a34a; font-weight: 600; }
.detail-price { display: flex; align-items: baseline; gap: 14px; margin: 22px 0; padding: 18px 20px; border-radius: var(--radius-lg); background: var(--bg-alt); }
.detail-price strong { font-size: 30px; font-weight: 800; color: var(--sale); }
.detail-price del { color: #9aa1ac; }
.detail-price .save { padding: 2px 8px; border-radius: 4px; background: var(--sale); color: var(--white); font-size: 12px; font-weight: 700; }
.detail-desc { color: #4a5566; }
.option-group { margin-top: 24px; }
.option-group > span { display: block; margin-bottom: 10px; font-size: 14px; font-weight: 700; }
.option-list { display: flex; flex-wrap: wrap; gap: 10px; }
.option-list button {
  min-width: 48px; height: 42px; padding: 0 14px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--white); font-size: 13px; font-weight: 600;
  transition: border-color var(--ease), color var(--ease), background var(--ease);
}
.option-list button:hover { border-color: var(--primary); color: var(--primary); }
.option-list button.is-active { border-color: var(--primary); background: var(--primary); color: var(--white); }
.color-list button { display: flex; align-items: center; gap: 8px; }
.color-list i { width: 16px; height: 16px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .1); }
.color-list button.is-active i { border-color: var(--white); }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: var(--radius); }
.qty button { width: 40px; height: 44px; border: 0; background: none; font-size: 18px; transition: color var(--ease); }
.qty button:hover { color: var(--primary); }
.qty input { width: 48px; height: 44px; border: 0; text-align: center; font-weight: 700; -moz-appearance: textfield; }
.qty input::-webkit-inner-spin-button { -webkit-appearance: none; }
.detail-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.detail-actions .btn { flex: 1; min-width: 160px; min-height: 50px; text-transform: uppercase; }
.detail-actions .wish-btn { position: static; width: 50px; height: 50px; border: 1px solid var(--line); background: var(--white); }
.detail-perks { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 13px; }
.detail-perks li { display: flex; align-items: center; gap: 10px; }
.detail-perks svg { width: 22px; height: 22px; color: var(--primary); }

.tabs { margin-top: 64px; }
.tab-nav { display: flex; gap: 32px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab-nav button {
  position: relative; padding: 14px 0; border: 0; background: none; white-space: nowrap;
  font-size: 15px; font-weight: 700; color: var(--muted); transition: color var(--ease);
}
.tab-nav button::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--primary); transform: scaleX(0); transition: transform var(--ease); }
.tab-nav button.is-active { color: var(--dark); }
.tab-nav button.is-active::after { transform: scaleX(1); }
.tab-panel { padding: 28px 0 0; color: #4a5566; }
.tab-panel[hidden] { display: none; }
.tab-panel ul { padding-left: 18px; list-style: disc; }
.tab-panel li + li { margin-top: 6px; }
.spec-table { width: 100%; max-width: 640px; border-collapse: collapse; font-size: 14px; }
.spec-table th, .spec-table td { padding: 12px 16px; border-bottom: 1px solid var(--line); text-align: left; }
.spec-table th { width: 38%; background: var(--bg-alt); font-weight: 600; color: var(--dark); }
.review { padding: 18px 0; border-bottom: 1px solid var(--line); }
.review-head { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.review-head strong { color: var(--dark); }
.review-head time { margin-left: auto; font-size: 12px; color: var(--muted); }

/* ---------- Cart ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 32px; align-items: start; }
.cart-list { border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.cart-row { display: grid; grid-template-columns: 90px 1fr auto auto 36px; align-items: center; gap: 20px; padding: 18px 20px; }
.cart-row + .cart-row { border-top: 1px solid var(--line); }
.cart-row img { width: 90px; height: 90px; border-radius: var(--radius); object-fit: cover; background: #f2f3f6; }
.cart-row h3 { font-size: 14px; font-weight: 600; }
.cart-row h3 a:hover { color: var(--primary); }
.cart-row small { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; }
.cart-row .line-price { min-width: 110px; text-align: right; font-weight: 700; color: var(--sale); }
.cart-row .remove { width: 36px; height: 36px; border: 0; border-radius: 50%; background: none; font-size: 20px; color: var(--muted); transition: background var(--ease), color var(--ease); }
.cart-row .remove:hover { background: #fdecec; color: var(--sale); }
.cart-summary { position: sticky; top: calc(var(--header-h) + 20px); padding: 24px; border-radius: var(--radius-lg); background: var(--bg-alt); }
.cart-summary h2 { margin-bottom: 18px; font-size: 18px; font-weight: 800; text-transform: uppercase; }
.sum-row { display: flex; justify-content: space-between; padding: 8px 0; font-size: 14px; }
.sum-row.total { margin-top: 10px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 16px; font-weight: 800; }
.sum-row.total span:last-child { color: var(--sale); font-size: 20px; }
.ship-note { margin: 14px 0 18px; font-size: 12px; color: var(--muted); }
.ship-bar { height: 6px; margin-top: 8px; border-radius: 6px; background: #dfe4ea; overflow: hidden; }
.ship-bar i { display: block; height: 100%; background: var(--primary); transition: width .4s ease; }
.coupon { display: flex; gap: 8px; margin-bottom: 18px; }
.coupon .input { height: 42px; }
.coupon .btn { min-height: 42px; padding: 0 16px; }

/* ---------- News ---------- */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.news-card { display: flex; flex-direction: column; overflow: hidden; border-radius: var(--radius-lg); background: var(--white); box-shadow: var(--shadow); transition: transform var(--ease), box-shadow var(--ease); }
.news-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.news-thumb { display: block; aspect-ratio: 16 / 10; background: #eef0f3; }
.news-thumb img { width: 100%; height: 100%; object-fit: cover; }
.news-body { display: flex; flex-direction: column; flex: 1; gap: 10px; padding: 20px 22px 24px; }
.news-meta { display: flex; gap: 12px; font-size: 12px; color: var(--muted); }
.news-tag { color: var(--primary); font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.news-body h2, .news-body h3 { font-size: 16px; font-weight: 700; line-height: 1.45; color: var(--dark); }
.news-card:hover h2, .news-card:hover h3 { color: var(--primary); }
.news-body p { font-size: 13px; color: var(--muted); }
.news-body .link-more { margin-top: auto; padding-top: 6px; }
.news-card--featured { grid-column: 1 / -1; flex-direction: row; }
.news-card--featured .news-thumb { flex: 1.3; aspect-ratio: auto; min-height: 340px; }
.news-card--featured .news-body { flex: 1; justify-content: center; padding: 36px 40px; }
.news-card--featured h2 { font-size: 24px; }
.news-card--featured p { font-size: 14px; }

.article-layout { display: grid; grid-template-columns: 1fr 320px; gap: 48px; align-items: start; }
.article-cover { overflow: hidden; border-radius: var(--radius-lg); aspect-ratio: 16 / 8; margin-bottom: 28px; background: #eef0f3; }
.article-cover img { width: 100%; height: 100%; object-fit: cover; }
.article h1 { font-size: 32px; font-weight: 800; color: var(--dark); }
.article .news-meta { margin: 12px 0 24px; }
.article-content { color: #3b4556; font-size: 15px; line-height: 1.8; }
.article-content p + p, .article-content h2 + p, .article-content ul + p { margin-top: 14px; }
.article-content h2 { margin: 30px 0 12px; font-size: 20px; font-weight: 800; color: var(--dark); }
.article-content ul { margin-top: 10px; padding-left: 20px; list-style: disc; }
.article-content blockquote { margin: 24px 0; padding: 18px 24px; border-left: 4px solid var(--primary); background: var(--primary-soft); font-style: italic; color: var(--dark); border-radius: 0 var(--radius) var(--radius) 0; }
.article-share { display: flex; align-items: center; gap: 12px; margin-top: 32px; padding-top: 22px; border-top: 1px solid var(--line); font-weight: 600; }
.article-share .social a { background: var(--bg-alt); color: var(--dark); }
.article-share .social a:hover { background: var(--primary); color: var(--white); }
.side-box { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius-lg); }
.side-box + .side-box { margin-top: 22px; }
.side-box h3 { margin-bottom: 16px; font-size: 14px; font-weight: 800; text-transform: uppercase; }
.side-post { display: grid; grid-template-columns: 76px 1fr; gap: 12px; align-items: center; }
.side-post + .side-post { margin-top: 14px; }
.side-post img { width: 76px; height: 60px; border-radius: var(--radius); object-fit: cover; }
.side-post strong { display: block; font-size: 13px; line-height: 1.45; font-weight: 600; }
.side-post:hover strong { color: var(--primary); }
.side-post small { color: var(--muted); font-size: 11px; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-cloud a { padding: 6px 12px; border-radius: 20px; background: var(--bg-alt); font-size: 12px; transition: background var(--ease), color var(--ease); }
.tag-cloud a:hover { background: var(--primary); color: var(--white); }

/* ---------- Contact ---------- */
.contact-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 48px; }
.contact-card { padding: 26px 22px; border: 1px solid var(--line); border-radius: var(--radius-lg); text-align: center; transition: border-color var(--ease), transform var(--ease), box-shadow var(--ease); }
.contact-card:hover { border-color: var(--primary); transform: translateY(-4px); box-shadow: var(--shadow); }
.contact-card span { display: grid; place-items: center; width: 54px; height: 54px; margin: 0 auto 14px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); }
.contact-card svg { width: 24px; height: 24px; }
.contact-card h3 { font-size: 15px; font-weight: 700; }
.contact-card p { margin-top: 6px; font-size: 13px; color: var(--muted); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.contact-form { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.contact-form .full { grid-column: 1 / -1; }
.contact-form h2 { grid-column: 1 / -1; font-size: 24px; font-weight: 800; text-transform: uppercase; }
.contact-form > p { grid-column: 1 / -1; margin-top: -10px; color: var(--muted); }
.map { overflow: hidden; min-height: 420px; border-radius: var(--radius-lg); background: var(--bg-alt); }
.map iframe { display: block; width: 100%; height: 100%; min-height: 420px; border: 0; }

/* ---------- Auth ---------- */
.auth-wrap { display: grid; grid-template-columns: 1fr 1fr; max-width: 1000px; margin: 0 auto; overflow: hidden; border-radius: var(--radius-lg); box-shadow: var(--shadow-hover); }
.auth-media { position: relative; background: #cfe4f7 url('../images/hero/hero-1.jpg') 65% center / cover; min-height: 560px; }
.auth-media::after { content: ''; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(16, 27, 41, .75), transparent 55%); }
.auth-media p { position: absolute; left: 32px; right: 32px; bottom: 32px; z-index: 1; color: var(--white); font-size: 22px; font-weight: 800; font-style: italic; text-transform: uppercase; line-height: 1.25; }
.auth-media p span { color: #58b1ff; }
.auth-box { padding: 44px 44px 40px; background: var(--white); }
.auth-tabs { display: flex; gap: 6px; margin-bottom: 28px; padding: 5px; border-radius: var(--radius); background: var(--bg-alt); }
.auth-tabs button { flex: 1; height: 42px; border: 0; border-radius: var(--radius); background: none; font-weight: 700; color: var(--muted); transition: background var(--ease), color var(--ease); }
.auth-tabs button.is-active { background: var(--white); color: var(--dark); box-shadow: 0 2px 8px rgba(16, 27, 41, .08); }
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-form[hidden] { display: none; }
.auth-row { display: flex; justify-content: space-between; align-items: center; font-size: 13px; }
.auth-row label { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.auth-row input { accent-color: var(--primary); }
.auth-row a { color: var(--primary); font-weight: 600; }
.auth-note { font-size: 12px; color: var(--muted); text-align: center; }

/* ---------- Policy ---------- */
.policy-layout { display: grid; grid-template-columns: 260px 1fr; gap: 48px; align-items: start; }
.policy-nav { position: sticky; top: calc(var(--header-h) + 20px); padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-lg); }
.policy-nav a { display: block; padding: 10px 14px; border-radius: var(--radius); font-size: 14px; font-weight: 600; transition: background var(--ease), color var(--ease); }
.policy-nav a:hover, .policy-nav a.is-active { background: var(--primary-soft); color: var(--primary); }
.policy-block { scroll-margin-top: calc(var(--header-h) + 20px); padding-bottom: 36px; margin-bottom: 36px; border-bottom: 1px solid var(--line); }
.policy-block:last-child { border-bottom: 0; }
.policy-block h2 { margin-bottom: 14px; font-size: 22px; font-weight: 800; text-transform: uppercase; color: var(--dark); }
.policy-block h3 { margin: 18px 0 8px; font-size: 16px; font-weight: 700; }
.policy-block p, .policy-block li { color: #4a5566; }
.policy-block ul { padding-left: 20px; list-style: disc; }
.policy-block li + li { margin-top: 6px; }

/* ==========================================================
   RESPONSIVE
   ========================================================== */
@media (max-width: 1199px) {
  .shop-grid { grid-template-columns: repeat(3, 1fr); }
  .contact-cards { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 991px) {
  .shop-layout { grid-template-columns: 1fr; }
  .shop-sidebar {
    position: fixed; top: 0; right: 0; bottom: 0; z-index: 130; width: min(320px, 86vw);
    padding: 20px; overflow-y: auto; background: var(--white);
    transform: translateX(100%); transition: transform var(--ease);
  }
  .filters-open .shop-sidebar { transform: none; }
  .filters-open .nav-backdrop { opacity: 1; visibility: visible; z-index: 125; }
  .filter-open { display: inline-flex; }
  .shop-grid { grid-template-columns: repeat(3, 1fr); }
  .detail-grid { grid-template-columns: 1fr; gap: 32px; }
  .detail-gallery { position: static; max-width: 560px; }
  .cart-layout, .article-layout, .contact-grid, .policy-layout { grid-template-columns: 1fr; }
  .cart-summary, .policy-nav { position: static; }
  .policy-nav { display: flex; flex-wrap: wrap; gap: 4px; }
  .news-grid { grid-template-columns: repeat(2, 1fr); }
  .news-card--featured { flex-direction: column; }
  .news-card--featured .news-thumb { min-height: 0; aspect-ratio: 16 / 9; }
  .auth-wrap { grid-template-columns: 1fr; max-width: 520px; }
  .auth-media { min-height: 220px; }
}

@media (max-width: 767px) {
  .shop-grid { grid-template-columns: repeat(2, 1fr); row-gap: 24px; }
  .detail-info h1 { font-size: 22px; }
  .detail-price strong { font-size: 24px; }
  .detail-perks { grid-template-columns: 1fr; }
  .tabs { margin-top: 44px; }
  .tab-nav { gap: 22px; }
  .cart-row { grid-template-columns: 72px 1fr 32px; gap: 12px; padding: 14px; }
  .cart-row img { width: 72px; height: 72px; grid-row: 1 / span 3; align-self: start; }
  .cart-row .qty { grid-column: 2; }
  .cart-row .line-price { grid-column: 2; grid-row: 3; text-align: left; min-width: 0; }
  .cart-row .remove { grid-column: 3; grid-row: 1; }
  .news-grid { grid-template-columns: 1fr; }
  .news-card--featured .news-body { padding: 22px; }
  .news-card--featured h2 { font-size: 18px; }
  .article h1 { font-size: 24px; }
  .contact-cards { grid-template-columns: 1fr 1fr; gap: 12px; }
  .contact-card { padding: 18px 12px; }
  .contact-form { grid-template-columns: 1fr; }
  .auth-box { padding: 28px 20px; }
  .auth-media { display: none; }
}
