/* ========================================
   Klassy Shoez - Professional Stylesheet
   ======================================== */

/* CSS Variables */
:root {
  --primary: #1a1a2e;
  --primary-light: #16213e;
  --accent: #e94560;
  --accent-hover: #d63a55;
  --gold: #c9a227;
  --gold-light: #f4d35e;
  --success: #2ecc71;
  --text-dark: #1a1a2e;
  --text-muted: #6c757d;
  --bg-light: #f8f9fa;
  --bg-cream: #faf8f5;
  --white: #ffffff;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.15);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --transition: all 0.3s ease;
}

/* Base Styles */
* { box-sizing: border-box; }

body {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--text-dark);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 { font-weight: 700; line-height: 1.2; margin-bottom: 0.5em; }
a { text-decoration: none; transition: var(--transition); }
img { max-width: 100%; height: auto; }

/* Navbar */
.navbar {
  padding: 1rem 0;
  background: var(--white) !important;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.navbar-brand {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary) !important;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.navbar-brand .logo-badge {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  color: var(--white);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
}

.nav-link {
  font-weight: 500;
  color: var(--text-dark) !important;
  padding: 0.5rem 1rem !important;
  border-radius: var(--radius-sm);
  position: relative;
}

.nav-link:hover { color: var(--accent) !important; background: var(--bg-light); }
.nav-link i { font-size: 1.1rem; }
.navbar-toggler { border: none; padding: 0.5rem; }
.navbar-toggler:focus { box-shadow: none; }

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--bg-cream) 0%, var(--bg-light) 100%);
  border-radius: var(--radius-lg);
  padding: 3rem;
  margin-bottom: 3rem;
  overflow: hidden;
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 60%;
  height: 200%;
  background: radial-gradient(circle, rgba(233,69,96,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero h1 {
  font-size: 2.8rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1rem;
}

.hero .lead { font-size: 1.15rem; color: var(--text-muted); max-width: 540px; }
.hero img { border-radius: var(--radius-md); box-shadow: var(--shadow-lg); transition: var(--transition); object-fit: cover; }
.hero img:hover { transform: scale(1.02); }

/* Buttons */
.btn {
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: var(--white);
  box-shadow: 0 4px 15px rgba(26,26,46,0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(233,69,96,0.4);
}

.btn-accent {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
  color: var(--white);
  box-shadow: 0 4px 15px rgba(233,69,96,0.3);
}

.btn-accent:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(233,69,96,0.4); }

.btn-outline-primary {
  border: 2px solid var(--primary);
  color: var(--primary);
  background: transparent;
}

.btn-outline-primary:hover {
  background: var(--primary);
  color: var(--white);
  transform: translateY(-2px);
}

.btn-outline-secondary {
  border: 1px solid #dee2e6;
  color: var(--text-dark);
  background: var(--white);
}

.btn-outline-secondary:hover { background: var(--bg-light); border-color: var(--text-muted); }
.btn-lg { padding: 1rem 2rem; font-size: 1.1rem; }
.btn-sm { padding: 0.4rem 0.8rem; font-size: 0.875rem; }

/* Cards */
.card {
  border: none;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  overflow: hidden;
}

.card:hover { box-shadow: var(--shadow-md); }
.card-body { padding: 1.25rem; }
.card-title { font-weight: 700; color: var(--text-dark); }

/* Product Cards */
.product-card {
  position: relative;
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: var(--transition);
}

.product-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.product-card .card-img-top, .product-card img { height: 260px; object-fit: cover; transition: var(--transition); }
.product-card:hover .card-img-top { transform: scale(1.05); }
.product-card .position-relative { overflow: hidden; }

.product-card .badge {
  font-weight: 600;
  font-size: 0.75rem;
  padding: 0.4rem 0.8rem;
  border-radius: 50px;
  box-shadow: var(--shadow-sm);
}

.product-card .badge.bg-warning { background: var(--gold) !important; color: var(--text-dark); }
.product-card .badge.bg-danger { background: var(--accent) !important; }
.product-card .card-body { padding: 1.25rem; }

.product-card .card-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-card .text-muted { font-size: 0.8rem; text-transform: capitalize; }
.product-card .price-current { font-size: 1.15rem; font-weight: 700; color: var(--primary); }
.product-card .price-original { font-size: 0.9rem; color: var(--text-muted); }
.product-card .rating { color: var(--gold); font-size: 0.85rem; }

/* Filter Sidebar */
.filter {
  background: var(--white);
  border-radius: var(--radius-md);
  position: sticky;
  top: 100px;
}

.filter .card-title {
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--bg-light);
}

.filter .form-label { font-weight: 600; font-size: 0.9rem; color: var(--text-dark); margin-bottom: 0.75rem; }
.filter .btn { font-size: 0.8rem; padding: 0.35rem 0.75rem; border-radius: 50px; }
.filter .btn-dark { background: var(--primary); border-color: var(--primary); }

/* Shop Header */
.shop-header { margin-bottom: 2rem; }
.shop-header h2 { font-size: 2rem; margin-bottom: 0.25rem; }
.shop-header p { color: var(--text-muted); }
.shop-header .view-toggle .btn { border-radius: 8px; }

/* Section Titles */
.section-title {
  position: relative;
  font-size: 1.75rem;
  margin-bottom: 2rem;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 60px;
  height: 4px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--gold) 100%);
  border-radius: 2px;
}

/* Feature Boxes */
.feature-box {
  text-align: center;
  padding: 2rem 1.5rem;
  background: var(--white);
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.feature-box:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }

