/* Alaa Beauty Studio — auth modal, cookie banner, account chip in topbar */

/* Cookie banner */
#cookieBanner {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  z-index: 10003;
  max-width: 760px;
  margin: 0 auto;
  background: linear-gradient(135deg, #fff, #fff3ef);
  border: 1px solid #f3c5c0;
  border-radius: 18px;
  box-shadow: 0 18px 40px rgba(112, 45, 55, 0.18);
  padding: 14px 18px;
  display: none;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
#cookieBanner.is-visible { display: flex; animation: cookieIn .3s ease both; }
@keyframes cookieIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
#cookieBanner .ck-text { flex: 1 1 320px; color: #321716; font-size: 13px; line-height: 1.45; }
#cookieBanner .ck-text strong { color: #b9445b; }
#cookieBanner .ck-actions { display: flex; gap: 8px; flex-wrap: wrap; }
#cookieBanner button {
  border: 0; cursor: pointer; font-family: inherit; font-weight: 900; font-size: 12px;
  border-radius: 999px; padding: 9px 14px;
}
#cookieBanner .ck-accept { background: linear-gradient(135deg, #d65a72, #b9445b); color: #fff; }
#cookieBanner .ck-decline { background: #fff; color: #b9445b; border: 1px solid #efd2cc; }
#cookieBanner .ck-link { background: transparent; color: #76534f; text-decoration: underline; padding: 9px 4px; }

/* Topbar account chip */
.topbar-account {
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.18); color: #fff;
  border: 1px solid rgba(255,255,255,.24);
  border-radius: 999px; padding: 9px 14px; font-weight: 900; font-size: 13px;
  text-decoration: none; cursor: pointer;
}
.topbar-account:hover { background: rgba(255,255,255,.28); }
.topbar-account .ta-name { max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Auth modal */
#authModal {
  position: fixed; inset: 0; z-index: 10010;
  background: rgba(50, 23, 22, 0.55);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
#authModal.is-open { display: flex; animation: authBgIn .25s ease both; }
@keyframes authBgIn { from { opacity: 0; } to { opacity: 1; } }

#authModal .auth-card {
  background: #fff;
  border-radius: 24px;
  border: 1px solid #f3c5c0;
  box-shadow: 0 24px 60px rgba(93, 59, 53, 0.3);
  width: min(460px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  padding: 28px;
  position: relative;
  animation: authCardIn .3s ease both;
}
@keyframes authCardIn { from { opacity: 0; transform: scale(.94) translateY(8px); } to { opacity: 1; transform: scale(1) translateY(0); } }

#authModal .auth-close {
  position: absolute; top: 12px; right: 12px;
  background: transparent; border: 0; font-size: 24px; line-height: 1;
  color: #76534f; cursor: pointer; padding: 6px 10px;
}

#authModal .auth-tabs {
  display: flex; gap: 6px; padding: 4px; background: #fff7f3; border: 1px solid #efd2cc; border-radius: 999px;
  margin-bottom: 18px;
}
#authModal .auth-tab {
  flex: 1; background: transparent; border: 0; cursor: pointer;
  font-family: inherit; font-weight: 900; font-size: 13px;
  color: #76534f; padding: 9px 12px; border-radius: 999px;
}
#authModal .auth-tab.is-active { background: linear-gradient(135deg, #d65a72, #b9445b); color: #fff; }

#authModal h2 { font-family: Georgia, serif; color: #321716; font-size: 22px; margin-bottom: 6px; }
#authModal .auth-sub { color: #76534f; font-size: 13px; margin-bottom: 16px; }

#authModal label { display: block; font-size: 12px; font-weight: 900; color: #321716; margin-bottom: 4px; }
#authModal input[type="text"],
#authModal input[type="email"],
#authModal input[type="password"] {
  width: 100%;
  padding: 11px 14px;
  font-size: 14px;
  font-family: inherit;
  color: #321716;
  background: #fff;
  border: 1px solid #efd2cc;
  border-radius: 14px;
  margin-bottom: 12px;
}
#authModal input:focus { outline: none; border-color: #d65a72; box-shadow: 0 0 0 3px rgba(214,90,114,.15); }

