/* =============================================
   lojaModaUnika — Site Público CSS
   Cor primária: #5BC8C0 (teal Unika)
   ============================================= */

:root {
  --primary:        #5BC8C0;
  --primary-dark:   #3AADA5;
  --primary-xdark:  #2A9D95;
  --primary-light:  #A8E6E2;
  --primary-pale:   #E8F8F7;
  --primary-glow:   rgba(91,200,192,.25);
  --accent:         #F6C90E;

  --bg:             #F5FAFA;
  --white:          #FFFFFF;
  --border:         #E2EBE8;
  --text:           #2D3748;
  --text-light:     #718096;
  --text-muted:     #A0AEC0;

  --success:        #38A169;
  --warning:        #D69E2E;
  --danger:         #E53E3E;
  --green-whats:    #25D366;

  --header-h:       68px;
  --radius:         12px;
  --radius-sm:      8px;
  --radius-xl:      20px;
  --shadow:         0 2px 12px rgba(0,0,0,.07);
  --shadow-md:      0 6px 24px rgba(0,0,0,.10);
  --shadow-lg:      0 16px 48px rgba(0,0,0,.14);

  --font-serif:     'Playfair Display', Georgia, serif;
  --font-sans:      'DM Sans', system-ui, sans-serif;

  --transition:     .22s ease;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.6;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a   { text-decoration: none; color: inherit; }

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ---- HEADER ---- */
.site-header {
  position: fixed; top: 0; left: 0; width: 100%;
  height: var(--header-h);
  background: rgba(255,255,255,.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  z-index: 200;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.site-header.scrolled {
  border-color: var(--border);
  box-shadow: 0 2px 20px rgba(0,0,0,.06);
}

.header-inner {
  max-width: 1180px; margin: 0 auto; padding: 0 1.5rem;
  height: 100%; display: flex; align-items: center; gap: 2rem;
}

.site-logo {
  display: flex; align-items: center; flex-shrink: 0;
}
.logo-img {
  height: 46px; width: auto;
}
.logo-fallback {
  font-family: var(--font-serif);
  font-size: 1.4rem; font-weight: 700;
  color: var(--primary-dark);
  letter-spacing: -.02em;
  display: none;
}

.site-nav {
  display: flex; align-items: center; gap: 2rem; flex: 1;
}
.nav-link {
  font-size: .875rem; font-weight: 500; color: var(--text-light);
  transition: color var(--transition); position: relative;
}
.nav-link::after {
  content: ''; position: absolute; bottom: -3px; left: 0;
  width: 0; height: 2px; background: var(--primary);
  transition: width var(--transition);
}
.nav-link:hover { color: var(--primary-dark); }
.nav-link:hover::after { width: 100%; }

.header-actions { display: flex; align-items: center; gap: .75rem; margin-left: auto; }

.header-whats {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--green-whats); color: #fff;
  display: flex; align-items: center; justify-content: center;
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 2px 8px rgba(37,211,102,.3);
}
.header-whats:hover { transform: scale(1.08); }

.nav-toggle {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer; padding: .35rem;
}
.nav-toggle span {
  display: block; width: 22px; height: 2px;
  background: var(--text); border-radius: 2px;
  transition: all .2s;
}
.nav-toggle.open span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

/* Mobile nav */
@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .site-nav {
    position: fixed; top: var(--header-h); left: 0; right: 0;
    background: var(--white); flex-direction: column; gap: 0;
    padding: 1rem 0; border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    transform: translateY(-120%); opacity: 0;
    transition: transform .3s, opacity .25s;
    z-index: 199;
  }
  .site-nav.open {
    transform: translateY(0); opacity: 1;
  }
  .nav-link {
    padding: .85rem 1.5rem; width: 100%;
    font-size: 1rem; border-bottom: 1px solid #f5f5f5;
  }
  .nav-link::after { display: none; }
}

/* ---- HERO ---- */
.hero-section {
  min-height: 100vh;
  background: linear-gradient(135deg, #1B3A4B 0%, var(--primary-xdark) 55%, var(--primary) 100%);
  display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
  padding-top: var(--header-h);
}

.hero-bg {
  position: absolute; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.hero-content {
  position: relative; z-index: 2;
  max-width: 680px; padding: 2rem 1.5rem;
  text-align: center;
}

.hero-tag {
  display: inline-block;
  background: rgba(255,255,255,.15);
  color: rgba(255,255,255,.9);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 20px;
  padding: .35rem 1rem;
  font-size: .8rem; font-weight: 500; letter-spacing: .04em;
  margin-bottom: 1.5rem;
  backdrop-filter: blur(6px);
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}
.hero-tag:hover {
  background: rgba(255,255,255,.28);
  transform: scale(1.04);
}



.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700; line-height: 1.1;
  color: #fff; margin-bottom: 1.25rem;
}
.hero-title em { font-style: italic; color: var(--primary-light); }

.hero-sub {
  font-size: 1.05rem; color: rgba(255,255,255,.7);
  max-width: 480px; margin: 0 auto 2.5rem;
}

.hero-ctas {
  display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap;
}

.btn-hero-primary {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .9rem 2rem; border-radius: var(--radius);
  background: var(--white); color: var(--primary-dark);
  font-weight: 600; font-size: .95rem;
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 4px 16px rgba(0,0,0,.15);
}
.btn-hero-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,.2);
}

