/* ============================================================================
   MR JEWELLERS — Premium E-Commerce Website
   Phase 1 MVP — Core CSS
   ============================================================================ */

/* IMPORTS & RESET */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: #2C2C2C;
  background-color: #F5F1ED;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ============================================================================
   TYPOGRAPHY
   ============================================================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  line-height: 1.3;
  color: #2C2C2C;
}

h1 {
  font-size: 48px;
  letter-spacing: -0.5px;
}

h2 {
  font-size: 36px;
  letter-spacing: -0.3px;
}

h3 {
  font-size: 28px;
}

h4 {
  font-size: 24px;
}

h5 {
  font-size: 18px;
  font-weight: 600;
}

h6 {
  font-size: 16px;
  font-weight: 600;
}

p {
  font-size: 16px;
  line-height: 1.8;
  margin-bottom: 16px;
}

.text-small {
  font-size: 14px;
}

.text-tiny {
  font-size: 12px;
}

.font-weight-bold {
  font-weight: 700;
}

.font-weight-semibold {
  font-weight: 600;
}

/* ============================================================================
   SPACING UTILITIES
   ============================================================================ */

.p-0 { padding: 0; }
.p-8 { padding: 8px; }
.p-16 { padding: 16px; }
.p-24 { padding: 24px; }
.p-32 { padding: 32px; }
.p-48 { padding: 48px; }

.px-16 { padding-left: 16px; padding-right: 16px; }
.px-24 { padding-left: 24px; padding-right: 24px; }
.px-32 { padding-left: 32px; padding-right: 32px; }

.py-16 { padding-top: 16px; padding-bottom: 16px; }
.py-24 { padding-top: 24px; padding-bottom: 24px; }
.py-32 { padding-top: 32px; padding-bottom: 32px; }
.py-48 { padding-top: 48px; padding-bottom: 48px; }

.m-0 { margin: 0; }
.m-8 { margin: 8px; }
.m-16 { margin: 16px; }
.m-24 { margin: 24px; }
.m-32 { margin: 32px; }

.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }

.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }

/* ============================================================================
   COLOR UTILITIES
   ============================================================================ */

