html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}
body {
  font-family: 'Montserrat', sans-serif;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
}
html.menu-open,
body.menu-open {
  overflow: hidden;
  overscroll-behavior: none;
}

h1, h2, h3, .font-display { font-family: 'Playfair Display', serif; }

/* Header */
#header {
  padding-top: max(0.5rem, env(safe-area-inset-top));
}
.header-bar {
  padding-bottom: 0.75rem;
}
@media (min-width: 768px) {
  .header-bar { padding-bottom: 1rem; }
}
.header-bar-inner {
  min-height: 3.5rem;
}
@media (min-width: 768px) {
  .header-bar-inner { min-height: 4.5rem; }
}
#header.scrolled,
#header.menu-active {
  background-color: rgba(255, 251, 247, 0.97);
  box-shadow: 0 4px 24px rgba(45, 42, 42, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.logo-img {
  transition: filter 0.35s ease;
}
#header.on-hero:not(.scrolled):not(.menu-active) .logo-img {
  filter: brightness(0) invert(1) drop-shadow(0 2px 10px rgba(0, 0, 0, 0.25));
}
#header.scrolled .logo-img,
#header.menu-active .logo-img {
  filter: none;
}

.header-nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
  transition: color 0.25s ease;
  position: relative;
}
.header-nav-link::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: #B76E79;
  transition: width 0.3s ease;
}
.header-nav-link:hover::after { width: 100%; }
#header.on-hero:not(.scrolled):not(.menu-active) .header-nav-link {
  color: rgba(255, 255, 255, 0.95);
}
#header.on-hero:not(.scrolled):not(.menu-active) .header-nav-link:hover {
  color: #F8E8EE;
}
#header.on-hero:not(.scrolled):not(.menu-active) .header-nav-link::after {
  background: #F8E8EE;
}
#header.scrolled .header-nav-link,
#header.menu-active .header-nav-link,
#header:not(.on-hero) .header-nav-link {
  color: #2D2A2A;
}
#header.scrolled .header-nav-link:hover,
#header.menu-active .header-nav-link:hover,
#header:not(.on-hero) .header-nav-link:hover {
  color: #B76E79;
}

.header-divider {
  width: 1px;
  height: 1.5rem;
  background: rgba(183, 110, 121, 0.35);
  flex-shrink: 0;
}
#header.on-hero:not(.scrolled):not(.menu-active) .header-divider {
  background: rgba(255, 255, 255, 0.35);
}

.header-menu-btn {
  width: 2.5rem;
  height: 2.5rem;
  min-width: 2.5rem;
  min-height: 2.5rem;
  border-radius: 9999px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: background-color 0.25s ease, border-color 0.25s ease;
  flex-shrink: 0;
}
#header.on-hero:not(.scrolled):not(.menu-active) .header-menu-btn {
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.12);
}
#header.on-hero:not(.scrolled):not(.menu-active) .header-menu-btn:hover {
  background: rgba(255, 255, 255, 0.22);
}
#header.scrolled .header-menu-btn,
#header.menu-active .header-menu-btn {
  border: 1px solid rgba(183, 110, 121, 0.25);
  background: rgba(248, 232, 238, 0.5);
}
#header.scrolled .header-menu-btn:hover,
#header.menu-active .header-menu-btn:hover {
  background: rgba(248, 232, 238, 0.9);
}
.hamburger-line {
  display: block;
  width: 1.125rem;
  height: 2px;
  background-color: #2D2A2A;
  transition: transform 0.3s ease, opacity 0.3s ease, background-color 0.3s ease;
  transform-origin: center;
}
#header.on-hero:not(.scrolled):not(.menu-active) .hamburger-line {
  background-color: #fff;
}
#header.menu-active .hamburger-line {
  background-color: #2D2A2A !important;
}

/* Hero */
.hero-bg {
  background-image: url('https://images.unsplash.com/photo-1570172619644-dfd03ed5d881?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
}
@media (max-width: 640px) {
  .hero-bg {
    background-position: center 35%;
  }
}
.hero-overlay {
  background: linear-gradient(
    180deg,
    rgba(45, 42, 42, 0.5) 0%,
    rgba(183, 110, 121, 0.3) 45%,
    rgba(45, 42, 42, 0.55) 100%
  );
}
.hero-section {
  min-height: 100vh;
}
@media (max-width: 767px) {
  .hero-section {
    min-height: 100svh;
    height: 100svh;
    max-height: 100svh;
  }
  .hero-bg {
    background-attachment: scroll;
  }
}
@media (min-width: 768px) {
  .hero-section {
    min-height: 100dvh;
  }
}

.btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 9999px;
  background-color: #B76E79;
  color: #fff;
  white-space: nowrap;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}
.btn-cta:hover {
  background-color: #a05d68;
}
@media (hover: hover) {
  .btn-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(183, 110, 121, 0.4);
  }
}
.btn-cta:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(183, 110, 121, 0.3);
}

.btn-header {
  min-height: 2.5rem;
  padding: 0.5rem 1rem;
  font-size: 0.625rem;
  line-height: 1;
}
@media (min-width: 380px) {
  .btn-header {
    padding: 0.5rem 1.125rem;
    font-size: 0.6875rem;
  }
}
@media (min-width: 768px) {
  .btn-header {
    min-height: 2.75rem;
    padding: 0.625rem 1.375rem;
    font-size: 0.75rem;
  }
}
#header.on-hero:not(.scrolled):not(.menu-active) .btn-header {
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.25);
}