.btn-hero-outline {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .9rem 2rem; border-radius: var(--radius);
  background: rgba(255,255,255,.12);
  border: 1.5px solid rgba(255,255,255,.4);
  color: #fff; font-weight: 600; font-size: .95rem;
  backdrop-filter: blur(6px);
  transition: background var(--transition), transform var(--transition);
}
.btn-hero-outline:hover {
  background: rgba(255,255,255,.22); transform: translateY(-2px);
}

.hero-scroll {
  position: absolute; bottom: 1.75rem; left: 50%; transform: translateX(-50%);
  color: rgba(255,255,255,.5); animation: bounce 2s infinite;
  display: flex; align-items: center; justify-content: center;
}
@keyframes bounce {
  0%,100% { transform: translateX(-50%) translateY(0); }
  50%      { transform: translateX(-50%) translateY(6px); }
}

/* ---- SECTION HEADERS ---- */
.section-eyebrow {
  display: flex; align-items: center; gap: .75rem;
  justify-content: center;
  color: var(--primary-dark); font-size: .75rem;
  font-weight: 600; text-transform: uppercase; letter-spacing: .12em;
  margin-bottom: 1.25rem;
}
.eyebrow-line {
  display: block; width: 32px; height: 1.5px; background: var(--primary-light);
}

/* ---- STORIES ---- */
.stories-section {
  padding: 2.5rem 0 1.5rem;
  background: var(--white);
  border-bottom: 1px solid var(--border);
}

.stories-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  margin-bottom: .25rem;
  flex-wrap: wrap; gap: .5rem;
}

.stories-nav-wrap {
  display: flex; gap: .4rem; align-items: center;
}
.stories-arrow {
  width: 34px; height: 34px; border-radius: 50%;
  border: 1.5px solid var(--border); background: var(--white);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--text-light); transition: all .15s;
}
.stories-arrow:hover { border-color: var(--primary); color: var(--primary); }

.stories-wrapper {
  position: relative; overflow: hidden;
}

.stories-track {
  display: flex; gap: .85rem;
  overflow-x: auto; scroll-behavior: smooth;
  padding: .75rem .25rem 1rem;
  scrollbar-width: none; -ms-overflow-style: none;
}
.stories-track::-webkit-scrollbar { display: none; }

/* Story Card — estilo Facebook */
.story-card {
  flex: 0 0 auto; width: 115px; cursor: pointer;
  transition: transform .2s; outline: none;
  -webkit-tap-highlight-color: transparent;
}
.story-card:hover  { transform: translateY(-3px); }
.story-card:focus .story-bg { box-shadow: 0 0 0 3px var(--primary); }

.story-bg {
  width: 115px; height: 180px; border-radius: 14px; overflow: hidden;
  position: relative; background: var(--primary-pale);
  border: 3px solid transparent; transition: border-color .2s;
}
.story-bg img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}

.story-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(27,58,75,.65) 100%);
}

.story-card.active .story-bg {
  border-color: var(--primary);
  box-shadow: 0 4px 16px var(--primary-glow);
}

/* Card "Ver Todas" */
.story-bg-all {
  background: linear-gradient(135deg, var(--primary-pale), var(--primary-light));
  display: flex; align-items: center; justify-content: center;
}
.story-all-icon { font-size: 2rem; color: var(--primary-dark); }

.story-placeholder {
  width: 100%; height: 100%;
  background: linear-gradient(135deg, var(--primary-pale), var(--primary-light));
  display: flex; align-items: center; justify-content: center;
}
.story-placeholder span {
  font-family: var(--font-serif); font-size: 2.5rem;
  font-weight: 700; color: var(--primary-dark);
}

