/* Findout prototype — design system + shared styles
 *
 * Phase 1 foundation. Prefer tokens and the components below.
 * --fo-* names are the public API for existing pages (do not rename).
 *
 * Breakpoints (use these values in @media going forward):
 *   480px  sm   large phones
 *   720px  md   phones / small tablet
 *   900px  lg   tablet
 *   1200px xl   desktop
 *   1440px 2xl  wide desktop
 */

:root {
  /* —— Brand —— */
  --fo-orange: #F58220;
  --fo-orange-dark: #E06D10;
  --fo-orange-light: #FFF4EB;
  --fo-blue: #4A90E2;
  --fo-blue-dark: #357ABD;
  --fo-blue-light: #E8F3FF;
  --fo-navy: #0F172A;

  /* —— Neutrals —— */
  --neutral-0: #FFFFFF;
  --neutral-50: #FAFBFC;
  --neutral-100: #F4F6F8;
  --neutral-200: #E8ECF0;
  --neutral-300: #D5DCE3;
  --neutral-400: #9AA3B0;
  --neutral-500: #6B7280;
  --neutral-600: #4B5563;
  --neutral-700: #374151;
  --neutral-800: #1A1A1A;
  --neutral-900: #0F172A;

  /* —— Surfaces —— */
  --fo-bg: var(--neutral-50);
  --fo-surface: var(--neutral-0);
  --bg-page-base: #f5f8fb;
  --bg-page:
    radial-gradient(ellipse 60% 35% at 100% 0%, rgba(74, 144, 226, 0.1), transparent 50%),
    radial-gradient(ellipse 40% 30% at 0% 30%, rgba(245, 130, 32, 0.05), transparent 45%),
    var(--bg-page-base);
  --bg-page-alt: var(--neutral-0);
  --bg-muted: var(--neutral-100);

  /* —— Text / border —— */
  --fo-text: var(--neutral-800);
  --fo-text-muted: var(--neutral-500);
  --fo-border: var(--neutral-200);
  --border-strong: var(--neutral-300);

  /* —— Semantic —— */
  --fo-success: #1F9D55;
  --fo-success-light: #ECFDF3;
  --fo-danger: #C0392B;
  --fo-danger-light: #FDECEA;
  --fo-warning: #C47B16;
  --fo-warning-light: #FFF6E8;
  --fo-info: var(--fo-blue);
  --fo-info-light: var(--fo-blue-light);

  /* Semantic aliases — orange = convert, blue = navigate */
  --color-action: var(--fo-orange);
  --color-action-dark: var(--fo-orange-dark);
  --color-nav: var(--fo-blue);
  --color-nav-dark: var(--fo-blue-dark);
  --color-primary: var(--fo-orange);
  --color-secondary: var(--fo-blue);
  --color-text: var(--fo-text);
  --color-muted: var(--fo-text-muted);
  --color-surface: var(--fo-surface);
  --color-bg: var(--fo-bg);
  --color-border: var(--fo-border);
  --color-success: var(--fo-success);
  --color-danger: var(--fo-danger);
  --color-warning: var(--fo-warning);
  --color-info: var(--fo-info);

  /* —— Typography —— */
  --fo-font: "Readex Pro", "Segoe UI", Tahoma, sans-serif;
  --fo-font-display: var(--fo-font);
  --text-xs: 0.75rem;      /* 12 */
  --text-sm: 0.8125rem;    /* 13 */
  --text-base: 0.9375rem;  /* 15 */
  --text-md: 1rem;         /* 16 */
  --text-lg: 1.125rem;     /* 18 */
  --text-xl: 1.25rem;      /* 20 */
  --text-2xl: 1.5rem;      /* 24 */
  --text-3xl: 1.875rem;    /* 30 */
  --text-4xl: 2.25rem;     /* 36 */
  --text-section: clamp(1.3rem, 2.5vw, 1.65rem);
  --text-display: clamp(1.75rem, 4vw, 2.65rem);
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;
  --leading-tight: 1.25;
  --leading-snug: 1.4;
  --leading-normal: 1.6;
  --leading-relaxed: 1.75;
  --tracking-tight: -0.02em;
  --tracking-display: -0.03em;

  /* —— Spacing (8px grid) —— */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 88px;
  --section-y: clamp(40px, 6vw, 72px);
  --section-y-tight: clamp(32px, 4vw, 48px);
  --section-gap: var(--space-5);

  /* —— Radius —— */
  --radius-sm: 8px;
  --radius-md: 10px;
  --radius-control: 10px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-2xl: 24px;
  --radius-full: 999px;
  --fo-radius: 12px;
  --fo-radius-lg: var(--radius-xl);

  /* —— Shadows (restrained; keep existing card hover values) —— */
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.06);
  --shadow-card: 0 8px 28px rgba(15, 23, 42, 0.08);
  --shadow-elevated: 0 20px 40px rgba(15, 23, 42, 0.12);
  --fo-shadow: var(--shadow-card);

  /* —— Focus / motion —— */
  --focus-color: var(--fo-blue);
  --focus-color-action: var(--fo-orange);
  --focus-ring: 0 0 0 3px rgba(74, 144, 226, 0.28);
  --focus-ring-action: 0 0 0 3px rgba(245, 130, 32, 0.28);
  --ease: cubic-bezier(.2, .8, .2, 1);
  --duration: 0.25s;
  --duration-fast: 0.15s;

  /* —— Controls —— */
  --control-height: 48px;
  --control-height-sm: 40px;
  --control-height-lg: 52px;
  --control-pad-x: 14px;
  --control-bg: var(--neutral-50);
  --control-bg-focus: var(--neutral-0);

  /* —— Layout —— */
  --fo-header: 72px;
  --container: 1180px;
  --container-wide: 1320px;
  --container-narrow: 760px;
  --container-pad: clamp(20px, 4vw, 40px);
  --fo-max: var(--container);

  /* Breakpoint reference (custom properties are not valid in @media) */
  --bp-sm: 480px;
  --bp-md: 720px;
  --bp-lg: 900px;
  --bp-xl: 1200px;
  --bp-2xl: 1440px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--fo-font);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  background: var(--bg-page);
  color: var(--fo-text);
  line-height: var(--leading-normal);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
h1, h2, h3 {
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-tight);
  line-height: var(--leading-tight);
}
main { flex: 1; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
button, input, select, textarea { font: inherit; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.skip-link {
  position: absolute;
  inset-inline-start: 12px;
  top: 12px;
  z-index: 200;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  background: var(--fo-navy);
  color: #fff;
  font-weight: 600;
  transform: translateY(-160%);
  transition: transform var(--duration-fast);
}
.skip-link:focus,
.skip-link:focus-visible {
  transform: translateY(0);
  outline: 2px solid var(--focus-color);
  outline-offset: 2px;
}
#main-content:focus {
  outline: none;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}
.container--wide { max-width: var(--container-wide); }
.container--narrow { max-width: var(--container-narrow); }



/* Header */
.header {
  position: sticky; top: 0; z-index: 50;
  height: var(--fo-header);
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--fo-border);
  width: 100%;
  max-width: 100%;
}
.header__inner {
  height: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  max-width: 1440px;
  width: 100%;
  min-width: 0;
  margin-inline: auto;
  padding-inline: var(--container-pad);
  box-sizing: border-box;
}
.header__start {
  display: flex;
  align-items: center;
  gap: 72px;
  flex-shrink: 0;
}
.header__end {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  margin-inline-start: auto;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 1.05rem; flex-shrink: 0;
}
.brand__img {
  height: 52px;
  width: auto;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
}
.brand__img--sm {
  width: 36px;
  height: 36px;
}
.brand__mark {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(145deg, var(--fo-blue), var(--fo-blue-dark));
  display: grid; place-items: center; color: #fff;
  box-shadow: 0 4px 12px rgba(74,144,226,0.3);
}
.brand__mark svg { width: 18px; height: 18px; }
.footer .brand__img {
  width: 36px;
  height: 36px;
}
.nav {
  display: flex; align-items: center; gap: 4px 18px;
  font-size: 0.9rem; font-weight: 500; color: var(--fo-text-muted);
  flex-shrink: 0;
  white-space: nowrap;
}
.nav a {
  padding: 6px 0; position: relative; transition: color var(--duration-fast);
  flex-shrink: 0; white-space: nowrap;
}
.nav a:hover, .nav a.is-active { color: var(--fo-text); }
.nav a.is-active::after {
  content: ""; position: absolute; inset-inline: 0; bottom: 0;
  height: 2px; background: var(--fo-orange); border-radius: 2px;
}
.header__actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.header-search,
.header-search__field,
.header-search__toggle,
.header__actions .locale,
.header__actions .header-icon,
.header__actions .user-chip,
.header__actions .menu-btn,
.header__actions > .btn {
  height: var(--control-height-sm);
  min-height: var(--control-height-sm);
  box-sizing: border-box;
  border-radius: var(--radius-control);
}
.header__actions > .btn.btn--sm { padding-block: 0; }
.header-menu { position: relative; display: flex; align-items: center; height: var(--control-height-sm); }
.header-menu > summary { list-style: none; cursor: pointer; }
.header-menu > summary::-webkit-details-marker { display: none; }
.header-menu__trigger { display: inline-flex; align-items: center; justify-content: center; gap: 5px; height: 40px; box-sizing: border-box; padding: 0 12px; border: 1px solid var(--fo-border); border-radius: 10px; background: #fff; color: var(--fo-text-muted); font-size: .78rem; font-weight: 700; transition: background .15s, border-color .15s; }
.header-menu__trigger:hover, .header-menu[open] > .header-menu__trigger { background: var(--fo-bg); border-color: #cbd7e5; color: var(--fo-text); }
.header-menu__panel { position: absolute; z-index: 80; top: calc(100% + 9px); inset-inline-end: 0; min-width: 180px; padding: 6px; border: 1px solid var(--fo-border); border-radius: 13px; background: #fff; box-shadow: 0 16px 38px rgba(15,23,42,.14); }
.header-menu__panel a { display: flex; align-items: center; min-height: 38px; padding: 7px 10px; border-radius: 9px; color: var(--fo-text-muted); font-size: .82rem; font-weight: 600; }
.header-menu__panel a:hover, .header-menu__panel a.is-active { background: var(--fo-blue-light); color: var(--fo-blue-dark); }
.header-menu__panel a.is-danger { margin-top: 5px; padding-top: 9px; border-top: 1px solid var(--fo-border); border-radius: 0 0 9px 9px; color: var(--fo-danger); }
.header-menu__panel a.is-danger:hover { background: #fdecea; color: #a93226; }
.header-menu__panel form { margin: 0; }
.header-menu__panel button.is-danger {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 38px;
  margin-top: 5px;
  padding: 9px 10px 7px;
  border: 0;
  border-top: 1px solid var(--fo-border);
  border-radius: 0 0 9px 9px;
  background: none;
  color: var(--fo-danger);
  font: inherit;
  font-size: .82rem;
  font-weight: 600;
  text-align: start;
  cursor: pointer;
}
.header-menu__panel button.is-danger:hover { background: #fdecea; color: #a93226; }
.header-menu__panel--compact { min-width: 132px; display: grid; gap: 5px; }
.header-menu__panel--compact a { border: 1px solid transparent; }
.header-menu__panel--compact a + a { margin-top: 0; }
.header-menu__panel--compact a.is-active { border-color: rgba(74,144,226,.22); }
.header .locale {
  display: flex; border: 1px solid var(--fo-border); border-radius: var(--radius-control);
  overflow: hidden; font-size: 0.75rem; font-weight: 600;
  flex-shrink: 0;
  align-self: center;
  height: var(--control-height-sm);
  box-sizing: border-box;
  line-height: 1;
}
.header .locale a {
  padding: 0 10px;
  height: 100%;
  min-height: 0;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  color: var(--fo-text);
  text-decoration: none;
  background: #fff;
}
.header .locale a.is-active { background: var(--fo-orange); color: #fff; }
.menu-btn {
  display: none;
  width: var(--control-height-sm);
  height: var(--control-height-sm);
  padding: 0;
  border: 1px solid var(--fo-border);
  border-radius: var(--radius-control);
  background: #fff;
  cursor: pointer;
  color: var(--fo-text);
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  grid-template: 1fr / 1fr;
}
.menu-btn > .fo-icon { grid-area: 1 / 1; }
.menu-btn .fo-icon[hidden] { display: none !important; }
.menu-btn svg { width: 20px; height: 20px; display: block; }
.menu-btn:focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: 2px;
}

/* Mobile nav — side drawer overlay */
.mobile-nav[hidden] { display: none !important; }
.mobile-nav:not([hidden]) {
  display: block;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  max-height: 100dvh;
  z-index: 70;
  overflow: hidden;
  overscroll-behavior: none;
}
.mobile-nav__backdrop {
  position: absolute;
  inset: 0;
  border: none;
  padding: 0;
  margin: 0;
  background: rgba(15, 23, 42, 0.4);
  cursor: pointer;
  opacity: 0;
  touch-action: none;
  transition: opacity 0.2s ease;
}
.mobile-nav.is-open .mobile-nav__backdrop { opacity: 1; }
.mobile-nav__backdrop:focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: -3px;
}
.mobile-nav__panel {
  position: absolute;
  inset-block-start: var(--fo-header);
  inset-block-end: 0;
  inset-inline-end: 0;
  width: min(88vw, 360px);
  background: #fff;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-elevated);
  transform: translate3d(100%, 0, 0);
  transition: transform 0.2s ease;
}
html[dir="rtl"] .mobile-nav__panel {
  transform: translate3d(-100%, 0, 0);
}
.mobile-nav.is-open .mobile-nav__panel,
html[dir="rtl"] .mobile-nav.is-open .mobile-nav__panel {
  transform: translate3d(0, 0, 0);
}
.mobile-nav__body {
  flex: 1;
  overflow-y: auto;
  padding: 8px 16px 16px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.mobile-nav__group {
  display: flex;
  flex-direction: column;
  padding: 8px 0 10px;
  border-bottom: 1px solid var(--fo-border);
}
.mobile-nav__group:last-child { border-bottom: none; }
.mobile-nav__label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--fo-text-muted);
  padding: 8px 4px 4px;
  letter-spacing: 0.04em;
}
.mobile-nav a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--fo-text);
}
.mobile-nav form { margin: 0; }
.mobile-nav__logout {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 0;
  border-radius: 10px;
  background: none;
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  color: #c0392b;
  text-align: start;
  cursor: pointer;
}
.mobile-nav a:hover,
.mobile-nav .mobile-nav__logout:hover { background: var(--bg-muted); }
.mobile-nav__count { margin-inline-start: auto; display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--fo-orange); color: #fff; font-size: .68rem; line-height: 1; direction: ltr; unicode-bidi: isolate; }
.mobile-nav a.is-active {
  background: var(--fo-blue-light);
  color: var(--fo-blue-dark);
}
.mobile-nav a:focus-visible,
.mobile-nav .mobile-nav__logout:focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: 2px;
}
.mobile-nav__foot {
  flex-shrink: 0;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--fo-border);
}
@media (min-width: 721px) {
  .mobile-nav__foot { display: none; }
}
html.nav-open {
  overflow: visible;
  overscroll-behavior: none;
  touch-action: none;
}
html.nav-open .mobile-nav__body {
  touch-action: pan-y;
}
body.nav-locked {
  overflow: hidden;
  overscroll-behavior: none;
}
html.nav-open .header {
  position: sticky;
  top: 0;
  z-index: 80;
}

/* Buttons
 * Canonical: --primary (action/orange), --secondary (outline), --tertiary (text)
 * Aliases kept: --orange = primary, --ghost = secondary, --link = tertiary
 */
.btn {
  --btn-bg: transparent;
  --btn-fg: var(--fo-text);
  --btn-border: transparent;
  --btn-hover-bg: var(--bg-muted);
  --btn-focus: var(--focus-color-action);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: var(--control-height-sm);
  padding: 10px 18px;
  border: 1px solid var(--btn-border);
  border-radius: var(--radius-control);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-weight: var(--weight-semibold);
  font-size: var(--text-base);
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  transition: transform var(--duration-fast), background var(--duration-fast), color var(--duration-fast), border-color var(--duration-fast), box-shadow var(--duration-fast), opacity var(--duration-fast);
}
.btn:hover { background: var(--btn-hover-bg); color: var(--btn-fg); }
.btn:active { transform: scale(0.98); }
.btn:focus-visible {
  outline: 2px solid var(--btn-focus);
  outline-offset: 2px;
}
.btn:disabled,
.btn[aria-disabled="true"],
.btn.is-disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
  transform: none;
}

.btn--primary,
.btn--orange {
  --btn-bg: var(--fo-orange);
  --btn-fg: #fff;
  --btn-border: transparent;
  --btn-hover-bg: var(--fo-orange-dark);
  --btn-focus: var(--focus-color-action);
}
.btn--secondary,
.btn--ghost {
  --btn-bg: var(--fo-surface);
  --btn-fg: var(--fo-text);
  --btn-border: var(--fo-border);
  --btn-hover-bg: var(--bg-muted);
  --btn-focus: var(--focus-color);
}
.btn--tertiary,
.btn--link,
.btn--text {
  --btn-bg: transparent;
  --btn-fg: var(--fo-text-muted);
  --btn-border: transparent;
  --btn-hover-bg: transparent;
  --btn-focus: var(--focus-color);
  min-height: auto;
  padding: 8px 6px;
  font-size: var(--text-sm);
}
.btn--tertiary:hover,
.btn--link:hover,
.btn--text:hover { color: var(--fo-blue-dark); }