#authModal .auth-submit {
  width: 100%;
  background: linear-gradient(135deg, #d65a72, #b9445b);
  color: #fff;
  border: 0;
  border-radius: 999px;
  padding: 13px 20px;
  font-family: inherit;
  font-weight: 900;
  font-size: 14px;
  cursor: pointer;
  margin-top: 6px;
}
#authModal .auth-submit:disabled { opacity: 0.6; cursor: wait; }

#authModal .auth-status {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
  display: none;
}
#authModal .auth-status.is-error { display: block; background: #fde7ea; border: 1px solid #f4b9c1; color: #8a1f30; }
#authModal .auth-status.is-info { display: block; background: #fff4ec; border: 1px solid #f5d8c0; color: #8a4a18; }
#authModal .auth-status.is-success { display: block; background: #e9f7ee; border: 1px solid #bfe5cc; color: #1f5b35; }

#authModal .auth-foot {
  margin-top: 14px;
  font-size: 12px;
  color: #76534f;
  text-align: center;
}
#authModal .auth-foot a { color: #b9445b; font-weight: 900; cursor: pointer; }

@media (max-width: 540px) {
  #authModal .auth-card { padding: 22px; border-radius: 20px; }
}

/* OAuth buttons */
#authModal .auth-oauth { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
#authModal .auth-oauth-btn {
  width: 100%; cursor: pointer; font-family: inherit; font-weight: 800; font-size: 13px;
  padding: 11px 14px; border-radius: 14px; border: 1px solid #efd2cc; background: #fff; color: #321716;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
#authModal .auth-oauth-btn:hover { background: #fff7f3; }
#authModal .auth-oauth-google::before { content: "G"; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: linear-gradient(135deg,#4285F4,#34A853); color: #fff; font-weight: 900; font-family: Arial, sans-serif; font-size: 12px; }
#authModal .auth-oauth-facebook::before { content: "f"; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: #1877F2; color: #fff; font-weight: 900; font-family: Arial, sans-serif; font-size: 13px; }
#authModal .auth-divider { display: flex; align-items: center; gap: 10px; color: #a07a76; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; }
#authModal .auth-divider::before, #authModal .auth-divider::after { content: ""; flex: 1; height: 1px; background: #efd2cc; }

/* Consent block */
#authModal .auth-consent {
  display: flex; align-items: flex-start; gap: 8px; margin-bottom: 8px;
  font-size: 12px; color: #321716; font-weight: 600;
}
#authModal .auth-consent input[type="checkbox"] { margin-top: 3px; }

/* Address textarea matches input styling */
#authModal textarea {
  width: 100%; padding: 11px 14px; font-size: 14px; font-family: inherit;
  color: #321716; background: #fff; border: 1px solid #efd2cc; border-radius: 14px;
  margin-bottom: 12px; resize: vertical; min-height: 60px;
}
#authModal textarea:focus { outline: none; border-color: #d65a72; box-shadow: 0 0 0 3px rgba(214,90,114,.15); }

/* Login-required prompt banner */
#authModal .auth-prompt {
  background: #fff4ec; border: 1px solid #f5d8c0; color: #8a4a18;
  border-radius: 12px; padding: 10px 12px; font-size: 13px; font-weight: 700;
  margin-bottom: 14px;
}

/* ==========================================================================
   Header — mobile hamburger menu only.
   The Trending Hair Styles dropdown markup uses .nav-dropdown classes (see
   end of file). All previous .menu-dropdown* rules below are intentionally
   no-ops because the markup no longer matches them.
   Brand: rose accent #b91c63, soft pink hover #fdf0f5
   ========================================================================== */