.story-label {
  display: block; text-align: center;
  font-size: .72rem; font-weight: 500;
  color: var(--text-light);
  margin-top: .5rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  max-width: 115px;
  transition: color .15s;
}
.story-card.active .story-label { color: var(--primary-dark); font-weight: 600; }
.story-card:hover .story-label  { color: var(--primary-dark); }

/* ---- PRODUCTS ---- */
.products-section {
  padding: 3rem 0 4rem;
}

.products-header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; flex-wrap: wrap; margin-bottom: 2rem;
}

.search-input {
  padding: .55rem 1rem; border: 1.5px solid var(--border); border-radius: 50px;
  font-family: var(--font-sans); font-size: .875rem; color: var(--text);
  outline: none; width: 220px; transition: border-color .15s, box-shadow .15s;
  background: var(--white);
}
.search-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

/* Grid */
.products-grid { min-height: 300px; position: relative; }
.grid-items {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
}

/* Product Card */
.product-card {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  cursor: pointer;
  transition: transform .22s, box-shadow .22s;
  box-shadow: var(--shadow);
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.product-img-wrap {
  aspect-ratio: 3/4; position: relative; overflow: hidden;
  background: var(--primary-pale);
}
.product-img-wrap img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s;
}
.product-card:hover .product-img-wrap img { transform: scale(1.04); }

.product-img-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem; color: var(--primary-light);
}

.badge-falta {
  position: absolute; top: .6rem; right: .6rem;
  background: #fffbea; color: #744210;
  border-radius: 6px; padding: .2rem .55rem;
  font-size: .7rem; font-weight: 600;
  box-shadow: 0 1px 4px rgba(0,0,0,.1);
}
.badge-destaque-card {
  position: absolute; top: .6rem; left: .6rem;
  background: var(--primary); color: #fff;
  border-radius: 6px; padding: .2rem .55rem;
  font-size: .68rem; font-weight: 600;
}

.product-body {
  padding: .9rem;
}

.product-cat {
  font-size: .7rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .06em; color: var(--primary);
  margin-bottom: .25rem;
}
.product-name {
  font-family: var(--font-serif);
  font-size: .95rem; font-weight: 600;
  color: var(--text); margin-bottom: .35rem;
  line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-price {
  font-size: 1.05rem; font-weight: 700; color: var(--accent);
  margin-bottom: .5rem;
}
.product-sizes {
  display: flex; flex-wrap: wrap; gap: .3rem; margin-bottom: .65rem;
}
.size-pip {
  display: inline-block; padding: .18rem .45rem;
  border: 1.5px solid var(--border); border-radius: 5px;
  font-size: .68rem; font-weight: 600; color: var(--text-light);
}

/* Card actions — linha com botão carrinho + whatsapp */
.product-card-actions {
  display: flex;
  gap: .5rem;
  margin-top: auto;
}
.btn-card-cart {
  flex-shrink: 0;
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  border: 1.5px solid var(--border);
  background: var(--white); color: var(--text-light);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition), color var(--transition);
}
.btn-card-cart:hover {
  background: var(--primary-pale);
  border-color: var(--primary);
  color: var(--primary-dark);
}
.btn-card-whats {
  display: flex; align-items: center; justify-content: center; gap: .4rem;
  flex: 1; padding: .6rem .75rem;
  background: var(--green-whats); color: #fff;
  border: none; border-radius: var(--radius-sm);
  font-family: var(--font-sans); font-size: .8rem; font-weight: 600;
  cursor: pointer; text-decoration: none;
  transition: opacity .15s;
}
.btn-card-whats:hover { opacity: .9; }

