:root {
  /* Teal & White Cracker Theme */
  --primary-teal: #0c7c79;
  --primary-teal-light: #129995;
  --bg-color: #0c7c79;
  --text-white: #ffffff;
  --text-dark: #0c7c79;
  --card-bg: #ffffff;

  --glass-white: rgba(255, 255, 255, 0.1);
  --border-radius-lg: 12px;
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  background-color: var(--bg-color);
  /* Cracker/Firework Burst Background Design */
  background-image:
    radial-gradient(circle at 10% 10%, rgba(255, 255, 255, 0.05) 0%, transparent 10%),
    radial-gradient(circle at 90% 20%, rgba(255, 255, 255, 0.08) 0%, transparent 15%),
    radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.04) 0%, transparent 20%),
    radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.06) 0%, transparent 12%),
    radial-gradient(circle at 80% 85%, rgba(255, 255, 255, 0.07) 0%, transparent 18%),
    /* Sparkle points */
    radial-gradient(white 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 100% 100%, 100% 100%, 100% 100%, 60px 60px;
  background-attachment: fixed;
  color: var(--text-white);
  font-family: 'Inter', system-ui, sans-serif;
  margin: 0;
  padding-bottom: 100px;
}

/* Navbar */
header {
  margin-bottom: 2rem;
}

.navbar {
  background-color: #ffffff !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  padding: 0.75rem 0;
  border-bottom: 4px solid var(--primary-teal-light);
}

.navbar-brand {
  color: var(--primary-teal) !important;
  font-weight: 900;
  font-size: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.nav-link {
  color: var(--primary-teal) !important;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.9rem;
  padding: 0.5rem 1.2rem !important;
  transition: var(--transition-smooth);
}

.nav-link:hover {
  background-color: rgba(12, 124, 121, 0.05);
  border-radius: 5px;
}

/* Admin Nav Tabs Fix */
.btn-group .btn-outline-primary {
  color: #fff !important;
  border-color: #fff !important;
  opacity: 0.8;
}

.btn-group .btn-outline-primary:hover {
  background-color: rgba(255, 255, 255, 0.1) !important;
  opacity: 1;
}

.btn-group .btn-primary.active {
  background-color: #fff !important;
  color: var(--primary-teal) !important;
  border-color: #fff !important;
  font-weight: 800;
}

/* Fix Logout visibility in Admin */
.btn-logout {
  color: var(--primary-teal) !important;
  font-weight: 700;
  text-decoration: none;
  border: 2px solid var(--primary-teal);
  padding: 8px 20px;
  border-radius: 50px;
  transition: var(--transition-smooth);
}

.btn-logout:hover {
  background-color: var(--primary-teal);
  color: white !important;
}

/* Home Section */
.hero-section {
  text-align: center;
  padding: 3rem 1rem;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(5px);
  border-radius: 20px;
  margin: 0 1rem 2rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-title {
  font-size: 3rem;
  font-weight: 900;
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
  font-size: 1.1rem;
  opacity: 0.9;
}

/* Category Headers */
.product-category {
  background-color: #ffffff;
  color: var(--primary-teal);
  padding: 10px 20px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  border-radius: 50px;
  display: inline-block;
  margin: 1.5rem 0 1rem 0;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Product Cards */
.product-row {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-lg);
  padding: 0.5rem 1rem;
  margin-bottom: 0.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #333;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  transition: var(--transition-smooth);
  border-left: 6px solid var(--primary-teal-light);
}

.product-row:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.product-card-hover {
  transition: var(--transition-smooth);
}

.product-card-hover:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15) !important;
}

.product-info {
  display: flex;
  align-items: center;
  flex: 3;
}

.product-image-thumb {
  width: 55px;
  height: 55px;
  object-fit: cover;
  border-radius: 8px;
  background: #f0f0f0;
}

.product-details {
  margin-left: 1.25rem;
}

.product-details h5 {
  margin: 0;
  font-weight: 800;
  color: var(--primary-teal);
}

.product-price {
  flex: 1;
  text-align: right;
  font-size: 1.3rem;
  font-weight: 900;
  color: #d32f2f;
  /* Red for price contrast */
}

/* Qty Input Custom */
.input-group-custom {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 5px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.qty-btn {
  background: #ffffff;
  border: none;
  padding: 5px 12px;
  color: var(--primary-teal);
  font-weight: bold;
  cursor: pointer;
  transition: background 0.2s;
}

.qty-btn:hover {
  background: #e9ecef;
}

.qty-input {
  width: 50px;
  border: none;
  border-left: 1px solid #dee2e6;
  border-right: 1px solid #dee2e6;
  text-align: center;
  font-weight: 700;
  background: transparent;
}

/* Sticky Footer */
.sticky-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: #ffffff;
  padding: 15px;
  display: flex;
  justify-content: space-around;
  align-items: center;
  box-shadow: 0 -5px 25px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  border-top: 5px solid var(--primary-teal-light);
}

