/* ==========================================================
   GLOBAL THEME VARIABLES
========================================================== */
:root {
    --bg: #ffffff;
    --bg-soft: #f5f6f8;
    --text: #111;
    --text-muted: #555;
    --border: #e0e0e0;
    --accent: #0d6efd;
    --card-bg: #fff5fb;
    --card-border: #e5e5e5;
    --card-shadow: rgba(0,0,0,0.08);
}

html[data-theme="dark"] {
    --bg: #0f1114;
    --bg-soft: #16191d;
    --text: #e8e8e8;
    --text-muted: #a9a9a9;
    --border: #333;
    --accent: #2196f3;
    --card-bg: #1b1f24;
    --card-border: #2a2d33;
    --card-shadow: rgba(0,0,0,0.35);
}
/* ==========================================================
   RESET + BODY
========================================================== */
body.omi-body {
    background: var(--bg);
    color: var(--text);
    transition: background .25s ease, color .25s ease;
}

/* ==========================================================
   NAVBAR
========================================================== */
.omi-navbar {
    background: transparent;
    border-bottom: 1px solid var(--border);
}

.omi-logo {
    width: 100px;
    height: 100px;
}

#mainNav {
  justify-content: center;
  align-self: center;
}

.mobile-menu-text {
    display: none;
    font-weight: bold;
    font-size: 18px;
    cursor: pointer;
}

@media (max-width: 991px) {
    .navbar-toggler { display: none; }
    .mobile-menu-text { display: block; color: #fff; }
}


/* Center navbar categories */
.omi-center-nav {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

@media (max-width: 991px) {
    /* On mobile, stack normally in the dropdown */
    .omi-center-nav {
        position: static;
        transform: none;
        text-align: center;
        width: 100%;
    }
}


.nav-link {
    color: var(--text-muted) !important;
}

.nav-link:hover {
    color: var(--accent) !important;
}

.omi-brand {
    font-weight: 700;
    font-size: 1.1rem;
}

/* Cart badge */
.omi-badge {
    background: var(--accent);
    color: #fff;
    position: absolute;
    top: -6px;
    right: -12px;
    padding: 3px 6px;
}

/* ==========================================================
   LAYOUT
========================================================== */
.omi-page {
    margin-top: 20px;
}

.omi-aside {
    background: var(--card-bg);
    border-right: 1px solid var(--border);
    min-height: calc(100vh - 110px);
    transition: background .25s ease;
}

.omi-main {
    background: var(--bg-soft);
    min-height: calc(100vh - 110px);
    border-left: 1px solid var(--border);
}

/* ==========================================================
   SIDEBAR
========================================================== */
.sidebar-section-title {
    font-weight: 700;
    margin-bottom: 10px;
    font-size: 1.5rem;
    width: 30%;
}

.sidebar-link {
    display: block;
    padding: 8px 12px;
    border-radius: 6px;
    color: var(--text-muted);
    
}

.sidebar-link:hover {
    background: var(--accent);
    color: #fff;
}

.chat-float {
  position: fixed;
  right: 20px;
  bottom: 25px;
  background: #25D366;
  padding: 12px;
  border-radius: 50%;
  z-index: 9999;
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
  transition: 0.3s;
}
.chat-float:hover {
  transform: scale(1.1);
}
.chat-float img {
  width: 32px;
}

/* ========================= FOOTER  ========================= */
.omi-footer {
  background: var(--footer-bg, #0d1720);
  color: #d8e2ea;
}

.footer-title {
  font-weight: 700;
  margin-bottom: 12px;
  font-size: 1rem;
}

.footer-text {
  font-size: 14px;
  line-height: 1.6;
  color: #cbd6de;
}

.footer-links a {
  display: block;
  font-size: 14px;
  color: #cbd6de;
  margin-bottom: 6px;
  text-decoration: none;
  transition: color .2s ease;
}
.footer-links a:hover {
  color: #fff;
}

/* Social Icons */
.social-icon {
  font-size: 20px;
  color: #cbd6de;
  transition: .25s;
}
.social-icon:hover {
  color: #fff;
  transform: translateY(-3px);
}

/* Payments */
.payments img {
  margin-right: 6px;
  opacity: 0.9;
  transition: .3s ease;
}
.payments img:hover {
  opacity: 1;
}

/* Newsletter Form */
.newsletter-form {
  display: flex;
  gap: 8px;
}
.newsletter-form input {
  flex-grow: 1;
  padding: 10px;
  border-radius: 6px;
  border: none;
  outline: none;
}
.newsletter-form button {
  background: #0d6efd;
  color: #fff;
  padding: 10px 14px;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.3s;
}
.newsletter-form button:hover {
  background: #0954c6;
}

/* Divider + Bottom Bar */
.footer-divider {
  border-color: rgba(255, 255, 255, 0.15);
}
.footer-bottom {
  font-size: 13px;
  color: #b4c0ca;
}

.omi-footer {
  animation: slideUp 0.7s ease;
}

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

/* Dark Theme Support */
[data-theme="dark"] .omi-footer {
  --footer-bg: #0b1218;
}
.footer-language select {
  padding: 8px 12px;
  border-radius: 6px;
  background: #0d6efd;
  color: #fff;
  border: none;
  cursor: pointer;
}

.newsletter-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 99999;
}
.newsletter-modal-content {
  background: #333333;
  padding: 30px;
  border-radius: 12px;
  width: 90%;
  max-width: 440px;
  text-align: center;
  animation: fadeIn .4s ease;
  color: #ffffff;
}
#close-newsletter {
  float: right;
  cursor: pointer;
  font-size: 22px;
}
@keyframes fadeIn {
  from {opacity: 0; transform: scale(0.9);}
  to {opacity: 1; transform: scale(1);}
}

#miniCartOverlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: 0.3s ease;
    z-index: 998;
}

#miniCartDrawer {
    position: fixed;
    top: 0;
    right: -400px;
    width: 360px;
    height: 100vh;
    background: #fff;
    padding: 20px;
    box-shadow: -2px 0 10px rgba(0,0,0,0.2);
    transition: 0.35s ease;
    z-index: 999;
    display: flex;
    flex-direction: column;
}

#miniCartDrawer.open {
    right: 0;
}

#miniCartOverlay.show {
    opacity: 1;
    visibility: visible;
}

.mini-cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ==========================================================
   CARD STYLING (used across products)
========================================================== */
.omi-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    transition: transform .2s ease, box-shadow .2s ease;
}

.omi-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(0,0,0,0.12);
}

/* ==========================================================
   PRODUCT GRID (fixes overlapping issues)
========================================================== */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill,minmax(260px,1fr));
    gap: 20px;
    margin-top: 20px;
}

.product-card-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 10px;
}

/* ==========================================================
   BUTTONS
========================================================== */
.btn-omi {
    background: var(--accent);
    border: none;
    color: #fff;
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 600;
    transition: background .2s ease;
}

.btn-omi:hover {
    background: #0b5ed7;
}

/* ==========================================================
   FORMS
========================================================== */
input, select {
    background: var(--card-bg) !important;
    border: 1px solid var(--border) !important;
    color: var(--text) !important;
}

input:focus {
    border: 1px solid var(--accent) !important;
    box-shadow: none !important;
}


/* Loader spinner */
.live-spinner {
  width: 38px;
  height: 38px;
  margin: 20px auto;
  border-radius: 50%;
  border: 4px solid #ddd;
  border-top-color: #111;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Dim content during loading */
#products-wrapper.loading {
  opacity: 0.4;
  position: relative;
}