/* Skeleton loader */
.grid-loading {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
}
.skeleton-card { border-radius: var(--radius); overflow: hidden; }
.skeleton-img { aspect-ratio: 3/4; background: #e8edf0; }
.skeleton-line { height: 14px; background: #e8edf0; margin: .6rem .75rem; border-radius: 4px; }
.shimmer {
  background: linear-gradient(90deg, #e8edf0 25%, #f0f5f5 50%, #e8edf0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
}
@keyframes shimmer { to { background-position: -200% 0; } }

/* Empty state */
.grid-empty {
  display: flex; flex-direction: column; align-items: center; gap: .75rem;
  padding: 4rem 1.5rem; color: var(--text-muted);
  grid-column: 1/-1;
}
.grid-empty p { font-size: .95rem; }

/* ---- SCROLL INFINITO — spinner ---- */
.grid-load-more {
  grid-column: 1 / -1;
  display: flex; justify-content: center;
  padding: 2rem 0 1rem;
}
.grid-load-more.hidden { display: none; }
.load-more-spinner {
  width: 36px; height: 36px;
  border: 3px solid var(--primary-pale);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: lm-spin .7s linear infinite;
}
@keyframes lm-spin { to { transform: rotate(360deg); } }

/* ---- CTA SECTION ---- */
.cta-section {
  padding: 4rem 0;
  background: linear-gradient(135deg, #1B3A4B, #2A9D95);
}

.cta-box {
  text-align: center; color: #fff; padding: 2rem 1.5rem; position: relative;
}
.cta-deco {
  font-size: 1.5rem; color: var(--primary-light);
  margin-bottom: .75rem; display: block;
}
.cta-box h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700; margin-bottom: .75rem; line-height: 1.2;
}
.cta-box p {
  color: rgba(255,255,255,.7); font-size: 1rem; margin-bottom: 2rem;
}

.btn-cta-whats {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: 1rem 2.25rem; border-radius: var(--radius);
  background: var(--green-whats); color: #fff;
  font-weight: 700; font-size: 1rem;
  transition: transform .2s, box-shadow .2s;
  box-shadow: 0 4px 16px rgba(37,211,102,.3);
}
.btn-cta-whats:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(37,211,102,.4); }

/* ---- FOOTER ---- */
.site-footer {
  background: #1B2E3C; color: rgba(255,255,255,.65);
  padding: 3.5rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

.footer-logo {
  height: 40px;
  max-width: 200px;
  width: auto;
  object-fit: contain;
  background: rgba(255,255,255,.95);
  border-radius: 10px;
  padding: 6px 14px;
  box-sizing: content-box;
  display: block;
}
.footer-logo-fallback {
  font-family: var(--font-serif); font-size: 1.4rem; font-weight: 700;
  color: rgba(255,255,255,.85); display: none;
}
.footer-brand p { font-size: .875rem; margin-top: .65rem; line-height: 1.6; }

.footer-links h4, .footer-contact h4 {
  font-size: .8rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .08em; color: rgba(255,255,255,.9); margin-bottom: 1rem;
}
.footer-links { display: flex; flex-direction: column; gap: .5rem; }
.footer-links a {
  font-size: .875rem; color: rgba(255,255,255,.55);
  transition: color .15s;
}
.footer-links a:hover { color: var(--primary-light); }

.footer-contact { display: flex; flex-direction: column; gap: .65rem; }
.footer-social {
  display: inline-flex; align-items: center; gap: .5rem;
  font-size: .875rem; color: rgba(255,255,255,.55);
  transition: color .15s;
}
.footer-social:hover { color: var(--primary-light); }
.footer-social.whats:hover { color: #5BDB8A; }
.footer-social.insta:hover { color: #F05CB5; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding-top: 1.25rem;
  display: flex; align-items: center; justify-content: space-between; gap: .5rem 1rem;
  flex-wrap: wrap;
}
.footer-bottom p { font-size: .78rem; color: rgba(255,255,255,.3); }
.footer-powered { font-size: .72rem !important; color: rgba(255,255,255,.2) !important; }
.footer-powered a { color: rgba(255,255,255,.38); text-decoration: none; transition: color .15s; }
.footer-powered a:hover { color: rgba(255,255,255,.7); text-decoration: underline; }
.footer-admin-link { font-size: .75rem; color: rgba(255,255,255,.2); transition: color .15s; }
.footer-admin-link:hover { color: rgba(255,255,255,.5); }

/* ---- MODAL ---- */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.65);
  backdrop-filter: blur(4px);
  z-index: 500;
  display: flex; align-items: center; justify-content: center;
  padding: 1.25rem;
  animation: fadeIn .2s ease;
}
.modal-overlay.hidden { display: none; }

@keyframes fadeIn  { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }

.modal-box {
  background: var(--white); border-radius: var(--radius-xl);
  max-width: 860px; width: 100%; max-height: 90vh;
  overflow-y: auto; position: relative;
  animation: slideUp .25s ease;
  box-shadow: var(--shadow-lg);
}

.modal-close {
  position: sticky; top: .75rem;
  float: right; margin: .75rem .75rem 0 0;
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--bg); border: 1.5px solid var(--border);
  cursor: pointer; color: var(--text-light);
  display: flex; align-items: center; justify-content: center;
  transition: all .15s; z-index: 1;
}
.modal-close:hover { border-color: var(--danger); color: var(--danger); }

.modal-inner {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 0;
}

.modal-img-wrap {
  position: relative; aspect-ratio: 3/4; overflow: hidden;
  border-radius: var(--radius-xl) 0 0 var(--radius-xl);
  background: var(--primary-pale);
}
.modal-img {
  width: 100%; height: 100%; object-fit: cover;
}
.modal-estoque-badge {
  position: absolute; top: .85rem; left: .85rem;
  padding: .25rem .7rem; border-radius: 6px;
  font-size: .75rem; font-weight: 600;
}
.modal-estoque-badge.em_falta   { background: #fffbea; color: #744210; }
.modal-estoque-badge.disponivel { display: none; }

.modal-info {
  padding: 2rem 2rem 2rem 1.75rem;
  display: flex; flex-direction: column; gap: .75rem;
  justify-content: center;
}

.modal-cat {
  font-size: .7rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .1em; color: var(--primary);
}
.modal-nome {
  font-family: var(--font-serif);
  font-size: 1.6rem; font-weight: 700; line-height: 1.2;
  color: var(--text);
}
.modal-preco {
  font-size: 1.4rem; font-weight: 700; color: var(--accent);
}
.modal-desc {
  font-size: .875rem; color: var(--text-light); line-height: 1.7;
}

.modal-sizes-label {
  font-size: .8rem; font-weight: 600; color: var(--text); margin-bottom: .4rem;
}
.modal-sizes {
  display: flex; flex-wrap: wrap; gap: .45rem;
}
.size-btn {
  padding: .4rem .8rem; border-radius: var(--radius-sm);
  border: 2px solid var(--border); background: var(--white);
  font-family: var(--font-sans); font-size: .8rem; font-weight: 600;
  color: var(--text-light); cursor: pointer; transition: all .15s;
}
.size-btn:hover  { border-color: var(--primary); color: var(--primary); }
.size-btn.active { border-color: var(--primary); background: var(--primary); color: #fff; }

.modal-actions { display: flex; flex-direction: column; gap: .65rem; }
.btn-modal-cart {
  display: flex; align-items: center; justify-content: center; gap: .55rem;
  padding: .85rem 1.5rem; border-radius: var(--radius);
  background: var(--primary); color: #fff;
  border: none; font-family: var(--font-sans); font-size: .9rem; font-weight: 600;
  cursor: pointer; transition: opacity .15s;
}
.btn-modal-cart:hover { opacity: .88; }

.btn-modal-whats {
  display: flex; align-items: center; justify-content: center; gap: .6rem;
  padding: .9rem 1.5rem; border-radius: var(--radius);
  background: var(--green-whats); color: #fff;
  font-weight: 700; font-size: .95rem;
  transition: opacity .15s;
  margin-top: .25rem;
}
.btn-modal-whats:hover { opacity: .9; }

/* ---- WHATSAPP FLOAT ---- */
.whatsapp-float {
  position: fixed; bottom: 1.75rem; right: 1.75rem;
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--green-whats); color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.45);
  z-index: 400;
  transition: transform .2s, box-shadow .2s;
}
.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 28px rgba(37,211,102,.55);
}

