/* ===== CSS Variables ===== */
:root {
  --primary: #5f1303;
  --primary-light: #8b2a0f;
  --primary-dark: #3d0c02;
  --cream: #faf7f2;
  --cream-dark: #f0e9df;
  --gold: #c9a86c;
  --gold-light: #d4bc8a;
  --text-dark: #2d2d2d;
  --text-muted: #6b6b6b;
  --white: #ffffff;
  --shadow: 0 4px 20px rgba(95, 19, 3, 0.15);
  --shadow-lg: 0 10px 40px rgba(95, 19, 3, 0.2);
  --radius: 12px;
  --transition: all 0.3s ease;
}

/* ===== Reset & Base ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Lato', sans-serif;
  background-color: var(--cream);
  color: var(--text-dark);
  line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
}

/* ===== Utilities ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border: none;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}

.btn-outline:hover {
  background: var(--primary);
  color: var(--white);
}

.btn-gold {
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  color: var(--text-dark);
}

.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

/* ===== Header ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(250, 247, 242, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 0;
}

.logo {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
}

.logo span {
  color: var(--gold);
}

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

.nav a {
  color: var(--text-dark);
  font-weight: 500;
  transition: var(--transition);
}

.nav a:hover {
  color: var(--primary);
}

.search-box {
  display: flex;
  align-items: center;
  background: var(--white);
  border-radius: 50px;
  padding: 8px 16px;
  border: 1px solid var(--cream-dark);
}

.search-box input {
  border: none;
  outline: none;
  background: transparent;
  padding: 4px 8px;
  font-size: 0.9rem;
  width: 200px;
}

.search-box button {
  background: none;
  border: none;
  color: var(--primary);
  cursor: pointer;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--primary);
  cursor: pointer;
}

/* ===== Hero ===== */
.hero {
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  background:
    linear-gradient(135deg, rgba(95, 19, 3, 0.85), rgba(139, 42, 15, 0.75)),
    url('https://images.unsplash.com/photo-1560066984-138dadb4c035?w=1920&q=80')
      center/cover;
  color: var(--white);
}

.hero-content {
  max-width: 700px;
  padding: 0 20px;
}

.hero h1 {
  font-size: 4rem;
  margin-bottom: 20px;
  line-height: 1.2;
}

.hero p {
  font-size: 1.25rem;
  margin-bottom: 30px;
  opacity: 0.9;
}

.hero-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===== Services Section ===== */
.services-section {
  padding: 100px 0;
  background: var(--cream);
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header h2 {
  font-size: 3rem;
  color: var(--primary);
  margin-bottom: 15px;
}

.section-header p {
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

/* Category Filters */
.category-filters {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 10px 24px;
  border: 2px solid var(--primary);
  background: transparent;
  color: var(--primary);
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--primary);
  color: var(--white);
}

/* Services Grid */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 30px;
}

/* Service Card */
.service-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.service-gallery {
  position: relative;
  height: 250px;
  overflow: hidden;
}

.service-gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100%;
  display: flex;
  justify-content: space-between;
  padding: 0 10px;
  opacity: 0;
  transition: var(--transition);
}

.service-card:hover .gallery-nav {
  opacity: 1;
}

.gallery-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: 1.2rem;
  transition: var(--transition);
}

.gallery-btn:hover {
  background: var(--white);
  transform: scale(1.1);
}

.gallery-dots {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
}

.gallery-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: none;
  cursor: pointer;
  transition: var(--transition);
}

.gallery-dot.active {
  background: var(--white);
  width: 20px;
  border-radius: 4px;
}

.service-category {
  position: absolute;
  top: 15px;
  left: 15px;
  background: var(--primary);
  color: var(--white);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.service-content {
  padding: 25px;
}

.service-content h3 {
  font-size: 1.5rem;
  color: var(--primary);
  margin-bottom: 10px;
}

.service-content p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 15px;
}

.service-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.service-price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold);
}

.service-duration {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.service-card .btn {
  width: 100%;
}

/* ===== Modal Styles ===== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  padding: 20px;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--white);
  border-radius: var(--radius);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.9);
  transition: var(--transition);
}

.modal-overlay.active .modal {
  transform: scale(1);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 25px;
  border-bottom: 1px solid var(--cream-dark);
  position: sticky;
  top: 0;
  background: var(--white);
  z-index: 10;
}

.modal-header h2 {
  font-size: 1.75rem;
  color: var(--primary);
}

.modal-close {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--cream);
  border: none;
  cursor: pointer;
  font-size: 1.5rem;
  color: var(--text-muted);
  transition: var(--transition);
}

.modal-close:hover {
  background: var(--primary);
  color: var(--white);
}

.modal-body {
  padding: 25px;
}

.modal-footer {
  padding: 25px;
  border-top: 1px solid var(--cream-dark);
  display: flex;
  gap: 15px;
  justify-content: flex-end;
}

/* Second Modal (Services Selection) */
.modal-overlay.services-modal {
  z-index: 1100;
}

/* ===== Booking Modal Specific ===== */
.selected-services {
  margin-bottom: 25px;
}

.selected-services h4 {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 15px;
}

.selected-service-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px;
  background: var(--cream);
  border-radius: var(--radius);
  margin-bottom: 10px;
}

