/* =============================================================
   Miraya Jewels — Custom Stylesheet
   ============================================================= */

/* ── Scrollbar ──────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #FAF8F3; }
::-webkit-scrollbar-thumb { background: #C9963F; border-radius: 3px; }

/* ── Selection ─────────────────────────────────────────────── */
::selection { background: rgba(201,150,63,.25); color: #1C1C1E; }

/* ── Typography ────────────────────────────────────────────── */
h1, h2, h3, .font-serif { font-family: 'Cormorant Garamond', Georgia, serif; }
body { font-family: 'Jost', system-ui, sans-serif; background-color: #FAF8F3; }

/* ── Badge (cart/wishlist count) ────────────────────────────── */
.badge {
    position: absolute; top: 2px; right: 2px;
    background: #C9963F; color: #fff;
    font-size: 9px; font-weight: 700; line-height: 1;
    width: 16px; height: 16px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Jost', sans-serif;
}

/* ── Buttons ────────────────────────────────────────────────── */
.btn-gold {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    background: #C9963F; color: #fff;
    padding: .875rem 2rem; border-radius: .75rem;
    font-size: .875rem; font-weight: 600; letter-spacing: .05em;
    transition: background .2s, transform .15s, box-shadow .2s;
    cursor: pointer; border: none;
}
.btn-gold:hover { background: #A07828; transform: translateY(-1px); box-shadow: 0 8px 24px rgba(201,150,63,.35); }
.btn-gold:active { transform: translateY(0); }

.btn-gold-sm {
    display: inline-flex; align-items: center; justify-content: center;
    background: #C9963F; color: #fff;
    padding: .6rem 1.25rem; border-radius: .5rem;
    font-size: .8rem; font-weight: 600; letter-spacing: .04em;
    transition: background .2s;
    cursor: pointer; border: none;
}
.btn-gold-sm:hover { background: #A07828; }

.btn-outline {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    border: 1.5px solid #C9963F; color: #C9963F;
    padding: .875rem 2rem; border-radius: .75rem;
    font-size: .875rem; font-weight: 600; letter-spacing: .05em;
    transition: all .2s; cursor: pointer; background: transparent;
}
.btn-outline:hover { background: #C9963F; color: #fff; transform: translateY(-1px); }

.btn-dark {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    background: #1C1C1E; color: #fff;
    padding: .875rem 2rem; border-radius: .75rem;
    font-size: .875rem; font-weight: 600; letter-spacing: .05em;
    transition: background .2s, transform .15s;
    cursor: pointer; border: none;
}
.btn-dark:hover { background: #3C3C3E; transform: translateY(-1px); }

/* ── Product Card ───────────────────────────────────────────── */
.product-card {
    background: #fff; border-radius: 1rem;
    overflow: hidden; transition: box-shadow .3s, transform .3s;
    box-shadow: 0 1px 3px rgba(0,0,0,.07);
}
.product-card:hover {
    box-shadow: 0 12px 40px rgba(0,0,0,.12);
    transform: translateY(-4px);
}
.product-card .card-img-wrap { position: relative; overflow: hidden; aspect-ratio: 3/4; }
.product-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.product-card:hover img { transform: scale(1.06); }

.product-card .card-actions {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: linear-gradient(to top, rgba(28,28,30,.7) 0%, transparent 100%);
    padding: 1rem .75rem .75rem;
    display: flex; justify-content: space-between; align-items: flex-end;
    opacity: 0; transform: translateY(8px);
    transition: opacity .3s, transform .3s;
}
.product-card:hover .card-actions { opacity: 1; transform: translateY(0); }

.product-card .wishlist-btn {
    position: absolute; top: .75rem; right: .75rem;
    background: rgba(255,255,255,.9); border-radius: 50%;
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transform: scale(.8);
    transition: opacity .25s, transform .25s, color .2s;
    cursor: pointer; border: none; color: #1C1C1E;
}
.product-card:hover .wishlist-btn { opacity: 1; transform: scale(1); }
.product-card .wishlist-btn.active { color: #ef4444; opacity: 1; }
.product-card .wishlist-btn:hover { color: #ef4444; }

.product-card .badge-tag {
    position: absolute; top: .75rem; left: .75rem;
    padding: .2rem .6rem; border-radius: .35rem;
    font-size: .65rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
}
.badge-sale       { background: #C9963F; color: #fff; }
.badge-new        { background: #1C1C1E; color: #fff; }
.badge-bestseller { background: #7c3aed; color: #fff; }

/* ── Hero Slider ────────────────────────────────────────────── */
.hero-slider { position: relative; overflow: hidden; height: 90vh; min-height: 520px; max-height: 800px; }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .8s ease; }
.hero-slide.active { opacity: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; }
.hero-slide::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(to right, rgba(0,0,0,.55) 0%, rgba(0,0,0,.2) 60%, transparent 100%);
}
.hero-content { position: absolute; inset: 0; z-index: 2; display: flex; align-items: center; padding: 3rem; }
.hero-dots { position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%); display: flex; gap: .5rem; z-index: 3; }
.hero-dot { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,.4); cursor: pointer; transition: background .3s, transform .3s; border: none; }
.hero-dot.active { background: #fff; transform: scale(1.3); }

/* ── Category Card ──────────────────────────────────────────── */
.cat-card { position: relative; overflow: hidden; border-radius: 1rem; aspect-ratio: 4/5; }
.cat-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.cat-card:hover img { transform: scale(1.08); }
.cat-card::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.55) 0%, transparent 50%);
    transition: opacity .3s;
}
.cat-card:hover::after { opacity: .85; }
.cat-card .cat-label {
    position: absolute; bottom: 0; left: 0; right: 0; z-index: 2;
    padding: 1.25rem 1rem;
    color: #fff; text-align: center; transition: transform .3s;
}
.cat-card:hover .cat-label { transform: translateY(-6px); }

/* ── Utility nav ────────────────────────────────────────────── */
.nav-link { color: #1C1C1E; transition: color .2s; font-size: .875rem; }
.mobile-nav-link {
    display: block; padding: .75rem .5rem;
    color: #1C1C1E; font-size: .9rem; font-weight: 500;
    border-bottom: 1px solid #f5f5f4;
    transition: color .2s;
}
.mobile-nav-link:hover { color: #C9963F; }
.footer-link { color: #a8a29e; transition: color .2s; }
.footer-link:hover { color: #C9963F; }
.social-icon {
    width: 36px; height: 36px; border-radius: 50%;
    background: rgba(255,255,255,.1);
    display: flex; align-items: center; justify-content: center;
    color: #a8a29e; transition: background .2s, color .2s;
}
.social-icon:hover { background: #C9963F; color: #fff; }
.trust-item { padding: .5rem 0; }

/* ── Section headings ───────────────────────────────────────── */
.section-eyebrow {
    font-size: .7rem; letter-spacing: .25em; text-transform: uppercase;
    color: #C9963F; font-weight: 600; display: block; margin-bottom: .5rem;
    font-family: 'Jost', sans-serif;
}
.section-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 600; line-height: 1.1; color: #1C1C1E;
}
.section-divider {
    width: 3rem; height: 2px; background: #C9963F;
    margin: 1rem 0 1.5rem;
}
.section-divider.center { margin-left: auto; margin-right: auto; }

/* ── Form controls ──────────────────────────────────────────── */
.form-input {
    width: 100%; padding: .75rem 1rem; border-radius: .625rem;
    border: 1.5px solid #e7e5e4; background: #fff;
    font-family: 'Jost', sans-serif; font-size: .875rem; color: #1C1C1E;
    transition: border-color .2s, box-shadow .2s; outline: none;
}
.form-input:focus { border-color: #C9963F; box-shadow: 0 0 0 3px rgba(201,150,63,.15); }
.form-label { display: block; font-size: .8rem; font-weight: 600; letter-spacing: .04em; margin-bottom: .4rem; color: #57534e; }
.form-error { font-size: .75rem; color: #dc2626; margin-top: .25rem; }

/* ── Tabs ───────────────────────────────────────────────────── */
.tab-btn {
    padding: .6rem 1.5rem; font-size: .8rem; font-weight: 600;
    letter-spacing: .05em; text-transform: uppercase;
    border-bottom: 2px solid transparent; color: #78716c;
    transition: color .2s, border-color .2s; background: none; cursor: pointer;
}
.tab-btn.active { color: #C9963F; border-color: #C9963F; }

/* ── Quantity stepper ───────────────────────────────────────── */
.qty-stepper { display: flex; align-items: center; border: 1.5px solid #e7e5e4; border-radius: .625rem; overflow: hidden; }
.qty-btn { width: 40px; height: 44px; background: #f5f5f4; font-size: 1.1rem; cursor: pointer; transition: background .2s; border: none; }
.qty-btn:hover { background: #C9963F; color: #fff; }
.qty-input { width: 52px; text-align: center; border: none; font-size: .9rem; font-weight: 600; outline: none; background: #fff; }

/* ── Skeleton loader ────────────────────────────────────────── */
@keyframes skeleton-pulse { 0%,100%{opacity:1} 50%{opacity:.4} }
.skeleton { background: #e7e5e4; border-radius: .5rem; animation: skeleton-pulse 1.8s ease infinite; }

/* ── Image gallery (product page) ──────────────────────────── */
.gallery-thumb { cursor: pointer; border: 2px solid transparent; border-radius: .5rem; overflow: hidden; transition: border-color .2s; }
.gallery-thumb.active { border-color: #C9963F; }
.gallery-thumb img { width: 100%; aspect-ratio: 1; object-fit: cover; }

/* ── Price ──────────────────────────────────────────────────── */
.price-original { text-decoration: line-through; color: #a8a29e; font-size: .85em; }
.price-sale { color: #C9963F; font-weight: 700; }

/* ── Sticky sidebar ─────────────────────────────────────────── */
@media (min-width: 1024px) {
    .sticky-sidebar { position: sticky; top: 88px; }
}

/* ── Admin sidebar ──────────────────────────────────────────── */
.admin-sidebar-link {
    display: flex; align-items: center; gap: .75rem;
    padding: .75rem 1rem; border-radius: .625rem;
    color: #a8a29e; font-size: .875rem; font-weight: 500;
    transition: background .2s, color .2s;
}
.admin-sidebar-link:hover, .admin-sidebar-link.active {
    background: rgba(201,150,63,.12); color: #C9963F;
}

/* ── Animations ─────────────────────────────────────────────── */
@keyframes fadeIn { from { opacity:0; transform:translateY(12px); } to { opacity:1; transform:translateY(0); } }
.animate-fade-in { animation: fadeIn .45s ease forwards; }

@keyframes slideUp { from { opacity:0; transform:translateY(40px); } to { opacity:1; transform:translateY(0); } }
.animate-slide-up { animation: slideUp .6s ease forwards; }

/* Stagger children */
.stagger > *:nth-child(1) { animation-delay:.05s }
.stagger > *:nth-child(2) { animation-delay:.1s  }
.stagger > *:nth-child(3) { animation-delay:.15s }
.stagger > *:nth-child(4) { animation-delay:.2s  }
.stagger > *:nth-child(5) { animation-delay:.25s }
.stagger > *:nth-child(6) { animation-delay:.3s  }
.stagger > *:nth-child(7) { animation-delay:.35s }
.stagger > *:nth-child(8) { animation-delay:.4s  }

/* ── Breadcrumb ─────────────────────────────────────────────── */
.breadcrumb { display: flex; align-items: center; gap: .5rem; font-size: .8rem; color: #78716c; }
.breadcrumb a { color: #78716c; transition: color .2s; }
.breadcrumb a:hover { color: #C9963F; }
.breadcrumb span.sep { color: #a8a29e; }

/* ── Range slider ────────────────────────────────────────────── */
input[type=range] { accent-color: #C9963F; }

/* ── Pagination ─────────────────────────────────────────────── */
.page-btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 36px; height: 36px; border-radius: .5rem;
    font-size: .8rem; font-weight: 600; transition: all .2s;
    border: 1.5px solid #e7e5e4; background: #fff; color: #57534e; cursor: pointer;
}
.page-btn:hover { border-color: #C9963F; color: #C9963F; }
.page-btn.active { background: #C9963F; border-color: #C9963F; color: #fff; }
.page-btn:disabled { opacity: .4; cursor: not-allowed; }

/* ── Responsive images ───────────────────────────────────────── */
img { max-width: 100%; }
