/*
Theme Name: RTG Luxury
Theme URI: https://rtgluxury.com
Author: Ernesto Ortega
Author URI: https://rtgluxury.com
Description: Tema oscuro estilo streetwear/luxury para catálogo de gorras, ropa y calzado. Mobile-first.
Version: 1.0.4
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: rtgluxury
Tags: dark, ecommerce, woocommerce, mobile-first, streetwear
*/

/* ─── VARIABLES ─── */
:root {
  --black: #0a0a0a;
  --dark: #111111;
  --card: #161616;
  --border: #222222;
  --gold: #C9A84C;
  --gold-light: #E8C96A;
  --white: #f0ede8;
  --muted: #666;
  --red: #c0392b;
}

/* ─── RESET ─── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
img { max-width: 100%; height: auto; display: block; }

body {
  background: var(--black);
  color: var(--white);
  font-family: 'Barlow', sans-serif;
  font-size: 16px;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

/* ─── GRAIN OVERLAY ─── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  opacity: 0.35;
}

/* ─── SITE HEADER ─── */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  height: 64px;
  background: rgba(10,10,10,0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-logo-wrap {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.nav-logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 26px;
  letter-spacing: 3px;
  color: var(--gold);
  text-shadow: 0 0 20px rgba(201,168,76,0.3);
  white-space: nowrap;
  text-decoration: none;
  display: flex;
  align-items: center;
  pointer-events: all;
}

.nav-logo img {
  height: 44px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
}

.nav-logo span { color: var(--white); }

/* ─── CART ─── */
.nav-cart {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--white);
  position: relative;
  z-index: 1;
  text-decoration: none;
  display: flex;
  align-items: center;
  padding: 4px;
  transition: color 0.2s;
}

.nav-cart:hover { color: var(--gold); }

.cart-count {
  position: absolute;
  top: -4px;
  right: -6px;
  background: var(--gold);
  color: var(--black);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  font-weight: 700;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
  z-index: 1;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  transition: all 0.3s;
  transform-origin: center;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ─── CART BUTTON ─── */
.nav-cart {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--white);
  font-size: 20px;
  position: relative;
  z-index: 1;
  text-decoration: none;
}

/* ─── DRAWER ─── */
.drawer {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: 100vh;
  background: rgba(10,10,10,0.97);
  z-index: 99;
  transform: translateX(-100%);
  transition: transform 0.4s cubic-bezier(0.77,0,0.18,1);
  overflow-y: auto;
  padding: 90px 32px 40px;
}

.drawer.open { transform: translateX(0); }

.drawer-nav-item { border-bottom: 1px solid var(--border); }

.drawer-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 32px;
  letter-spacing: 2px;
  color: var(--white);
  text-decoration: none;
  cursor: pointer;
  transition: color 0.2s;
}

.drawer-link:hover,
.drawer-link.open-sub { color: var(--gold); }

.drawer-link .arrow {
  font-size: 18px;
  transition: transform 0.3s;
  color: var(--gold);
}

.drawer-link.open-sub .arrow { transform: rotate(90deg); }

/* ─── SUBMENU L1 ─── */
.submenu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
  padding-left: 16px;
}

.submenu.open { max-height: 2000px; }

.sub-item { border-bottom: 1px solid #1a1a1a; }

/* Gorras / Ropa / Calzado */
.sub-link-cat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 21px;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: #aaa;
  cursor: pointer;
  text-transform: uppercase;
  transition: color 0.2s;
}

.sub-link-cat:hover { color: var(--gold-light); }

.sub-link-cat .arrow {
  font-size: 14px;
  color: var(--gold);
  transition: transform 0.3s;
}

.sub-link-cat.open-sub2 .arrow { transform: rotate(90deg); }

/* Marcas (New Era, Barbas, Nike...) */
.sub-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: #aaa;
  text-decoration: none;
  cursor: pointer;
  text-transform: uppercase;
  transition: color 0.2s;
}

.sub-link:hover { color: var(--gold-light); }

.sub-link .arrow {
  font-size: 14px;
  color: var(--gold);
  transition: transform 0.3s;
}

.sub-link.open-sub2 .arrow { transform: rotate(90deg); }

/* ─── SUBMENU L2 ─── */
.submenu2 {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
  padding-left: 14px;
}

.submenu2.open { max-height: 1200px; }