.selected-service-item img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
}

.selected-service-info {
  flex: 1;
}

.selected-service-info h5 {
  font-size: 1rem;
  color: var(--primary);
  margin-bottom: 5px;
}

.selected-service-info span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.remove-service {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid var(--cream-dark);
  cursor: pointer;
  color: var(--text-muted);
  transition: var(--transition);
}

.remove-service:hover {
  background: #ff4444;
  color: var(--white);
  border-color: #ff4444;
}

.add-more-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 15px;
  background: var(--cream);
  border: 2px dashed var(--primary);
  border-radius: var(--radius);
  width: 100%;
  color: var(--primary);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.add-more-btn:hover {
  background: var(--primary);
  color: var(--white);
  border-style: solid;
}

/* Date & Time Selection */
.datetime-section {
  margin-top: 25px;
}

.datetime-section h4 {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 15px;
}

.date-picker {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
  margin-bottom: 20px;
}

.date-item {
  padding: 12px 8px;
  text-align: center;
  border: 1px solid var(--cream-dark);
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition);
}

.date-item:hover,
.date-item.selected {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

.date-item .day {
  font-size: 0.75rem;
  opacity: 0.7;
}

.date-item .num {
  font-size: 1.1rem;
  font-weight: 600;
}

.time-slots {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.time-slot {
  padding: 12px;
  text-align: center;
  border: 1px solid var(--cream-dark);
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition);
  font-weight: 500;
}

.time-slot:hover,
.time-slot.selected {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

/* Contact Form */
.contact-form {
  margin-top: 25px;
}

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

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-dark);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 18px;
  border: 1px solid var(--cream-dark);
  border-radius: var(--radius);
  font-size: 1rem;
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(95, 19, 3, 0.1);
}

/* ===== Services Selection Modal ===== */
.services-search {
  padding: 0 25px 25px;
  position: sticky;
  top: 75px;
  background: var(--white);
  z-index: 5;
}

.services-search input {
  width: 100%;
  padding: 14px 18px;
  border: 1px solid var(--cream-dark);
  border-radius: 50px;
  font-size: 1rem;
}

.services-search input:focus {
  outline: none;
  border-color: var(--primary);
}

.services-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.service-select-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px;
  border: 2px solid var(--cream-dark);
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
}

.service-select-item:hover {
  border-color: var(--primary);
}

.service-select-item.selected {
  border-color: var(--primary);
  background: rgba(95, 19, 3, 0.05);
}

.service-select-item img {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: 8px;
}

.service-select-info {
  flex: 1;
}

.service-select-info h4 {
  font-size: 1.1rem;
  color: var(--primary);
  margin-bottom: 5px;
}

.service-select-info p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 5px;
}

.service-select-info .meta {
  display: flex;
  gap: 15px;
  font-size: 0.9rem;
}

.service-select-info .meta .price {
  color: var(--gold);
  font-weight: 600;
}

.service-checkbox {
  width: 24px;
  height: 24px;
  border: 2px solid var(--cream-dark);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.service-select-item.selected .service-checkbox {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
}

/* ===== Booking History Page ===== */
.history-section {
  padding: 120px 0 80px;
  min-height: 100vh;
}

.history-grid {
  display: grid;
  gap: 25px;
}

.booking-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.booking-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
}

.booking-header h3 {
  font-size: 1.25rem;
}

.booking-status {
  padding: 5px 15px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
}

.booking-status.confirmed {
  background: rgba(255, 255, 255, 0.2);
}

.booking-status.completed {
  background: #2ecc71;
}

.booking-status.cancelled {
  background: #e74c3c;
}

.booking-details {
  padding: 25px;
}

.booking-datetime {
  display: flex;
  gap: 30px;
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--cream-dark);
}

.booking-datetime div {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-muted);
}

.booking-datetime i {
  color: var(--primary);
}

.booking-services {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
}

.booking-service-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--cream);
  border-radius: 8px;
  flex: 1;
  min-width: 250px;
}

.booking-service-item img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 6px;
}

.booking-service-item h5 {
  font-size: 0.95rem;
  color: var(--primary);
  margin-bottom: 3px;
}

.booking-service-item span {
  font-size: 0.85rem;
  color: var(--gold);
  font-weight: 600;
}

.booking-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  background: var(--cream);
}

.booking-total span:first-child {
  font-weight: 600;
  color: var(--text-muted);
}

.booking-total span:last-child {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
}

/* ===== Footer ===== */
.footer {
  background: var(--primary-dark);
  color: var(--white);
  padding: 60px 0 30px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-col h4 {
  font-size: 1.25rem;
  margin-bottom: 20px;
  color: var(--gold);
}

.footer-col p,
.footer-col a {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.95rem;
  line-height: 2;
  display: block;
}

.footer-col a:hover {
  color: var(--gold);
}

.footer-bottom {
  text-align: center;
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .nav {
    display: none;
  }

  .mobile-menu-btn {
    display: block;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

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

  .time-slots {
    grid-template-columns: repeat(3, 1fr);
  }

  .date-picker {
    grid-template-columns: repeat(4, 1fr);
  }

  .search-box {
    display: none;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }

  .section-header h2 {
    font-size: 2rem;
  }

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