/**
* Fenix International Shop - Premium Theme
* Gold + Dark/Light Color Scheme Support
*/

/* Import Premium Fonts - Raleway + Lato */
@import url('https://fonts.googleapis.com/css2?family=Raleway:wght@300;400;500;600;700;800&family=Lato:wght@300;400;700;900&display=swap');

/* CSS Variables - Light Theme (Default) */
:root {
  --gold: #d4af37;
  --gold-light: #f4d03f;
  --gold-dark: #b8860b;
  --bg-primary: #f8f9fa;
  --bg-surface: #ffffff;
  --bg-surface-light: #f0f0f0;
  --text-primary: #1a1a1a;
  --text-secondary: #4a4a4a;
  --text-muted: rgba(0, 0, 0, 0.5);
  --border-color: rgba(212, 175, 55, 0.3);
  --gold-gradient: linear-gradient(135deg, #d4af37 0%, #f4d03f 50%, #d4af37 100%);
  --font-heading: 'Raleway', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Lato', 'Helvetica Neue', Arial, sans-serif;
}

/* CSS Variables - Dark Theme */
[data-bs-theme="dark"],
.dark-mode {
  --bg-primary: #0a0a0a;
  --bg-surface: #1a1a1a;
  --bg-surface-light: #252525;
  --text-primary: #ffffff;
  --text-secondary: #e0e0e0;
  --text-muted: rgba(255, 255, 255, 0.6);
  --border-color: rgba(212, 175, 55, 0.25);
  --border-color-strong: rgba(212, 175, 55, 0.35);
}

/* Override Bootstrap Variables */
body {
  background-color: var(--bg-primary) !important;
  color: var(--text-primary) !important;
  font-family: var(--font-body) !important;
}

/* Typography */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
  color: var(--text-primary) !important;
  font-family: var(--font-heading) !important;
  font-weight: 600 !important;
}

/* Gold Text Effect */
/* Light theme - use gradient */
[data-bs-theme="light"] .gold-text,
[data-bs-theme="light"] .text-gold,
.gold-text, .text-gold {
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Dark theme - use solid light gold color for better contrast */
[data-bs-theme="dark"] .gold-text,
[data-bs-theme="dark"] .text-gold {
  color: var(--gold-light);
  background: none;
  -webkit-text-fill-color: unset;
  background-clip: unset;
}

/* ================================
   TOPBAR STYLES
================================ */
.bg-secondary {
  background: var(--gold-gradient) !important;
  border-bottom: 1px solid var(--border-color);
}

.bg-secondary .text-body {
  color: #0a0a0a !important;
  transition: all 0.3s ease;
}

.bg-secondary .text-body:hover {
  color: #1a1a1a !important;
}

/* ================================
   HEADER / BRANDING
================================ */
.bg-light {
  background: var(--bg-surface) !important;
}

.bg-dark {
  background: var(--bg-primary) !important;
  border-bottom: 1px solid var(--border-color);
}

/* Logo Enhancement */
.logo img {
  filter: drop-shadow(0 0 10px rgba(212, 175, 55, 0.3));
}

/* Search Input */
.form-control {
  background-color: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  color: var(--text-primary) !important;
  border-radius: 0 !important;
}

.form-control:focus {
  border-color: var(--gold) !important;
  box-shadow: 0 0 0 0.2rem rgba(212, 175, 55, 0.25) !important;
  background-color: var(--bg-surface) !important;
}

/* Enhanced focus state for dark theme */
[data-bs-theme="dark"] .form-control:focus {
  border-color: var(--gold-light) !important;
  box-shadow: 0 0 0 0.3rem rgba(244, 208, 63, 0.35) !important;
}

.form-control::placeholder {
  color: var(--text-muted) !important;
}

/* Placeholder text in dark theme - make it more visible */
[data-bs-theme="dark"] .form-control::placeholder {
  color: rgba(255, 255, 255, 0.5) !important;
}

.input-group-text {
  background: var(--gold-gradient) !important;
  border: none !important;
  color: #0a0a0a !important;
  border-radius: 0 !important;
}

/* ================================
   PRIMARY BUTTON STYLES
================================ */
.btn-primary {
  background: var(--gold-gradient) !important;
  border: none !important;
  color: #0a0a0a !important;
  font-weight: 600 !important;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  border-radius: 0 !important;
  transition: all 0.4s ease !important;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.5s ease;
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(212, 175, 55, 0.4) !important;
  background: var(--gold-gradient) !important;
  color: #0a0a0a !important;
}

.btn-primary:focus {
  box-shadow: 0 0 0 0.2rem rgba(212, 175, 55, 0.5) !important;
}

/* Outline Button */
.btn-outline-light {
  border: 2px solid var(--gold) !important;
  color: var(--gold) !important;
  background: transparent !important;
  border-radius: 0 !important;
  font-weight: 600 !important;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: all 0.4s ease !important;
}

.btn-outline-light:hover {
  background: var(--gold) !important;
  color: #0a0a0a !important;
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(212, 175, 55, 0.4) !important;
}

.btn-light {
  background: var(--bg-surface-light) !important;
  border: 1px solid var(--border-color) !important;
  color: var(--text-primary) !important;
  border-radius: 0 !important;
}

.btn-light:hover {
  background: var(--bg-surface) !important;
  border-color: var(--gold) !important;
  color: var(--gold) !important;
}

/* Dropdown Styles */
.dropdown-menu {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 0 !important;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2) !important;
  border-top: 3px solid var(--gold) !important;
}

