@import url("https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@500;600;700&family=Manrope:wght@400;500;600;700&display=swap");

:root {
  color-scheme: light;
  --bg: #fff4fa;
  --bg-soft: #ffe6f2;
  --bg-strong: #ffcde2;
  --ink: #2f1a29;
  --muted: #7e5a6f;
  --accent: #ea4b95;
  --accent-dark: #bf2c6c;
  --accent-soft: #ff91be;
  --accent-2: #ff6ea5;
  --card: #ffffff;
  --line: rgba(234, 75, 149, 0.2);
  --shadow: 0 22px 48px rgba(234, 75, 149, 0.18);
  --radius: 20px;
  --max: 1180px;
  --font-title: "Cormorant Garamond", "Times New Roman", serif;
  --font-body: "Manrope", "Arial", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  background:
    radial-gradient(circle at 12% 8%, #ffffff 0%, #fff3f9 36%, var(--bg) 100%),
    linear-gradient(140deg, rgba(255, 255, 255, 0.55), rgba(255, 209, 230, 0.35));
  color: var(--ink);
  line-height: 1.6;
  min-height: 100vh;
  position: relative;
}

body::before,
body::after {
  content: "";
  position: fixed;
  z-index: -1;
  pointer-events: none;
  filter: blur(2px);
}

body::before {
  top: -120px;
  right: -80px;
  width: 360px;
  height: 360px;
  background: radial-gradient(circle, rgba(255, 168, 208, 0.55), rgba(255, 168, 208, 0));
}

body::after {
  left: -110px;
  bottom: -120px;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(234, 75, 149, 0.2), rgba(234, 75, 149, 0));
}

a {
  transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
  color: var(--accent-dark);
}

.page {
  max-width: var(--max);
  margin: 0 auto;
  padding: 20px 24px 86px;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px 16px;
  margin-bottom: 24px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(10px);
  box-shadow: 0 14px 30px rgba(234, 75, 149, 0.12);
  position: sticky;
  top: 12px;
  z-index: 10;
}

.logo {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: inherit;
}

.logo:hover {
  color: inherit;
  opacity: 0.96;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--accent), var(--accent-soft));
  color: #fff;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.logo strong {
  display: block;
  font-size: 18px;
  font-weight: 700;
}

.logo span {
  font-size: 12px;
  color: var(--muted);
}

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

.nav a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid transparent;
}

.nav a.active {
  background: rgba(234, 75, 149, 0.14);
  border-color: rgba(234, 75, 149, 0.24);
  color: var(--accent-dark);
}

.nav a:hover {
  background: rgba(234, 75, 149, 0.08);
}

.nav-avatar {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  border: 1px solid #f2c3d6;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--accent-dark);
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(234, 75, 149, 0.18);
}

.nav-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 20px;
  border-radius: 999px;
  border: 1px solid var(--line);
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  color: var(--accent);
  background: rgba(255, 255, 255, 0.72);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  cursor: pointer;
}

.button.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  border-color: transparent;
  box-shadow: 0 16px 30px rgba(234, 75, 149, 0.36);
}

.button.ghost {
  border-color: var(--accent-soft);
  color: var(--accent-dark);
}

.button:hover {
  transform: translateY(-2px) scale(1.01);
  box-shadow: 0 12px 24px rgba(43, 28, 39, 0.14);
  border-color: rgba(234, 75, 149, 0.45);
}

.button.danger {
  border-color: #ef6b87;
  color: #b02047;
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  align-items: center;
  padding: 34px;
  background: var(--bg-soft);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  animation: rise 0.8s ease both;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -10% -30% auto;
  width: 380px;
  height: 380px;
  background: radial-gradient(circle, rgba(234, 75, 149, 0.34), transparent 72%);
  filter: blur(14px);
  z-index: 0;
}

.hero-text,
.hero-panel {
  position: relative;
  z-index: 1;
}

.hero-text h1 {
  font-family: var(--font-title);
  font-size: clamp(2.2rem, 3.2vw, 3.6rem);
  line-height: 1.1;
  margin-bottom: 16px;
}

.eyebrow {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.25em;
  color: var(--muted);
  margin-bottom: 12px;
}

.lead {
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 20px;
  max-width: 60ch;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 26px;
}

.hero-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

.hero-meta div {
  background: var(--card);
  border-radius: 16px;
  padding: 12px 14px;
  box-shadow: 0 10px 20px rgba(242, 75, 143, 0.12);
}

.hero-meta strong {
  display: block;
  font-size: 16px;
  margin-bottom: 4px;
}

.hero-meta span {
  color: var(--muted);
  font-size: 13px;
}