.text-burgundy { color: #8B3A3A; }
.text-gold { color: #D4AF37; }
.text-charcoal { color: #2C2C2C; }
.text-ivory { color: #F5F1ED; }
.text-muted { color: #6B6B6B; }

.bg-burgundy { background-color: #8B3A3A; }
.bg-gold { background-color: #D4AF37; }
.bg-ivory { background-color: #F5F1ED; }
.bg-cream { background-color: #FAF8F5; }
.bg-white { background-color: #FFFFFF; }

/* ============================================================================
   BUTTONS
   ============================================================================ */

button, .btn {
  border: none;
  cursor: pointer;
  transition: all 0.3s ease-in-out;
  font-weight: 600;
  font-size: 16px;
  border-radius: 4px;
  display: inline-block;
  text-decoration: none;
  text-align: center;
  padding: 12px 32px;
}

.btn-primary {
  background-color: #8B3A3A;
  color: #F5F1ED;
}

.btn-primary:hover {
  background-color: #6B2C2C;
  transform: translateY(-2px);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background-color: transparent;
  color: #8B3A3A;
  border: 2px solid #8B3A3A;
}

.btn-secondary:hover {
  background-color: #8B3A3A;
  color: #F5F1ED;
}

.btn-text {
  background-color: transparent;
  color: #D4AF37;
  font-weight: 600;
  text-decoration: underline;
  padding: 8px 0;
}

.btn-text:hover {
  color: #8B3A3A;
}

.btn-gold {
  background-color: #D4AF37;
  color: #2C2C2C;
}

.btn-gold:hover {
  background-color: #C9A961;
}

.btn-small {
  padding: 8px 16px;
  font-size: 14px;
}

.btn-block {
  display: block;
  width: 100%;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ============================================================================
   CARDS
   ============================================================================ */

.card {
  background-color: #FFFFFF;
  border: 1px solid #E8E4DF;
  border-radius: 8px;
  padding: 24px;
  transition: all 0.3s ease-in-out;
}

.card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.card-compact {
  padding: 16px;
}

.card-header {
  border-bottom: 1px solid #E8E4DF;
  margin-bottom: 16px;
  padding-bottom: 16px;
}

/* ============================================================================
   FORM ELEMENTS
   ============================================================================ */

input[type='text'],
input[type='email'],
input[type='password'],
input[type='number'],
input[type='tel'],
textarea,
select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #E8E4DF;
  border-radius: 4px;
  font-family: inherit;
  font-size: 16px;
  transition: border-color 0.3s ease-in-out;
  background-color: #FFFFFF;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: #8B3A3A;
  box-shadow: 0 0 0 3px rgba(139, 58, 58, 0.1);
}

label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  font-size: 14px;
}

.form-group {
  margin-bottom: 24px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

/* ============================================================================
   LAYOUT SYSTEMS
   ============================================================================ */

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 24px;
}

.col-1 { grid-column: span 1; }
.col-2 { grid-column: span 2; }
.col-3 { grid-column: span 3; }
.col-4 { grid-column: span 4; }
.col-5 { grid-column: span 5; }
.col-6 { grid-column: span 6; }
.col-8 { grid-column: span 8; }
.col-9 { grid-column: span 9; }
.col-12 { grid-column: span 12; }

.flex {
  display: flex;
}

.flex-row {
  flex-direction: row;
}

.flex-col {
  flex-direction: column;
}

.flex-center {
  justify-content: center;
  align-items: center;
}

.flex-between {
  justify-content: space-between;
  align-items: center;
}

.gap-8 { gap: 8px; }
.gap-16 { gap: 16px; }
.gap-24 { gap: 24px; }
.gap-32 { gap: 32px; }

.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }

.align-center { align-items: center; }
.align-start { align-items: flex-start; }
.align-end { align-items: flex-end; }

/* ============================================================================
   HEADER & NAVIGATION
   ============================================================================ */

header {
  background-color: #FFFFFF;
  border-bottom: 1px solid #E8E4DF;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.top-bar {
  background-color: #2C2C2C;
  color: #F5F1ED;
  padding: 8px 0;
  font-size: 13px;
}

.top-bar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.top-bar a {
  color: #F5F1ED;
  text-decoration: none;
  margin: 0 16px;
  transition: color 0.3s;
}

.top-bar a:hover {
  color: #D4AF37;
}

.main-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 24px;
  font-weight: 700;
  color: #8B3A3A;
  text-decoration: none;
  letter-spacing: 2px;
}

.nav-center {
  display: flex;
  gap: 32px;
  flex: 1;
  justify-content: center;
}

.nav-item {
  text-decoration: none;
  color: #2C2C2C;
  font-weight: 600;
  font-size: 15px;
  position: relative;
  transition: color 0.3s;
}

.nav-item:hover {
  color: #8B3A3A;
}

.nav-item::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #D4AF37;
  transition: width 0.3s;
}

.nav-item:hover::after {
  width: 100%;
}

.nav-right {
  display: flex;
  gap: 24px;
  align-items: center;
}

.nav-icon {
  width: 24px;
  height: 24px;
  cursor: pointer;
  transition: transform 0.3s;
}

.nav-icon:hover {
  transform: scale(1.1);
}

/* ============================================================================
   HERO SECTION
   ============================================================================ */

.hero {
  position: relative;
  height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #8B3A3A 0%, #6B2C2C 100%);
  overflow: hidden;
  color: #F5F1ED;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 600px;
}

.hero h1 {
  color: #D4AF37;
  margin-bottom: 16px;
  font-size: 56px;
}

.hero p {
  font-size: 18px;
  margin-bottom: 32px;
  color: #F5F1ED;
}

.hero-image {
  position: absolute;
  right: 0;
  top: 0;
  width: 50%;
  height: 100%;
  object-fit: cover;
  opacity: 0.3;
  z-index: 1;
}

/* ============================================================================
   PRODUCT GRID
   ============================================================================ */

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin: 32px 0;
}

.product-card {
  background-color: #FFFFFF;
  border: 1px solid #E8E4DF;
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.3s ease-in-out;
}

.product-card:hover {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
  transform: translateY(-4px);
  border-color: #D4AF37;
}

.product-image {
  width: 100%;
  height: 280px;
  object-fit: cover;
  background-color: #FAF8F5;
}

.product-info {
  padding: 20px;
}

.product-category {
  font-size: 12px;
  color: #D4AF37;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.product-name {
  font-size: 18px;
  font-weight: 600;
  color: #2C2C2C;
  margin-bottom: 8px;
  line-height: 1.4;
}

.product-specs {
  font-size: 13px;
  color: #6B6B6B;
  margin-bottom: 12px;
}

.product-price {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.price {
  font-size: 20px;
  font-weight: 700;
  color: #8B3A3A;
}

.wishlist-btn {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: #D4AF37;
  transition: transform 0.3s;
}

.wishlist-btn:hover {
  transform: scale(1.2);
}

.product-action {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.btn-add-to-cart {
  background-color: #8B3A3A;
  color: #F5F1ED;
  border: 2px solid #8B3A3A;
  padding: 10px 16px;
  font-size: 14px;
}

.btn-add-to-cart:hover {
  background-color: #6B2C2C;
}

/* ============================================================================
   FOOTER
   ============================================================================ */

footer {
  background-color: #2C2C2C;
  color: #F5F1ED;
  padding: 48px 0 24px;
  margin-top: 64px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px 48px;
}

.footer-section h4 {
  color: #D4AF37;
  margin-bottom: 16px;
  font-size: 16px;
}

.footer-section ul {
  list-style: none;
}

.footer-section li {
  margin-bottom: 12px;
}

.footer-section a {
  color: #F5F1ED;
  text-decoration: none;
  transition: color 0.3s;
}

.footer-section a:hover {
  color: #D4AF37;
}

.footer-bottom {
  border-top: 1px solid #444;
  padding-top: 24px;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.footer-bottom p {
  font-size: 14px;
  margin: 0;
}

/* ============================================================================
   RESPONSIVE DESIGN
   ============================================================================ */

@media (max-width: 1024px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .nav-center {
    gap: 24px;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  h1 {
    font-size: 40px;
  }

  h2 {
    font-size: 28px;
  }

  .hero {
    height: 400px;
  }

  .hero h1 {
    font-size: 40px;
  }
}

@media (max-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .nav-center {
    display: none;
  }

  .hamburger {
    display: block;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 32px;
  }

  h2 {
    font-size: 24px;
  }

  .hero {
    height: 300px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .main-header {
    padding: 12px 16px;
  }

  .top-bar-content {
    padding: 0 16px;
  }
}

@media (max-width: 480px) {
  .product-grid {
    grid-template-columns: 1fr;
  }

  .container {
    padding: 0 16px;
  }

  h1 {
    font-size: 24px;
  }

  h2 {
    font-size: 20px;
  }

  .hero {
    height: 200px;
  }

  .hero h1 {
    font-size: 24px;
  }

  .hero p {
    font-size: 16px;
  }

  .nav-right {
    gap: 16px;
  }

  .p-32, .px-32, .py-32 {
    padding: 16px;
  }
}

/* ============================================================================
   UTILITY CLASSES
   ============================================================================ */

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

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.hidden {
  display: none;
}

.visible {
  display: block;
}

.opacity-50 {
  opacity: 0.5;
}

.opacity-75 {
  opacity: 0.75;
}

.rounded {
  border-radius: 8px;
}

.rounded-full {
  border-radius: 50%;
}

.shadow {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.shadow-lg {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* ============================================================================
   ANIMATIONS
   ============================================================================ */

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

.animate-fade-in {
  animation: fadeIn 0.5s ease-in-out;
}

.animate-slide-up {
  animation: slideUp 0.5s ease-in-out;
}