/* ---- UTILS ---- */
.hidden { display: none !important; }

/* ---- RESPONSIVE ---- */
@media (max-width: 860px) {
  .modal-inner { grid-template-columns: 1fr; }
  .modal-img-wrap {
    aspect-ratio: 4/3;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  }
  .modal-img { object-position: top center; }
  .modal-info { padding: 1.5rem; }
}

@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .grid-items { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; }
  .grid-loading { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; }
  .hero-title { font-size: 2.5rem; }
}

@media (max-width: 480px) {
  .products-header { flex-direction: column; align-items: flex-start; }
  .search-input { width: 100%; }
  .story-card { width: 95px; }
  .story-bg { width: 95px; height: 150px; }
}

/* ================================================================
   STORIES VIEWER — botão header
   ================================================================ */
.header-stories-btn {
  display: flex; align-items: center; gap: .4rem;
  background: linear-gradient(white, white) padding-box,
              linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888) border-box;
  border: 1.5px solid transparent;
  color: #cc2366;
  border-radius: 20px;
  padding: .38rem .85rem; font-size: .82rem; font-weight: 600;
  cursor: pointer; font-family: var(--font-sans);
  transition: opacity var(--transition), transform var(--transition);
  white-space: nowrap;
}
.header-stories-btn:hover {
  opacity: .85;
  transform: scale(1.04);
}
@media (max-width: 480px) {
  .header-stories-btn span { display: none; }
  .header-stories-btn { padding: .38rem .5rem; border-radius: 50%; }
}

/* ================================================================
   CARRINHO — botão header, badge, drawer, itens
   ================================================================ */