.hero-panel {
  display: grid;
  gap: 16px;
}

.hero-card {
  background: var(--card);
  border-radius: 18px;
  padding: 20px;
  box-shadow: 0 18px 32px rgba(234, 75, 149, 0.15);
  border: 1px solid var(--line);
  display: grid;
  gap: 12px;
}

.hero-card.subtle {
  background: #fff5fa;
  border-style: dashed;
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: #fff0f6;
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 700;
}

.hero-slot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  border-radius: 14px;
  background: #fff6fb;
  font-size: 14px;
}

.section {
  padding: 58px 0 0;
}

.section-title {
  margin-bottom: 24px;
}

.section-title h2 {
  font-family: var(--font-title);
  font-size: clamp(1.8rem, 2.6vw, 2.6rem);
  margin-bottom: 8px;
}

.section-title p {
  color: var(--muted);
}

.search-panel {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  background: var(--card);
  padding: 18px;
  border-radius: 18px;
  border: 1px solid var(--line);
  box-shadow: 0 16px 28px rgba(234, 75, 149, 0.14);
}

.hero-search {
  margin-top: 18px;
}

.field {
  display: grid;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}

.field input,
.field select,
.field textarea {
  border: 1px solid #f2c3d6;
  border-radius: 12px;
  padding: 10px 12px;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--ink);
  background: #fff;
  width: 100%;
  min-width: 0;
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.inline input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(234, 75, 149, 0.13);
}

.field textarea {
  resize: vertical;
  min-height: 84px;
}

.field input[type="file"] {
  padding: 8px;
  font-size: 13px;
  max-width: 100%;
}

.catalog {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin-top: 24px;
}

.mk-card {
  background: var(--card);
  padding: 14px;
  border-radius: 18px;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 14px;
  border: 1px solid var(--line);
  box-shadow: 0 14px 26px rgba(234, 75, 149, 0.11);
  transition: transform 0.2s ease;
  color: var(--ink);
  overflow: hidden;
}

.mk-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 36px rgba(234, 75, 149, 0.2);
}