.btn--white {
  --btn-bg: #fff;
  --btn-fg: var(--fo-blue-dark);
  --btn-border: transparent;
  --btn-hover-bg: var(--fo-blue-light);
  --btn-focus: var(--focus-color);
}

.btn--sm { min-height: 36px; padding: 8px 14px; font-size: var(--text-sm); }
.btn--lg { min-height: var(--control-height); padding: 14px 26px; font-size: var(--text-md); border-radius: var(--fo-radius); }
.btn--block { width: 100%; }

.btn--icon {
  width: var(--control-height-sm);
  height: var(--control-height-sm);
  min-height: 0;
  padding: 0;
  border-radius: var(--radius-control);
  color: var(--fo-text);
  background: var(--fo-surface);
  border: 1px solid var(--fo-border);
}
.btn--icon:hover { background: var(--bg-muted); color: var(--fo-text); }
.btn--icon.btn--sm { width: 32px; height: 32px; }
.btn--icon.btn--lg { width: 48px; height: 48px; }
.btn--icon.btn--primary,
.btn--icon.btn--orange { color: #fff; border-color: transparent; }

.btn.is-loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}
.btn.is-loading::after {
  content: "";
  position: absolute;
  width: 1em;
  height: 1em;
  border-radius: 50%;
  border: 2px solid var(--btn-fg);
  border-inline-end-color: transparent;
  opacity: 0.85;
  animation: fo-spin 0.7s linear infinite;
}
@keyframes fo-spin {
  to { transform: rotate(360deg); }
}

/* Listing pagination — rounded rectangles, not circles. Used on Explore / Events / Offers / Favorites. */
.pagination {
  width: 100%;
  max-width: 100%;
  margin: 18px 0 10px;
}
.pagination__list {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  max-width: 100%;
}
.pagination__item {
  display: flex;
  flex: 0 0 auto;
  min-width: 0;
}
.pagination__num,
.pagination__nav,
.pagination__ellipsis {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  height: 38px;
  border-radius: 11px;
  font-size: 0.875rem;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition: background var(--duration-fast), color var(--duration-fast), border-color var(--duration-fast);
}
.pagination__num,
.pagination__ellipsis {
  min-width: 38px;
  padding: 0 8px;
  border: 1px solid var(--neutral-200);
  background: var(--fo-surface);
  color: var(--fo-text);
  font-weight: var(--weight-semibold);
}
.pagination__num:hover {
  background: var(--fo-orange-light);
  border-color: rgba(245, 130, 32, 0.28);
  color: var(--fo-text);
}
.pagination__num:focus-visible,
.pagination__nav:focus-visible {
  outline: 2px solid var(--focus-color-action, var(--fo-orange));
  outline-offset: 2px;
}
.pagination__num.is-current {
  background: var(--fo-orange);
  border-color: var(--fo-orange);
  color: #fff;
  pointer-events: none;
}
.pagination__ellipsis {
  color: var(--neutral-400);
  font-weight: 600;
  letter-spacing: 0.06em;
  pointer-events: none;
}
.pagination__nav {
  position: relative;
  gap: 6px;
  padding: 0 12px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--fo-text-muted);
  font-weight: var(--weight-medium, 500);
}
.pagination__nav:hover {
  background: var(--neutral-50);
  border-color: var(--neutral-200);
  color: var(--fo-text);
}
.pagination__nav.is-disabled {
  opacity: 0.4;
  pointer-events: none;
}
.pagination__arrow {
  display: inline-flex;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.pagination__arrow svg {
  width: 16px;
  height: 16px;
  display: block;
}
html[dir="ltr"] .pagination__nav--prev .pagination__arrow,
html[dir="rtl"] .pagination__nav--next .pagination__arrow {
  transform: scaleX(-1);
}
@media (max-width: 720px) {
  .pagination { margin: 14px 0 8px; }
  .pagination__list { gap: 4px; }
  .pagination__num,
  .pagination__nav,
  .pagination__ellipsis {
    min-height: 36px;
    height: 36px;
  }
  .pagination__num,
  .pagination__ellipsis { min-width: 36px; padding: 0 6px; }
  .pagination__nav { padding: 0 8px; gap: 4px; }
  .pagination__num--wide,
  .pagination__num--edge,
  .pagination__item--ellipsis { display: none; }
}
@media (max-width: 480px) {
  .pagination__nav {
    width: 36px;
    min-width: 36px;
    padding: 0;
  }
  .pagination__label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
}

/* Card foundation — shared anatomy; page types (.place, .event, .offer, .cat, .partner-card)
 * keep their current class names. Migrate onto .card in later phases. */
.card {
  display: flex;
  flex-direction: column;
  background: var(--fo-surface);
  border: 1px solid var(--fo-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  color: inherit;
  min-width: 0;
}
.card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--neutral-200);
  overflow: hidden;
}
.card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: var(--space-1);
  padding: var(--space-4);
}
.card__eyebrow {
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--fo-blue);
}
.card__title {
  font-family: var(--fo-font-display);
  font-size: var(--text-base);
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-tight);
  line-height: var(--leading-snug);
  margin: 0;
}
.card__meta {
  font-size: var(--text-sm);
  color: var(--fo-text-muted);
  line-height: var(--leading-snug);
}
.card__foot {
  margin-top: auto;
  padding-top: var(--space-3);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}
.card--overlay {
  position: relative;
  color: #fff;
  isolation: isolate;
  min-height: 170px;
  justify-content: flex-end;
}
.card--overlay .card__media {
  position: absolute;
  inset: 0;
  aspect-ratio: auto;
}
.card--overlay .card__body {
  position: relative;
  z-index: 1;
}
.card--wide .card__media { aspect-ratio: 16 / 10; }

/* UI states */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.94);
  color: var(--fo-text);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  line-height: 1.2;
}
.badge--accent {
  background: var(--fo-orange);
  color: #fff;
}
.badge--nav {
  background: var(--fo-blue-light);
  color: var(--fo-blue-dark);
}
.badge--success {
  background: var(--fo-success-light);
  color: var(--fo-success);
}
.badge--danger {
  background: var(--fo-danger-light);
  color: var(--fo-danger);
}

.alert,
.auth-notice {
  padding: 12px 14px;
  border-radius: var(--fo-radius);
  border: 1px solid var(--fo-border);
  background: var(--fo-surface);
  color: var(--fo-text);
  font-size: var(--text-base);
  line-height: var(--leading-snug);
}
.alert--success,
.auth-notice {
  color: #166534;
  background: var(--fo-success-light);
  border-color: #bbf7d0;
}
.alert--danger {
  color: var(--fo-danger);
  background: var(--fo-danger-light);
  border-color: #f5c6c0;
}
.alert--warning {
  color: var(--fo-warning);
  background: var(--fo-warning-light);
  border-color: #f5d5b0;
}
.alert--info {
  color: var(--fo-blue-dark);
  background: var(--fo-blue-light);
  border-color: #c5d4e8;
}

.web-flash {
  position: fixed;
  top: calc(var(--fo-header) + 12px);
  inset-inline-end: max(16px, var(--container-pad));
  z-index: 120;
  display: grid;
  gap: 8px;
  width: min(400px, calc(100vw - 32px));
}
.web-flash__item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 12px 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--fo-border);
  background: #fff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.14);
  color: var(--fo-text);
  animation: web-flash-in 0.28s ease-out;
}
html[dir="rtl"] .web-flash__item { padding: 12px 14px 12px 12px; }
.web-flash__item.is-leaving {
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  animation: web-flash-out 0.2s ease-in forwards;
}
.web-flash__item--success {
  background: var(--fo-success-light);
  border-color: #bbf7d0;
  color: #166534;
}
.web-flash__item--error {
  background: var(--fo-danger-light);
  border-color: #f5c6c0;
  color: var(--fo-danger);
}
.web-flash__item--warning {
  background: var(--fo-warning-light);
  border-color: #f5d5b0;
  color: var(--fo-warning);
}
.web-flash__item--info {
  background: var(--fo-blue-light);
  border-color: #c5d4e8;
  color: var(--fo-blue-dark);
}
.web-flash__icon {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  margin-top: 1px;
}
.web-flash__icon svg { width: 22px; height: 22px; display: block; }
.web-flash__text {
  flex: 1 1 auto;
  margin: 0;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.45;
}
.web-flash__close {
  flex: 0 0 auto;
  position: relative;
  z-index: 1;
  width: 32px;
  height: 32px;
  margin: -6px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: inherit;
  opacity: 0.7;
  cursor: pointer;
  display: grid;
  place-items: center;
}
.web-flash__close svg { width: 16px; height: 16px; }
.web-flash__close:hover { opacity: 1; background: rgba(15, 23, 42, 0.06); }
@keyframes web-flash-in {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes web-flash-out {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(-8px); }
}
@media (max-width: 720px) {
  .web-flash {
    inset-inline: 12px;
    top: calc(var(--fo-header) + 8px);
    width: auto;
  }
}

.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-7) var(--space-4);
  text-align: center;
  color: var(--fo-text-muted);
  background: var(--bg-muted);
  border: 1px dashed var(--fo-border);
  border-radius: var(--radius-lg);
}
.empty__title {
  color: var(--fo-text);
  font-size: var(--text-base);
  font-weight: var(--weight-bold);
}
.empty .btn { margin-top: var(--space-2); }

.spinner {
  width: 1.25em;
  height: 1.25em;
  border: 2px solid var(--neutral-300);
  border-top-color: var(--fo-blue);
  border-radius: 50%;
  animation: fo-spin 0.7s linear infinite;
}
.loading {
  display: grid;
  place-items: center;
  gap: var(--space-3);
  padding: var(--space-7) var(--space-4);
  color: var(--fo-text-muted);
  font-size: var(--text-sm);
}

@keyframes fo-shimmer {
  to { background-position: -200% 0; }
}
.skeleton {
  display: block;
  background: linear-gradient(90deg, var(--neutral-100) 0%, var(--neutral-200) 50%, var(--neutral-100) 100%);
  background-size: 200% 100%;
  animation: fo-shimmer 1.2s ease-in-out infinite;
  border-radius: var(--radius-sm);
}
.skeleton--text { height: 0.8em; width: 80%; }
.skeleton--title { height: 1.1em; width: 60%; }
.skeleton--media { aspect-ratio: 4 / 3; width: 100%; border-radius: var(--radius-lg); }
.skeleton--card {
  height: 280px;
  width: 100%;
  border-radius: var(--radius-lg);
}
@media (prefers-reduced-motion: reduce) {
  .skeleton { animation: none; background: var(--neutral-100); }
  .spinner, .btn.is-loading::after { animation: none; }
}

/* Hero — centered composition so content doesn’t hug the RTL edge */
.hero {
  position: relative;
  min-height: min(88vh, 720px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  overflow: hidden;
}
.hero__bg {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(10, 18, 36, 0.45) 0%, rgba(10, 18, 36, 0.55) 40%, rgba(10, 18, 36, 0.82) 100%);
}
.hero__inner {
  position: relative;
  z-index: 1;
  width: 100%;
  padding: 56px 0 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.hero__kicker {
  display: inline-block; font-size: .85rem; font-weight: 500; opacity: .95;
  margin-bottom: 14px; padding: 6px 14px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.3); background: rgba(255,255,255,.1);
}
.hero__title {
  font-size: clamp(1.85rem, 4.5vw, 2.85rem); font-weight: 700;
  line-height: 1.35;
  max-width: 18ch;
  margin: 0 auto 14px;
  text-wrap: balance;
}
.hero__lead {
  font-size: clamp(.95rem, 2vw, 1.12rem); opacity: .92;
  max-width: 34ch;
  margin: 0 auto 32px;
  line-height: 1.7;
}
.compass {
  display: grid; grid-template-columns: minmax(0, 0.38fr) minmax(0, 0.38fr) minmax(0, 0.24fr); gap: 8px;
  background: #fff; border-radius: 16px; padding: 10px;
  box-shadow: 0 20px 50px rgba(0,0,0,.28);
  width: min(100%, 880px);
  min-height: 76px;
  margin-inline: auto;
  text-align: start;
  align-items: stretch;
  box-sizing: border-box;
}
.compass--sticky {
  box-shadow: var(--fo-shadow);
  border: 1px solid var(--fo-border);
  width: 100%;
  max-width: none;
}
.compass__field {
  display: flex; flex-direction: column; gap: 2px;
  padding: 8px 12px; border-radius: 10px; background: var(--fo-bg); min-width: 0;
}
.compass__label { font-size: .72rem; font-weight: 600; color: var(--fo-text-muted); }
.compass__field input, .compass__field select {
  border: none; background: transparent; color: var(--fo-text);
  outline: none; font-weight: 500; width: 100%; min-height: 28px;
}
.compass__submit {
  background: var(--fo-orange); color: #fff; border: none; border-radius: 12px;
  padding: 0 22px; font-weight: 700; font-size: 1rem; cursor: pointer;
  min-height: 56px; width: 100%;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.compass__submit svg { width: 18px; height: 18px; flex-shrink: 0; }
.compass__submit:hover { background: var(--fo-orange-dark); }
.hero__chips {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px;
  justify-content: center;
}
.chip {
  display: inline-flex; padding: 6px 14px; border-radius: 999px;
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.28);
  color: #fff; font-size: .82rem; font-weight: 500;
}
.chip:hover { background: rgba(255,255,255,.22); }

/* Keep callouts/notes readable inside centered hero */
.hero .flow-callout {
  width: min(100%, 880px);
  margin-top: 18px;
  text-align: start;
}

/* Page shell (inner pages) */
.page-hero {
  background: transparent;
  padding: 40px 0 32px;
}
.page-hero h1 {
  font-size: clamp(1.45rem, 2.6vw, 1.95rem); font-weight: 700; margin-bottom: 6px;
  letter-spacing: -0.02em;
}
.page-hero p { color: var(--fo-text-muted); font-size: .95rem; max-width: 50ch; }
.breadcrumb {
  display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
  font-size: .82rem; color: var(--fo-text-muted); margin-bottom: 12px;
}
.breadcrumb a { color: var(--fo-blue); font-weight: 500; }
.breadcrumb span.sep { opacity: .5; }