/* Botão no header */
.cart-btn {
  position: relative;
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  color: var(--text-light);
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition), color var(--transition), transform .15s;
  flex-shrink: 0;
}
.cart-btn:hover {
  background: var(--primary-pale);
  border-color: var(--primary);
  color: var(--primary-dark);
  transform: scale(1.05);
}
.cart-badge {
  position: absolute;
  top: -7px; right: -7px;
  background: var(--accent);
  color: #1a1200;
  font-size: .62rem; font-weight: 800;
  min-width: 18px; height: 18px;
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 4px; line-height: 1;
  pointer-events: none;
  border: 2px solid var(--white);
}
.cart-badge.hidden { display: none; }
@keyframes cartPulse {
  0%  { transform: scale(1); }
  45% { transform: scale(1.25); }
  100%{ transform: scale(1); }
}
.cart-btn.cart-pulse { animation: cartPulse .35s ease; }

/* Overlay escuro */
.cart-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 800;
}
.cart-overlay.hidden { display: none; }

/* Drawer deslizante */
.cart-drawer {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: 380px; max-width: 100vw;
  background: var(--white);
  z-index: 801;
  display: flex; flex-direction: column;
  box-shadow: -8px 0 40px rgba(0,0,0,.14);
  animation: drawerIn .25s ease;
}
.cart-drawer.hidden { display: none; }
@keyframes drawerIn {
  from { transform: translateX(100%); }
  to   { transform: translateX(0); }
}

/* Cabeçalho do drawer */
.cart-drawer-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.cart-drawer-title {
  display: flex; align-items: center; gap: .5rem;
  font-family: var(--font-serif); font-size: 1.1rem; font-weight: 700;
  color: var(--text); margin: 0;
}
.cart-drawer-close {
  background: none; border: none;
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px; color: var(--text-light); cursor: pointer;
  transition: background var(--transition), color var(--transition);
}
.cart-drawer-close:hover { background: var(--primary-pale); color: var(--primary-dark); }

/* Body com scroll */
.cart-drawer-body {
  flex: 1; overflow-y: auto;
  padding: .75rem 1.25rem;
}

/* Estado vazio */
.cart-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .65rem; height: 100%; min-height: 240px;
  text-align: center; color: var(--text-muted);
}
.cart-empty p { font-size: .95rem; font-weight: 500; color: var(--text-light); }
.cart-empty small { font-size: .8rem; }