.feature-box .icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--gold) 100%);
  color: var(--white);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.feature-box h5 { font-weight: 700; margin-bottom: 0.5rem; }
.feature-box p { color: var(--text-muted); font-size: 0.9rem; margin: 0; }

/* Founder Card */
.founder-card {
  background: var(--bg-light);
  color: var(--text);
  border-radius: var(--radius-md);
  padding: 2rem;
  text-align: center;
}

.founder-card h4,
.founder-card h5 { color: var(--primary); }
.founder-card p { color: var(--text-muted); opacity: 1; }

/* Product Detail */
.product-gallery img { border-radius: var(--radius-md); box-shadow: var(--shadow-md); }
.product-info h2 { font-size: 2rem; margin-bottom: 0.5rem; }
.product-info .price { font-size: 1.75rem; font-weight: 700; color: var(--accent); }
.product-info .badge { font-size: 0.85rem; padding: 0.5rem 1rem; }

/* Cart */
.cart-item {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-bottom: 1rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.cart-item:hover { box-shadow: var(--shadow-md); }
.cart-total { background: var(--bg-light); border-radius: var(--radius-md); padding: 1.5rem; }

/* Checkout */
.checkout-card { background: var(--white); border-radius: var(--radius-md); box-shadow: var(--shadow-md); overflow: hidden; }
.checkout-card .card-body { padding: 2rem; }

/* Form Controls */
.form-control, .form-select {
  border: 2px solid #e9ecef;
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  transition: var(--transition);
}

.form-control:focus, .form-select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(233,69,96,0.15); }
.form-label { font-weight: 600; color: var(--text-dark); margin-bottom: 0.5rem; }

/* Footer */
footer {
  background: var(--primary);
  color: var(--white);
  padding: 3rem 0 1.5rem;
  margin-top: 4rem;
}

footer h5 {
  color: var(--gold-light);
  font-size: 1rem;
  margin-bottom: 1.25rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

footer a { color: rgba(255,255,255,0.8); display: block; padding: 0.35rem 0; }
footer a:hover { color: var(--gold-light); }

footer .social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  margin-right: 0.5rem;
  font-size: 1.1rem;
}

footer .social-links a:hover { background: var(--accent); color: var(--white); }
footer .footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); margin-top: 2rem; padding-top: 1.5rem; }

footer .payment-icons { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
footer .payment-icons span {
  background: var(--white);
  color: var(--text-dark);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
}

/* Alerts */
.alert { border: none; border-radius: var(--radius-sm); padding: 1rem 1.25rem; }

/* Tables */
.table { border-radius: var(--radius-md); overflow: hidden; }
.table thead { background: var(--primary); color: var(--white); }
.table th { font-weight: 600; padding: 1rem; border: none; }
.table td { padding: 1rem; vertical-align: middle; }

/* Admin */
.admin-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  height: 100%;
}

.admin-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }

.admin-card .icon {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--gold) 100%);
  color: var(--white);
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

/* Login Card */
.login-card {
  max-width: 420px;
  margin: 2rem auto;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.login-card .card-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: var(--white);
  text-align: center;
  padding: 2rem;
}

.login-card .card-header h3 { margin: 0; font-size: 1.5rem; }
.login-card .card-body { padding: 2rem; }

/* Animations */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in { animation: fadeInUp 0.6s ease forwards; }

/* Responsive */
@media (max-width: 768px) {
  .hero { padding: 2rem; text-align: center; }
  .hero h1 { font-size: 2rem; }
  .hero .lead { max-width: 100%; }
  .hero img { margin-top: 2rem; }
  .product-card .card-img-top, .product-card img { height: 200px; }
  .shop-header { flex-direction: column; gap: 1rem; text-align: center; }
  footer { text-align: center; }
  footer .footer-bottom { flex-direction: column; gap: 1rem; }
  footer .payment-icons { justify-content: center; }
}

/* Utility Classes */
.text-accent { color: var(--accent) !important; }
.text-gold { color: var(--gold) !important; }
.bg-cream { background: var(--bg-cream) !important; }
.rounded-pill { border-radius: 50px !important; }

/* Checkout Card */
.checkout-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: none;
}

.checkout-card .card-body {
  padding: 2rem;
}

/* Input Groups Enhancement */
.input-group-text {
  background: var(--bg-light);
  border-color: #dee2e6;
  color: var(--text-muted);
}

.form-control:focus, .form-select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(233, 69, 96, 0.1);
}

/* Admin Table Enhancements */
.table-hover tbody tr:hover {
  background-color: rgba(233, 69, 96, 0.05);
}

.table th {
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

/* Badge Enhancements */
.badge {
  font-weight: 500;
  padding: 0.4em 0.8em;
}

/* Code Styling */
code {
  font-family: 'SF Mono', Monaco, 'Cascadia Code', monospace;
  font-size: 0.875em;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 3rem 1rem;
}

.empty-state i {
  font-size: 4rem;
  color: var(--text-muted);
  opacity: 0.5;
  margin-bottom: 1rem;
}

/* Scroll to Top */
.scroll-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 50px;
  height: 50px;
  background: var(--accent);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  box-shadow: var(--shadow-md);
  z-index: 999;
}

.scroll-top.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-top:hover {
  background: var(--accent-hover);
  transform: translateY(-3px);
}

/* Loading Spinner */
.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid var(--bg-light);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Print Styles */
@media print {
  .navbar, footer, .btn { display: none !important; }
  body { background: white; }
  .container { max-width: 100%; }
}