.footer-stat {
  color: var(--primary-teal);
  font-weight: 800;
  font-size: 1.1rem;
}

.btn-checkout {
  background-color: var(--primary-teal);
  color: white;
  border: none;
  padding: 12px 30px;
  border-radius: 50px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: var(--transition-smooth);
}

.btn-checkout:hover:not(:disabled) {
  background-color: var(--primary-teal-light);
  transform: scale(1.05);
}

.btn-checkout:disabled {
  background-color: #ccc;
}

/* Site Footer */
.site-footer {
  background-color: #ffffff;
  color: var(--primary-teal);
  padding: 4rem 0 2rem 0;
  margin-top: 4rem;
  border-top: 1px solid rgba(12, 124, 121, 0.1);
}

.site-footer h5 {
  font-weight: 800;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.site-footer a {
  color: var(--primary-teal);
  opacity: 0.8;
  text-decoration: none;
}

.site-footer a:hover {
  opacity: 1;
}

/* Modal */
.modal-content {
  border: 0;
  border-radius: 12px;
  background-color: #ffffff;
  color: #212529 !important;
  /* Force dark text on white modal */
}

/* Global Fix for White Containers */
.card,
.bg-white,
.dropdown-menu,
.popover,
.offcanvas {
  color: #212529;
}

/* Fix Form Inputs */
.form-control,
.form-select,
.input-group-text {
  color: #212529 !important;
  background-color: #ffffff !important;
  border-color: #dee2e6;
}

.form-control:focus,
.form-select:focus {
  color: #212529 !important;
  background-color: #ffffff !important;
  border-color: var(--primary-teal-light);
  box-shadow: 0 0 0 0.25rem rgba(12, 124, 121, 0.25);
}

.form-label {
  color: #212529;
  font-weight: 600;
}

/* Floating WhatsApp Fix */
.floating-whatsapp {
  position: fixed;
  bottom: 100px;
  right: 30px;
  background-color: #25d366 !important;
  color: white !important;
  padding: 12px 25px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 800;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: var(--transition-smooth);
}

.floating-whatsapp:hover {
  transform: scale(1.1);
  color: white !important;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
}

/* PDF Button Style */
.btn-pdf {
  background-color: #d32f2f !important;
  color: white !important;
  border: none;
  padding: 12px 25px;
  border-radius: 8px;
  font-weight: 700;
  transition: var(--transition-smooth);
}

.btn-pdf:hover {
  background-color: #b71c1c !important;
  transform: translateY(-2px);
  color: white !important;
}

/* Global Print Styles - Compact */
@media print {
  @page {
    margin: 0.5cm;
    size: A4 portrait;
  }

  body {
    visibility: hidden;
    background: white !important;
    color: black !important;
    padding: 0 !important;
    margin: 0 !important;
    font-size: 10pt;
    /* Smaller font */
  }

  /* Hide everything non-essential */
  header,
  footer,
  nav,
  .navbar,
  .btn,
  .no-print,
  form,
  .card-header button,
  .alert,
  .floating-whatsapp,
  .sticky-footer,
  .hero-section,
  .breadcrumb {
    display: none !important;
  }

  /* Maximize Content Area */
  main,
  .container,
  .table-responsive,
  .card,
  .card-body {
    visibility: visible;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    box-shadow: none !important;
    width: 100% !important;
    display: block !important;
  }

  main {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
  }

  /* Compact Tables */
  .table {
    width: 100% !important;
    border-collapse: collapse !important;
    font-size: 9pt;
    /* Compact Table Font */
    margin-bottom: 5px !important;
  }

  .table th,
  .table td {
    border: 1px solid #000 !important;
    /* High contrast border */
    padding: 2px 4px !important;
    /* Minimal padding */
    line-height: 1.2;
  }

  .table th {
    background-color: #f0f0f0 !important;
    font-weight: bold;
    color: black !important;
  }

  /* Compact Headings */
  h2,
  h3,
  h4,
  h5,
  h6 {
    visibility: visible;
    color: black !important;
    margin-top: 5px !important;
    margin-bottom: 5px !important;
    font-size: 1.1em !important;
  }

  /* Address/Info Compact */
  .row {
    display: flex !important;
    flex-wrap: nowrap !important;
  }

  .col-6 {
    width: 50% !important;
  }

  p {
    margin-bottom: 2px !important;
  }

  a[href]:after {
    content: none !important;
  }
}