.dropdown-item {
  color: var(--text-primary) !important;
  transition: all 0.3s ease;
}

.dropdown-item:hover {
  background: rgba(212, 175, 55, 0.1) !important;
  color: var(--gold) !important;
}

/* ================================
   NAVIGATION
================================ */
.navbar {
  background: var(--bg-surface) !important;
}

.navbar-nav .nav-link {
  color: var(--text-primary) !important;
  font-weight: 500 !important;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 14px !important;
  padding: 20px 18px !important;
  position: relative;
  transition: all 0.3s ease;
}

.navbar-nav .nav-link::after {
  content: '';
  position: absolute;
  bottom: 15px;
  left: 18px;
  right: 18px;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
  transform: scaleX(1);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
  color: var(--gold) !important;
}

/* Categories Sidebar */
.navbar-vertical {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
}

.navbar-vertical .nav-link {
  color: var(--text-secondary) !important;
  border-bottom: 1px solid var(--border-color) !important;
  padding: 15px 20px !important;
}

.navbar-vertical .nav-link:hover {
  background: rgba(212, 175, 55, 0.1) !important;
  color: var(--gold) !important;
}

/* ================================
   CAROUSEL / HERO
================================ */
.carousel-item {
  position: relative;
}

.carousel-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, rgba(10, 10, 10, 0.5) 0%, rgba(10, 10, 10, 0.8) 100%);
  z-index: 1;
}

.carousel-caption {
  z-index: 2;
}

.carousel-caption h1 {
  font-size: 3.5rem !important;
  text-transform: uppercase;
  letter-spacing: 3px;
  text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
}

.carousel-caption p {
  color: rgba(255, 255, 255, 0.8) !important;
  font-size: 1.1rem;
}

.carousel-indicators li {
  width: 50px !important;
  height: 4px !important;
  background: rgba(255, 255, 255, 0.3) !important;
  border-radius: 0 !important;
  margin: 0 5px !important;
}

.carousel-indicators li.active {
  background: var(--gold) !important;
}

/* ================================
   PRODUCT CARDS
================================ */
.product-item {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 0 !important;
  transition: all 0.4s ease;
  overflow: hidden;
}

.product-item:hover {
  transform: translateY(-10px);
  border-color: var(--gold) !important;
  box-shadow: 0 20px 40px rgba(212, 175, 55, 0.15);
}

.product-item h6 a {
  color: var(--text-primary) !important;
  transition: color 0.3s ease;
}

.product-item h6 a:hover {
  color: var(--gold) !important;
  text-decoration: none !important;
}

.product-item .text-primary {
  color: var(--gold) !important;
}

.product-item .text-muted {
  color: var(--text-muted) !important;
}

/* Product Overlay */
.product-item .product-overlay {
  background: rgba(10, 10, 10, 0.9) !important;
}

.product-item .product-overlay a {
  background: var(--gold) !important;
  color: #0a0a0a !important;
  border: none !important;
}

.product-item .product-overlay a:hover {
  background: var(--gold-light) !important;
}

/* ================================
   CATEGORY ITEMS
================================ */
.cat-item {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  transition: all 0.4s ease;
}

.cat-item:hover {
  border-color: var(--gold) !important;
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(212, 175, 55, 0.15);
}

.cat-item h6 {
  color: var(--text-primary) !important;
}

/* ================================
   FEATURED SERVICES
================================ */
.d-flex.align-items-center.bg-light {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  transition: all 0.4s ease;
}

.d-flex.align-items-center.bg-light:hover {
  border-color: var(--gold) !important;
  transform: translateY(-5px);
}

.d-flex.align-items-center.bg-light .fa,
.d-flex.align-items-center.bg-light .fas {
  color: var(--gold) !important;
}