.btn-hero {
  min-height: 3rem;
  padding: 0.875rem 2rem;
  font-size: 0.75rem;
}
@media (min-width: 640px) {
  .btn-hero {
    min-height: 3.25rem;
    padding: 1rem 2.5rem;
    font-size: 0.875rem;
  }
}

.service-card {
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}
@media (hover: hover) and (pointer: fine) {
  .service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(183, 110, 121, 0.18);
  }
}

#mobile-menu {
  transition: opacity 0.3s ease, visibility 0.3s ease;
  max-height: calc(100dvh - var(--header-h, 64px));
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
#mobile-menu.hidden-menu {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
#mobile-menu.open-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.mobile-nav-link {
  min-height: 3rem;
  display: flex;
  align-items: center;
  font-size: 0.9375rem;
  font-weight: 500;
  transition: color 0.25s ease;
}
.btn-header-mobile {
  min-height: 3rem;
  width: 100%;
  font-size: 0.75rem;
  margin-top: 0.5rem;
}

.site-footer {
  background: linear-gradient(180deg, #2D2A2A 0%, #252222 100%);
}
.footer-brand {
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
@media (min-width: 1024px) {
  .footer-brand {
    padding-bottom: 0;
    border-bottom: none;
  }
}
.footer-link {
  color: rgba(255, 255, 255, 0.65);
  transition: color 0.25s ease;
  display: inline-block;
  min-height: 2.25rem;
  line-height: 2.25rem;
}
@media (min-width: 768px) {
  .footer-link {
    min-height: auto;
    line-height: inherit;
  }
}
.footer-link:hover {
  color: #F8E8EE;
}
.footer-social {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.85);
  transition: background-color 0.25s ease, border-color 0.25s ease, color 0.25s ease, transform 0.25s ease;
}
@media (hover: hover) {
  .footer-social:hover {
    background: #B76E79;
    border-color: #B76E79;
    color: #fff;
    transform: translateY(-2px);
  }
}

.form-input {
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  font-size: 16px;
}
.form-input:focus {
  border-color: #B76E79;
  box-shadow: 0 0 0 3px rgba(183, 110, 121, 0.15);
  outline: none;
}

.section-pad {
  padding-top: 3.5rem;
  padding-bottom: 3.5rem;
}
@media (min-width: 640px) {
  .section-pad {
    padding-top: 5rem;
    padding-bottom: 5rem;
  }
}
@media (min-width: 768px) {
  .section-pad {
    padding-top: 7rem;
    padding-bottom: 7rem;
  }
}

.fade-in {
  animation: fadeInUp 0.8s ease forwards;
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

.about-deco {
  inset: -0.5rem;
}
@media (min-width: 640px) {
  .about-deco { inset: -0.75rem; }
}

/* Inner pages */
.page-hero {
  padding-top: calc(5rem + env(safe-area-inset-top));
  padding-bottom: 3rem;
  background: linear-gradient(135deg, #F8E8EE 0%, #F5F0EB 100%);
}
@media (min-width: 768px) {
  .page-hero {
    padding-top: 7rem;
    padding-bottom: 4rem;
  }
}

.alert {
  padding: 1rem 1.25rem;
  border-radius: 0.75rem;
  font-size: 0.875rem;
  margin-bottom: 1rem;
}
.alert-success {
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}
.alert-error {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}
.alert-info {
  background: #eff6ff;
  color: #1e40af;
  border: 1px solid #bfdbfe;
}

/* Appointment booking */
.booking-step {
  display: none;
}
.booking-step.active {
  display: block;
}
.service-select-card {
  cursor: pointer;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.service-select-card.selected {
  border-color: #B76E79;
  box-shadow: 0 0 0 3px rgba(183, 110, 121, 0.2);
}
.time-slot {
  cursor: pointer;
  transition: all 0.2s ease;
}
.time-slot:hover:not(.disabled) {
  border-color: #B76E79;
  background: #F8E8EE;
}
.time-slot.selected {
  background: #B76E79;
  color: #fff;
  border-color: #B76E79;
}
.time-slot.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.date-btn {
  cursor: pointer;
  transition: all 0.2s ease;
}
.date-btn:hover:not(.disabled) {
  border-color: #B76E79;
}
.date-btn.selected {
  background: #B76E79;
  color: #fff;
  border-color: #B76E79;
}
.date-btn.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.status-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
}
.status-pending { background: #fef3c7; color: #92400e; }
.status-approved { background: #d1fae5; color: #065f46; }
.status-rejected { background: #fee2e2; color: #991b1b; }

/* Admin panel */
.admin-sidebar {
  background: linear-gradient(180deg, #2D2A2A 0%, #252222 100%);
  min-height: 100vh;
}
.admin-nav-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  color: rgba(255,255,255,0.7);
  transition: all 0.2s ease;
}
.admin-nav-link:hover,
.admin-nav-link.active {
  background: rgba(183, 110, 121, 0.3);
  color: #fff;
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
}
.admin-table th,
.admin-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid #F8E8EE;
}
.admin-table th {
  background: #F5F0EB;
  font-weight: 600;
  font-size: 0.875rem;
}
.admin-card {
  background: #fff;
  border-radius: 1rem;
  border: 1px solid rgba(248, 232, 238, 0.8);
  box-shadow: 0 1px 3px rgba(45, 42, 42, 0.06);
}
