/* ==========================================================================
   Sarab-inspired storefront theme
   Loaded AFTER app.css, on storefront pages only (components/layouts/site
   .blade.php). Every rule here only overrides *cosmetic* properties (color,
   font, radius, shadow, spacing, border) on the existing class contract —
   no selector is renamed and no layout (display/grid/flex/width) is
   touched, so every data-action/id hook that public/js/*.js depends on
   keeps working untouched. Font (Onest) is loaded via the Google Fonts
   <link> in site.blade.php.
   ========================================================================== */

:root {
    --font-display: 'Onest', sans-serif;
    --font-eyebrow: 'Onest', sans-serif;
    /* Sarab accent palette — --site-primary/--site-secondary stay wired to the
       admin-configurable site settings; these are only the fallback defaults. */
    --color-primary: var(--site-primary, #be185d);
    --color-primary-dark: #8a0f45;
    --color-primary-soft: rgba(190, 24, 93, 0.12);
    --color-secondary: var(--site-secondary, #f6a623);
    --color-dark: #1a1a1a;
    --color-green: #2d6a4f;
    --cream: #fff8f0;
    --cream2: #fef0dc;
    --light: #f9f5f0;
    --star: #f6a623;
    --accent: var(--color-secondary);
    --sale-badge: #d1264c;
    --border-color: #efe3d8;
    --text-muted: #888;
    --radius: 12px;
    --radius-lg: 18px;
    --radius-pill: 50px;
    --shadow-sm: 0 4px 18px rgba(26, 15, 10, 0.07);
    --shadow-md: 0 12px 32px rgba(26, 15, 10, 0.12);
    --shadow-lg: 0 20px 48px rgba(26, 15, 10, 0.18);
}

body {
    font-family: 'Onest', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #444;
    background: var(--light);
}

/* ----- Buttons: gradient pill CTAs with a lift-on-hover, like sarab's .btn-red ----- */
.btn {
    border-radius: var(--radius-pill);
    font-family: 'Onest', sans-serif;
    font-weight: 600;
    letter-spacing: 0.01em;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    border: none;
    box-shadow: 0 8px 24px var(--color-primary-soft);
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    transform: translateY(-3px);
    box-shadow: 0 14px 34px var(--color-primary-soft);
}

.btn-outline {
    border: 1.5px solid var(--border-color);
    background: #fff;
    color: var(--color-dark);
}

.btn-outline:hover:not(:disabled) {
    border-color: var(--color-primary);
    color: var(--color-primary);
    background: #fff;
    transform: translateY(-2px);
}

.btn-buy-now {
    background: var(--color-dark);
}

.btn-buy-now:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    transform: translateY(-3px);
}

.btn-google {
    border-radius: var(--radius-pill);
}

.btn-icon {
    border-radius: 50%;
}

/* ----- Forms / cards ----- */
.form-control {
    border-radius: var(--radius);
    border-color: var(--border-color);
    font-family: 'Onest', sans-serif;
}

.form-control:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-soft);
}

.card {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border-color: var(--border-color);
}

.badge {
    font-family: 'Onest', sans-serif;
}

.section-title {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--color-dark);
}

.page-title {
    font-family: var(--font-display);
    font-weight: 900;
    color: var(--color-dark);
    position: relative;
    padding-bottom: 16px;
}

.page-title::after {
    content: "";
    display: block;
    width: 58px;
    height: 4px;
    border-radius: 4px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-secondary));
    margin-top: 12px;
}

/* Centered sarab-style section intro: eyebrow label, then .page-title with
   its underline re-centered via this modifier, then an optional description. */
.section-eyebrow {
    display: inline-block;
    font-family: 'Onest', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
}

.page-title-center {
    text-align: center;
}

.page-title-center::after {
    margin-left: auto;
    margin-right: auto;
}

.section-header-desc {
    max-width: 560px;
    margin: 0.75rem auto 0;
    color: var(--text-muted);
    text-align: center;
}


/* ===================== Header / topbar / nav (sarab-style, single row) ===================== */
.site-topbar {
    background: var(--color-dark);
    font-family: 'Onest', sans-serif;
}

.site-topbar svg {
    color: var(--color-secondary);
}

.site-topbar-tag {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    color: #fff;
}

.site-topbar-social a {
    transition: background-color 0.2s ease;
}

.site-topbar-social a:hover {
    background: var(--color-primary);
}

.site-header {
    background: #fff;
    color: var(--color-dark);
    border-bottom: none;
    box-shadow: 0 2px 20px rgba(26, 15, 10, 0.07);
}

.site-navbar-inner {
    padding: 1rem 1rem;
}