.d-flex.align-items-center.bg-light h5 {
  color: var(--text-primary) !important;
}

/* ================================
   SECTION TITLES
================================ */
.section-title {
  position: relative;
}

.section-title span {
  background: var(--bg-primary) !important;
  color: var(--gold) !important;
  font-family: var(--font-heading) !important;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.section-title::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border-color);
  z-index: -1;
}

/* ================================
   OFFER BOXES
================================ */
.product-offer {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.product-offer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.2) 0%, rgba(10, 10, 10, 0.7) 100%);
  z-index: 1;
}

.product-offer .offer-text {
  z-index: 2;
}

.product-offer h6 {
  color: var(--gold) !important;
}

/* ================================
   CART PAGE
================================ */
.table {
  color: var(--text-primary) !important;
}

.table td, .table th {
  border-color: var(--border-color) !important;
  color: var(--text-primary) !important;
}

.table thead th {
  background: rgba(212, 175, 55, 0.1) !important;
  color: var(--gold) !important;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

.table-light td {
  background: var(--bg-surface) !important;
}

.table-bordered {
  border-color: var(--border-color) !important;
}

/* Cart Summary */
.cart-summary {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
}

/* ================================
   FORMS
================================ */
.custom-control-input:checked ~ .custom-control-label::before {
  background-color: var(--gold) !important;
  border-color: var(--gold) !important;
}

.custom-checkbox .custom-control-input:checked ~ .custom-control-label::before {
  background-color: var(--gold) !important;
}

input[type="number"] {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  color: var(--text-primary) !important;
}

/* ================================
   FOOTER
================================ */
.footer-dark,
.container-fluid.bg-dark.text-secondary {
  background: var(--bg-surface) !important;
  position: relative;
}

.container-fluid.bg-dark.text-secondary::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.text-secondary {
  color: var(--text-secondary) !important;
}

footer h5 {
  color: var(--gold) !important;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600 !important;
  position: relative;
  padding-bottom: 15px;
}

footer h5::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 2px;
  background: var(--gold);
}

footer a.text-secondary {
  transition: all 0.3s ease;
}

footer a.text-secondary:hover {
  color: var(--gold) !important;
  padding-left: 5px;
  text-decoration: none !important;
}

/* Social Links */
footer .social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(212, 175, 55, 0.3);
  color: var(--gold) !important;
  margin-right: 10px;
  transition: all 0.4s ease;
}

footer .social-links a:hover {
  background: var(--gold) !important;
  color: var(--dark-bg) !important;
  transform: translateY(-5px);
}

/* ================================
   BACK TO TOP BUTTON
================================ */
.back-to-top {
  background: var(--gold) !important;
  color: var(--dark-bg) !important;
  border-radius: 0 !important;
  width: 50px;
  height: 50px;
}

.back-to-top:hover {
  background: var(--gold-light) !important;
  transform: translateY(-5px);
}

/* ================================
   BREADCRUMB
================================ */
.breadcrumb {
  background: var(--bg-surface) !important;
  border-radius: 0 !important;
}

.breadcrumb-item a {
  color: var(--gold) !important;
}

.breadcrumb-item.active {
  color: var(--text-secondary) !important;
}

.breadcrumb-item + .breadcrumb-item::before {
  color: var(--text-muted) !important;
}

/* ================================
   PAGINATION
================================ */
.page-link {
  background: var(--bg-surface) !important;
  border-color: var(--border-color) !important;
  color: var(--text-primary) !important;
}

.page-link:hover {
  background: rgba(212, 175, 55, 0.1) !important;
  border-color: var(--gold) !important;
  color: var(--gold) !important;
}

.page-item.active .page-link {
  background: var(--gold) !important;
  border-color: var(--gold) !important;
  color: #0a0a0a !important;
}

/* ================================
   CONTACT PAGE
================================ */
.contact-form {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
}

/* ================================
   BADGE
================================ */
.badge {
  border-radius: 0 !important;
}

.badge-primary {
  background: var(--gold) !important;
  color: #0a0a0a !important;
}

/* ================================
   ALERT
================================ */
.alert {
  border-radius: 0 !important;
}

.alert-success {
  background: rgba(212, 175, 55, 0.1) !important;
  border-color: var(--gold) !important;
  color: var(--gold-dark) !important;
}

[data-bs-theme="dark"] .alert-success {
  color: var(--gold) !important;
}

/* ================================
   PRICE DISPLAY
================================ */
.text-primary,
.price {
  color: var(--gold) !important;
}

del {
  color: var(--text-muted) !important;
}