/* Page context header — soft intro band (reusable breadcrumb) */
@keyframes pch-gradient-shift {
  0%, 100% { background-position: 0% 40%; }
  50% { background-position: 100% 60%; }
}
@keyframes pch-float {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(0, -12px, 0); }
}
@keyframes pch-float-alt {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(8px, 10px, 0) scale(1.06); }
}
@keyframes pch-wave-drift {
  0% { transform: translateX(0); }
  100% { transform: translateX(-5%); }
}
@keyframes pch-photo-zoom {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}
@keyframes pch-enter {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pch-mark-pulse {
  0%, 100% { opacity: .75; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.2); }
}
.page-context-header {
  position: relative;
  width: 100%;
  max-width: none;
  margin: 0;
}
.page-context-header__band {
  position: relative;
  min-height: 168px;
  padding: 0;
  overflow: hidden;
  background: linear-gradient(125deg, #fff6ef 0%, #f3f7fc 38%, #e8f0fa 68%, #fff0e3 100%);
  background-size: 220% 220%;
  animation: pch-gradient-shift 14s ease-in-out infinite;
}
.page-context-header--plain .page-context-header__band {
  min-height: 0;
}
.page-context-header--plain:not(.page-context-header--has-image) .page-context-header__band {
  background: var(--bg-page-base);
  background-size: auto;
  animation: none;
}
.page-context-header--plain.page-context-header--has-image .page-context-header__band {
  min-height: 168px;
}
.page-context-header--plain .page-context-header__center {
  text-align: start;
  padding: 16px clamp(16px, 4vw, 32px) 20px;
}
.page-context-header--plain .page-context-header__trail {
  justify-content: flex-start;
  margin-top: 0;
  margin-bottom: 8px;
}
@media (max-width: 720px) {
  .page-context-header--plain .page-context-header__center {
    padding: 14px 16px 16px;
  }
}
.page-context-header__photo {
  position: absolute;
  inset: -4%;
  background-image: var(--pch-bg-image, none);
  background-size: cover;
  background-position: var(--pch-bg-position, center);
  background-repeat: no-repeat;
  opacity: 0.16;
  pointer-events: none;
  transform-origin: center;
  animation: pch-photo-zoom 20s ease-in-out infinite;
}
.page-context-header__decor {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.page-context-header__orb {
  position: absolute;
  border-radius: 50%;
  background: rgba(74, 144, 226, 0.14);
  will-change: transform;
}
.page-context-header__orb--1 {
  width: 96px;
  height: 96px;
  top: 16%;
  inset-inline-start: 6%;
  animation: pch-float 8s ease-in-out infinite;
}
.page-context-header__orb--2 {
  width: 64px;
  height: 64px;
  top: 10%;
  inset-inline-end: 10%;
  background: rgba(245, 130, 32, 0.12);
  animation: pch-float-alt 10s ease-in-out infinite;
  animation-delay: -2s;
}
.page-context-header__orb--3 {
  width: 40px;
  height: 40px;
  bottom: 26%;
  inset-inline-end: 20%;
  background: rgba(74, 144, 226, 0.1);
  animation: pch-float 6.5s ease-in-out infinite reverse;
  animation-delay: -3s;
}
.page-context-header__orb--4 {
  width: 28px;
  height: 28px;
  bottom: 34%;
  inset-inline-start: 18%;
  background: rgba(245, 130, 32, 0.1);
  animation: pch-float-alt 7s ease-in-out infinite;
  animation-delay: -1s;
}
.page-context-header__wave-line {
  position: absolute;
  width: 115%;
  height: 44px;
  bottom: 20%;
  inset-inline-start: -8%;
  color: rgba(15, 23, 42, 0.1);
  animation: pch-wave-drift 16s ease-in-out infinite alternate;
}
.page-context-header__wave-line--2 {
  bottom: 28%;
  inset-inline-start: -12%;
  width: 120%;
  color: rgba(74, 144, 226, 0.08);
  animation-duration: 22s;
  animation-delay: -4s;
}
.page-context-header__back {
  position: absolute;
  top: 14px;
  inset-inline-start: clamp(16px, 4vw, 32px);
  z-index: 2;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--fo-navy, #0F172A);
  cursor: pointer;
  text-decoration: none;
  transition: border-color .2s ease;
  animation: pch-enter .55s cubic-bezier(.22, 1, .36, 1) both;
  animation-delay: .08s;
}
.page-context-header__back svg {
  width: 17px;
  height: 17px;
  transition: transform .2s ease;
}
.page-context-header__back:hover { border-color: rgba(37, 99, 235, 0.35); }
.page-context-header__back:hover svg { transform: translateX(2px); }
html[dir="ltr"] .page-context-header__back svg { transform: scaleX(-1); }
html[dir="ltr"] .page-context-header__back:hover svg { transform: scaleX(-1) translateX(-2px); }
.page-context-header__back:focus-visible {
  outline: 2px solid var(--fo-orange);
  outline-offset: 2px;
}
.page-context-header__center {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 36px clamp(56px, 12vw, 80px) 44px;
  max-width: 1280px;
  margin-inline: auto;
  animation: pch-enter .75s cubic-bezier(.22, 1, .36, 1) both;
  animation-delay: .15s;
}
.page-context-header__context {
  margin: 0;
  font-family: var(--fo-font-display);
  font-size: clamp(1.65rem, 4.2vw, 2.15rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -.03em;
  color: var(--fo-navy, #0F172A);
  text-decoration: none;
  transition: color .15s ease;
}
a.page-context-header__context:hover { color: var(--fo-blue, #2563eb); }
a.page-context-header__context:focus-visible {
  outline: 2px solid var(--fo-orange);
  outline-offset: 4px;
  border-radius: 4px;
}
.page-context-header__trail {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
  font-size: .875rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--fo-text-muted);
}
.page-context-header__trail a {
  color: var(--fo-text-muted);
  text-decoration: none;
  transition: color .15s ease;
}
.page-context-header__trail a:hover { color: var(--fo-blue, #2563eb); }
.page-context-header__trail-sep {
  opacity: .45;
  user-select: none;
  font-size: .75rem;
}
.page-context-header__trail-current {
  font-weight: 600;
  color: var(--fo-navy, #0F172A);
}
.page-context-header__subtitle {
  margin: 10px auto 0;
  max-width: 50ch;
  font-size: .95rem;
  line-height: 1.5;
  color: var(--fo-text-muted);
}
.page-context-header__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: .8125rem;
  font-weight: 600;
  color: var(--fo-navy, #0F172A);
}
.page-context-header__mark {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--fo-orange);
  flex-shrink: 0;
  opacity: .85;
  animation: pch-mark-pulse 2.8s ease-in-out infinite;
}
.page-context-header__mark:last-child { animation-delay: .45s; }
.page-context-header__title {
  font-family: var(--fo-font-display);
  font-size: clamp(1.65rem, 4.2vw, 2.15rem);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.2;
  margin: 0;
  color: var(--fo-navy, #0F172A);
}
.page-context-header__curve {
  display: block;
  width: 100%;
  height: 36px;
  margin-bottom: -1px;
  color: var(--bg-page-base);
}
@media (max-width: 720px) {
  .page-context-header__band { min-height: 132px; }
  .page-context-header__center { padding: 28px 48px 32px; }
  .page-context-header__context,
  .page-context-header__title { font-size: clamp(1.35rem, 5.5vw, 1.65rem); }
  .page-context-header__back { top: 10px; width: 36px; height: 36px; }
  .page-context-header__back svg { width: 15px; height: 15px; }
  .page-context-header__orb--1 { width: 64px; height: 64px; }
  .page-context-header__orb--2 { width: 42px; height: 42px; }
  .page-context-header__wave-line--2 { display: none; }
  .page-context-header__curve { height: 28px; }
}
@media (prefers-reduced-motion: reduce) {
  .page-context-header__band,
  .page-context-header__photo,
  .page-context-header__orb,
  .page-context-header__wave-line,
  .page-context-header__center,
  .page-context-header__back,
  .page-context-header__mark {
    animation: none !important;
  }
}


/* Sections */
.section { padding: var(--section-y) 0; }
.section--tight { padding: var(--section-y-tight) 0; }
.section__head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: var(--space-4); margin-bottom: var(--section-gap); flex-wrap: wrap;
}
.section__eyebrow {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-size: var(--text-sm); font-weight: var(--weight-semibold); color: var(--fo-orange-dark); margin-bottom: 6px;
}
.section__eyebrow::before {
  content: ""; width: 18px; height: 2px; border-radius: 2px;
  background: var(--fo-orange);
}
.section__title { font-size: var(--text-section); font-weight: var(--weight-bold); letter-spacing: var(--tracking-tight); }
.section__sub { color: var(--fo-text-muted); font-size: var(--text-base); margin-top: 6px; max-width: 40ch; }
.section__link { color: var(--fo-blue); font-weight: var(--weight-semibold); font-size: var(--text-base); }
.section__cta-wrap { text-align: center; margin-top: var(--section-gap); }

/* Categories grid */
.cats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.cat {
  position: relative; border-radius: var(--fo-radius-lg); overflow: hidden;
  min-height: 170px; display: flex; align-items: flex-end; color: #fff; isolation: isolate;
  transition: transform .25s, box-shadow .25s;
}
.cat:hover { transform: translateY(-4px); box-shadow: var(--fo-shadow); }
.cat__img {
  position: absolute; inset: 0; background-size: cover; background-position: center; z-index: -2;
  transition: transform .4s;
}
.cat:hover .cat__img { transform: scale(1.05); }
.cat::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, transparent 30%, rgba(15,23,42,.85));
}
.cat__body { padding: 16px; }
.cat__name { font-size: 1.05rem; font-weight: 700; display: block; }
.cat__count { font-size: .8rem; opacity: .85; }

/* Filters */
.filters-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.filter-chip {
  display: inline-flex; align-items: center;
  padding: 9px 18px; border-radius: var(--radius-full);
  border: 1px solid var(--fo-border); background: var(--fo-surface);
  font-size: var(--text-sm); font-weight: var(--weight-medium); color: var(--fo-text-muted);
  cursor: pointer;
  transition: background var(--duration-fast), color var(--duration-fast), border-color var(--duration-fast);
}
.filter-chip:hover { border-color: var(--border-strong); color: var(--fo-text); }
.filter-chip.is-active, a.filter-chip.is-active {
  background: var(--fo-blue); border-color: var(--fo-blue); color: #fff;
}
.filter-chip:focus-visible {
  outline: 2px solid var(--fo-blue); outline-offset: 2px;
}
.filter-chip:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Place card — single system (Home quality). Use .place; .place-card is an alias. */
.places { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.place,
.place-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--fo-surface);
  border-radius: var(--radius-xl);
  overflow: hidden;
  border: 1px solid var(--fo-border);
  color: inherit;
  transition: transform var(--duration) var(--ease), box-shadow var(--duration);
}
.place:hover,
.place-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-elevated);
}
.place.is-hidden,
.place-card.is-hidden { display: none; }
.place__link { display: flex; flex-direction: column; flex: 1; color: inherit; min-width: 0; }
.place__media { position: relative; aspect-ratio: 4/3; background: #dde3ea; overflow: hidden; }
.place__media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.6s var(--ease);
}
.place:hover .place__media img,
.place-card:hover .place__media img { transform: scale(1.06); }
.place__badge {
  position: absolute; top: 12px; inset-inline-start: 12px; z-index: 2;
  background: rgba(255,255,255,.94); font-size: .72rem; font-weight: 600;
  padding: 5px 11px; border-radius: var(--radius-full);
}
.place__heart {
  position: absolute; top: 12px; inset-inline-end: 12px; z-index: 2;
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,255,255,.94); border: none;
  display: grid; place-items: center; cursor: pointer;
  color: var(--fo-text-muted);
  transition: color var(--duration-fast), transform var(--duration-fast);
}
.place__heart:hover { color: var(--fo-orange); transform: scale(1.06); }
.place__heart:focus-visible {
  outline: 2px solid var(--fo-orange); outline-offset: 2px;
}
.place__heart.is-active { color: var(--fo-orange); background: #fff; }
.place__heart .fo-icon { width: 18px; height: 18px; }

@keyframes fav-heart-pop {
  0% { transform: scale(1); }
  45% { transform: scale(1.2); }
  100% { transform: scale(1); }
}
@keyframes fav-target-pulse {
  0%, 100% { transform: scale(1); }
  40% { transform: scale(1.14); }
}
[data-favorite-toggle].is-fav-pop {
  animation: fav-heart-pop 0.32s ease;
}
[data-favorites-target].is-fav-pulse {
  animation: fav-target-pulse 0.36s ease;
}
.fav-flyer {
  position: fixed;
  top: 0;
  left: 0;
  right: auto;
  width: 22px;
  height: 22px;
  margin: 0;
  padding: 0;
  color: var(--fo-orange);
  pointer-events: none;
  z-index: 240;
  will-change: transform, opacity;
}
.fav-flyer .fo-icon,
.fav-flyer svg {
  width: 100%;
  height: 100%;
  display: block;
}
.fav-fly-dot {
  position: fixed;
  top: 0;
  left: 0;
  right: auto;
  border-radius: 50%;
  background: var(--fo-orange);
  pointer-events: none;
  z-index: 239;
  opacity: 0;
  will-change: transform, opacity;
}
@media (prefers-reduced-motion: reduce) {
  [data-favorite-toggle].is-fav-pop,
  [data-favorites-target].is-fav-pulse {
    animation: none;
  }
}
.place__body { padding: 16px; flex: 1; display: flex; flex-direction: column; }
.place__rating { font-size: .82rem; font-weight: 600; color: var(--fo-orange); margin-bottom: 4px; }
.place__name {
  font-family: var(--fo-font-display);
  font-size: .95rem; font-weight: 700; margin-bottom: 4px;
}
.place__meta { font-size: .8rem; color: var(--fo-text-muted); }
.place__price { margin-top: auto; padding-top: 10px; font-size: .85rem; font-weight: 600; }
.place__price-level {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}
.place__price-level .fo-sar-symbol,
.fo-sar-symbol {
  width: 14px;
  height: 14px;
  display: block;
  object-fit: contain;
  opacity: .85;
}
.place__badge--offer {
  background: var(--fo-orange);
  color: #fff;
  max-width: calc(100% - 56px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.place__hotel-star {
  font-size: .78rem;
  font-weight: 600;
  color: var(--fo-text-muted);
  margin-bottom: 4px;
}
.place__rating-count {
  color: var(--fo-text-muted);
  font-weight: 500;
  margin-inline-start: 4px;
}
.search-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 48px 16px;
  color: var(--fo-text-muted);
}
.search-empty p { margin: 0; }
.search-count {
  font-size: .84rem;
  color: var(--fo-text-muted);
}
[data-favorites-recent] {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

/* Rail events */
.rail {
  display: flex; gap: 14px; overflow-x: auto; padding-bottom: 4px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
}
.rail::-webkit-scrollbar {
  display: none; /* Chrome, Safari */
  width: 0;
  height: 0;
}
.event {
  flex: 0 0 250px; scroll-snap-align: start; border-radius: var(--fo-radius-lg);
  overflow: hidden; background: #fff; border: 1px solid var(--fo-border);
}
.event__media { aspect-ratio: 16/10; background-size: cover; background-position: center; }
.event__body { padding: 14px; }
.event__date { font-size: .75rem; font-weight: 600; color: var(--fo-orange); margin-bottom: 4px; }
.event__name { font-weight: 700; font-size: .92rem; }
.event__loc { font-size: .8rem; color: var(--fo-text-muted); margin-top: 4px; }

/* Offers */
.offers { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 14px; }
.offer-wrap {
  position: relative;
  height: 100%;
  min-height: inherit;
}
.offer-wrap .place__heart { z-index: 3; }
.offer-wrap > .offer { height: 100%; min-height: inherit; }
.offer {
  position: relative; border-radius: var(--fo-radius-lg); overflow: hidden;
  min-height: 200px; color: #fff; display: flex; align-items: flex-end; isolation: isolate;
}
.offer__bg { position: absolute; inset: 0; background-size: cover; background-position: center; z-index: -2; }
.offer::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, transparent 20%, rgba(15,23,42,.9));
}
.offer__body { padding: 18px; }
.offer__tag {
  display: inline-block; background: var(--fo-orange); font-size: .75rem;
  font-weight: 700; padding: 3px 10px; border-radius: 6px; margin-bottom: 8px;
}
.offer__name { font-weight: 700; font-size: 1.05rem; display: block; }
.offer__place { font-size: .85rem; opacity: .85; margin-top: 4px; display: block; }

/* Why / partner / app */
.why { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.why__item {
  text-align: center; padding: 28px 20px; border-radius: var(--fo-radius-lg);
  background: #fff; border: 1px solid var(--fo-border);
}
.why__icon {
  width: 52px; height: 52px; margin: 0 auto 14px; border-radius: 14px;
  background: var(--fo-blue-light); color: var(--fo-blue-dark);
  display: grid; place-items: center; font-size: 1.3rem;
}
.why__item h3 { font-size: 1.05rem; margin-bottom: 6px; }
.why__item p { font-size: .88rem; color: var(--fo-text-muted); max-width: 22ch; margin-inline: auto; }

.partner {
  background: linear-gradient(120deg, var(--fo-blue), var(--fo-blue-dark));
  border-radius: var(--fo-radius-lg); padding: 28px 32px;
  display: grid; grid-template-columns: auto 1fr auto; gap: 20px;
  align-items: center; color: #fff;
}
.partner__icon {
  width: 64px; height: 64px; border-radius: 16px; background: #fff;
  display: grid; place-items: center; color: var(--fo-blue); font-size: 1.5rem;
}
.partner__eyebrow { font-size: .82rem; opacity: .85; margin-bottom: 4px; }
.partner__title { font-size: clamp(1.15rem, 2vw, 1.35rem); font-weight: 700; margin-bottom: 4px; }
.partner__text { font-size: .9rem; opacity: .9; max-width: 42ch; }

.app-band {
  background: var(--fo-blue-light); border-radius: var(--fo-radius-lg);
  padding: 36px 32px; display: grid; grid-template-columns: 1fr auto;
  gap: 24px; align-items: center;
}
.app-band__eyebrow { font-size: .82rem; font-weight: 600; color: var(--fo-blue-dark); margin-bottom: 6px; }
.app-band__title { font-size: clamp(1.25rem, 2.2vw, 1.5rem); font-weight: 700; margin-bottom: 8px; }
.app-band__text { color: var(--fo-text-muted); font-size: .95rem; max-width: 36ch; }
.store-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.store {
  display: flex; align-items: center; gap: 10px;
  background: var(--fo-navy); color: #fff; border-radius: 12px;
  padding: 10px 16px; min-width: 148px;
}
.store__label { font-size: .68rem; opacity: .75; display: block; }
.store__name { font-size: .95rem; font-weight: 700; }

/* App Store / Google Play badges with icons */
.store-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.store-badge {
  direction: ltr;
  unicode-bidi: isolate;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 168px;
  height: 52px;
  padding: 0 16px 0 12px;
  border-radius: 10px;
  background: #000;
  border: 1px solid rgba(255,255,255,0.28);
  color: #fff;
  text-decoration: none;
  box-sizing: border-box;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.store-badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0,0,0,0.25);
  color: #fff;
}
.store-badge__icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
}
.store-badge__icon svg {
  width: 26px;
  height: 26px;
  display: block;
}
.store-badge__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  line-height: 1.15;
  text-align: start;
}
.store-badge[dir="ltr"] .store-badge__text {
  text-align: left;
}
.store-badge__small {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.02em;
  opacity: 0.85;
}
.store-badge__big {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.store-badge--sm {
  min-width: 150px;
  height: 46px;
  padding-block: 0;
  padding-inline: 10px 14px;
  gap: 8px;
}
.store-badge--sm .store-badge__icon {
  width: 24px;
  height: 24px;
}
.store-badge--sm .store-badge__icon svg {
  width: 22px;
  height: 22px;
}
.store-badge--sm .store-badge__big { font-size: 14px; }
.store-badge--sm .store-badge__small { font-size: 8px; }

/* Search layout */
.search-layout {
  display: grid; grid-template-columns: 280px 1fr; gap: 24px;
  padding: 28px 0 48px; align-items: start;
}
.filters-panel {
  background: #fff; border: 1px solid var(--fo-border);
  border-radius: var(--fo-radius-lg); padding: 18px; position: sticky; top: 88px;
}
.filters-panel h3 { font-size: .95rem; margin-bottom: 14px; }
.filter-group { margin-bottom: 16px; }
.filter-group h4 { font-size: .8rem; color: var(--fo-text-muted); margin-bottom: 8px; font-weight: 600; }
.filter-group .filters-row { margin-bottom: 0; }
.search-tools {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px; margin-bottom: 16px;
}
.mode-toggle {
  display: flex; border: 1px solid var(--fo-border); border-radius: 10px; overflow: hidden;
}
.mode-toggle a {
  padding: 8px 14px; font-size: .85rem; font-weight: 600; color: var(--fo-text-muted); background: #fff;
}
.mode-toggle a.is-active { background: var(--fo-blue); color: #fff; }
.results-count { font-size: .9rem; color: var(--fo-text-muted); }
.results-count strong { color: var(--fo-text); }
.map-placeholder {
  border: 2px dashed var(--fo-border); border-radius: var(--fo-radius-lg);
  background: #e8eef5; min-height: 420px;
  display: grid; place-items: center; color: var(--fo-text-muted);
  text-align: center; padding: 24px;
}
.map-placeholder strong { display: block; color: var(--fo-text); margin-bottom: 8px; font-size: 1.1rem; }

/* Place detail */
.place-detail { display: grid; grid-template-columns: 1.4fr 1fr; gap: 28px; padding: 32px 0 56px; }
.gallery {
  border-radius: var(--fo-radius-lg); overflow: hidden; aspect-ratio: 16/11;
  background: #dde3ea;
}
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.place-info h1 { font-size: 1.75rem; font-weight: 700; margin-bottom: 8px; }
.place-meta { color: var(--fo-text-muted); font-size: .95rem; margin-bottom: 12px; }
.place-rating { color: var(--fo-orange); font-weight: 700; margin-bottom: 16px; }
.place-desc { color: var(--fo-text-muted); margin-bottom: 20px; font-size: .95rem; }
.place-facts {
  display: grid; gap: 10px; margin-bottom: 24px;
  padding: 16px; background: #fff; border: 1px solid var(--fo-border); border-radius: var(--fo-radius);
}
.place-facts dt { font-size: .75rem; color: var(--fo-text-muted); font-weight: 600; }
.place-facts dd { font-weight: 600; margin-bottom: 6px; }
.place-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.next-steps {
  margin-top: 20px; padding: 14px; background: var(--fo-orange-light);
  border-radius: var(--fo-radius); font-size: .85rem; border: 1px solid #f5d5b0;
}
.next-steps strong { display: block; margin-bottom: 6px; }
.next-steps a { color: var(--fo-blue-dark); font-weight: 600; text-decoration: underline; }

/* Auth forms */
.auth-wrap {
  max-width: 420px; margin: 48px auto; background: #fff;
  border: 1px solid var(--fo-border); border-radius: var(--fo-radius-lg); padding: 32px;
}
.auth-wrap h1 { font-size: 1.4rem; margin-bottom: 8px; text-align: center; }
.auth-wrap .lead { text-align: center; color: var(--fo-text-muted); font-size: .9rem; margin-bottom: 24px; }
.field { margin-bottom: 14px; }
.field label {
  display: block;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  margin-bottom: 6px;
  color: var(--fo-text);
}
.field__hint {
  display: block;
  margin-top: 6px;
  font-size: var(--text-xs);
  color: var(--fo-text-muted);
  line-height: var(--leading-snug);
}
.field__error {
  display: block;
  margin-top: 6px;
  font-size: var(--text-xs);
  color: var(--fo-danger);
  line-height: var(--leading-snug);
}
.input,
.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: var(--control-height);
  border: 1px solid var(--fo-border);
  border-radius: var(--radius-control);
  padding: 12px var(--control-pad-x);
  background: var(--control-bg);
  color: var(--fo-text);
  outline: none;
  transition: border-color var(--duration-fast), background var(--duration-fast), box-shadow var(--duration-fast);
}
.field textarea,
textarea.input { min-height: 140px; padding-block: 12px; resize: vertical; }
.field select,
select.input { cursor: pointer; }
.input:hover,
.field input:hover,
.field select:hover,
.field textarea:hover { border-color: var(--border-strong); }
.input:focus,
.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--fo-blue);
  background: var(--control-bg-focus);
  box-shadow: var(--focus-ring);
}
.input:disabled,
.field input:disabled,
.field select:disabled,
.field textarea:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  background: var(--neutral-100);
}
.field.is-error input,
.field.is-error select,
.field.is-error textarea,
.input.is-error {
  border-color: var(--fo-danger);
  background: var(--fo-surface);
}
.field.is-error input:focus,
.field.is-error select:focus,
.field.is-error textarea:focus,
.input.is-error:focus { box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.18); }
.field.is-success input,
.field.is-success select,
.field.is-success textarea,
.input.is-success {
  border-color: var(--fo-success);
}
.field.is-success input:focus,
.field.is-success select:focus,
.field.is-success textarea:focus { box-shadow: 0 0 0 3px rgba(31, 157, 85, 0.18); }