.site-logo {
    max-height: 56px;
}

.mobile-menu-toggle,
.site-brand,
.nav-icon-btn {
    color: var(--color-dark);
}

.site-brand:hover {
    color: var(--color-primary);
}

.site-brand {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: 1.7rem;
    letter-spacing: 0.01em;
    gap: 0.6rem;
}

/* Sarab-style icon badge next to the wordmark (only rendered when there's
   no uploaded logo image — see components/layouts/site.blade.php). */
.site-brand-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: #fff;
    box-shadow: 0 4px 15px var(--color-primary-soft);
    flex-shrink: 0;
}

.site-brand-icon svg {
    width: 22px;
    height: 22px;
}

/* Center the primary nav links like sarab's navbar-nav.mx-auto (desktop only
   — the 640px-and-below breakpoint in app.css switches .site-nav to a
   column-flex dropdown, where centering has no visible effect anyway). */
.site-nav {
    justify-content: center;
}

.site-nav a {
    font-family: 'Onest', sans-serif;
    font-size: 0.87rem;
    font-weight: 600;
    color: var(--color-dark);
    position: relative;
}

.site-nav a::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: var(--color-primary);
    border-radius: 3px 3px 0 0;
    transition: width 0.3s ease;
}

.site-nav a:hover,
.site-nav a.active {
    color: var(--color-primary);
}

.site-nav a:hover::after,
.site-nav a.active::after {
    width: 55%;
}

/* Right-side icon buttons: search toggle, wishlist, cart, account */
.nav-icon-btn:hover {
    background: var(--light);
    color: var(--color-primary);
}

.site-icon-count {
    background: var(--color-primary);
    color: #fff;
}

.nav-search-panel {
    background: var(--light);
}

.nav-search-form {
    background: #fff;
    border-radius: var(--radius-pill);
}

.nav-search-form input {
    color: var(--color-dark);
}

.nav-search-form button {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    color: #fff;
    transition: filter 0.2s ease, transform 0.15s ease;
}

.nav-search-form button:hover {
    filter: brightness(1.08);
}

.nav-search-form button:active {
    transform: scale(0.93);
}

/* ===================== Footer ===================== */
.site-footer {
    background: var(--color-dark);
    color: rgba(255, 255, 255, 0.6);
    border-top: none;
}

.site-footer-brand-name {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: 1.6rem;
    color: #fff;
}

.site-footer-heading {
    font-family: 'Onest', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 0.02em;
    color: #fff;
    display: inline-block;
    padding-bottom: 9px;
    border-bottom: 2px solid var(--color-primary);
}

.site-footer-link:hover {
    color: var(--color-secondary);
}

.site-footer-social a {
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.06);
}

.site-footer-social a:hover {
    background: var(--color-primary);
    transform: translateY(-3px);
}

/* ===================== Home: hero, trust bar, category, products ===================== */
.hero-slider {
    border-radius: 0;
    background: var(--cream);
}

.hero-slide-title {
    font-family: var(--font-display);
    font-weight: 900;
    letter-spacing: 0.01em;
}

.hero-slide-subtitle {
    font-family: 'Onest', sans-serif;
}