/* ================================
   QUANTITY INPUT
================================ */
.quantity-input {
  display: flex;
  align-items: center;
}

.quantity-input .btn {
  background: var(--bg-surface-light) !important;
  border: 1px solid var(--border-color) !important;
  color: var(--gold) !important;
  width: 40px;
  height: 40px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.quantity-input .btn:hover {
  background: var(--gold) !important;
  color: #0a0a0a !important;
}

.quantity-input input {
  width: 60px;
  text-align: center;
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  color: var(--text-primary) !important;
  height: 40px;
}

/* ================================
   MOBILE RESPONSIVE
================================ */
@media (max-width: 991px) {
  .navbar-toggler {
    border-color: var(--gold) !important;
  }

  .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(212, 175, 55, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
  }

  .navbar-collapse {
    background: var(--bg-surface) !important;
    padding: 20px;
    border-top: 3px solid var(--gold);
  }
}

/* ================================
   SCROLLBAR STYLING
================================ */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--gold);
  border-radius: 0;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gold-light);
}

/* ================================
   SELECTION STYLING
================================ */
::selection {
  background: var(--gold);
  color: #0a0a0a;
}

::-moz-selection {
  background: var(--gold);
  color: #0a0a0a;
}

/* ================================
   UTILITY CLASSES
================================ */
.bg-gold {
  background: var(--gold-gradient) !important;
}

.border-gold {
  border-color: var(--gold) !important;
}

.text-white {
  color: #ffffff !important;
}

/* Card Styles */
.card {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 0 !important;
}

.card-header {
  background: rgba(212, 175, 55, 0.1) !important;
  border-bottom: 1px solid var(--border-color) !important;
}

.card-footer {
  background: rgba(212, 175, 55, 0.05) !important;
  border-top: 1px solid var(--border-color) !important;
}

/* Modal Styles */
.modal-content {
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 0 !important;
}

.modal-header {
  border-bottom: 1px solid var(--border-color) !important;
}

.modal-footer {
  border-top: 1px solid var(--border-color) !important;
}

.close {
  color: var(--gold) !important;
}

/* List Group */
.list-group-item {
  background: var(--bg-surface) !important;
  border-color: var(--border-color) !important;
  color: var(--text-primary) !important;
}

.list-group-item:hover {
  background: rgba(212, 175, 55, 0.1) !important;
}

/* ================================
   THEME TOGGLE BUTTON (Shop)
================================ */
.theme-toggle-shop {
  position: fixed;
  top: 100px;
  right: 20px;
  background: var(--gold-gradient);
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 5px 20px rgba(212, 175, 55, 0.4);
  transition: all 0.3s ease;
  z-index: 9999;
}

.theme-toggle-shop:hover {
  transform: scale(1.1);
  box-shadow: 0 8px 30px rgba(212, 175, 55, 0.5);
}

.theme-toggle-shop svg {
  width: 24px;
  height: 24px;
  color: #0a0a0a;
}

.theme-toggle-shop .sun-icon { display: none; }
.theme-toggle-shop .moon-icon { display: block; }
[data-bs-theme="dark"] .theme-toggle-shop .sun-icon { display: block; }
[data-bs-theme="dark"] .theme-toggle-shop .moon-icon { display: none; }

/* ================================
   LOGO VISIBILITY FIX - ALL THEMES
================================ */
/* Light theme - logo is dark, visible on white backgrounds */
img[src*="logo"],
img[src*="new_logo"],
.navbar-brand img,
.logo img {
  filter: drop-shadow(0 0 1px rgba(0, 0, 0, 0.2)) !important;
  transition: filter 0.3s ease;
}

/* Dark theme - INVERT dark logo to white + add gold tint glow */
[data-bs-theme="dark"] img[src*="logo"],
[data-bs-theme="dark"] img[src*="new_logo"],
[data-bs-theme="dark"] .navbar-brand img,
[data-bs-theme="dark"] .logo img {
  filter: brightness(0) invert(1) drop-shadow(0 0 3px rgba(212, 175, 55, 0.5)) !important;
}

/* Ensure logo is visible in light sections */
.bg-light img[src*="logo"],
.bg-white img[src*="logo"] {
  filter: drop-shadow(0 0 1px rgba(0, 0, 0, 0.2)) !important;
}

/* Dark backgrounds - invert logo */
.bg-dark img[src*="logo"],
[data-bs-theme="dark"] .bg-light img[src*="logo"],
[data-bs-theme="dark"] .bg-dark img[src*="logo"] {
  filter: brightness(0) invert(1) drop-shadow(0 0 3px rgba(212, 175, 55, 0.5)) !important;
}