.search-field {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: var(--control-height);
  padding: 0 var(--control-pad-x);
  border: 1px solid var(--fo-border);
  border-radius: var(--radius-control);
  background: var(--control-bg);
}
.search-field:focus-within {
  border-color: var(--fo-blue);
  background: var(--control-bg-focus);
  box-shadow: var(--focus-ring);
}
.search-field input {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  outline: none;
  min-height: 44px;
  color: var(--fo-text);
}
.auth-links { text-align: center; margin-top: 16px; font-size: .88rem; color: var(--fo-text-muted); }
.auth-links a { color: var(--fo-blue); font-weight: 600; }

.auth-page { padding: clamp(24px, 3vw, 40px) 0 clamp(48px, 6vw, 80px); }
.auth-card {
  display: grid;
  grid-template-columns: 0.88fr 1.12fr;
  max-width: 880px;
  margin-inline: auto;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(232, 236, 240, 0.95);
  box-shadow: 0 20px 48px rgba(15, 23, 42, 0.08);
  background: #fff;
}
.auth-card__panel {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: linear-gradient(165deg, var(--fo-blue) 0%, var(--fo-blue-dark) 55%, #1e4f8a 100%);
  color: #fff;
  padding: clamp(28px, 4vw, 40px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
}
.auth-card__bg-logo {
  position: absolute;
  z-index: 0;
  width: min(70%, 180px);
  inset-inline-end: 6%;
  bottom: 8%;
  opacity: 0.22;
  pointer-events: none;
  mix-blend-mode: screen;
  user-select: none;
}
.auth-card__panel > *:not(.auth-card__bg-logo) { position: relative; z-index: 1; }
.auth-card__panel h2 {
  font-family: var(--fo-font-display);
  font-size: clamp(1.25rem, 2.2vw, 1.55rem);
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: -0.02em;
  margin: 0;
}
.auth-card__panel p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.9);
  max-width: 24ch;
}
.auth-card__form { padding: clamp(24px, 3.5vw, 40px); }
.auth-card__form .field { margin-bottom: 12px; }
.auth-card__form .field label {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--fo-text);
  margin-bottom: 6px;
}
.auth-field {
  position: relative;
  display: flex;
  align-items: center;
}
.auth-field__icon {
  position: absolute;
  inset-inline-start: 12px;
  width: 16px;
  height: 16px;
  color: var(--fo-text-muted);
  pointer-events: none;
  z-index: 1;
}
.auth-field input,
.auth-field select {
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  padding-inline-start: 38px;
  border: 1px solid var(--fo-border);
  border-radius: 8px;
  background: #fcfdff;
  outline: none;
  font-size: 0.875rem;
  line-height: 1.35;
  color: var(--fo-text);
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}
.auth-field input:hover,
.auth-field select:hover { border-color: #c5d4e8; }
.auth-field input:focus,
.auth-field select:focus {
  border-color: var(--fo-blue);
  background: var(--control-bg-focus);
  box-shadow: var(--focus-ring);
}
.auth-field--select::after {
  content: "";
  position: absolute;
  inset-inline-end: 14px;
  width: 7px;
  height: 7px;
  border-inline-end: 2px solid var(--fo-text-muted);
  border-bottom: 2px solid var(--fo-text-muted);
  transform: rotate(45deg);
  margin-top: -2px;
  pointer-events: none;
}
.auth-field--select select {
  appearance: none;
  cursor: pointer;
  padding-inline-end: 32px;
}
.auth-field--pass input { padding-inline-end: 42px; }
.auth-field__toggle {
  position: absolute;
  inset-inline-end: 4px;
  width: 34px;
  height: 34px;
  border: none;
  background: transparent;
  color: var(--fo-text-muted);
  cursor: pointer;
  display: grid;
  place-items: center;
  border-radius: 8px;
}
.auth-field__toggle:hover { color: var(--fo-text); background: rgba(15, 23, 42, 0.04); }
.auth-field__toggle svg { width: 16px; height: 16px; }

/* Phone: keep digit order LTR, align with the locale label (no generic input[type=tel] rule). */
.phone-input {
  direction: ltr;
  unicode-bidi: isolate;
}
html[dir="rtl"] .phone-input {
  text-align: right;
}
html[dir="ltr"] .phone-input {
  text-align: left;
}
/* .phone-input is LTR, so pad the physical icon side (icon uses inset-inline-start on the RTL/LTR parent). */
html[dir="rtl"] .auth-field .phone-input {
  padding: 8px 38px 8px 12px;
}
html[dir="ltr"] .auth-field .phone-input {
  padding: 8px 12px 8px 38px;
}

.auth-card__form .btn--primary,
.auth-card__form .btn--orange {
  margin-top: 6px;
  min-height: 44px;
  padding: 10px 20px;
  font-size: 0.9rem;
  box-shadow: 0 8px 20px rgba(245, 130, 32, 0.25);
}
.auth-card__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin: 0 0 18px;
  font-size: 0.82rem;
}
.auth-card__meta a { color: var(--fo-blue); font-weight: 600; }
.auth-card .auth-links { margin-top: 18px; }
.auth-notice {
  margin: 0 0 16px;
}
.otp-hint {
  font-size: 0.9rem;
  color: var(--fo-text-muted);
  margin: 0 0 18px;
  line-height: 1.65;
}
.otp-hint strong { color: var(--fo-text); font-weight: 700; }
.otp-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  direction: ltr;
  margin-bottom: 20px;
}
.otp-row input {
  width: 42px;
  height: 44px;
  text-align: center;
  font-size: 1.05rem;
  font-weight: 700;
  border: 1px solid var(--fo-border);
  border-radius: 8px;
  background: #fcfdff;
  outline: none;
}
.otp-row input:focus {
  border-color: var(--fo-blue);
  background: var(--control-bg-focus);
  box-shadow: var(--focus-ring);
}
@media (max-width: 800px) {
  .auth-card { grid-template-columns: 1fr; }
  .auth-card__panel { padding: 24px 22px 20px; }
  .auth-card__panel p { max-width: none; }
  .auth-card__bg-logo { width: 120px; bottom: -10%; opacity: 0.16; }
  .otp-row input { width: 38px; height: 40px; font-size: 1rem; }
}

/* CMS */
.cms { max-width: 720px; margin: 0 auto; padding: 40px 0 64px; }
.cms h1 { font-size: 1.75rem; margin-bottom: 16px; }
.cms p { color: var(--fo-text-muted); margin-bottom: 12px; }