/* Modelos (59Fifty, Air Max...) */
.sub2-link {
  display: block;
  padding: 10px 0;
  font-family: 'Barlow', sans-serif;
  font-size: 14px;
  letter-spacing: 1px;
  color: #666;
  text-decoration: none;
  text-transform: uppercase;
  transition: color 0.2s;
  border-bottom: 1px solid #161616;
}

.sub2-link:hover { color: var(--white); }

/* ─── DRAWER SOCIALS ─── */
.drawer-socials {
  display: flex;
  gap: 20px;
  padding-top: 32px;
  margin-top: 8px;
}

.drawer-socials a {
  color: var(--muted);
  font-size: 22px;
  text-decoration: none;
  transition: color 0.2s;
}

.drawer-socials a:hover { color: var(--gold); }

/* ─── MAIN CONTENT ─── */
.site-main { padding-top: 64px; }

/* ─── HERO ─── */
.hero {
  height: 100vh;
  min-height: 600px;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 0 24px 60px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,10,10,1) 0%, rgba(10,10,10,0.3) 60%, rgba(10,10,10,0.6) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 420px;
}

.hero-eyebrow {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 13px;
  letter-spacing: 4px;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.hero-eyebrow::before {
  content: '';
  display: block;
  width: 30px;
  height: 1px;
  background: var(--gold);
}

.hero-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(56px, 14vw, 88px);
  line-height: 0.92;
  letter-spacing: 1px;
  margin-bottom: 24px;
  color: var(--white);
}

.hero-title .gold { color: var(--gold); }

.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }

.btn-primary {
  background: var(--gold);
  color: var(--black);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 14px 28px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s, transform 0.15s;
}

.btn-primary:hover { background: var(--gold-light); transform: translateY(-1px); }

.btn-outline {
  background: transparent;
  color: var(--white);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 14px 28px;
  border: 1px solid rgba(240,237,232,0.3);
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: border-color 0.2s, color 0.2s;
}

.btn-outline:hover { border-color: var(--gold); color: var(--gold); }

/* ─── MARQUEE ─── */
.marquee-wrap {
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 14px 0;
  background: var(--dark);
}

.marquee-track {
  display: flex;
  gap: 40px;
  animation: marquee 20s linear infinite;
  width: max-content;
}

.marquee-item {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 14px;
  letter-spacing: 4px;
  color: var(--muted);
  white-space: nowrap;
  text-transform: uppercase;
}

.marquee-item .dot { color: var(--gold); margin-right: 40px; }

@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ─── SECTIONS ─── */
.section { padding: 64px 20px; }

.section-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11px;
  letter-spacing: 4px;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.section-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 40px;
  letter-spacing: 2px;
  margin-bottom: 28px;
}

/* ─── CATEGORY CARDS ─── */
.cat-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
}

@media (min-width: 640px) {
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
}

.cat-card {
  position: relative;
  aspect-ratio: 3/4;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  align-items: flex-end;
  text-decoration: none;
}

@media (min-width: 640px) {
  .cat-card { aspect-ratio: 2/3; }
}

.cat-card-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.6s cubic-bezier(0.25,0.46,0.45,0.94);
  background-color: #1a1a1a;
}

.cat-card:hover .cat-card-bg { transform: scale(1.05); }

.cat-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,10,10,0.95) 0%, rgba(10,10,10,0.1) 60%);
}

.cat-content {
  position: relative;
  z-index: 2;
  padding: 24px 20px;
  width: 100%;
}

.cat-number {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--gold);
  margin-bottom: 6px;
}

.cat-name {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 36px;
  letter-spacing: 2px;
  line-height: 1;
  margin-bottom: 16px;
  color: var(--white);
}

.cat-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  border-bottom: 1px solid rgba(201,168,76,0.3);
  padding-bottom: 2px;
  transition: border-color 0.2s, gap 0.2s;
}

.cat-card:hover .cat-btn { gap: 14px; border-color: var(--gold); }