.hero-slide-btn {
    border-radius: var(--radius-pill);
    font-family: 'Onest', sans-serif;
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-slide-btn:hover {
    transform: translateY(-3px);
}

.hero-slider-dot.active {
    background: var(--color-primary);
}

.trust-bar {
    background: var(--cream2);
}

.trust-item {
    border-radius: var(--radius-lg);
    box-shadow: none;
    background: #fff;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.trust-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-sm);
}

.trust-item svg {
    background: var(--color-primary-soft);
    color: var(--color-primary);
    border-radius: 50%;
}

.trust-item-title {
    font-family: 'Onest', sans-serif;
    font-weight: 600;
}

.home-panel-title {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: 1.6rem;
    color: var(--color-dark);
}

.home-panel-link {
    font-family: 'Onest', sans-serif;
    font-weight: 600;
}

.home-panel-link:hover {
    color: var(--color-primary);
}

.category-tile {
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.category-tile:hover {
    transform: translateY(-7px);
    box-shadow: var(--shadow-md);
}

.category-name {
    font-family: 'Onest', sans-serif;
    font-weight: 700;
}

.product-card {
    border-radius: var(--radius-lg);
    border-color: var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.product-card:hover {
    border-color: var(--border-color);
    box-shadow: var(--shadow-md);
    transform: translateY(-8px);
}

.product-card:hover .product-card-image {
    transform: scale(1.08);
}

.product-card-image {
    transition: transform 0.5s ease;
}

.product-card-category {
    font-family: 'Onest', sans-serif;
    font-weight: 700;
    color: var(--color-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.product-card-name {
    font-family: 'Onest', serif;
    font-weight: 700;
    color: var(--color-dark);
}

.product-card-link:hover .product-card-name {
    color: var(--color-primary);
}

.wishlist-btn,
.wishlist-btn-card {
    border-radius: 50%;
}

.wishlist-btn.active,
.wishlist-btn-card.active {
    color: var(--sale-badge);
    border-color: var(--sale-badge);
}

.wishlist-btn.active svg,
.wishlist-btn-card.active svg {
    fill: var(--sale-badge);
}

.stars-fill {
    color: var(--star);
}

.price,
.product-card-price {
    color: var(--color-primary);
    font-family: 'Onest', serif;
    font-weight: 700;
}

.price-off {
    background: var(--color-primary);
    color: #fff;
    border-radius: 7px;
}

/* ===================== Shop / category listing ===================== */
.shop-rail,
.shop-toolbar {
    border-radius: var(--radius-lg);
    background: #fff;
    border-color: var(--border-color);
    box-shadow: var(--shadow-sm);
}

.shop-rail-title {
    font-family: 'Onest', sans-serif;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.03em;
    color: var(--color-dark);
}

.shop-facet-link:hover,
.shop-facet-link.active,
.shop-clear {
    color: var(--color-primary);
}

.pagination-link {
    border-radius: 50%;
}

.pagination-link.is-current {
    background: var(--color-primary);
    border-color: var(--color-primary);
}

/* ===================== Product detail ===================== */
.pdp-title {
    font-family: var(--font-display);
    font-weight: 900;
    color: var(--color-dark);
}

.pdp-category:hover,
.pdp-rating-value {
    color: var(--color-primary);
}

.qty-stepper {
    border-radius: var(--radius-pill);
    overflow: visible;
    border-color: var(--border-color);
}

.qty-btn {
    border-radius: 50%;
    background: #fff;
    transition: background 0.3s ease, color 0.3s ease;
}

.qty-btn:hover {
    background: var(--color-primary);
    color: #fff;
}

.rating-stars,
.star-filled {
    color: var(--star);
}

.review-item-avatar {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    font-family: 'Onest', sans-serif;
}

.review-form-box {
    border-radius: var(--radius-lg);
}

.star-rating-input label,
.star-rating-input label:hover,
.star-rating-input label:hover ~ label,
.star-rating-input input:checked ~ label {
    color: var(--star);
}

/* ===================== Cart / checkout / orders ===================== */
.cart-panel,
.order-summary,
.buybox,
.order-head-card,
.order-card {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border-color: var(--border-color);
}

.cart-panel-title {
    font-family: var(--font-display);
    font-weight: 700;
}

.cart-row-name:hover {
    color: var(--color-primary);
}

.cart-row-delete {
    color: var(--sale-badge);
}

.cart-panel-foot strong,
.order-summary-row.order-summary-grand-total {
    color: var(--color-primary);
}

.order-summary-checkout-btn {
    border-radius: var(--radius-pill);
}

.address-option,
.payment-option {
    border-radius: var(--radius);
}

.address-option:has(input:checked) {
    border-color: var(--color-primary);
    background: var(--color-primary-soft);
}

.link-add-address,
.shop-clear {
    color: var(--color-primary);
}

/* ===================== Auth / profile ===================== */
.auth-card {
    border-radius: var(--radius-lg);
}

.auth-card-links a:hover {
    color: var(--color-primary);
}

.profile-hero {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    border-radius: var(--radius-lg);
}

.profile-avatar,
.profile-avatar-edit {
    color: var(--color-primary);
}

.profile-tab-btn.active {
    background: var(--color-primary);
    border-radius: var(--radius-pill);
}

.profile-tab-btn:hover {
    background: var(--color-primary-soft);
}

/* ===================== Static pages: about / contact / faq ===================== */
.faq-item {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.faq-question {
    font-family: 'Onest', sans-serif;
}

/* ===================== Mobile header: search/wishlist/cart/account icons stay
   in the row at every breakpoint; only the Home/Shop/... links collapse into
   the hamburger dropdown ===================== */
@media (max-width: 640px) {
    /* The popup nav sits on a white sheet, matching the desktop bar (now also
       white) — keep readable dark text, no underline-grow effect on mobile. */
    .site-nav a {
        color: var(--color-dark);
        font-weight: 500;
    }

    .site-nav a::after {
        display: none;
    }

    .site-nav a:hover,
    .site-nav a.active {
        color: var(--color-primary);
    }
}