body.page-cms { overflow-x: clip; }
main[data-cms-page] { overflow-x: clip; width: 100%; max-width: 100%; }
.cms-page { padding: 0 0 clamp(48px, 7vw, 80px); }
.cms-page .container { padding-top: 28px; max-width: 860px; }
.cms-page--story .container { max-width: 960px; padding-top: 28px; }
.cms-card { margin-bottom: 0; }
.cms-story { display: flow-root; }
.cms-story__visual {
  float: inline-start;
  width: min(300px, 40%);
  position: relative;
  z-index: 1;
  margin: 0 0 12px;
  margin-inline-end: 32px;
  padding: 4px 8px 16px 0;
}
.cms-story__plate {
  position: absolute;
  inset-block-start: 22px;
  inset-block-end: 2px;
  inset-inline-start: -10px;
  inset-inline-end: 16px;
  border-radius: 24px;
  background: linear-gradient(155deg, #2a4a78 0%, var(--fo-navy) 72%);
}
.cms-story__photo {
  position: relative;
  z-index: 1;
  margin: 0;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.16);
}
.cms-story__photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  display: block;
}
.cms-story__photo::after {
  content: "";
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: var(--fo-orange);
  inset-block-start: 14px;
  inset-inline-end: 14px;
  box-shadow: 0 0 0 5px rgba(245, 130, 32, 0.22);
}
.cms-story__glow { display: none; }
.cms-story__copy { overflow: visible; }
.cms-story__copy.cms-form { overflow: hidden; }
.cms-prose {
  font-size: 1.02rem;
  line-height: 1.85;
  color: #4a5568;
}
.cms-prose h2 {
  font-family: var(--fo-font-display);
  font-size: 1.12rem;
  font-weight: 700;
  color: var(--fo-navy);
  letter-spacing: -0.02em;
  margin: 28px 0 10px;
}
.cms-prose h2:first-child { margin-top: 0; }
.cms-prose p { margin: 0 0 12px; color: #4a5568; }
.cms-prose ul, .cms-prose ol {
  margin: 0 0 14px;
  padding-inline-start: 1.25em;
}
.cms-prose li { margin-bottom: 6px; }
.cms-prose a { color: var(--fo-blue); font-weight: 600; }
.cms-form .field-row { margin-bottom: 0; }
.cms-form textarea { min-height: 140px; resize: vertical; }
.cms-form .btn--primary,
.cms-form .btn--orange { min-height: 48px; padding-inline: 24px; }
.cms-story__copy.cms-form h2 {
  font-family: var(--fo-font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--fo-navy);
  letter-spacing: -0.02em;
  margin: 0 0 6px;
}
.cms-story__copy.cms-form > .lead {
  margin: 0 0 18px;
  color: var(--fo-text-muted);
  font-size: 0.92rem;
}
.cms-story__copy.cms-form .auth-notice { margin-bottom: 14px; }
@media (max-width: 720px) {
  .cms-page .container { padding-top: 20px; }
  .cms-story__visual {
    float: none;
    width: 100%;
    margin-inline-end: 0;
    margin-bottom: 20px;
    padding: 0 12px 12px 0;
  }
  .cms-story__photo img { aspect-ratio: 16 / 10; }
  .cms-story__plate {
    inset-block-start: 16px;
    inset-inline-start: 8px;
    inset-inline-end: 8px;
    inset-block-end: -6px;
  }
}

/* Footer */
.footer {
  background: var(--fo-navy);
  color: #cbd5e1;
  padding: 36px 0 0;
  margin-top: auto;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.25fr repeat(2, minmax(0, 0.78fr)) minmax(230px, 1.1fr);
  gap: 20px 18px;
  padding-bottom: 22px;
  align-items: start;
}
.footer .brand,
.footer__brand {
  color: #fff;
  margin-bottom: 8px;
}
.footer .brand__img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  background: transparent;
  border-radius: 0;
  padding: 0;
}
.footer__about {
  font-size: var(--text-sm);
  line-height: 1.58;
  color: #94a3b8;
  max-width: 28ch;
  margin: 0;
}
.footer__contact {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
}
.footer__contact li { margin-bottom: 6px; }
.footer__contact li:last-child { margin-bottom: 0; }
.footer__contact a {
  font-size: var(--text-sm);
  color: #94a3b8;
  transition: color var(--duration-fast);
}
.footer__contact a:hover { color: #fff; }
.footer__social {
  display: flex;
  gap: 6px;
  margin-top: 12px;
}
.footer__social a {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  display: grid;
  place-items: center;
  color: #cbd5e1;
  transition: color var(--duration-fast), border-color var(--duration-fast), background var(--duration-fast);
}
.footer__social a:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.32);
  background: rgba(255, 255, 255, 0.04);
}
.footer__social svg {
  width: 16px;
  height: 16px;
  display: block;
}
.footer h2,
.footer h4,
.footer__col h2,
.footer__col h4 {
  color: #fff;
  font-size: 0.86rem;
  font-weight: var(--weight-bold);
  margin: 0 0 9px;
}
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: 5px; }
.footer li:last-child { margin-bottom: 0; }
.footer li a {
  font-size: var(--text-sm);
  color: #94a3b8;
  transition: color var(--duration-fast);
}
.footer li a:hover { color: #fff; }
.footer__app-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-width: 230px;
  overflow: visible;
}
.footer__app-col h2,
.footer__app-col h4 {
  margin-bottom: 0;
  font-size: 0.86rem;
  max-width: 22ch;
}
.footer__app-lead {
  font-size: 0.78rem;
  font-weight: var(--weight-semibold);
  line-height: 1.5;
  color: #cbd5e1;
  margin: 0;
  max-width: none;
  white-space: nowrap;
}
.footer__app-desc {
  font-size: var(--text-sm);
  color: #94a3b8;
  line-height: 1.6;
  max-width: 28ch;
  margin: 0;
}
.footer .store-badges--footer {
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  margin-top: 2px;
}
.footer .store-badge {
  background: #0b0b0b;
  border-color: rgba(255, 255, 255, 0.2);
}
.footer .store-badge--footer-compact {
  min-width: 128px;
  height: 36px;
  padding: 0 10px 0 8px;
  gap: 7px;
  border-radius: var(--radius-sm);
  box-shadow: none;
}
.footer .store-badge--footer-compact:hover {
  transform: none;
  box-shadow: var(--shadow-sm);
}
.footer .store-badge--footer-compact .store-badge__icon {
  width: 18px;
  height: 18px;
}
.footer .store-badge--footer-compact .store-badge__icon svg {
  width: 16px;
  height: 16px;
}
.footer .store-badge--footer-compact .store-badge__big { font-size: 12px; }
.footer .store-badge--footer-compact .store-badge__small { font-size: 7px; }
.footer__bar {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 12px 0 14px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: var(--space-2);
  font-size: 0.78rem;
  color: #94a3b8;
  text-align: center;
}
.footer__bar a { color: #94a3b8; }
.footer__bar a:hover { color: #fff; }

@media (max-width: 900px) {
  .footer__grid {
    grid-template-columns: 1fr 1fr;
    gap: 18px 16px;
  }
  .footer__brand-col,
  .footer__app-col { grid-column: 1 / -1; }
  .footer__app-col { padding-top: 4px; }
}
@media (max-width: 720px) {
  .footer { padding-top: 28px; }
  .footer__grid {
    grid-template-columns: 1fr;
    gap: 16px;
    padding-bottom: 18px;
  }
  .footer__brand-col,
  .footer__app-col { grid-column: auto; }
  .footer__about { max-width: none; }
  .footer .store-badges--footer {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .footer__app-lead { white-space: normal; }
}

/* Sitemap page */
.sitemap-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px;
  padding: 28px 0 48px;
}
.sitemap-card {
  background: #fff; border: 1px solid var(--fo-border); border-radius: var(--fo-radius);
  padding: 16px; transition: box-shadow .15s, border-color .15s;
}
.sitemap-card:hover { border-color: var(--fo-blue); box-shadow: var(--fo-shadow); }
.sitemap-card h3 { font-size: .95rem; margin-bottom: 4px; }
.sitemap-card code {
  font-size: .72rem; direction: ltr; unicode-bidi: embed;
  color: var(--fo-blue-dark); background: var(--fo-blue-light);
  padding: 1px 6px; border-radius: 4px; display: inline-block; margin-bottom: 8px;
}
.sitemap-card p { font-size: .8rem; color: var(--fo-text-muted); }
.sitemap-card .flow {
  margin-top: 10px; font-size: .75rem; color: var(--fo-orange-dark); font-weight: 600;
}

/* Flow callout */
.flow-callout {
  background: #fff; border: 1px solid var(--fo-border); border-inline-start: 4px solid var(--fo-orange);
  border-radius: 10px; padding: 12px 16px; margin: 16px 0; font-size: .88rem;
}
.flow-callout strong { color: var(--fo-orange-dark); }

@media (max-width: 1000px) {
  .cats, .places { grid-template-columns: 1fr 1fr; }
  .offers { grid-template-columns: 1fr; }
  .search-layout { grid-template-columns: 1fr; }
  .filters-panel { position: static; }
  .place-detail { grid-template-columns: 1fr; }
}
/* Logged-in header */
.auth-slot {
  display: flex;
  align-items: center;
  gap: 8px;
}
.header-icon {
  position: relative;
  width: var(--control-height-sm);
  height: var(--control-height-sm);
  border-radius: var(--radius-control);
  border: 1px solid var(--fo-border);
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  color: var(--fo-orange);
  background: #fff;
  transition: background .15s, border-color .15s;
}
.header-favorite__count { position: absolute; top: -5px; inset-inline-start: -5px; display: grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px; border: 2px solid #fff; border-radius: 999px; background: var(--fo-orange); color: #fff; font-size: .62rem; font-weight: 700; line-height: 1; direction: ltr; unicode-bidi: isolate; }
.header-favorite__count[hidden] { display: none; }
.notification-bell { cursor: pointer; }
.notification-menu__panel { width: min(360px, calc(100vw - 28px)); padding: 0; overflow: hidden; }
.notification-menu__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--fo-border); }
.notification-menu__head strong { color: var(--fo-text); font-size: .9rem; }
.notification-menu__head form { margin: 0; }
.notification-menu__head button { border: 0; background: none; color: var(--fo-blue-dark); font: inherit; font-size: .76rem; font-weight: 700; cursor: pointer; }
.notification-menu__list { display: grid; max-height: 360px; overflow: auto; }
.header-menu__panel .notification-menu__item { display: flex; align-items: flex-start; gap: 10px; min-height: 0; padding: 10px 12px; border-radius: 0; border-bottom: 1px solid var(--fo-border); color: inherit; }
.notification-menu__item.is-unread { background: var(--fo-orange-light); }
.notification-menu__item:hover { background: var(--fo-blue-light); }
.notification-menu__image { width: 42px; height: 42px; flex-shrink: 0; border-radius: 10px; overflow: hidden; background: var(--fo-bg); }
.notification-menu__image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.notification-menu__image.is-default { padding: 5px; background: #fff; border: 1px solid var(--fo-border); }
.notification-menu__image.is-default img { object-fit: contain; }
.notification-menu__body { min-width: 0; display: grid; gap: 2px; }
.notification-menu__title { color: var(--fo-text); font-size: .82rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notification-menu__text { color: var(--fo-text-muted); font-size: .74rem; line-height: 1.5; }
.notification-menu__time { color: var(--fo-text-muted); font-size: .68rem; }
.notification-menu__empty { padding: 18px 14px; color: var(--fo-text-muted); font-size: .82rem; text-align: center; }
.header-menu__panel .notification-menu__all { justify-content: center; min-height: 42px; border-radius: 0; color: var(--fo-blue-dark); font-weight: 800; }
.header-icon:hover {
  background: var(--fo-orange-light);
  border-color: #f5d5b0;
}
.header-icon:focus-visible {
  background: var(--fo-orange-light);
  border-color: #f5d5b0;
}
.header-search {
  display: flex;
  align-items: center;
  flex: 0 0 280px;
  width: 280px;
  max-width: 280px;
  min-width: 240px;
  height: var(--control-height-sm);
  padding: 0;
  border: none;
  background: transparent;
  box-sizing: border-box;
  outline: none;
  box-shadow: none;
}
.header-search__toggle { display: none; }
.header-search__field {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
  height: var(--control-height-sm);
  padding-inline-start: 10px;
  padding-inline-end: 4px;
  border: 1px solid var(--fo-border);
  border-radius: var(--radius-control);
  background: #fff;
  box-sizing: border-box;
  outline: none;
  box-shadow: none;
  transition: border-color .15s, box-shadow .15s;
}
.header-search:focus,
.header-search:focus-visible {
  outline: none;
  box-shadow: none;
}
.header-search__field:focus-within {
  outline: none;
  background: #fff;
  border-color: var(--fo-border);
  box-shadow: none;
}
.header-search__input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: none;
  background: transparent;
  color: var(--fo-text);
  font: inherit;
  font-size: 0.84rem;
  font-weight: 500;
  outline: none;
  box-shadow: none;
  appearance: none;
  -webkit-appearance: none;
}
.header-search__input:focus,
.header-search__input:focus-visible {
  outline: none;
  box-shadow: none;
}
.header-search__input::placeholder {
  color: var(--fo-text-muted);
  font-weight: 400;
}
.header-search__btn {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--fo-orange);
  display: grid;
  place-items: center;
  cursor: pointer;
}
.header-search__btn:hover,
.header-search__btn:focus,
.header-search__btn:focus-visible {
  outline: none;
  box-shadow: none;
  background: #f4f6f8;
}
.header-search .fo-icon { width: 18px; height: 18px; }
.user-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  height: var(--control-height-sm);
  max-height: var(--control-height-sm);
  overflow: hidden;
  box-sizing: border-box;
  padding-block: 3px;
  padding-inline-start: 3px;
  padding-inline-end: 8px;
  margin: 0;
  border: 1px solid var(--fo-border);
  border-radius: var(--radius-control);
  background: #fff;
  max-width: 210px;
  transition: border-color .15s, background .15s;
}
.user-chip__chevron { margin-inline-start: 2px; color: var(--fo-text-muted); font-size: .72rem; transition: transform .18s ease; }
.user-menu[open] .user-chip__chevron { transform: rotate(180deg); }
.user-menu__panel { min-width: 190px; }
.user-chip:hover {
  border-color: var(--fo-blue);
  box-shadow: 0 2px 10px rgba(74, 144, 226, 0.15);
}
.user-chip__avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #e8eef5;
  overflow: hidden;
  display: block;
  flex-shrink: 0;
}
.user-chip__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.user-chip__meta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  line-height: 1.15;
  min-width: 0;
}
.user-chip__name {
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-chip__sub {
  font-size: 0.68rem;
  color: var(--fo-text-muted);
  font-weight: 500;
}
.mobile-nav__account {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--fo-border);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mobile-nav__hello {
  font-size: 0.88rem;
  color: var(--fo-text-muted);
  padding: 8px 4px 4px;
}
.mobile-nav__account a[data-logout] {
  color: #c0392b;
}

/* Account area */
.account-page { padding: 0 0 clamp(48px, 6vw, 80px); }
.account-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 28px;
  padding: 28px 0 0;
  align-items: start;
}
.account-nav {
  background: #fff;
  border: 1px solid var(--fo-border);
  border-radius: 20px;
  padding: 18px 14px;
  position: sticky;
  top: calc(var(--fo-header) + 16px);
  box-shadow: var(--shadow-sm);
}
.account-nav__user {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 8px 16px;
  margin-bottom: 10px;
  border-bottom: 1px solid var(--fo-border);
}
.account-nav__avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #e8eef5;
  overflow: hidden;
  display: block;
  flex-shrink: 0;
}
.account-nav__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.account-nav__name {
  font-weight: 700;
  font-size: 0.95rem;
}
.account-nav__phone {
  font-size: 0.78rem;
  color: var(--fo-text-muted);
  direction: ltr;
  unicode-bidi: embed;
}
.account-nav__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.account-nav__list a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--fo-text-muted);
  transition: background .15s, color .15s;
}
.account-nav__list a:hover {
  background: var(--fo-bg);
  color: var(--fo-text);
}
.account-nav__list a.is-active {
  background: var(--fo-blue-light);
  color: var(--fo-blue-dark);
}
.account-nav__list a.is-danger {
  color: #c0392b;
}
.account-nav__list a.is-danger:hover {
  background: #fdecea;
  color: #a93226;
}
.account-nav__icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--fo-bg);
  color: inherit;
  flex-shrink: 0;
  opacity: 1;
  text-align: center;
}
.account-nav__icon svg {
  width: 18px;
  height: 18px;
  display: block;
}
.account-nav__list a.is-active .account-nav__icon {
  background: #fff;
  color: var(--fo-blue);
}
.account-nav__list a.is-danger .account-nav__icon {
  background: #fdecea;
}
.account-panel {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.account-panel__head {
  margin-bottom: 20px;
}
.account-panel__head h1 {
  font-size: clamp(1.35rem, 2.2vw, 1.7rem);
  font-weight: 700;
  margin-bottom: 4px;
}
.account-panel__head p {
  color: var(--fo-text-muted);
  font-size: 0.92rem;
}
.account-welcome {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px;
  border-radius: 20px;
  background: linear-gradient(165deg, var(--fo-blue) 0%, var(--fo-blue-dark) 55%, #1e4f8a 100%);
  color: #fff;
  box-shadow: 0 16px 36px rgba(53, 122, 189, 0.22);
}
.account-welcome__bg-logo {
  position: absolute;
  z-index: 0;
  width: min(42%, 140px);
  inset-inline-end: 4%;
  bottom: -18%;
  opacity: 0.18;
  pointer-events: none;
  mix-blend-mode: screen;
  user-select: none;
}
.account-welcome > *:not(.account-welcome__bg-logo) { position: relative; z-index: 1; }
.account-welcome__who {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.account-welcome__avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.18);
  border: 2px solid rgba(255, 255, 255, 0.35);
  flex-shrink: 0;
  display: block;
}
.account-welcome__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.account-welcome__hello {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.82);
}
.account-welcome h2 {
  margin: 2px 0 4px;
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}
.account-welcome__meta {
  margin: 0;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.82);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.account-welcome__meta [data-user-phone] {
  direction: ltr;
  unicode-bidi: embed;
}
.account-welcome .btn--primary,
.account-welcome .btn--orange {
  flex-shrink: 0;
  box-shadow: 0 8px 18px rgba(245, 130, 32, 0.35);
}
.account-photo {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  padding: 14px 16px;
  border: 1px dashed var(--fo-border);
  border-radius: 16px;
  background: var(--fo-bg);
}
.account-photo__preview {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  overflow: hidden;
  background: #e8eef5;
  border: 3px solid #fff;
  box-shadow: 0 0 0 1px var(--fo-border);
  flex-shrink: 0;
  display: block;
}
.account-photo__preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.account-photo__meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  min-width: 0;
}
.account-photo__meta strong {
  font-size: 0.95rem;
}
.account-photo__meta span {
  font-size: 0.8rem;
  color: var(--fo-text-muted);
}
.account-photo__btn { margin-top: 8px; cursor: pointer; }
.account-card {
  background: #fff;
  border: 1px solid var(--fo-border);
  border-radius: 20px;
  padding: 22px 24px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
}
.account-card h2 {
  font-size: 1.05rem;
  margin-bottom: 4px;
}
.account-card h2 + .field-row { margin-top: 14px; }
.account-card > .lead,
.account-card__head .lead {
  color: var(--fo-text-muted);
  font-size: 0.88rem;
}
.account-card > .lead { margin-bottom: 18px; }
.account-card__head .lead { margin-bottom: 0; }
.account-panel > .account-card:last-child { margin-bottom: 0; }
.account-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.account-card__head h2 { margin: 0 0 4px; }
.account-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.account-tile {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 16px 16px 16px 14px;
  background: #fff;
  border: 1px solid var(--fo-border);
  border-radius: 16px;
  min-height: 0;
  box-shadow: var(--shadow-sm);
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.account-tile:hover {
  border-color: #c5d4e8;
  box-shadow: var(--shadow-card);
  transform: translateY(-2px);
}
.account-tile__icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--fo-blue-light);
  color: var(--fo-blue-dark);
  flex-shrink: 0;
}
.account-tile__icon svg { width: 20px; height: 20px; display: block; }
.account-tile__icon--orange {
  background: var(--fo-orange-light);
  color: var(--fo-orange-dark);
}
.account-tile__body { min-width: 0; }
.account-tile h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0 0 2px;
}
.account-tile p {
  font-size: 0.8rem;
  color: var(--fo-text-muted);
  line-height: 1.5;
  margin: 0;
}
.account-tile__chevron {
  width: 22px;
  height: 22px;
  color: #c5d4e8;
  display: grid;
  place-items: center;
}
.account-tile__chevron svg { width: 16px; height: 16px; display: block; }
.account-tile:hover .account-tile__chevron { color: var(--fo-blue); }
.account-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.account-stat {
  background: #fff;
  border: 1px solid var(--fo-border);
  border-radius: 16px;
  padding: 16px 18px;
  text-align: start;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  color: inherit;
  min-width: min(100%, 240px);
  transition: border-color .15s, box-shadow .15s;
}
a.account-stat:hover {
  border-color: rgba(74, 144, 226, 0.35);
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.08);
}
.account-stat__icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--fo-blue-light);
  color: var(--fo-blue);
  flex-shrink: 0;
}
.account-stat__icon svg { width: 20px; height: 20px; display: block; }
.account-stat__icon--orange {
  background: var(--fo-orange-light);
  color: var(--fo-orange);
}
.account-stat strong {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--fo-navy);
  margin-bottom: 0;
  line-height: 1.2;
}
.account-stat span {
  font-size: 0.8rem;
  color: var(--fo-text-muted);
}
.account-empty {
  grid-column: 1 / -1;
  border: 1px dashed var(--fo-border);
  border-radius: 16px;
  padding: 28px 20px;
  text-align: center;
  color: var(--fo-text-muted);
  background: var(--fo-bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.account-empty strong { color: var(--fo-text); font-size: 0.98rem; }
.account-empty .btn { margin-top: 8px; }
.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.field--full { grid-column: 1 / -1; }
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
  padding-top: 8px;
}
.place__heart.is-active {
  color: var(--fo-orange);
  background: #fff;
}
.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--fo-navy);
  color: #fff;
  padding: 12px 20px;
  border-radius: var(--radius-full);
  font-size: var(--text-base);
  font-weight: var(--weight-semibold);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-fast), transform var(--duration);
  z-index: 100;
  box-shadow: var(--shadow-elevated);
}
.toast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--fo-border);
}
.switch-row:last-of-type { border-bottom: none; }
.switch-row strong {
  display: block;
  font-size: 0.92rem;
  margin-bottom: 2px;
}
.switch-row span {
  font-size: 0.8rem;
  color: var(--fo-text-muted);
}
.switch {
  position: relative;
  width: 44px;
  height: 26px;
  flex-shrink: 0;
}
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}
.switch__track {
  position: absolute;
  inset: 0;
  background: var(--neutral-300);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: background var(--duration-fast);
}
.switch__track::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  top: 3px;
  inset-inline-start: 3px;
  transition: transform var(--duration-fast);
  box-shadow: var(--shadow-xs);
}
.switch input:checked + .switch__track {
  background: var(--fo-blue);
}
.switch input:checked + .switch__track::after {
  transform: translateX(18px);
}
html[dir="rtl"] .switch input:checked + .switch__track::after {
  transform: translateX(-18px);
}
.switch input:focus-visible + .switch__track {
  outline: 2px solid var(--fo-blue);
  outline-offset: 2px;
}