/* Itens */
.cart-items { display: flex; flex-direction: column; gap: .75rem; }
.cart-item {
  display: flex; align-items: center; gap: .85rem;
  padding: .75rem;
  background: var(--bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.cart-item-img {
  width: 58px; height: 58px; flex-shrink: 0;
  border-radius: var(--radius-sm); overflow: hidden;
  background: var(--primary-pale);
  display: flex; align-items: center; justify-content: center;
}
.cart-item-img img { width: 100%; height: 100%; object-fit: cover; }
.cart-item-img-ph { font-size: 1.2rem; color: var(--primary-light); }
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-name {
  font-size: .85rem; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cart-item-size { font-size: .75rem; color: var(--text-muted); margin-top: 2px; }
.cart-item-price { font-size: .82rem; font-weight: 700; color: var(--accent); margin-top: 4px; }
.cart-item-controls { display: flex; flex-direction: column; align-items: flex-end; gap: .5rem; flex-shrink: 0; }
.cart-qty { display: flex; align-items: center; gap: .3rem; }
.cart-qty-btn {
  width: 26px; height: 26px;
  border: 1px solid var(--border); background: var(--white);
  border-radius: 6px; font-size: .9rem; font-weight: 700;
  color: var(--text-light); cursor: pointer;
  transition: background var(--transition), border-color var(--transition);
  display: flex; align-items: center; justify-content: center;
}
.cart-qty-btn:hover { background: var(--primary-pale); border-color: var(--primary); color: var(--primary-dark); }
.cart-qty-num { font-size: .85rem; font-weight: 700; color: var(--text); min-width: 18px; text-align: center; }
.cart-remove-btn {
  background: none; border: none;
  color: var(--text-muted); cursor: pointer; padding: 2px;
  border-radius: 4px; transition: color var(--transition);
}
.cart-remove-btn:hover { color: var(--danger); }

/* Footer do drawer */
.cart-drawer-footer {
  padding: 1rem 1.25rem 1.25rem;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
  background: var(--white);
}
.cart-drawer-footer.hidden { display: none; }
.cart-total-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: .3rem;
}
.cart-total-label { font-size: .85rem; font-weight: 600; color: var(--text-light); }
.cart-total-value { font-size: 1.25rem; font-weight: 800; color: var(--text); }
.cart-total-hint { display: block; font-size: .72rem; color: var(--text-muted); margin-bottom: .9rem; }
.cart-checkout-btn {
  display: flex; align-items: center; justify-content: center; gap: .55rem;
  width: 100%; padding: 1rem;
  background: var(--green-whats); color: #fff;
  border: none; border-radius: var(--radius);
  font-family: var(--font-sans); font-size: .95rem; font-weight: 700;
  cursor: pointer; transition: opacity .15s;
}
.cart-checkout-btn:hover { opacity: .9; }

/* Shake — tamanho obrigatório não selecionado */
@keyframes shakeRequired {
  0%,100% { transform: translateX(0); }
  15%     { transform: translateX(-6px); }
  30%     { transform: translateX( 6px); }
  45%     { transform: translateX(-5px); }
  60%     { transform: translateX( 5px); }
  75%     { transform: translateX(-3px); }
  90%     { transform: translateX( 3px); }
}
.shake-required {
  animation: shakeRequired .55s ease;
  outline: 2px solid var(--danger);
  border-radius: var(--radius-sm);
}

/* Toast de confirmação */
.cart-toast {
  position: fixed;
  bottom: 1.5rem; left: 50%; transform: translateX(-50%) translateY(80px);
  background: #1e2a26; color: #fff;
  padding: .65rem 1.25rem;
  border-radius: 50px;
  font-size: .82rem; font-weight: 600;
  z-index: 9000;
  pointer-events: none;
  transition: transform .28s ease, opacity .28s ease;
  opacity: 0;
  white-space: nowrap;
}
.cart-toast.visible { transform: translateX(-50%) translateY(0); opacity: 1; }

/* Stories — tamanho selecionável */
.stories-size-pip {
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.stories-size-pip.selected {
  background: var(--primary); border-color: var(--primary); color: #fff;
}
/* Botão carrinho no stories */
.stories-cart-btn {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  border: none; color: #fff;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: background .2s;
  flex-shrink: 0;
}
.stories-cart-btn:hover { background: rgba(255,255,255,.22); }
.stories-cart-btn.added { background: var(--primary); }

/* ================================================================
   STORIES VIEWER — overlay full-screen
   ================================================================ */
.stories-overlay {
  position: fixed; inset: 0; background: #000;
  z-index: 9999; display: flex; align-items: center; justify-content: center;
}
.stories-overlay.hidden { display: none; }

.stories-ui {
  position: relative; width: 100%; max-width: 430px;
  height: 100%; max-height: 100dvh;
  overflow: hidden; user-select: none; touch-action: none;
}

/* Barras de progresso */
.stories-top {
  position: absolute; top: 0; left: 0; right: 0; z-index: 10;
  padding: 12px 10px 20px;
  background: linear-gradient(to bottom, rgba(0,0,0,.6) 0%, transparent 100%);
}
.stories-bars {
  display: flex; gap: 3px; margin-bottom: 10px;
}
.story-bar {
  flex: 1; height: 2px;
  background: rgba(255,255,255,.3);
  border-radius: 2px; overflow: hidden;
}
.story-bar-fill {
  height: 100%; width: 0%;
  background: #fff; border-radius: 2px;
}

/* Topbar: avatar + nome categoria + fechar */
.stories-topbar-info {
  display: flex; align-items: center; gap: 8px;
}
.stories-cat-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--primary); border: 2px solid #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .8rem; color: #fff;
  flex-shrink: 0;
}
.stories-cat-label {
  flex: 1; color: #fff; font-size: .88rem; font-weight: 600;
  font-family: var(--font-sans); text-shadow: 0 1px 3px rgba(0,0,0,.5);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.stories-close-btn {
  background: none; border: none; color: rgba(255,255,255,.85);
  cursor: pointer; padding: 4px; display: flex; align-items: center;
  transition: color .15s; flex-shrink: 0;
}
.stories-close-btn:hover { color: #fff; }

/* Zonas de toque prev/next */
.stories-tap-prev, .stories-tap-next {
  position: absolute; top: 0; bottom: 0; width: 30%; z-index: 5;
  cursor: pointer;
}
.stories-tap-prev { left: 0; }
.stories-tap-next { right: 0; }

/* Imagem */
.stories-media {
  position: absolute; inset: 0; background: #111;
}
.stories-img {
  width: 100%; height: 100%; object-fit: cover;
  transition: opacity .2s;
}
.stories-img-ph {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 5rem; color: rgba(255,255,255,.2);
}

/* Gradiente inferior + info */
.stories-bottom {
  position: absolute; bottom: 0; left: 0; right: 0; z-index: 10;
  padding: 60px 16px 28px;
  background: linear-gradient(to top, rgba(0,0,0,.80) 0%, transparent 100%);
}
.stories-product-info { margin-bottom: .85rem; }
.stories-prod-cat {
  color: rgba(255,255,255,.6); font-size: .72rem;
  text-transform: uppercase; letter-spacing: .06em;
  margin-bottom: .2rem;
}
.stories-prod-name {
  font-family: var(--font-serif); color: #fff;
  font-size: 1.2rem; font-weight: 600; line-height: 1.3;
  text-shadow: 0 1px 4px rgba(0,0,0,.4);
  margin-bottom: .25rem;
}
.stories-prod-price {
  color: var(--accent); font-weight: 700; font-size: 1rem;
}
.stories-prod-sizes {
  display: flex; flex-wrap: wrap; gap: 5px; margin-top: .45rem;
}
.stories-size-pip {
  background: rgba(255,255,255,.12); color: rgba(255,255,255,.9);
  border: 1px solid rgba(255,255,255,.25); border-radius: 4px;
  padding: 2px 9px; font-size: .72rem; font-weight: 500;
}

/* Ações: like + comprar */
.stories-actions {
  display: flex; align-items: center; gap: 10px;
}
.stories-like-btn {
  width: 46px; height: 46px; border-radius: 50%;
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.2);
  color: #fff; display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: background .2s, color .2s;
  flex-shrink: 0;
}
.stories-like-btn:hover { background: rgba(255,255,255,.2); }
.stories-like-btn.liked { color: #FF4F6A; background: rgba(255,79,106,.15); border-color: rgba(255,79,106,.4); }
.stories-like-btn.liked svg { fill: #FF4F6A; stroke: #FF4F6A; }
.stories-like-btn.like-burst { animation: svLikeBurst .35s ease; }
@keyframes svLikeBurst {
  0%  { transform: scale(1); }
  40% { transform: scale(1.45); }
  70% { transform: scale(.9); }
  100%{ transform: scale(1); }
}

.stories-buy-btn {
  flex: 1; display: flex; align-items: center; justify-content: center;
  gap: .5rem; height: 46px;
  background: var(--green-whats); color: #fff;
  border-radius: 23px; font-weight: 700; font-size: .92rem;
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(37,211,102,.35);
  transition: transform .15s, box-shadow .15s;
}
.stories-buy-btn:hover { transform: scale(1.02); box-shadow: 0 6px 20px rgba(37,211,102,.5); }

/* Botão "ver mais fotos" dentro dos stories */
.stories-vermais-btn {
  display: inline-flex; align-items: center; gap: .35rem;
  margin-top: .55rem;
  background: rgba(255,255,255,.15);
  border: 1px solid rgba(255,255,255,.35);
  color: #fff; border-radius: 14px;
  padding: .3rem .75rem; font-size: .75rem; font-weight: 600;
  font-family: var(--font-sans); cursor: pointer;
  transition: background .2s;
  backdrop-filter: blur(4px);
}
.stories-vermais-btn:hover { background: rgba(255,255,255,.28); }
.stories-vermais-btn.hidden { display: none !important; }

/* Desktop: moldura de celular */
@media (min-width: 600px) {
  .stories-overlay { background: rgba(0,0,0,.82); }
  .stories-ui {
    border-radius: 14px;
    box-shadow: 0 32px 80px rgba(0,0,0,.65);
  }
}

/* ================================================================
   MODAL — Galeria de fotos
   ================================================================ */
.modal-img { transition: opacity .18s ease; }

.modal-gal-prev, .modal-gal-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(0,0,0,.45); border: none;
  color: #fff; cursor: pointer; z-index: 2;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s;
}
.modal-gal-prev:hover, .modal-gal-next:hover { background: rgba(0,0,0,.7); }
.modal-gal-prev { left: .6rem; }
.modal-gal-next { right: .6rem; }
.modal-gal-prev.hidden, .modal-gal-next.hidden { display: none; }

.modal-gal-dots {
  position: absolute; bottom: .7rem; left: 50%; transform: translateX(-50%);
  display: flex; gap: 6px; z-index: 2;
}
.modal-gal-dots.hidden { display: none; }

.modal-gal-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: rgba(255,255,255,.45); cursor: pointer;
  transition: background .15s, transform .15s;
}
.modal-gal-dot.active {
  background: #fff; transform: scale(1.25);
}