/* ─── PRODUCT GRID ─── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2px;
}

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

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

.product-card {
  background: var(--card);
  position: relative;
  overflow: hidden;
  text-decoration: none;
  color: var(--white);
  display: block;
  transition: transform 0.3s;
}

.product-card:hover { transform: translateY(-2px); }

.product-img {
  aspect-ratio: 1;
  background: #1a1a1a;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.product-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.badge {
  position: absolute;
  top: 10px; left: 10px;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 4px 8px;
  z-index: 2;
}

.badge-agotado { background: #333; color: #aaa; }
.badge-sale { background: var(--red); color: #fff; }
.badge-new { background: var(--gold); color: var(--black); }

.product-info {
  padding: 14px 14px 16px;
  border-top: 1px solid var(--border);
}

.product-brand {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  letter-spacing: 2px;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.product-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
  line-height: 1.2;
}

.product-price {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px;
  letter-spacing: 1px;
  color: var(--white);
}

.product-price .original {
  font-size: 14px;
  color: var(--muted);
  text-decoration: line-through;
  margin-right: 8px;
}

/* ─── WOOCOMMERCE OVERRIDES ─── */
.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product {
  background: var(--card);
  border: none;
  padding: 0;
}

.woocommerce ul.products li.product a img {
  border: none;
  margin: 0;
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 15px;
  color: var(--white);
  padding: 14px 14px 4px;
}

.woocommerce ul.products li.product .price {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px;
  color: var(--white);
  padding: 0 14px 14px;
}

.woocommerce ul.products li.product .price del { color: var(--muted); font-size: 14px; }
.woocommerce ul.products li.product .price ins { text-decoration: none; }

.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
  background: var(--gold) !important;
  color: var(--black) !important;
  font-family: 'Barlow Condensed', sans-serif !important;
  font-weight: 700 !important;
  letter-spacing: 2px !important;
  text-transform: uppercase !important;
  border: none !important;
  border-radius: 0 !important;
  transition: background 0.2s !important;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover {
  background: var(--gold-light) !important;
}

/* ─── FOOTER ─── */
.site-footer {
  background: var(--dark);
  border-top: 1px solid var(--border);
  padding: 40px 24px 32px;
  text-align: center;
}

.footer-logo-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
}

.footer-logo-img {
  width: 100px;
  height: 100px;
  object-fit: contain;
  filter: drop-shadow(0 0 16px rgba(201,168,76,0.25));
}

.footer-logo-placeholder {
  width: 64px;
  height: 64px;
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--gold);
  background: var(--dark);
}

.footer-logo-text {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 28px;
  letter-spacing: 4px;
  color: var(--gold);
  text-shadow: 0 0 20px rgba(201,168,76,0.3);
}

.footer-logo-text span { color: var(--white); }

.footer-links {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.footer-links a {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--white); }

.footer-socials {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 24px;
}

.footer-socials a {
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  text-decoration: none;
  font-size: 16px;
  transition: all 0.2s;
}

.footer-socials a:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.gold-line {
  width: 40px;
  height: 2px;
  background: var(--gold);
  margin: 0 auto 32px;
}

.footer-copy {
  font-family: 'Barlow', sans-serif;
  font-size: 11px;
  letter-spacing: 1px;
  color: #333;
  text-transform: uppercase;
}

/* ─── OCULTAR "VER CARRITO" FLOTANTE DE WOOCOMMERCE ─── */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error,
.wc-block-components-notice-banner,
.woocommerce-store-notice,
p.demo_store,
.added_to_cart,
.woocommerce .woocommerce-message a.button,
.cart-contents-count + .added_to_cart { display: none !important; }

/* ─── SCROLL REVEAL ─── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── ARCHIVE / CATEGORY PAGE ─── */
.archive-header {
  padding: 40px 20px 20px;
}

.archive-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 48px;
  letter-spacing: 3px;
  color: var(--white);
}

.archive-breadcrumb {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

.archive-breadcrumb a { color: var(--gold); }

/* ─── SINGLE PRODUCT ─── */
.single-product-wrap {
  padding: 20px;
  max-width: 960px;
  margin: 0 auto;
}

.product-gallery img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--card);
}

.product-details {
  padding: 24px 0;
}

.product-details .product-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 36px;
  letter-spacing: 2px;
  color: var(--white);
  margin-bottom: 8px;
}

.product-details .product-price-single {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 28px;
  color: var(--gold);
  margin-bottom: 16px;
}

.product-details .product-desc {
  font-family: 'Barlow', sans-serif;
  font-size: 15px;
  color: #aaa;
  line-height: 1.6;
  margin-bottom: 24px;
}

.whatsapp-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #25D366;
  color: #fff;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 16px 28px;
  text-decoration: none;
  transition: background 0.2s, transform 0.15s;
}

.whatsapp-btn:hover { background: #1ebe5a; transform: translateY(-1px); }