@media (max-width: 900px) {
  .account-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .account-nav {
    position: static;
    padding: 14px;
  }
  .account-nav__list {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px;
  }
  .account-nav__list a {
    padding: 6px 10px;
    font-size: 0.82rem;
  }
  .account-nav__list a .account-nav__label-long {
    display: none;
  }
  .account-nav__icon {
    width: 30px;
    height: 30px;
    border-radius: 8px;
  }
  .account-welcome {
    flex-direction: column;
    align-items: flex-start;
    padding: 20px;
  }
  .account-welcome .btn--primary,
  .account-welcome .btn--orange { width: 100%; text-align: center; }
  .account-stat { min-width: 0; width: 100%; }
  .account-grid {
    grid-template-columns: 1fr;
  }
  .account-card__head {
    flex-direction: column;
  }
  .field-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .account-welcome__avatar { width: 52px; height: 52px; font-size: 1.2rem; }
}

@media (max-width: 720px) {
  .header__actions .btn--ghost,
  .header__actions .btn--secondary,
  .header__actions .btn--primary,
  .header__actions .btn--link { display: none; }
  .user-chip__meta { display: none; }
  .user-chip__chevron { display: none; }
  .user-chip { padding: 4px; width: 40px; max-width: 40px; border-radius: 10px; }
  .compass { grid-template-columns: 1fr; }
  .compass__submit { width: 100%; min-height: 48px; }
  .cats, .places, .why { grid-template-columns: 1fr; }
  .partner, .app-band { grid-template-columns: 1fr; text-align: center; justify-items: center; }
  .partner__text, .app-band__text { max-width: none; }
  .store-btns { justify-content: center; }
  .store-badges { justify-content: center; }
  .hero__title { max-width: 14ch; }
  .hero__inner { padding: 40px 0 36px; }
  .hero { min-height: min(90vh, 640px); align-items: flex-end; }
}

@media (max-width: 1200px) {
  .header .nav { display: none; }
  .header .menu-btn { display: grid; place-items: center; }
  .header-search {
    flex: 0 1 220px;
    width: 220px;
    min-width: 180px;
    max-width: 220px;
  }
}
@media (max-width: 900px) {
  .header__inner { gap: 12px; }
  .header__start, .header__end { min-width: 0; }
  html { overflow-x: clip; }
  .header-search {
    position: static;
    flex: 0 0 40px;
    width: 40px;
    min-width: 40px;
    max-width: 40px;
    height: 40px;
  }
  .header-search__toggle {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--fo-border);
    border-radius: 10px;
    background: #fff;
    color: var(--fo-orange);
    cursor: pointer;
    outline: none;
    box-shadow: none;
  }
  .header-search__toggle:hover,
  .header-search__toggle:focus-visible,
  .header-search.is-open .header-search__toggle {
    outline: none;
    border-color: var(--fo-border);
    background: #f4f6f8;
    box-shadow: none;
  }
  .header-search__field {
    display: none;
  }
  .header-search.is-open .header-search__field {
    display: flex;
    position: absolute;
    top: calc(100% + 8px);
    inset-inline: var(--container-pad);
    z-index: 55;
    width: auto;
    height: 44px;
    margin: 0;
    padding-inline-start: 10px;
    padding-inline-end: 4px;
    border: 1px solid var(--fo-border);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  }
  .header.is-search-open::after {
    content: "";
    position: absolute;
    top: 100%;
    inset-inline: 0;
    height: 60px;
    background: #fff;
    border-bottom: 1px solid var(--fo-border);
    z-index: 54;
    pointer-events: none;
  }
  .header-search.is-open .header-search__field:focus-within {
    border-color: var(--fo-border);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  }
  .header-search.is-open .header-search__input {
    font-size: 16px;
    height: 40px;
  }
}
@media (max-width: 400px) {
  .header .brand { font-size: 0; gap: 0; }
}

/* Shared icon glyph */
.fo-icon {
  display: inline-grid;
  place-items: center;
  width: 1.15em;
  height: 1.15em;
  flex-shrink: 0;
}
.fo-icon[hidden] { display: none !important; }
.fo-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

/* Partner cards (extracted from Home / partners pages) */
.partner-card {
  background: var(--fo-surface);
  border: 1px solid var(--fo-border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  color: inherit;
  transition: transform var(--duration) var(--ease), box-shadow var(--duration);
}
.partner-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-elevated);
}
.partner-card__cover {
  aspect-ratio: 16/10;
  background-size: cover;
  background-position: center;
}
.partner-card__body {
  padding: 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.partner-card__cat {
  font-size: .72rem;
  font-weight: 600;
  color: var(--fo-blue);
  margin-bottom: 4px;
}
.partner-card__name {
  font-family: var(--fo-font-display);
  font-size: 1.02rem;
  font-weight: 700;
  margin-bottom: 4px;
}
.partner-card__meta {
  font-size: .8rem;
  color: var(--fo-text-muted);
  margin-bottom: 8px;
}
.partner-card__desc {
  font-size: .84rem;
  color: var(--fo-text-muted);
  line-height: 1.5;
  flex: 1;
}
.partner-card__foot {
  margin-top: 12px;
  font-size: .82rem;
  font-weight: 600;
  color: var(--fo-blue-dark);
}

body.page-place { scroll-padding-top: var(--fo-header); }

@media (prefers-reduced-motion: reduce) {
  .place,
  .place-card,
  .place__media img,
  .partner-card {
    transition: none;
  }
  .place:hover .place__media img,
  .place-card:hover .place__media img { transform: none; }
  .place:hover,
  .place-card:hover,
  .partner-card:hover { transform: none; }
  .mobile-nav__backdrop,
  .mobile-nav__panel { transition: none; }
}

:focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: 2px;
}

.header-icon .fo-icon { width: 18px; height: 18px; }

/* Button canonical names: .btn--primary / .btn--secondary / .btn--tertiary
 * Legacy aliases .btn--orange / .btn--ghost / .btn--link remain for compatibility.
 * Place detail live UI: .pd-cine / .pd2 (legacy .pd-gallery / .pd-head removed)
 * Breakpoints: prefer 480 / 720 / 900 / 1200 / 1440; existing queries left intact
 */

/* —— Place / event detail (extracted from place.html + event.html; visual freeze) —— */
/* Place detail v3 — premium travel / discovery */
body.page-place { overflow-x: clip; }
main[data-place-detail] { overflow-x: clip; width: 100%; max-width: 100%; }
.pd2 { padding: 0 0 80px; max-width: 1280px; margin: 0 auto; width: 100%; overflow-x: clip; }

/* ── Cinematic Hero + Media Slider ── */
.pd-cine { position: relative; margin-bottom: 0; }
.pd-media {
  position: relative;
  background: transparent;
  padding: 12px 16px 0;
}
.pd-media__viewport {
  position: relative;
  min-height: min(52vh, 520px);
  max-height: min(68vh, 620px);
  height: clamp(280px, 52vh, 620px);
  overflow: hidden;
  border-radius: 10px;
  background: #1e293b;
}
.pd-media--solo .pd-media__viewport { cursor: pointer; }
.pd-media__hit {
  display: block; width: 100%; height: 100%; border: none; padding: 0; margin: 0;
  background: #1e293b; cursor: pointer; position: relative; overflow: hidden;
}
.pd-media__fill {
  position: absolute; inset: -24px;
  width: calc(100% + 48px); height: calc(100% + 48px);
  object-fit: cover; object-position: center;
  filter: blur(28px) saturate(1.05);
  transform: scale(1.06);
  pointer-events: none;
  user-select: none;
}
.pd-media__main {
  position: relative; z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
}
.pd-media__main--video { object-fit: contain; background: #000; }
.pd-media__nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
  width: 44px; height: 44px; border-radius: 50%; border: none;
  background: rgba(255,255,255,.94); backdrop-filter: blur(8px);
  color: var(--fo-text); cursor: pointer;
  display: grid; place-items: center;
  box-shadow: 0 4px 20px rgba(15,23,42,.15);
  transition: transform .15s, background .15s;
}
.pd-media__nav:hover { transform: translateY(-50%) scale(1.06); background: #fff; }
.pd-media__nav svg { width: 20px; height: 20px; }
.pd-media__nav--prev { inset-inline-start: 14px; }
.pd-media__nav--next { inset-inline-end: 14px; }
html[dir="ltr"] .pd-media__nav svg { transform: scaleX(-1); }
.pd-media__bar {
  position: absolute; bottom: 14px; inset-inline: 14px; z-index: 3;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  pointer-events: none;
}
.pd-media__bar > * { pointer-events: auto; }
.pd-media__counter {
  background: rgba(15,23,42,.72); backdrop-filter: blur(8px);
  color: #fff; font-size: .82rem; font-weight: 700;
  padding: 7px 14px; border-radius: 999px; letter-spacing: .02em;
  direction: ltr;
  unicode-bidi: isolate;
}
.pd-media__all {
  background: rgba(255,255,255,.94); backdrop-filter: blur(8px);
  border: none; border-radius: 999px; padding: 8px 16px;
  font-size: .8rem; font-weight: 600; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; font-family: inherit;
}
.pd-media__empty {
  min-height: min(52vh, 520px); display: grid; place-items: center;
  color: #94a3b8; font-weight: 600; background: #1e293b;
  border-radius: 10px;
}

/* Thumbnails — overlaid on the main photo */
.pd-media--multi .pd-media__viewport::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 120px;
  background: linear-gradient(180deg, transparent, rgba(8, 16, 36, 0.48));
  pointer-events: none;
  z-index: 2;
}
.pd-media--multi .pd-media__thumbs-wrap {
  display: block;
  position: absolute;
  z-index: 4;
  inset-inline: 28px;
  bottom: 52px;
  padding: 0;
  background: transparent;
  pointer-events: none;
}
.pd-media__thumbs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 8px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  direction: ltr;
  pointer-events: auto;
}
.pd-media__thumbs::-webkit-scrollbar { display: none; }
.pd-media__thumb {
  flex: 0 0 56px;
  width: 56px;
  height: 42px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, 0.88);
  padding: 0;
  cursor: pointer;
  background-color: #1e293b;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
  scroll-snap-align: start;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.28);
  transition: border-color .15s, opacity .15s, box-shadow .15s;
}
.pd-media__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pd-media__thumb.is-active {
  border-color: #fff;
  opacity: 1;
  box-shadow: 0 0 0 2px var(--fo-orange), 0 4px 14px rgba(15, 23, 42, 0.28);
}
.pd-media__thumb:not(.is-active) { opacity: .78; }
.pd-media__thumb:not(.is-active):hover { opacity: 1; }
.pd-media__thumb--video::after {
  content: "▶";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: .7rem;
  color: #fff;
  background: rgba(15, 23, 42, 0.45);
}
@media (min-width: 721px) {
  .pd-media { padding: 16px 24px 0; }
  .pd-media--multi .pd-media__thumbs-wrap {
    inset-inline: 40px;
    bottom: 16px;
  }
  .pd-media--multi .pd-media__bar { bottom: 86px; }
  .pd-media__thumb {
    flex: 0 0 80px;
    width: 80px;
    height: 60px;
    border-radius: 10px;
  }
}

.pd-cine__float {
  position: absolute;
  top: clamp(16px, 2.5vw, 24px);
  inset-inline-end: clamp(16px, 2.5vw, 24px);
  z-index: 5;
  display: flex; gap: 8px;
  pointer-events: none;
}
.pd-cine__float > * { pointer-events: auto; }
.pd-cine__float--sheet { position: relative; top: auto; inset: auto; justify-content: flex-end; padding: 12px 16px 0; pointer-events: auto; }
.pd-cine__fab {
  width: 44px; height: 44px; border-radius: 50%; border: none;
  background: rgba(255,255,255,.94); backdrop-filter: blur(8px);
  display: grid; place-items: center; cursor: pointer;
  color: var(--fo-text-muted); box-shadow: 0 4px 20px rgba(15,23,42,.12);
  transition: color .15s, transform .15s;
}
.pd-cine__fab:hover { color: var(--fo-orange); transform: scale(1.05); }
.pd-cine__fab.is-active { color: var(--fo-orange); }
.pd-cine__fab .fo-icon { width: 20px; height: 20px; }

.pd-cine__sheet {
  position: relative; z-index: 5;
  background: #fff; border-radius: 16px;
  padding: 24px 28px 20px;
  border: 1px solid rgba(232,236,240,.65);
  box-shadow: 0 6px 28px rgba(15,23,42,.06);
  margin: -44px 16px 0;
}
/* Solo / mobile: overlap main viewport only */
@media (min-width: 721px) {
  .pd-cine:has(.pd-media--multi) .pd-cine__sheet {
    margin: 20px 24px 0;
  }
  .pd-cine:has(.pd-media--solo) .pd-cine__sheet {
    margin: -64px 24px 0;
  }
}
.pd-cine__eyebrow {
  font-size: .78rem; font-weight: 500; color: #8b95a5;
  margin-bottom: 6px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
}
.pd-cine__eyebrow span.dot { opacity: .35; }
.pd-cine__stars { color: #1a7f4b; font-weight: 600; }
.pd-cine__title {
  font-family: var(--fo-font-display);
  font-size: clamp(1.75rem, 3.5vw, 2.65rem);
  font-weight: 700; letter-spacing: -.03em; line-height: 1.2;
  margin: 0 0 16px;
}
.pd-cine__meta {
  display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center;
  font-size: .84rem; font-weight: 500; color: var(--fo-text-muted); margin-bottom: 18px;
}
.pd-cine__meta-sep { opacity: .35; user-select: none; }
.pd-cine__rating { color: var(--fo-text-muted); font-weight: 600; display: inline-flex; align-items: center; gap: 4px; }
.pd-cine__rating strong { color: var(--fo-orange); font-weight: 700; }
.pd-cine__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.pd-cine__actions .btn--primary-lg {
  min-height: 48px; padding-inline: 24px; font-size: .95rem; font-weight: 700;
  border-radius: 14px;
}
.pd-cine__actions .btn--secondary,
.pd-cine__actions .btn--ghost {
  min-height: 48px; padding-inline: 20px; font-size: .92rem; font-weight: 700;
  border-radius: 14px;
}
.pd-cine__actions .fo-icon { width: 18px; height: 18px; }
.pd-cine__actions-secondary { display: flex; gap: 4px; margin-inline-start: auto; }
.pd-cine__actions-secondary .btn--text {
  background: transparent; border: none; color: var(--fo-text-muted);
  font-weight: 600; font-size: .88rem; padding: 10px 14px; cursor: pointer;
  border-radius: 10px; display: inline-flex; align-items: center; gap: 6px;
  font-family: inherit; text-decoration: none;
}
.pd-cine__actions-secondary .btn--text:hover { background: #f4f6f9; color: var(--fo-text); }

/* Price level — matches admin v2 fo-price-level-display */
.pd-price-level {
  display: inline-flex; align-items: center; gap: 2px;
  min-height: 28px; padding: 4px 10px;
  border: 1px solid var(--fo-orange-dark, #E06D10);
  border-radius: 8px; background: var(--fo-orange, #F58220);
  vertical-align: middle;
}
.pd-price-level .fo-sar-symbol {
  width: 14px; height: 14px; display: block; object-fit: contain;
  filter: brightness(0) invert(1);
}
.pd-price-level--plain {
  min-height: 0; padding: 0; border: none; background: transparent;
}
.pd-price-level--plain .fo-sar-symbol {
  width: 15px; height: 15px; filter: none; opacity: .9;
}

/* Sticky sub-nav — same inset + radius as .pd-cine__sheet */
.pd-subnav-wrap {
  position: sticky; top: calc(var(--fo-header) + 8px); z-index: 30;
  background: #fff;
  border: 1px solid rgba(232,236,240,.65);
  border-radius: 16px;
  box-shadow: 0 6px 28px rgba(15,23,42,.06);
  margin: 16px 24px 0;
  overflow: hidden;
}
.pd-subnav {
  display: flex; gap: 0; overflow-x: auto; scrollbar-width: none;
  padding: 0 8px;
}
.pd-subnav::-webkit-scrollbar { display: none; }
.pd-subnav [role="tab"] {
  flex-shrink: 0; padding: 14px 18px; font-size: .88rem; font-weight: 600;
  color: var(--fo-text-muted); text-decoration: none;
  border: none; border-bottom: 2px solid transparent; margin-bottom: -1px;
  background: none; font-family: inherit; cursor: pointer;
  appearance: none; -webkit-appearance: none;
  transition: color .15s, border-color .15s;
  display: inline-flex; align-items: center; gap: 6px;
}
.pd-subnav [role="tab"]:hover { color: var(--fo-text); }
.pd-subnav [role="tab"].is-active { color: var(--fo-orange); border-bottom-color: var(--fo-orange); }
.pd-subnav [role="tab"]:focus-visible {
  outline: 2px solid var(--fo-orange); outline-offset: -4px;
}
.pd-subnav__offer-icon {
  width: 15px; height: 15px; flex-shrink: 0;
  color: currentColor;
}
.pd-subnav__offer-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--fo-orange); flex-shrink: 0;
  opacity: .85;
}

/* Body grid */
.pd-body {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 400px);
  gap: 48px; padding: 40px 24px 0; align-items: start;
}
.pd-body--solo { grid-template-columns: 1fr; max-width: 780px; }
.pd-main { min-width: 0; min-height: 240px; }

/* Editorial sections */
.pd-sec { margin-bottom: 8px; }
.pd-sec[hidden] { display: none !important; }
.pd-sec__label {
  font-size: .72rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--fo-orange); margin-bottom: 8px;
}
.pd-sec__title {
  font-family: var(--fo-font-display);
  font-size: clamp(1.25rem, 2vw, 1.55rem); font-weight: 700;
  letter-spacing: -.02em; margin-bottom: 16px;
}
.pd-about {
  font-size: 1.02rem; line-height: 1.85; color: #4a5568;
  max-width: 58ch;
}
.pd-about p { margin: 0 0 .55em; }
.pd-about p:last-child { margin-bottom: 0; }
.pd-about ul, .pd-about ol { margin: 0 0 .55em; padding-inline-start: 1.25em; }
.pd-about li { margin-bottom: .25em; }
.pd-about h2, .pd-about h3, .pd-about h4 { font-size: 1.05em; margin: .5em 0 .3em; color: inherit; font-weight: 650; }
.pd-about strong, .pd-about b { font-weight: 700; color: inherit; }
.pd-about em, .pd-about i { font-style: italic; }
.pd-about span { color: inherit; }
.pd-about.is-clamped {
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical;
  overflow: hidden;
}
.pd-about-toggle {
  margin-top: 12px; background: none; border: none; padding: 0;
  color: var(--fo-orange); font-weight: 600; font-size: .88rem;
  cursor: pointer; font-family: inherit;
}