/* Hamburger (mobile only) */
.menu-burger {
  display: none;
  position: relative;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid #efd2cc;
  border-radius: 12px;
  cursor: pointer;
  padding: 0;
  margin-left: auto;
  align-items: center;
  justify-content: center;
}
.menu-burger span {
  position: absolute;
  left: 10px;
  right: 10px;
  height: 2px;
  background: #b91c63;
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease, top 0.25s ease;
}
.menu-burger span:nth-child(1) { top: 13px; }
.menu-burger span:nth-child(2) { top: 19px; }
.menu-burger span:nth-child(3) { top: 25px; }
.menu-burger[aria-expanded="true"] span:nth-child(1) { top: 19px; transform: rotate(45deg); }
.menu-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-burger[aria-expanded="true"] span:nth-child(3) { top: 19px; transform: rotate(-45deg); }

/* (Old .menu-dropdown* rules removed. The Trending Hair Styles dropdown
   uses the .nav-dropdown / .nav-dropdown-panel classes defined at the
   bottom of this file, with !important on every property.) */

/* ==========================================================================
   Mobile menu drawer (≤ 768px) — applies to .menu (the main nav container).
   ========================================================================== */
@media (max-width: 768px) {
  .menu-burger { display: flex; }

  .menu {
    position: absolute !important;
    top: 100% !important;
    left: 0;
    right: 0;
    flex-direction: column !important;
    align-items: stretch !important;
    background: #fff;
    padding: 12px 16px 18px !important;
    border-top: 1px solid #f3e0ea;
    box-shadow: 0 12px 24px rgba(185, 28, 99, 0.08);
    gap: 4px !important;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.28s ease, padding 0.2s ease;
    z-index: 150;
  }
  .menu.is-open {
    display: flex !important;
    max-height: 75vh;
    overflow-y: auto;
    padding: 12px 16px 18px !important;
  }
  .menu > a {
    display: block;
    padding: 14px 6px;
    font-size: 16px;
    border-bottom: 1px solid #fbe9f0;
    color: #321716;
    text-align: left;
    width: 100%;
  }
  .menu > a:hover,
  .menu > a:focus { color: #b91c63; }
}

/* On very small screens, keep the topbar WhatsApp button visible — never hide */
@media (max-width: 480px) {
  .topbar-call,
  .topbar-wa,
  .topbar-book {
    padding: 8px 12px;
    font-size: 12px;
  }
}

/* Logged-in user dashboard panel inside loyalty area */
#userDashboard {
  display: none;
  margin-top: 16px;
  padding: 18px;
  background: #fff;
  border: 1px solid #efd2cc;
  border-radius: 18px;
  box-shadow: 0 12px 28px rgba(112,45,55,.07);
}
#userDashboard.is-visible { display: block; }
#userDashboard h3 { font-family: Georgia, serif; color: #b9445b; font-size: 18px; margin-bottom: 8px; }
#userDashboard .ud-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px dotted #efd2cc; font-size: 14px; }
#userDashboard .ud-row:last-child { border-bottom: 0; }
#userDashboard .ud-label { color: #76534f; font-weight: 700; }
#userDashboard .ud-value { color: #321716; font-weight: 900; }

/* (Old Trending Hair Styles dropdown rules removed.
   Trending Hair Styles is now a normal nav link to #top20HairStyles.) */

/* Login / Register / Profile / Logout chips inside the topbar */
.topbar-account-group {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.topbar-account-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-family: inherit;
  font-weight: 900;
  font-size: 13px;
  padding: 9px 14px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.24);
  cursor: pointer;
  white-space: nowrap;
}
.topbar-account-link:hover { background: rgba(255, 255, 255, 0.28); }
.topbar-account-link.is-primary {
  background: #fff;
  color: #b91c63;
  border-color: rgba(255, 255, 255, 0.35);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
}
.topbar-account-link.is-primary:hover { background: #fdf0f5; }
.topbar-account-group [hidden] { display: none !important; }

@media (max-width: 540px) {
  .topbar-account-link { padding: 7px 11px; font-size: 12px; }
}