.mk-photo {
  height: 160px;
  border-radius: 14px;
  background: linear-gradient(145deg, #ffbcd6, #ffd7e8);
  display: grid;
  place-items: center;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.mk-photo.large {
  height: 220px;
}

.mk-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.mk-info h3 {
  margin-bottom: 6px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.mk-cover-link,
.mk-title-link,
.master-link {
  color: inherit;
  text-decoration: none;
}

.mk-cover-link {
  display: block;
}

.mk-title-link {
  text-underline-offset: 4px;
}

.mk-title-link:hover,
.master-link:hover {
  color: var(--accent-dark);
  text-decoration: underline;
}

.mk-info p {
  color: var(--muted);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.mk-info {
  display: grid;
  gap: 6px;
  align-content: start;
  min-width: 0;
}

.image-fallback {
  color: #fff;
  font-size: 20px;
  letter-spacing: 0.01em;
  text-align: center;
  padding: 0 12px;
}

.mk-meta {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  color: var(--accent-dark);
}

.master-card {
  background: var(--card);
  padding: 22px;
  border-radius: 20px;
  display: grid;
  gap: 18px;
  border: 1px solid var(--line);
  box-shadow: 0 18px 32px rgba(234, 75, 149, 0.14);
}

.master-identity {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.avatar {
  width: 60px;
  height: 60px;
  border-radius: 18px;
  background: linear-gradient(135deg, #f24b8f, #ff9bc3);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
}

.avatar.large {
  width: 70px;
  height: 70px;
  font-size: 20px;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.contact-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: var(--muted);
  font-size: 13px;
  margin-top: 6px;
}

.master-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px;
}

.master-stats div {
  background: #fff5fa;
  border-radius: 14px;
  padding: 10px 12px;
}

.master-details {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.card {
  background: var(--card);
  padding: 20px;
  border-radius: 18px;
  border: 1px solid var(--line);
  box-shadow: 0 14px 26px rgba(234, 75, 149, 0.11);
  display: grid;
  gap: 12px;
  min-width: 0;
}

.map-card {
  background: linear-gradient(135deg, #ffd7e8, #ffeef6);
  border-radius: 18px;
  padding: 18px;
  display: grid;
  gap: 14px;
  min-height: 180px;
}

.map-pin {
  font-weight: 700;
  color: var(--accent-dark);
}

.map-view {
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: #fff;
  height: 100%;
  color: var(--muted);
  overflow: hidden;
}

.map-view iframe {
  border: 0;
  width: 100%;
  min-height: 220px;
}

.master-services {
  display: grid;
  gap: 14px;
  margin-top: 24px;
}

.service {
  background: var(--card);
  padding: 18px;
  border-radius: 18px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  box-shadow: 0 14px 26px rgba(234, 75, 149, 0.11);
}

.service-meta {
  display: flex;
  gap: 16px;
  align-items: center;
  font-weight: 700;
  color: var(--accent-dark);
}

.reviews {
  margin-top: 32px;
}

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.review {
  background: var(--card);
  padding: 18px;
  border-radius: 18px;
  border: 1px solid var(--line);
  box-shadow: 0 12px 24px rgba(234, 75, 149, 0.1);
  display: grid;
  gap: 10px;
}

.review-head {
  display: flex;
  gap: 12px;
  align-items: center;
}

.review-avatar {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #ff9bc3;
  display: grid;
  place-items: center;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.review-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.review-reply {
  background: #fff0f6;
  border-radius: 12px;
  padding: 8px 10px;
  font-size: 13px;
  color: var(--muted);
}

.booking-card {
  background: var(--card);
  padding: 22px;
  border-radius: 20px;
  display: grid;
  gap: 20px;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

.booking-media {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  align-items: start;
  position: relative;
  z-index: 0;
}

#workshop-photo {
  border-radius: 14px;
  overflow: hidden;
  min-width: 0;
}

#workshop-photo .mk-photo,
#workshop-photo .mk-photo.large {
  height: clamp(220px, 32vw, 320px);
  width: 100%;
}

#workshop-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.booking-desc ul {
  list-style: none;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.booking-desc strong {
  overflow-wrap: anywhere;
}

.booking-form {
  display: grid;
  gap: 12px;
}

#booking .field {
  position: relative;
  z-index: 1;
}

.slot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  background: #fff5fa;
  border: 1px solid rgba(234, 75, 149, 0.18);
}

.slot.full {
  background: #ffe8f1;
}

.hint {
  font-size: 13px;
  color: var(--muted);
}

.account-grid,
.auth-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.admin-grid > .card {
  width: 100%;
  min-width: 0;
}

.profile-card .field-group {
  display: grid;
  gap: 12px;
}

.profile-row {
  display: flex;
  gap: 16px;
  align-items: center;
}

.bookings-card {
  display: grid;
  gap: 12px;
}

.booking-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 12px;
  background: #fff5fa;
  border-radius: 14px;
  border: 1px solid rgba(234, 75, 149, 0.17);
}

.queue-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: #fff5fa;
  border-radius: 12px;
  border: 1px solid rgba(234, 75, 149, 0.17);
}

.workshop-admin-meta {
  display: grid;
  gap: 4px;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: #ffe1ee;
  font-size: 12px;
  color: var(--accent-dark);
}

.badge.success {
  background: #d9f5e7;
  color: #0b7a4a;
}

.site-footer {
  margin-top: 70px;
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 13px;
  flex-wrap: wrap;
  gap: 12px;
  border-top: 1px dashed rgba(234, 75, 149, 0.3);
  padding-top: 16px;
}

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

@media (max-width: 820px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
    padding: 14px;
  }

  .service {
    align-items: flex-start;
  }

  .slot {
    flex-direction: column;
    align-items: flex-start;
  }

  .page {
    padding: 16px 14px 62px;
  }

  .hero {
    padding: 24px 16px;
  }

  .mk-photo {
    height: 140px;
  }
}

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

.inline {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.inline input {
  min-width: 220px;
  border: 1px solid #f2c3d6;
  border-radius: 10px;
  padding: 8px 10px;
}

.link-btn {
  border: 0;
  background: transparent;
  padding: 0;
  margin-top: 2px;
  color: var(--accent-dark);
  font-weight: 700;
  text-align: left;
  cursor: pointer;
}

.link-btn:hover {
  text-decoration: underline;
}

.login-code-wrap {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px dashed rgba(234, 75, 149, 0.35);
  border-radius: 12px;
  background: #fff7fb;
}

#admin-workshops,
#admin-queue,
#my-bookings-list {
  display: grid;
  gap: 10px;
}

.nav .hint {
  font-weight: 700;
  color: var(--muted);
}

#auth-status {
  min-height: 20px;
  font-weight: 600;
  margin-bottom: 10px;
}

.toast-container {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 2000;
  display: grid;
  gap: 8px;
  max-width: min(92vw, 380px);
}

.toast {
  background: rgba(47, 26, 41, 0.93);
  color: #fff;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 14px 24px rgba(31, 21, 29, 0.3);
  font-size: 14px;
  line-height: 1.35;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.toast.hide {
  opacity: 0;
  transform: translateY(6px);
}