/* Quick info strip */
.pd-quick {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px 22px; padding: 18px 0;
  border-top: 1px solid rgba(232,236,240,.7);
  border-bottom: 1px solid rgba(232,236,240,.7);
  margin-bottom: 28px;
}
.pd-quick__item { display: flex; gap: 10px; align-items: flex-start; min-width: 0; }
.pd-quick__icon {
  flex-shrink: 0; color: var(--fo-orange);
  display: grid; place-items: center; margin-top: 1px;
}
.pd-quick__icon .fo-icon { width: 18px; height: 18px; }
.pd-quick__label { font-size: .7rem; font-weight: 500; color: #8b95a5; margin-bottom: 2px; }
.pd-quick__val { font-size: .84rem; font-weight: 600; color: var(--fo-text); line-height: 1.45; }

/* Features — travel discovery list */
.pd-feats {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 14px 20px;
}
.pd-feats.is-collapsed .pd-feat:nth-child(n+9) { display: none; }
.pd-feat { display: flex; align-items: center; gap: 10px; font-size: .86rem; font-weight: 500; color: var(--fo-text); }
.pd-feat__ico {
  width: 32px; height: 32px; border-radius: 8px;
  background: #f4f7fb; color: #64748b;
  display: grid; place-items: center; flex-shrink: 0;
}
.pd-feat__ico .fo-icon { width: 18px; height: 18px; }
.pd-feat__ico-img { width: 18px; height: 18px; object-fit: contain; display: block; }

/* Contact icons */
.pd-contact { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.pd-contact__btn {
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid var(--fo-border); background: #fff;
  display: grid; place-items: center; color: var(--fo-text-muted);
  text-decoration: none; transition: border-color .15s, color .15s, transform .15s;
}
.pd-contact__btn:hover { border-color: var(--fo-blue); color: var(--fo-blue); transform: translateY(-2px); }
.pd-contact__btn--booking { width: auto; padding: 0 16px; border-radius: 999px; font-size: .78rem; font-weight: 700; gap: 6px; display: inline-flex; align-items: center; }
.pd-contact__btn svg { width: 18px; height: 18px; }

/* Map — sidebar card */
.pd-map-card {
  background: #fff; border-radius: 20px; overflow: hidden;
  border: 1px solid rgba(232,236,240,.9);
  box-shadow: 0 16px 48px rgba(15,23,42,.08);
}
.pd-map-hero {
  position: relative; overflow: hidden;
  min-height: 360px; background: #dce6f0;
}
.pd-map-hero--live { min-height: 420px; }
.pd-map-hero__iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0; display: block;
}
.pd-map-hero__canvas {
  position: absolute; inset: 0;
  background:
    linear-gradient(#e8eef5 1px, transparent 1px),
    linear-gradient(90deg, #e8eef5 1px, transparent 1px),
    linear-gradient(135deg, #c8d8e8 0%, #e2eaf2 50%, #d4e0ec 100%);
  background-size: 32px 32px, 32px 32px, auto;
}
.pd-map-hero__pin {
  position: absolute; top: 42%; inset-inline-start: 44%;
  width: 36px; height: 36px; border-radius: 50% 50% 50% 0;
  background: var(--fo-orange); transform: rotate(-45deg);
  box-shadow: 0 8px 24px rgba(245,130,32,.4);
}
.pd-map-hero__pin::after {
  content: ""; position: absolute; inset: 9px; border-radius: 50%; background: #fff;
}
.pd-map-hero__foot {
  position: absolute; inset-inline: 0; bottom: 0; z-index: 1;
  padding: 16px; display: flex; flex-wrap: wrap;
  align-items: flex-end; gap: 12px;
  flex-direction: column; justify-content: flex-end;
  background: linear-gradient(0deg, rgba(15,23,42,.78) 0%, rgba(15,23,42,.35) 55%, transparent 100%);
  pointer-events: none;
}
.pd-map-hero--live .pd-map-hero__foot {
  min-height: 0;
}
.pd-map-hero__addr { color: #fff; font-weight: 600; font-size: .9rem; margin: 0; max-width: none; }
.pd-map-hero__addr small { display: block; font-weight: 400; opacity: .75; font-size: .78rem; margin-top: 4px; }
.pd-map-hero__foot .btn { width: 100%; justify-content: center; pointer-events: auto; }

/* Reviews premium */
.pd-rev-layout {
  display: grid; grid-template-columns: auto 1fr; gap: 40px;
  align-items: start; margin-bottom: 32px;
}
.pd-rev-score { font-size: 3.5rem; font-weight: 700; color: var(--fo-orange); line-height: 1; }
.pd-rev-score-label { font-size: .85rem; color: var(--fo-text-muted); margin-top: 6px; }
.pd-dist { display: flex; flex-direction: column; gap: 7px; max-width: 360px; }
.pd-dist__row {
  display: grid; grid-template-columns: 12px 1fr 32px; gap: 8px;
  align-items: center; font-size: .75rem; color: var(--fo-text-muted);
}
.pd-dist__bar { height: 5px; background: #eef1f5; border-radius: 99px; overflow: hidden; }
.pd-dist__bar span { display: block; height: 100%; background: var(--fo-orange); border-radius: 99px; }
.pd-rev-list { display: flex; flex-direction: column; gap: 24px; }
.pd-rev-item {
  display: grid; grid-template-columns: 48px 1fr; gap: 14px;
  padding-bottom: 24px; border-bottom: 1px solid #f0f2f5;
}
.pd-rev-item:last-child { border-bottom: none; padding-bottom: 0; }
.pd-rev-item__av {
  width: 48px; height: 48px; border-radius: 50%; background: #e8eef5;
  display: grid; place-items: center; overflow: hidden; flex-shrink: 0;
}
.pd-rev-item__av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pd-rev-item__head { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.pd-rev-item__name { font-weight: 700; font-size: .92rem; }
.pd-rev-item__stars { color: var(--fo-orange); font-size: .82rem; font-weight: 600; display: inline-flex; align-items: center; gap: 3px; }
.pd-rev-item__text { color: #5a6577; font-size: .9rem; line-height: 1.7; margin: 0; }
.pd-rev-reply {
  margin-top: 12px;
  padding: 12px 14px;
  border-inline-start: 3px solid var(--fo-orange);
  border-radius: 10px;
  background: #fff8f2;
  color: #4b5565;
}
.pd-rev-reply__head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 7px;
}
.pd-rev-reply__head img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  background: #e8eef5;
}
.pd-rev-reply__head strong {
  color: #9a5a21;
  font-size: .82rem;
  font-weight: 700;
}
.pd-rev-reply p { margin: 0; font-size: .88rem; line-height: 1.65; }

.pd-rev-compose {
  background: #fff;
  border: 1px solid rgba(232,236,240,.9);
  border-radius: 16px;
  box-shadow: 0 6px 28px rgba(15,23,42,.05);
  padding: 20px 22px;
  margin: 0 0 28px;
}
.pd-rev-compose__title {
  font-size: 1rem; font-weight: 700; margin: 0 0 6px;
}
.pd-rev-compose__sub {
  font-size: .82rem; color: var(--fo-text-muted); margin: 0 0 14px;
}
.pd-rev-stars {
  display: flex; gap: 2px; direction: ltr; justify-content: flex-end;
  margin-bottom: 14px;
}
.pd-rev-star {
  width: 40px; height: 40px; padding: 0; border: none; background: none;
  color: #d5dce3; cursor: pointer; display: grid; place-items: center;
  border-radius: 10px; font-family: inherit;
  transition: color .12s, transform .12s, background .12s;
}
.pd-rev-star:hover { background: #fff8f2; transform: scale(1.06); }
.pd-rev-star.is-on { color: var(--fo-orange); }
.pd-rev-star:focus-visible { outline: 2px solid var(--fo-orange); outline-offset: 2px; }
.pd-rev-star .fo-icon { width: 24px; height: 24px; }
.pd-rev-compose textarea {
  width: 100%; min-height: 96px; box-sizing: border-box;
  border: 1px solid var(--fo-border); border-radius: 12px;
  padding: 12px 14px; font-family: inherit; font-size: .9rem; line-height: 1.65;
  background: #fafbfc; resize: vertical; color: var(--fo-text);
}
.pd-rev-compose textarea:focus {
  outline: none; border-color: var(--fo-orange); background: #fff;
}
.pd-rev-compose__foot { margin-top: 12px; }
.pd-rev-compose .btn--primary,
.pd-rev-compose .btn--orange { min-height: 44px; border-radius: 12px; font-weight: 700; }
.pd-rev-compose.is-done {
  text-align: center; padding: 28px 22px;
}
.pd-rev-compose.is-done strong {
  display: block; font-size: 1.02rem; color: var(--fo-text); margin-bottom: 6px;
}
.pd-rev-compose.is-done span { font-size: .88rem; color: var(--fo-text-muted); }
.pd-rev-compose__count {
  font-size: .82rem; color: var(--fo-text-muted); margin: 6px 0 0; text-align: end;
}

/* Booking rail */
.pd-rail { position: sticky; top: calc(var(--fo-header) + 68px); }
.pd-booking {
  background: #fff; border-radius: 20px;
  border: 1px solid rgba(232,236,240,.9);
  box-shadow: 0 16px 48px rgba(15,23,42,.08);
  padding: 24px; margin-bottom: 24px;
}
.pd-booking__title { font-size: 1.05rem; font-weight: 700; margin-bottom: 16px; }
.pd-booking__fields { display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }
.pd-field label { display: block; font-size: .72rem; font-weight: 600; color: var(--fo-text-muted); margin-bottom: 4px; }
.pd-field input {
  width: 100%; min-height: 44px; border: 1px solid var(--fo-border);
  border-radius: 12px; padding: 10px 12px; font-family: inherit; font-size: .88rem;
  background: #fafbfc;
}
.pd-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pd-booking .btn--primary,
.pd-booking .btn--orange { min-height: 48px; border-radius: 14px; font-weight: 700; min-width: 180px; }
.pd-booking--panel { margin-bottom: 28px; }
.pd-booking--panel .pd-booking__fields {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.2fr) minmax(88px, .7fr) auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 0;
}
.pd-booking--panel .pd-booking__fields .btn--primary {
  min-width: 0;
  white-space: nowrap;
}
.pd-booking__direct {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  margin-top: 12px;
  font-size: .84rem; font-weight: 600; color: var(--fo-blue);
  text-decoration: none;
}
.pd-booking__direct .fo-icon { width: 16px; height: 16px; }
.pd-booking__direct:hover { color: var(--fo-blue-dark); }

/* Pricing results */
.pd-booking-results { margin-top: 24px; }
.pd-booking--panel .pd-booking__direct { justify-content: flex-start; }
.pd-featured-room {
  display: grid; grid-template-columns: 1fr 120px; gap: 16px;
  padding: 20px 0; border-bottom: 1px solid var(--fo-border);
  margin-bottom: 20px;
}
.pd-featured-room__name { font-size: 1rem; font-weight: 700; margin-bottom: 4px; }
.pd-featured-room__source {
  font-size: .78rem; color: var(--fo-text-muted); margin: 0 0 6px;
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.pd-featured-room__amenities {
  display: flex; flex-wrap: wrap; gap: 6px;
  list-style: none; margin: 0 0 10px; padding: 0;
}
.pd-featured-room__amenities li {
  font-size: .72rem; background: #f4f6f8; color: #475569;
  padding: 4px 8px; border-radius: 999px;
}
.pd-featured-room__details { font-size: .82rem; color: var(--fo-text-muted); margin-bottom: 8px; }
.pd-featured-room__price { font-size: 1.2rem; font-weight: 700; color: var(--fo-orange); }
.pd-featured-room__img { border-radius: 12px; overflow: hidden; aspect-ratio: 1; background: #dde3ea; }
.pd-featured-room__img img { width: 100%; height: 100%; object-fit: cover; }

.pd-providers { display: flex; flex-direction: column; gap: 16px; }
.pd-provider-v2 {
  border: 1px solid var(--fo-border); border-radius: 16px; overflow: hidden;
}
.pd-provider-v2__head {
  padding: 12px 16px; font-weight: 700; font-size: .88rem;
  background: #fafbfc; border-bottom: 1px solid var(--fo-border);
  display: flex; align-items: center; gap: 8px;
}
.pd-provider-v2__logo {
  width: 24px; height: 24px; border-radius: 6px; background: #003580;
  color: #fff; font-size: .6rem; font-weight: 800;
  display: grid; place-items: center;
}
.pd-room-row {
  display: grid; grid-template-columns: 56px 1fr auto; gap: 12px;
  align-items: center; padding: 12px 16px;
  border-bottom: 1px solid #f0f2f5;
}
.pd-room-row:last-child { border-bottom: none; }
.pd-room-row__thumb { width: 56px; height: 42px; border-radius: 8px; overflow: hidden; background: #dde3ea; }
.pd-room-row__thumb img { width: 100%; height: 100%; object-fit: cover; }
.pd-room-row__name { font-weight: 600; font-size: .84rem; }
.pd-room-row__det { font-size: .74rem; color: var(--fo-text-muted); }
.pd-provider-v2__official {
  margin-inline-start: auto;
  font-size: .72rem; font-weight: 600; color: var(--fo-text-muted);
}
.pd-room-row__cancel { font-size: .72rem; color: #0a7a3e; margin: 4px 0 0; }
.pd-room-row__price { font-weight: 700; color: var(--fo-orange); font-size: .88rem; white-space: nowrap; }
.pd-room-row__book {
  grid-column: 1 / -1; text-align: left; padding-top: 4px;
}
.pd-room-row__book a {
  font-size: .78rem; font-weight: 700; color: var(--fo-orange);
  text-decoration: none;
}
.pd-room-row__book a:hover { text-decoration: underline; }

.pd-state {
  text-align: center; padding: 32px 16px; color: var(--fo-text-muted); font-size: .88rem;
}
.pd-state strong { display: block; color: var(--fo-text); margin-bottom: 4px; }
.pd-state.is-loading strong::after {
  content: ""; display: inline-block; width: 12px; height: 12px; margin-inline-end: 6px;
  border: 2px solid var(--fo-border); border-top-color: var(--fo-orange);
  border-radius: 50%; animation: pd-spin .7s linear infinite; vertical-align: -1px;
}
@keyframes pd-spin { to { transform: rotate(360deg); } }

.pd-empty {
  padding: 48px 24px;
  text-align: center;
  color: var(--fo-text-muted);
  border: 1px dashed var(--fo-border);
  border-radius: var(--radius-lg);
  background: var(--fo-surface);
}
.pd-empty strong { display: block; color: var(--fo-text); margin-bottom: 6px; font-size: 1rem; }

/* Similar */
.pd-similar { padding: 0 24px; margin-top: 16px; border-top: 1px solid var(--fo-border); padding-top: 48px; }
.pd-similar .places.places--similar { grid-template-columns: repeat(3, 1fr); gap: 18px; }
.pd-similar .place--compact .place__body { padding: 14px 15px; }
.pd-similar .place--compact .place__name { font-size: .93rem; }
.pd-similar .place--compact .place__meta { font-size: .78rem; }
.pd-similar .place--compact .place__rating { font-size: .8rem; margin-bottom: 3px; }
.pd-similar .place--compact .place__price { font-size: .82rem; padding-top: 8px; }
.place__price-level .fo-sar-symbol {
  width: 14px; height: 14px; display: block; object-fit: contain;
  opacity: .85;
}

/* Mobile dock */
.pd-dock { display: none; }

/* Lightbox — full viewport, centered media (RTL-safe) */
.pd-lightbox {
  border: none; padding: 0; margin: 0;
  width: 100%; height: 100%;
  max-width: 100%; max-height: 100%;
  background: transparent; color: var(--fo-text); overflow: hidden;
}
.pd-lightbox::backdrop {
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px) saturate(1.05);
  -webkit-backdrop-filter: blur(8px) saturate(1.05);
}
.pd-lightbox[open] {
  position: fixed; inset: 0;
  display: flex; flex-direction: column;
  width: 100%; height: 100%;
  max-width: 100%; max-height: 100%;
}
.pd-lightbox__inner {
  display: flex; flex-direction: column;
  width: 100%; height: 100%; min-height: 100dvh;
  direction: ltr;
}
.pd-lightbox__bar {
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px clamp(16px, 3vw, 24px); gap: 12px;
  direction: rtl;
}
.pd-lightbox__bar span[data-lightbox-label] {
  flex: 1; text-align: center; font-size: .88rem; font-weight: 600;
}
.pd-lightbox__close {
  flex-shrink: 0;
  width: 44px; height: 44px; border-radius: 50%; border: none;
  background: rgba(15, 23, 42, 0.55); color: #fff; cursor: pointer;
  font-size: 1.25rem; font-weight: 600; line-height: 1;
  display: grid; place-items: center;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}
.pd-lightbox__body {
  flex: 1; min-height: 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(8px, 2vw, 20px);
  padding: 0 clamp(8px, 2vw, 20px) clamp(16px, 3vw, 28px);
  box-sizing: border-box;
}
.pd-lightbox__stage {
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 100%;
  min-width: 0; min-height: 0;
  max-height: calc(100dvh - 68px);
}
.pd-lightbox:focus,
.pd-lightbox:focus-visible {
  outline: none;
}
.pd-lightbox__stage img,
.pd-lightbox__stage video {
  display: block; margin: 0;
  max-width: min(960px, 100%);
  max-height: calc(100dvh - 80px);
  width: auto; height: auto;
  object-fit: contain;
  background: transparent;
  border-radius: 16px;
  outline: none;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -webkit-user-drag: none;
  -webkit-tap-highlight-color: transparent;
}
.pd-lightbox__stage img::selection,
.pd-lightbox__stage img::-moz-selection {
  background: transparent;
}
.pd-lightbox__nav {
  flex-shrink: 0; align-self: center;
  width: clamp(40px, 5vw, 52px); height: clamp(40px, 5vw, 52px);
  border-radius: 50%; border: none;
  background: rgba(15, 23, 42, 0.55); color: #fff; cursor: pointer;
  display: grid; place-items: center;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}
.pd-lightbox__nav:focus,
.pd-lightbox__nav:focus-visible,
.pd-lightbox__close:focus,
.pd-lightbox__close:focus-visible {
  outline: none;
  box-shadow: none;
}
.pd-lightbox__nav svg { width: 22px; height: 22px; transform: scaleX(-1); }
.pd-lightbox__nav[hidden] { display: none; }
.pd-lightbox [hidden] { display: none !important; }
body:has(.pd-lightbox[open]) .pd-media__nav,
body:has(.pd-lightbox[open]) .pd-media__bar,
body:has(.pd-lightbox[open]) .pd-media__thumbs-wrap,
body:has(.pd-lightbox[open]) .pd-cine__float {
  visibility: hidden;
}

@media (max-width: 960px) {
  .pd-body { grid-template-columns: 1fr; gap: 0; }
  .pd-rail { position: static; margin-bottom: 32px; margin-top: 28px; }
  .pd-booking--panel .pd-booking__fields { grid-template-columns: 1fr; }
  .pd-rev-layout { grid-template-columns: 1fr; gap: 20px; }
  .pd-rev-compose { padding: 16px; }
  .pd-rev-compose .btn--primary,
  .pd-rev-compose .btn--orange { width: 100%; }
}
@media (max-width: 720px) {
  .pd-cine { overflow-x: clip; }
  .pd-media { padding: 12px 16px 0; }
  .pd-media__nav { width: 38px; height: 38px; }
  .pd-media__viewport { height: 56vw; min-height: 220px; max-height: 380px; }
  .pd-cine__sheet {
    margin: -44px 16px 0;
    padding: 18px 18px 16px;
    border-radius: 14px;
    width: auto;
    max-width: none;
    box-sizing: border-box;
  }
  .pd-cine__float {
    top: max(clamp(16px, 4vw, 22px), env(safe-area-inset-top, 0px));
    inset-inline-end: max(clamp(16px, 4vw, 22px), env(safe-area-inset-left, 0px));
  }
  .pd-cine__actions-secondary { display: none; }
  .pd-subnav-wrap { margin-inline: 16px; border-radius: 14px; }
  .pd-subnav { padding-inline: 4px; }
  .pd-body, .pd-similar { padding-inline: 16px; }
  .pd-feats { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 4px; }
  .pd-feat { flex: 0 0 auto; scroll-snap-align: start; min-width: 130px; }
  .pd-feats.is-collapsed .pd-feat:nth-child(n+5) { display: none; }
  .pd-similar .places.places--similar { grid-template-columns: 1fr; }
}
@media (min-width: 721px) and (max-width: 1000px) {
  .pd-similar .places.places--similar { grid-template-columns: 1fr 1fr; }
}


/* Event-only: title/rail offsets differ from place; PCH decor hidden; ed-cards */
body.page-event { overflow-x: clip; }
.page-event .page-context-header__decor,
.page-event .page-context-header__curve {
  display: none;
}
main[data-event-detail] { overflow-x: clip; width: 100%; max-width: 100%; }
.page-event .pd-cine__title { margin: 0 0 18px; }
.page-event .pd-rail { top: calc(var(--fo-header) + 16px); }

.pd-cine__status {
  display: inline-block;
  background: var(--fo-orange); color: #fff;
  font-size: .72rem; font-weight: 600;
  padding: 4px 10px; border-radius: 999px;
}
.ed-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.ed-card {
  display: flex; flex-direction: column; background: #fff;
  border: 1px solid rgba(232,236,240,.75); border-radius: 18px;
  overflow: hidden; color: inherit;
}
.ed-card:hover { border-color: rgba(74,144,226,.28); }
.ed-card__media { position: relative; aspect-ratio: 4 / 3; background: #e8edf2; overflow: hidden; }
.ed-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ed-card__date {
  position: absolute; top: 10px; inset-inline-start: 10px;
  min-width: 42px; padding: 6px 7px 5px; border-radius: 10px;
  background: #fff; text-align: center; line-height: 1.05;
}
.ed-card__date strong { display: block; font-size: 1rem; font-weight: 700; color: var(--fo-navy); }
.ed-card__date span { font-size: .62rem; font-weight: 600; color: var(--fo-text-muted); }
.ed-card__body { padding: 14px 15px 15px; }
.ed-card__name { font-family: var(--fo-font-display); font-size: .95rem; font-weight: 700; line-height: 1.35; margin: 0 0 6px; }
.ed-card__loc { font-size: .8rem; color: var(--fo-text-muted); margin: 0; }
@media (max-width: 720px) {
  .ed-cards { grid-template-columns: 1fr; }
}
@media (min-width: 721px) and (max-width: 900px) {
  .ed-cards { grid-template-columns: 1fr 1fr; }
}

/* Detail gallery grid + full gallery viewer (shared by Place and Event). */
.pd-media--grid .pd-media__viewport {
  height: clamp(320px, 26vw, 440px);
  min-height: 0;
  max-height: none;
}
.pd-gallery-grid {
  width: 100%; height: 100%; display: grid; gap: 6px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  overflow: hidden; border-radius: inherit; background: #e5e7eb;
}
.pd-gallery-grid__item {
  position: relative; min-width: 0; min-height: 0; padding: 0;
  border: 0; overflow: hidden; cursor: pointer; background: #dbe1e8;
}
.pd-gallery-grid__item:first-child { grid-column: span 2; grid-row: span 2; }
.pd-gallery-grid__item img {
  width: 100%; height: 100%; display: block;
  object-fit: cover; object-position: center; transition: transform .2s ease;
}
.pd-gallery-grid__item:hover img { transform: scale(1.015); }
.pd-gallery-grid[data-count="1"] { grid-template-columns: 1fr; grid-template-rows: 1fr; }
.pd-gallery-grid[data-count="1"] .pd-gallery-grid__item:first-child { grid-column: auto; grid-row: auto; }
.pd-gallery-grid[data-count="2"] { grid-template-columns: 3fr 2fr; grid-template-rows: 1fr; }
.pd-gallery-grid[data-count="2"] .pd-gallery-grid__item:first-child { grid-column: auto; grid-row: auto; }
.pd-gallery-grid[data-count="3"] { grid-template-columns: 2fr 1fr; }
.pd-gallery-grid[data-count="3"] .pd-gallery-grid__item:first-child { grid-column: auto; grid-row: span 2; }
.pd-gallery-grid[data-count="4"] { grid-template-columns: 2fr 1fr 1fr; }
.pd-gallery-grid[data-count="4"] .pd-gallery-grid__item:first-child { grid-column: auto; grid-row: span 2; }
.pd-gallery-grid[data-count="4"] .pd-gallery-grid__item:last-child { grid-column: span 2; }
.pd-gallery-grid__all {
  position: absolute; inset-inline-end: 16px; bottom: 16px; z-index: 4;
  display: inline-flex; align-items: center; gap: 7px; padding: 10px 15px;
  border: 1px solid rgba(15,23,42,.18); border-radius: 10px;
  background: rgba(255,255,255,.94); color: #172033;
  box-shadow: 0 4px 16px rgba(15,23,42,.15);
  font: 600 .82rem/1 var(--fo-font); cursor: pointer;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.pd-gallery-grid__dots { display: none; }
.pd-gallery-grid__play,
.pd-lightbox__thumb-play {
  position: absolute; inset: 50% auto auto 50%; transform: translate(-50%, -50%);
  display: grid; place-items: center; width: 42px; height: 42px;
  border-radius: 50%; background: rgba(15,23,42,.72); color: #fff;
  font-size: 15px; line-height: 1; pointer-events: none;
}
html.is-gallery-open,
body.is-gallery-open { overflow: hidden; }

.pd-lightbox[open] { background: #f7f8fa; color: var(--fo-text); }
.pd-lightbox::backdrop { background: rgba(15,23,42,.42); backdrop-filter: none; -webkit-backdrop-filter: none; }
.pd-lightbox__inner { background: #f7f8fa; }
.pd-lightbox__bar {
  min-height: 68px; padding: 10px 24px; border-bottom: 1px solid var(--fo-border);
  background: rgba(255,255,255,.94); direction: rtl;
}
.pd-lightbox__heading { flex: 1; min-width: 0; text-align: center; }
.pd-lightbox__heading span { display: block; color: var(--fo-text-muted); font-size: .76rem; font-weight: 500; }
.pd-lightbox__heading strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .95rem; }
.pd-lightbox__bar-spacer { width: 44px; flex: 0 0 44px; }
.pd-lightbox__close { background: #fff; color: var(--fo-text); border: 1px solid var(--fo-border); box-shadow: 0 2px 10px rgba(15,23,42,.08); }
.pd-lightbox__body { padding: 20px clamp(14px,3vw,40px) 10px; gap: clamp(10px,2vw,24px); }
.pd-lightbox__stage { max-height: none; }
.pd-lightbox__stage img,
.pd-lightbox__stage video {
  width: auto; height: auto; max-width: min(980px,100%); max-height: calc(100dvh - 226px);
  object-fit: contain; border-radius: 12px; box-shadow: 0 8px 28px rgba(15,23,42,.12);
}
.pd-lightbox__nav { background: #fff; color: var(--fo-text); border: 1px solid var(--fo-border); box-shadow: 0 4px 16px rgba(15,23,42,.1); }
.pd-lightbox__footer { flex: 0 0 auto; padding: 0 24px 16px; }
.pd-lightbox__counter { display: block; margin-bottom: 10px; text-align: center; direction: ltr; font-size: .82rem; font-weight: 700; }
.pd-lightbox__thumbs {
  display: flex; justify-content: center; gap: 8px; max-width: 980px; margin: 0 auto;
  padding: 3px 2px 5px; overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-width: thin;
}
.pd-lightbox__thumb {
  position: relative; flex: 0 0 84px; width: 84px; height: 62px; padding: 2px;
  border: 2px solid transparent; border-radius: 9px; overflow: hidden;
  background: #fff; cursor: pointer; opacity: .65;
}
.pd-lightbox__thumb.is-active { border-color: var(--fo-orange); opacity: 1; }
.pd-lightbox__thumb img { width: 100%; height: 100%; display: block; object-fit: cover; border-radius: 5px; }
.pd-lightbox__thumb-play { width: 24px; height: 24px; font-size: 9px; }

@media (min-width: 961px) {
  .pd2 { width: 100%; max-width: 1280px; margin: 0 auto; }
  .pd-media--grid { padding: 16px 24px 0; }
  .pd-media--grid + .pd-cine__sheet {
    height: auto;
    min-height: 0;
    margin: 20px 24px 0;
    padding: 24px 28px 14px;
  }
}
@media (min-width: 1024px) and (max-width: 1440px) {
  .pd-media--grid .pd-media__viewport { height: 340px; }
}
@media (min-width: 1441px) and (max-width: 1600px) {
  .pd-media--grid .pd-media__viewport { height: 390px; }
}
@media (min-width: 768px) and (max-width: 960px) {
  .pd-media--grid .pd-media__viewport { height: clamp(300px, 48vw, 380px); min-height: 0; max-height: none; }
  .pd-gallery-grid { grid-template-columns: 2fr 1fr; grid-template-rows: repeat(3, minmax(0, 1fr)); }
  .pd-gallery-grid__item:first-child { grid-column: auto; grid-row: span 3; }
  .pd-gallery-grid__item:nth-child(n+5) { display: none; }
  .pd-gallery-grid[data-count="1"] { grid-template-columns: 1fr; grid-template-rows: 1fr; }
  .pd-gallery-grid[data-count="1"] .pd-gallery-grid__item:first-child { grid-row: auto; }
  .pd-gallery-grid[data-count="2"] { grid-template-columns: 3fr 2fr; grid-template-rows: 1fr; }
  .pd-gallery-grid[data-count="2"] .pd-gallery-grid__item:first-child { grid-row: auto; }
  .pd-gallery-grid[data-count="3"] { grid-template-columns: 2fr 1fr; grid-template-rows: repeat(2, minmax(0, 1fr)); }
  .pd-gallery-grid[data-count="3"] .pd-gallery-grid__item:first-child { grid-row: span 2; }
}
@media (max-width: 767px) {
  .pd-media--grid { padding: 12px 16px 0; }
  .pd-media--grid .pd-media__viewport {
    width: 100%; height: clamp(240px, 64vw, 280px);
    min-height: 0; max-height: none; border-radius: 12px;
  }
  .pd-media--grid .pd-cine__fab {
    width: 34px; height: 34px; background: rgba(255,255,255,.68); color: var(--fo-text-muted);
    box-shadow: 0 2px 10px rgba(15,23,42,.12); backdrop-filter: blur(6px); filter: none;
  }
  .pd-media--grid .pd-cine__fab .fo-icon { width: 18px; height: 18px; }
  .pd-gallery-grid { display: block; }
  .pd-gallery-grid__item { width: 100%; height: 100%; }
  .pd-gallery-grid__item:nth-child(n+2) { display: none; }
  .pd-gallery-grid__all { display: none; }
  .pd-gallery-grid__dots {
    position: absolute; left: 12px; right: 12px; bottom: 62px; z-index: 4;
    display: flex; justify-content: center; align-items: center; gap: 5px; pointer-events: none;
  }
  .pd-gallery-grid__dot {
    width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,.58);
    box-shadow: 0 1px 4px rgba(15,23,42,.28);
  }
  .pd-gallery-grid__dot.is-active { width: 8px; height: 8px; background: #fff; }
  .pd-lightbox__bar { min-height: 58px; padding: 7px 12px; }
  .pd-lightbox__heading strong { font-size: .86rem; }
  .pd-lightbox__body { position: relative; display: block; padding: 10px 6px 8px; }
  .pd-lightbox__nav { position: absolute; top: 50%; z-index: 3; width: 36px; height: 36px; transform: translateY(-50%); }
  .pd-lightbox__nav--prev { inset-inline-start: 10px; }
  .pd-lightbox__nav--next { inset-inline-end: 10px; }
  .pd-lightbox__stage { height: 100%; }
  .pd-lightbox__stage img,
  .pd-lightbox__stage video { max-width: 100%; max-height: calc(100dvh - 190px); border-radius: 8px; box-shadow: none; }
  .pd-lightbox__footer { padding: 0 10px 10px; }
  .pd-lightbox__counter { margin-bottom: 7px; }
  .pd-lightbox__thumbs { justify-content: flex-start; gap: 6px; }
  .pd-lightbox__thumb { flex-basis: 64px; width: 64px; height: 48px; border-radius: 7px; }
}
